Next: Scripted Restoration, Previous: Backup Parameters, Up: Backups
The syntax for running a backup script is:
backup --level=level --time=time
The level option requests the dump level. Thus, to produce
a full dump, specify --level=0
(this is the default, so
--level may be omitted if its value is 0
).
1
The --time option determines when should the backup be run. Time may take three forms:
You should start a script with a tape or disk mounted. Once you
start a script, it prompts you for new tapes or disks as it
needs them. Media volumes don't have to correspond to archive
files — a multi-volume archive can be started in the middle of a
tape that already contains the end of another multi-volume archive.
The restore
script prompts for media by its archive volume,
so to avoid an error message you should keep track of which tape
(or disk) contains which volume of the archive (see Scripted Restoration).
The backup scripts write two files on the file system. The first is a record file in /etc/tar-backup/, which is used by the scripts to store and retrieve information about which files were dumped. This file is not meant to be read by humans, and should not be deleted by them. See Snapshot Files, for a more detailed explanation of this file.
The second file is a log file containing the names of the file systems and files dumped, what time the backup was made, and any error messages that were generated, as well as how much space was left in the media volume after the last volume of the archive was written. You should check this log file after every backup. The file name is log-mm-dd-yyyy-level-n, where mm-dd-yyyy represents current date, and n represents current dump level number.
The script also prints the name of each system being dumped to the standard output.
Following is the full list of options accepted by backup
script:
[1] For backward compatibility, the backup
will also
try to deduce the requested dump level from the name of the
script itself. If the name consists of a string ‘level-’
followed by a single decimal digit, that digit is taken as
the dump level number. Thus, you may create a link from backup
to level-1
and then run level-1
whenever you need to
create a level one dump.