The nsrarchive program archives files, including directories or entire filesystems, to the Backup server. You can use the nwadmin or nsrwatch programs to monitor the progress of an archive operation. Only users on the Administrator and Archive Users lists have the required privileges to run the nsrarchive program. Additionally, you can allow or disallow public archives through an option in the NSR (or Server) resource, which enables other clients to recover data archived from a particular client machine.
If you do not specify a path argument, the current directory is archived. The nsrarchive program archives all the files and subdirectories contained in a directory, but does not cross mount points or follow symbolic links. If the paths to be archived are mounted from a network fileserver, the nsrarchive program returns a message that instructs you to run the nsrarchive program on the remote machine or use the -L option.
The .nsr directive files encountered in each directory are read by default. The directive files contain instructions on how specific files should be archived (for example, compression).
Each file in the subdirectory structures specified by the path option is encapsulated in a Backup save stream. This stream of data is sent to a receiving process on the Backup server, which processes the data and adds entries to the client file index for each file in the stream. The data is then directed to long-term storage, either on the server or the designated storage node.
The following example describes the format and options available for the nsrarchive program:
nsrarchive [-BiLnpqvxVy] [-b pool] [-C clone-pool] [-f filename] [-G remove] [-N name] [-R name] [-s server] [-T annotation] [-W width] [path...] |
Use the -b pool option to specify a destination pool for the archive save sets. This option overrides the automatic pool selection typically used by the server. Archive data must be directed to volumes specifically labeled for a pool type of Archive. If you do not specify a pool, the Archive pool is selected by default.
Use the -B option to force an archive of all the connecting directory information, from root (/) to the point of invocation.
Use the -C clone-pool option to automatically generate a clone of the archived save sets to the specified clone pool. Cloned archive data must be directed to volumes specifically labeled for a pool type of Archive Clone. If you do not specify a clone pool, the Archive Clone pool is selected by default.
Use the -E option to estimate the amount of data that the archive generates, followed by the archive. Note that the estimate is generated from the inode information; therefore, the data is only read once.
Use the -f filename option to specify a file from which nsrarchive should read the default directives to apply to the archive data (refer to the nsr(5) man page for further information on directives). A value of - for filename causes the default directives to be read from standard input.
Use the -G remove option to groom (remove) files after they are successfully archived. If you specify cloning or verification options as well, the groom operation is not performed until those operations are completed successfully. Unless you also specify the -y option, you are prompted for removal of top-level directories. The nsrarchive program creates a temporary file that contains a list of all the files and directories to be groomed. The temporary file is placed in the directory specified by the TMPDIR environment variable, or in the /tmp directory if the environment variable is not defined.
Use the -i option to instruct the nsrarchive program to ignore any directive files encountered in the subdirectories that are archived.
Use the -L option to perform a local archive from the Backup client, even when the files are from a network file server.
Use the -n option to estimate the amount of data that is generated by the archive without performing the actual archive. This option is similar to the -E option, except that data is not saved to a volume after the estimate is completed.
Use the -N name option to instruct nsrarchive to use the symbolic name of the archive save set. By default, the first path argument is used as the value for name.
Use the -p option to instruct nsrarchive to exit with a status of 0. This Backup server uses this option to determine whether the client is properly installed.
Use the -q option to cause nsrarchive to run in quiet mode and display only summary information and error messages.
The -R name option should only be used by the nsralist program, which handles the execution of the archive requests. Updates to the named archive request resource occur when the Backup server specifies this option.
Use the -s server option to specify the machine to use as the Backup server. If you omit this option, the default machine considered is either the current machine (if it is a Backup server) or a machine with the logical name of nsrhost entered in the host table.
Use the -T annotation option to assign an arbitrary text string of 1024 characters or fewer to the archive save set. The string specified as annotation is used by the nsrretrieve program to browse the media database for archive save set entries to retrieve back to local disk. The annotation is a mandatory requirement for all archive save sets; if you omit this option, you are prompted for it before the process continues.
Use the -v option to cause nsrarchive to run in verbose mode.
Use the -V option to verify each archive save set.
Use the -W width option to specify the width that nsrarchive should use to format summary information to standard output. The default width used is 80.
Use the -x option to instruct nsrarchive to cross mount points.
Use the -y option to automatically enter an affirmative response to any queries generated by the nsrarchive program.