backup(1M) SYSTEM ADMINISTRATION COMMANDS backup(1M)
NAME
backup - initiate or control a system backup session
SYNOPSIS
backup -i [-t table] [-o name] [-m user] [-ne] [-s | -v] [-c
week:day | demand] backup [-a] [-t table] [-o name] [-m
user] [-ne] [-c week:day|demand] backup -S | -R | -C [-u
user | -A | -j jobid]
DESCRIPTION
Without options, the backup command performs all backup
operations specified for the current day and week of the
backup rotation in the backup register. This set of backup
operations is considered a single job and is assigned a
backup job id which can be used to control the progress of
the session. As backup operations are processed, their
status is tracked [See bkstatus(1M)]. As backup operations
are completed, they are recorded in the backup history log.
backup may only be executed by a user with superuser
privilege. A backup job can be controlled in three ways.
It can be canceled, suspended or resumed (after being
suspended).
Modes of Operator Intervention
Backup operations may require operator intervention to per-
form such tasks as inserting volumes into devices or con-
firming proper volume labels. backup provides three modes
of operator interaction.
backup with no options assumes that an operator is present,
but not at the terminal where the backup command was issued.
This mode sends a mail message to the operator. The mail
identifies the device requiring service and the volume
required. The operator reads the mail message, invokes the
bkoper command, responds to the prompts, and the backup
operation continues.
backup -i establishes interactive mode, which assumes that
an operator is present at the terminal where the backup com-
mand was issued. In this mode, bkoper is automatically
invoked at the terminal where the backup command was
entered. The operator responds to the prompts as they
arrive.
backup -a establishes automatic mode, which assumes that no
operator is available. In this mode, any backup operation
that requires operator intervention fails. Backups that can
be satisfied by mounted volume proceed.
Register Validations
A number of backup service databases must be consistent
before the backups listed in a backup register can be
1
backup(1M) SYSTEM ADMINISTRATION COMMANDS backup(1M)
performed. These consistencies can only be validated at the
time backup is initiated. If any of them fail, backup will
terminate. Invoking backup -ne performs the validation
checks in addition to displaying the set of backup opera-
tions to be performed. The validations are:
1. The backup method must be a default method or be an
executable file in /bkup/method .
2. The dependencies for an entry are all defined in the
register. Circular dependencies (eg., entry abc
depends on entry def; entry def depends on entry abc)
are allowed.
3. The device group for a destination must be defined in
the device group table, /dgroup.tab [See "Device
Management" ).
Options
-a Initiates all backup operations in automatic mode;
does not prompt an operator to service media.
-c week:day|demand
Selects from the backup register only those backup
operations for the specified week and day of the
backup rotation, instead of the current day and
week of the rotation. If demand is specified,
selects only those backup operations scheduled to
be performed on demand.
-e This option displays an estimate of the number of
volumes required to perform each backup operation.
-i Selects interactive operation
-j jobid Controls only the backup job identified by jobid.
jobid is a backup job id.
-m user Sends mail to the named user when all backup
operations for the backup job are complete.
-n Displays the set of backup operations that would
be performed but does not actually perform the
backup operations. The display is ordered accord-
ing to the dependencies and priorities specified
in the backup register.
-o name Initiates backup operations only on the named ori-
ginating object. name is an item in the following
form:
oname|odevice
2
backup(1M) SYSTEM ADMINISTRATION COMMANDS backup(1M)
-s Displays a "." for each 100 (512-byte) blocks
transferred to the destination device. The dots
are displayed while each backup operation is pro-
gressing.
-t table Initiates backup operations described in the
specified backup register instead of the default
register, etc/bkup/bkreg.tab . table is a backup
register.
-u user Controls backup jobs started by the named user
instead of those started by the user invoking the
command. user is a valid login id.
-v While each backup operation is progressing,
display the name of each file or directory as soon
as it has been transferred to the destination dev-
ice.
-A Controls backup jobs for all users instead of
those started by the user invoking the command.
-C Cancels backup jobs.
-R Resumes suspended backup jobs.
-S Suspends backup jobs.
DIAGNOSTICS
The exit codes for the backup command are the following:
0 = successful completion of the task
1 = one or more parameters to backup are invalid.
2 = an error has occurred which caused backup to fail to
complete all portions of its task.
EXAMPLES
Example 1:
backup -i -v -c 2:1 -m admin3
initiates those backups scheduled for Monday of the second week
in the rotation period instead of backups for the current day and
week. Performs the backup in interactive mode and displays on
standard output the name of each file, directory, file system
partition, or data partition as soon as it is transferred to the
destination device. When all backups are completed, sends mail
notification to the user with login id admin3.
Example 2:
backup -o /usr
initiates only those backups from the usr file system that is
mounted on the originating device /dev/rdsk/c1d0s2 and is labeled
usr.
3
backup(1M) SYSTEM ADMINISTRATION COMMANDS backup(1M)
Example 3:
backup -S
Suspends the backup jobs requested by the invoking user.
Example 4:
backup -R -j back-359
resumes the backup operations included in backup job id back-359.
FILES
/etc/bkup/method/*
/etc/bkup/bkreg.tab
/etc/device.tab
/etc/dgroup.tab
SEE ALSO
bkhistory(1M), bkoper(1M), bkreg(1M), bkstatus(1M)
4