fimage(1M) (System Administration Utilities) fimage(1M)
NAME
fimage - create, restore an image archive of a filesystem
SYNOPSIS
fimage -B [-dlmotuvAENS] bkjobid ofsname ofsdev ofslab descript
fimage -RC [-dlmotuvAENS] ofsname ofsdev refsname redev rsjobid
descript
fimage -RF [-dlmotuvAENS] ofsname ofsdev descript
rsjobid:uid:date:type:name
[:[rename]:[inode]] ...
DESCRIPTION
The fimage command is invoked as a child process by other shell
commands. The command name, fimage, is read either from the
bkhist.tab file or the bkreg -m command and option. The -B, -R, -F,
and -C options are passed to fimage by the shell commands backup,
restore, and urestore described below. The other options are passed
from the bkhist.tab file or the bkreg -p command and option. The
arguments are sent to fimage from various locations in the backup
service. fimage neither reads from standard-input nor writes to
standard-output or standard-error.
fimage -B is invoked as a child process by bkdaemon to perform an
image backup of the filesystem ofsname (the originating filesystem).
All files in ofsname are archived. The resulting backup is created
in the format described on volcopy(1M). The backup is recorded in
the backup history log, /etc/bkup/bkhist.tab.
fimage -RC and -RF are invoked as child processes by the rsoper
command to extract files from an image archive created by fimage -B.
The filesystem archive is assumed to be in the format described on
volcopy format.
If the -RC option is selected, the entire filesystem is restored.
If the -RF option is specified, only selected objects from the
archive are restored. Each 7-tuple, composed of
rsjobid:uid:date:type:name:rename:inode, specifies an object to be
restored from the filesystem archive. The 7-tuple objects come to
fimage from the rsstatus.tab file.
The arguments to fimage are defined as follows:
bkjobid
the job id assigned by backup. The method uses the bkjobid
when it creates history log and table-of-contents entries.
ofsname
the name of the file system that is to be backed up.
7/91 Page 1
fimage(1M) (System Administration Utilities) fimage(1M)
ofsdev the name of the block special device on which the file system
resides.
ofslab the volume name on the file system [see labelit(1M)].
descript
is a description for a destination device in the form:
dgroup:dname:dchar:dlabels
dgroup specifies a device group [see devgroup.tab(4)].
dname specifies a particular device name [see device.tab(4)].
dchars specifies characteristics associated with the device.
If specified, dchar overrides the defaults for the specified
device and group. [See device.tab(4) for a further
description of device characteristics.] dlabels specifies the
volume names for the media to be used for reading or writing
the archive.
refsname
if non-null, the name of the file system to be restored to
instead of ofsname. At least one of refsname and redev must
be null.
redev if non-null, the partition to be restored to instead of
ofsdev. At least one of refsname and redev must be null.
rsjobid
the restore jobid assigned by restore or urestore.
uid the real uid of the user who requested the object to be
restored. It must match the uid of the owner of the object at
the time the archive was made, or it must be the superuser
uid.
date the newest "last modification time" that is acceptable for a
restorable object. The object is restored from the archive
immediately older than this date. date is a hexadecimal
representation of the date and time provided by the time
system call [see time(2)].
type either F or D, indicating that the object is a file or a
directory, respectively.
name the name the object had in the file system archive.
rename the name that the object should be restored to (it may differ
from the name the object had in the file system archive). If
omitted, the object is restored to name.
inode the inode number of the object as it was stored in the file
system archive. [inode] is not used by ffile -R, and is
provided only for command-line compatibility with other
Page 2 7/91
fimage(1M) (System Administration Utilities) fimage(1M)
restoration methods.
Options
Some options are only significant during fimage -B invocations; they
are accepted but ignored during fimage -R invocations because the
command is invoked and options are specified automatically by
restore. These options are flagged with an asterisk (*).
d* Inhibits recording the archive in the backup history log.
l* Creates a long form of the backup history log that includes
a table-of-contents for the archive. This includes the
data used to generate a listing of each file in the archive
(like that produced by the ls -l command).
m* Mounts the originating filesystem read-only before starting
the backup and remounts it with its original permissions
after completing the backup. Cannot be used with root or
/usr filesystems.
o Permits the user to override media insertion requests [see
getvol(1M) and the description of the -o option].
t* Creates a table of contents for the backup on additional
media instead of in the backup history log.
u* Unmounts the originating filesystem before the backup is
begun. After the backup is complete, remounts the
filesystem under its original permission. This option
cannot be used with a root or usr filsystem. The -u option
overrides the -m option.
v* Validates the archive as it is written. A checksum is
computed as the archive is being written; as each medium is
completed, it is re-read and the checksum recomputed to
verify that each block is readable and correct. If either
check fails, the medium is considered unreadable. If -A
has been specified, the archiving operation fails;
otherwise, the operator is prompted to replace the failed
medium.
A Do not prompt the user for removable media operations
(automated operation).
E* Reports an estimate of media usage for the archive; then
performs the backup.
N* Reports an estimate of media usage for the archive; does
not perform the backup.
7/91 Page 3
fimage(1M) (System Administration Utilities) fimage(1M)
S Displays a period (.) for every 100 (512 byte) blocks
read-from or written-to the archive on the destination
device.
User Interactions
The connection between an archiving method and backup is more complex
than a simple fork/exec or pipe. The backup command is responsible
for all interactions with the user, either directly, or through
bkoper. Therefore, ffile neither reads from standard-input nor
writes to standard-output or standard-error. A method library must
be used [see libbrmeth(3)] to communicate reports (estimates,
filenames, periods, status, etc.) to backup.
DIAGNOSTICS
The exit codes for ffile are the following:
0 successful completion of the task
1 one or more parameters to ffile are invalid.
2 an error has occurred which caused ffile to fail to complete all
portions of its task.
FILES
/etc/bkup/bkhist.tab
lists the labels of all volumes that have been used
for backup operations.
/etc/bkup/rsstatus.tab
tracks the status ofall restore requests from users.
/etc/bkup/bklog logs errors generated by the backup methods and the
backup command
/etc/bkup/rslog logs errors generated by the restore methods and the
restore command
$TMP/filelist$$ temporarily stores a table of contents for a backup
archive.
SEE ALSO
backup(1M), bkoper(1M) device.tab(4), fdp(1), ffile(1), fimage(1),
getvol(1M), incfile(1), labelit(1M), libbrmeth(3), ls(1),
restore(1M), rsoper(1M), time(2), urestore(1), volcopy(1M)
Page 4 7/91