The savefs program is used by the savegrp program to probe a client for its filesystems and recent save times. Running savefs directly to perform a save is not recommended. However, you can safely invoke savefs manually with the -p option to probe the client and produce a preview report of the save sets (and levels) that a savegrp will back up. When probing, savefs does not actually save data, but instead produces a machine-parsable report that describes the layout of the client's filesystems. The -p option provides command line access to the same information you obtain with the Group Control>Preview feature available in the GUI version of the Administration program.
If a filesystem argument is not provided with the savefs command line, the filesystems listed in the Save Set attribute are probed. If the save set list consists of the keyword "All," then the filesystem tables (/etc/vfstab on Solaris)are examined to determine which filesystems to save. Only local, mounted filesystems are considered by the probe.
Metadevices within the Sun Solaris: Online DiskSuite are treated similar to independent disks. This approach allows each to be saved in its own session, assuming sufficient parallelism.
Care should be taken when the Clients resource explicitly lists the save sets, for two primary reasons. First, this list must be manually updated when new filesystems that need saving are added. Second, since savefs only stops at the end of a path or a mount point, if you list two save sets in the same filesystem and one is a subdirectory of the other, the subdirectory is saved twice.
You can specify filesystem arguments to limit the filesystem saves to only those specified, but the specified filesystems must appear on a Save Set list for this client (see the -F option).
The following example describes the format and options available for the savefs program:
savefs -p [options] [filesystem...] [-M filesystem...] |
The following lists the valid values for options:
[-BEFnpqRv] [-s server] [-N name] [-g group] [-l level | -C schedule] [-e expiration] [-f filename] [-W width] [-t date] [-T seconds] |
Use the -B option to force a save of all connecting directory information from root (/)down to the point of invocation. This option is used by savegrp, for example, when saving the server's bootstrap information.
Use the -C schedule option to specify the name of the schedule to use when automatically determining the save level. If this option is not specified, savefs uses the schedule named by the Clients resource for the specified filesystem.
Use the -e expiration option to specify the expiration date for the saved data (in nsr_getdate format). By default, no explicit expiration date is used.
Use the -E option to walk the filesystems specified and estimate the amount of data that the save will generate. Without this flag, the estimated size is zero. Note that this flag consumes an amount of time proportional to the number of files in each filesystem. This is because the entire directory is walked before any saving begins and walked again when actually saving the directory. The file data is only read from the disk the last time. In many cases, the overhead for using this flag is small and is well justified.
Use the -f filename flag to specify the file from which application-specific modules (ASMs) should take their directives. By default, these are taken from the Directives resource named by the Directive attribute in the Clients resource for each client.
Use the -F option to save every argument like a filesystem, even if the arguments are not listed in the filesystem tables or the Clients resource.
Use the -M option, as part of a probe, to signify that all subsequent filesystems should be probed for their ability to be migrated. This option is quietly ignored on systems that do not support file migration.
Use the -g group option to restrict the scope of the client to a particular group. If this option is not specified, save sets from all instances of the Clients resource for this client are used, regardless of the group. This value is also passed on to save, which uses it to select a specific media pool.
Use the -l level option to specify the level of save to perform. There are 12 levels: full, levels 1 though 9, incr, and skip. Full specifies that all files are to be saved. Incr specifies incremental saves in which only those files modified since the most recent save, at any level, are saved. Skip causes no files to be saved. Levels 1 through 9 save all files modified since any lower level save was performed. For example, if you did a Full on Monday, followed by a level 3 save on Tuesday, a subsequent level 3 save on Wednesday contains all files modified or added since the Monday Full save. If you do not specify a level, the save level is determined automatically from the Backup client's schedule. Using the history of previous saves maintained by nsrmmd on the Backup server, savefs accurately computes the time for the given level. When tapes are deleted, savefs uses media information on the server to automatically adjust the time computed for saves based on previous save levels.
Use the -n option to have savefs accurately estimate the amount of data generated, as described for -E, but not actually save any data.
Use the -N name option to assign the symbolic name for the save sets. By default, the first filesystem argument is used as the name.
Use the -p option to list the name of the filesystems, the level of save that would be performed, and the file modification time of files to be saved, but not actually perform the save. This information is gleaned from an operating system-specific file and the Schedules resource.
Use the -q option to run savefs in quite mode. Only summary information and error messages are displayed.
Use the -qq option to run savefs in really quiet mode, and display only error messages.
Use the -R option to cause savefs to echo a simple succeeded or failed message as it is completed. This option is automatically used by the savegrp program when it runs savefs.
Use the -s server option to specify the Backup server for savefs to use.
Use the -t date option to specify the date (in nsr_getdate format)for savefs to use as a base for calculating the level. If this option is not specified, the current time is used.
Use the -T seconds option to specify the inactivity timeout, in seconds, for savefs. If savefs detects that the local server has not made progress in the specified time, it concludes that the save program is not responding. A message is printed to stderr and savefs exits normally. This option should only be used on Backup server machines.
Use the -v option to run savefs in verbose mode. This option results in a lot of debug-style output. This option is automatically used by the savegrp program when it probes for the ability of the client's savefs to support multiple versions.
Use the -W width option to specify the width used for formatting output or notification messages. The default value for width is 80.