NAME
|
fossil – archival file server |
SYNOPSIS
|
fossil/fossil [ –Dt ] [ –c cmd ]... [ –f file ] fossil/flchk [ –f ] [ –c ncache ] [ –h host ] file fossil/flfmt [ –y ] [ –b blocksize ] [ –h host ] [ –l label ] [ –v score ] file fossil/conf [ –w ] file [ config ]
fossil/last file |
DESCRIPTION
|
Fossil will become the main file system for Plan 9. Unlike the
Plan 9 file servers of old, fossil is a collection of user–space
programs that run on a standard Plan 9 kernel. The name of the
main fossil file server at Murray Hill is yoshimi. The Plan 9
distribution file server, sources, is also a fossil server. Fossil is structured as a magnetic disk write buffer optionally backed by a Venti server for archival storage. It serves the Plan 9 protocol via TCP. A fossil file server conventionally presents three trees in the root directory of each file system: active, archive, and snapshot. /active is the root of a conventional file system whose blocks are stored in a disk file. In a typical configuration, the file server periodically marks the entire file system copy–on–write, effectively taking a snapshot of the file system at that moment. This snapshot is made available in a name created from the date and time of the snapshot: /snapshot/yyyy/mmdd/hhmm where yyyy is the full year, mm is the month number, dd is the day number, hh is the hour, and mm is the minute. The snapshots in /snapshot are ephemeral: eventually they are deleted to reclaim the disk space they occupy. Long–lasting snapshots stored on a Venti server are kept in /archive and also named from the date (though not the time) of the snapshot: /archive/yyyy/mmdds, where yyyy, mm, and dd are year, month, and day as before, and s is a sequence number if more than one archival snapshot is done in a day. For the first snapshot, s is null. For the subsequent snapshots, s is .1, .2, .3, etc. The root of the main file system that is frozen for the first archival snapshot of December 15, 2002 will be named /archive/2002/1215/. The attach name used in mount (see bind(1), bind(2) and attach(5)) selects a file system to be served and optionally a subtree, in the format fs[/dir]. An empty attach name selects main/active. Fossil normally requires all users except none to provide authentication tickets on each attach(5). To keep just anyone from connecting, none is only allowed to attach after another user has successfully attached on the same connection. The other user effectively acts as a chaperone for none. Authentication can be disabled using the –A flag to open or srv (see fossilcons(8)). The groups called noworld and write are special on the file server. Any user belonging to noworld has attenuated access privileges. Specifically, when checking such a user's access to files, the file's permission bits are first ANDed with 0770 for normal files and 0771 for directories. The effect is to deny world access permissions to noworld users, except when walking into directories. If the write group exists, then the file system appears read–only to users not in the group. This is used to make the Plan 9 distribution file server (sources.cs.bell–labs.com) readable by the world but writable only to the developers. Fossil starts a new instance of the fossil file server. It is configured mainly through console commands, documented in fossilcons(8).
The options are:
Flchk does not modify the file system, so it is safe to run concurrently with fossil, though in this case the list of unreachable blocks and any inconsistencies involving the active file system should be taken with a grain of salt.
The options are:
–y Yes mode. By default, flfmt will prompt for confirmation before formatting a file that already contains a fossil file system, and before formatting a file that is not served directly by a kernel device. If the –y flag is given, no such checks are made. –b blocksize
Last prints the vac score that resulted after the most recent
archival snapshot of the fossil in file. |
EXAMPLES
Place the root of the archive file system on /n/dump and show
the modified times of the MIPS C compiler over all dumps in December
2002:
Perhaps because the disk has been corrupted or replaced, format
a new file system using the last archive score printed on the
console:
Blindly accept the changes prescribed by flchk (not recommended):
|
SOURCE
|
/sys/src/cmd/fossil |
SEE ALSO
|
yesterday(1), fs(3), fs(4), srv(4), fossilcons(8), venti(8) |
BUGS
|
It is likely that the disk format (but not the Venti format) will
change in the future, to make the disk a full cache rather than
just a write buffer. Changing to the new format will require reformatting
the disk as in the example above, but note that this will preserve
most of the file system (all but /snapshot) with little
effort. |