UASM(8) Legato NetWorker 3.0 UASM(8)
NAME
uasm - NetWorker module for saving and recovering UNIX filesystems
SYNOPSIS
uasm -s [-binvx] [ -t date ] [ -f proto ] [ -p ppath ] file...
uasm -r [-nv] [ -i {nNyYrR} ] [ -m src=dst ] -z suffix ] [ file ]...
DESCRIPTION
Uasm is the default UNIX filesystem ASM (Application Specific Mod
ule). It is called directly by save(8) and recover(8). This
description of uasm applies to all ASM's. For clarity only uasm is
mentioned.
Uasm has two modes, saving and recovering. When saving, uasm will
walk UNIX directory trees and generate an XDR stream, see
nsrdata(5), on its stdout representing the files and organization of
the directory tree. When recovering, uasm reads an XDR stream on its
stdin and creates the corresponding directories and files.
While saving, uasm's behavior may be controlled by directive files.
The directive files control how descendent directories are searched;
which files are ignored; how the XDR stream is generated; and how to
process subsequent directive files, see nsr(5). When walking a
directory tree, symbolic links are never followed.
The following table lists the properties of the ASM's supplied with
NetWorker.
c c c c c c l c c c c c. ASM
name internal walking filtering auto-applied skip X
holey X X X always X X uasm X
logasm X mailasm X swapasm X
xlateasm X X compressasm X X
nsrmmdbasm X nsrindexasm X
Internal ASM's are not separate programs, but are contained within
all ASM's. External ASM's are separate programs, and are invoked as
needed. For security reasons, external ASM names must end in asm and
be located in the same directory as the originally invoked program
(typically save or recover). Walking ASM's traverse directory trees.
The skip ASM does not walk.
Generally, a file is processed by just one ASM. While saving, for
example, an ASM reads a file and generates the appropriate XDR
stream. When a different ASM is needed to process a file, the new
ASM is invoked and it generates the XDR stream. When a filtering ASM
is traversing a directory tree and invokes another ASM, that ASM's
XDR stream is processed by the filtering ASM. Hence, while using
compressasm to save a directory tree, the mailasm can still be used
to process the mail files correctly.
Auto-applied ASM's are used under certain conditions, and do not need
to be specifically mentioned in a directive file. For example, when
a large file only has a small number of disk blocks allocated, the
Licensed material--property of copyright holder(s) 1
UASM(8) Legato NetWorker 3.0 UASM(8)
holey ASM is automatically invoked to process the file. Auto-applied
ASM's are not used when a file's name matches an explicit directive.
The skip ASM skips files and directories. The holey ASM checks for
blocks of zeros (holes) when saving and recovering files. The always
ASM always saves, it ignores the file's modification time. The
logasm does not complain if a file changes during the save and can be
used for log files and other similar files where a file changing dur
ing a save is not worth noting. The mailasm uses mail style file
locking and maintains a file's access time, thus preserving most mail
handlers' new mail has arrived flag. The swapasm doesn't save any
actual file data and on recovery recreates a zero-filled file of the
correct size; this is useful for diskless clients' swap files. The
xlateasm translates the file data; it does not change directory data.
The compressasm uses the Lempel-Ziv compression algorithm to compress
file data, directories are not compressed. The nsrmmdbasm is used to
process NetWorker's media index. The nsrindexasm is used to process
NetWorker's client file indexes.
OPTIONS
All ASM's accept the options described below. These options are gen
erally referred to as the standard-asm-arguments. ASM's may also
have additional options. A particular ASM's additional options must
be capital letters.
Either -s (saving) or -r (recovering) must be specified, and must
precede any other options. When saving, at least one file argument
must be specified. File may be either a directory or file name.
The following options are valid when saving or recovering:
-n Perform a dry run. When saving, do everything except produce
the XDR stream. When recovering, consume the input XDR
stream, but do not actually create any directories or files.
-v Turn on verbose mode. The current ASM, its arguments, and the
file it is processing are displayed. When a filtering ASM
operating in filtering mode (that is processing another ASM's
XDR stream) modifies the stream, its name, arguments and the
current file are displayed within square brackets.
When saving, the following options may also be used:
-b Produce a byte count. This option is like the -n
option, but byte count mode will estimate the amount of
data that would be produced instead of actually reading
file data so it is faster but less accurate than the -n
option. Byte count mode produces three numbers: the
number of records, i.e. files and directories; the num
ber of bytes of header information; and the number of
bytes of file data. Byte count mode does not produce a
save stream so its outout cannot be used as input to
another asm in recover mode.
Licensed material--property of copyright holder(s) 2
UASM(8) Legato NetWorker 3.0 UASM(8)
-i Ignore all save directives from .nsr directive files
found in the directory tree.
-f proto
Specifies the location of a .nsr directive file to
interpret before processing any files, see nsr(5).
Within the directive file specified by proto, <<path>>
directives must resolve to files within the directory
tree being processed, otherwise their subsequent direc
tives will be ignored.
-p ppath
This string is prepended to each file's name as it is
processed.
-t date
The date (in getdate(3) format) after which files must
have been modified before they will be saved.
-x Cross filesystem boundaries. Normally, filesystem
boundaries are not crossed during walking. Symbolic
links are never followed.
When recovering, the following options may also be used:
-i {nNyYrR}
Specifies the initial default overwrite response. Only
one letter may be used. When the name of the file
being recovered conflicts with an existing file, the
user is prompted for overwrite permission. The default
response, selected by just pressing return, is dis
played within square brackets. Unless otherwise speci
fied with the -i option, `n' is the initial default
overwrite response. Each time a response other than
the default is selected, the new response becomes the
default. When either N, R, or Y is specified, no
prompting is done, and each subsequent conflict is
resolved as if the corresponding lower case letter had
been selected.
The valid overwrite responses and their meanings are:
n Do not recover the current file.
N Do not recover any files with conflict
ing names.
y Overwrite the existing file with the
recovered file.
Y Overwrite files with conflicting names.
r Rename the conflicting files. A dot, .,
and a suffix are appended to the
Licensed material--property of copyright holder(s) 3
UASM(8) Legato NetWorker 3.0 UASM(8)
recovered file's name. If a conflict
still exists, the user will be prompted
again.
R Rename conflicting files by appending a
dot, ., and a suffix.
-m src=dst
This option will map the file names that will be cre
ated. Any files that have start exactly with src will
be mapped to have the path of dst replacing the leading
src component of the path name. This option is useful
if you which to perform relocation of the recovered
files that were saved using absolute pathnames into an
alternate directory (e.g., -m /usr/etc=.).
-z suffix
Specifies the suffix to append when renaming conflict
ing files. The default suffix is R.
file Used to restrict the files being recovered. Only files
with prefixes matching file will be recovered. This
checking is performed before any potential name mapping
is done with the -m specification. When file is not
specified, no checking is done.
EXAMPLES
Copying files
To copy all of the files in the current directory to tar
getdir, use:
uasm -s . | (cd targetdir; uasm -rv)
This will preserve ownership, time, and the other unix
attributes. Only the data in holey files will be copied, the
holes will not be.
Copying a file tree to an archive directory
To copy the file tree under the directory here to archive and
overwrite any files with conflicting names, use:
cd here
uasm -s . | (cd archive; uasm -r -iY)
Note that we cd to here first and give the first uasm doing
the save a relative path so that the second uasm doing the
recover will recreate the file tree under archive.
Another way to get the same effect is to use the -m option on
the second uasm doing the recover to explicitly map the path
names.
uasm -s here | uasm -r -iY -m here=archive
FILES
.nsr Save directive files located throughout the filesystem.
SEE ALSO
compressasm(8), logasm(8), mailasm(8), nsr(5), nsrindexasm(8),
Licensed material--property of copyright holder(s) 4
UASM(8) Legato NetWorker 3.0 UASM(8)
nsrmmdbasm(8), nsrdata(5), recover(8), save(8), scanner(8), swa
pasm(8), XDR(3N), xlateasm(8).
Licensed material--property of copyright holder(s) 5