NAME
|
gefs – file server maintenance |
SYNOPSIS
|
mount /srv/gefs /adm adm /adm/ctl /adm/status /adm/users /srv/gefs.cmd |
DESCRIPTION
|
Gefs(4) provides a number of special files for administration
in the adm snapshot (traditionally mounted in /adm), as well as
an interactive console on /srv/gefs.cmd. |
SNAPSHOTS
|
Snapshots are views of a filesystem hierarchy within a branching
timeline. The branch may have a single mutable snapshot which
will update the branch when written to. All other snapshots are
immutable and frozen in time. Each branch evolves independently
of all other branches, and is referred to by the label of its
head snapshot. All branches are forked from an empty snapshot.
Any snapshot is mountable by label via mount(1)'s attach spec. When the attach spec starts with the % sigil, that snapshot is mounted in permissive mode. This allows the mounting user to bypass normal file system permission checks. In order to mount a snapshot in permissive mode, the mounting user must be in the adm group.
There are several attach names that are reserved for the file
system's internal use. All except main may not be removed by the
user.
main:This branch is mounted by default if a mount spec is not provided. It may be deleted, created, and freely modified.
All snapshots are allocated from the same storage pool, and therefore
share space. |
ADM FILES
|
Gefs supports independent snapshots in the same file system. As
a result, global configuration needs to be separated from snapshots.
The global configuration resides in a well known snapshot called
adm. The adm snapshot would conventionally be mounted in /adm. It contains the users(6) file. The users file is read at file system startup, or when the users command is run on the console. If the users file is malformed at file system start, then the file system will refuse to initialize. Permissive mode will allow the file system to fall back to a default users table. It will also allow any user to mount the adm snapshot: this can help recover from disasters.
The default table looks like this:
The /adm/status file contains a read–only view of the configuration of the filesystem as well as a list of snapshots.
The control file, located at /adm/ctl, takes the following commands:
halt Sync all IO to disk and exit the file system. usereserve [ 0 | 1 ]
fork base new Create a new fork from base, giving it the name new. The new label will be the label used to mutate the new branch. sync Write dirty blocks in memory to the disk. The write will not return until all data that was in flight when the sync was issued has been written to disk. users Attempt to reload the user ids from /adm/users. If the user table fails to reload, the write will error. |
CONSOLE
|
The console at /srv/gefs.cmd handles the following commands: checkPerforms the same checks as the ctl file, but shows results on the cmd console, instead of on stdout. halt Sync all IO to disk and exits the file system. While the syncing occurs, the file system does not allow new writes. help Print a summary of the available commands. This table includes additional debug commands that are subject to change, and are intentionally undocumented. |
EXAMPLES
To show current disk usage:
|
BUGS
|
Currently, it's not possible to change the mutability of a snapshot.
Instead, a new label needs to be created.
|
SEE ALSO
|
gefs(4) |