Skip Navigation Links | |
Exit Print View | |
Sun Storage Archive Manager 5.3 Configuration and Administration Guide Sun QFS and Sun Storage Archive Manager 5.3 Information Library |
2. Configuring Storage Devices for Archiving
3. Performing Additional SAM-QFS Configuration
4. Creating Parameters Files for Network-Attached Automated Libraries
5. Checking the Drive Order in Libraries
7. Managing Automated Libraries and Manually Loaded Drives
8. Managing Vendor-Specific Libraries
11. Archive Directives (archiver.cmd)
archivemeta Directive: Controlling Whether Metadata Is Archived
archmax Directive: Controlling the Size of Archive Files
bufsize Directive: Setting the Archiver Buffer Size
drives Directive: Controlling the Number of Drives Used for Archiving
examine Directive: Controlling Archive Scans
interval Directive: Specifying an Archive Interval
logfile Directive: Specifying an Archiver Log File
notify Directive: Renaming the Event Notification Script
ovflmin Directive: Controlling Volume Overflow
scanlist_squash Directive: Controlling Scanlist Consolidation
setarchdone Directive: Controlling the Setting of the archdone Flag
fs Directive: Specifying the File System
Global Directives as File System Directives
-release Directive: Releasing Disk Space After Archiving
-norelease Directive: Delaying Disk Space Release
Using -release and -norelease Together
Specifying More Than One Copy for Metadata
12. Archive Set Directives (archiver.cmd)
Global directives control the overall archiver operation and enable you to optimize operations for your site. You can add global directives directly to the archiver.cmd file, or you can specify them using the SAM-QFS Manager software. For more information about using SAM-QFS Manager to set global directives, see the SAM-QFS Manager online help.
Specify the global directives before you specify any file system directives (fs= directives). The archiver issues a message if it detects a global directive located after an fs= directive.
You can identify a global directive in the archiver.cmd file by either the presence of the equal sign (=) in the second field or the absence of additional fields. The following global directives are supported:
archivemeta Directive: Controlling Whether Metadata Is Archived
drives Directive: Controlling the Number of Drives Used for Archiving
scanlist_squash Directive: Controlling Scanlist Consolidation
setarchdone Directive: Controlling the Setting of the archdone Flag
The archivemeta directive controls whether file system metadata is archived. If files are often moved around and there are frequent changes to the directory structures in a file system, archive the file system metadata. In contrast, if the directory structures are very stable, you can disable metadata archiving and reduce the actions performed by removable media drives. By default, metadata is not archived.
This directive has the following format:
archivemeta=state
For state, specify either on or off. The default is off.
The archiving process for metadata depends on whether you are using a Version 1 or a Version 2 superblock, as follows:
For Version 1 file systems, the archiver archives directories, removable media files, segment index inodes, and symbolic links as metadata.
For Version 2 file systems, the archiver archives directories and segment index inodes as metadata. Removable media files and symbolic links are stored in inodes rather than in data blocks. They are not archived. Symbolic links are archived as data.
The archmax directive specifies the maximum size of an archive file. User files are combined to form the archive file. After the target-size value is met, no more user files are added to the archive file. Large user files are written in a single archive file.
To change the defaults, use the following directive:
archmax=media target-size
|
Setting large or small sizes for archive files has advantages and disadvantages. For example, if you are archiving to tape and archmax is set to a large size, the tape drive stops and starts less often. However, when writing large archive files, a premature end-of-tape causes a large amount of tape to be wasted. As a best practice, do not set the archmax directive to be more than 5 percent of the media capacity.
The archmax directive can also be set for an individual archive set.
Note - The archmax directive is not a valid directive for archive sets that are archived to the StorageTek 5800 media type.
By default, a file being archived is copied to archive media using a memory buffer. You can use the bufsize directive to specify a nondefault buffer size and, optionally, to lock the buffer. These actions can improve performance. You can experiment with different buffer-size values. This directive has the following format:
bufsize=media buffer-size [lock]
|
You can specify a buffer size and a lock for each archive set basis by using the archive set copy parameters, -bufsize and -lock. For more information, see Archive Set Copy Parameters.
By default, the archiver uses all of the drives in an automated library for archiving. To limit the number of drives used, use the drives directive. This directive has the following format:
drives=auto-lib count
|
Also see the descriptions of the archive set copy parameters -drivemax, -drivemin, and -drives in Specifying the Number of Drives for an Archive Request: -drivemax, -drivemin, and -drives
New files and files that have changed are candidates for archiving. The archiver finds such files through one of the following methods:
Continuous archiving, in which the archiver works with the file system to detect file changes immediately
Scan archiving, in which the archiver scans the file system periodically for files that need to have changed.
The example directive for scan archiving has the following format:
examine=method
|
The archiver runs periodically to examine the status of all mounted archived-enabled file systems. The timing is controlled by the archive interval, which is the time between scan operations on each file system. To change the time, use the interval directive.
The interval directive initiates full scans only when continuous archiving is not set and no startage, startsize, or startcount parameters have been specified. If continuous archiving is set (examine=noscan), the interval directive acts as the default startage value. This directive has the following format:
interval=time
For time, specify the amount of time you want between scan operations on a file system. By default, time is interpreted in seconds and has a value of 600, which is 10 minutes. You can specify a different unit of time, such as minutes or hours.
If the archiver receives the samu utility's :arrun command, it begins scanning all file systems immediately. If the examine=scan directive is also specified in the archiver.cmd file, a scan is performed after :arrun or :arscan is issued.
If the hwm_archive mount option is set for the file system, the archive interval can be shortened automatically. This mount option specifies that the archiver commences its scan when the file system is filling up and the high-water mark is crossed. The high=percent mount option sets the high-water mark for the file system.
For more information about specifying the archive interval, see archiver.cmd(4) in Sun QFS and Sun Storage Archive Manager Reference Manual. For more information on setting mount options, see mount_samfs(1M) in Sun QFS and Sun Storage Archive Manager Reference Manual.
The archiver can produce a log file that contains information about each file that is archived, re-archived, or automatically unarchived. The log file is a continuous record of archival action. By default, this file is not produced. To specify a log file, use the logfile directive. This directive has the following format:
logfile=pathname
For pathname, specify the absolute path and name of the log file. The logfile directive can also be set for an individual file system.
Example 11-1 Backing Up an Archiver Log File
Assume that you want to back up the archiver log file every day by copying the previous day's log file to an alternate location. Be sure to perform the copy operation when the archiver log file is closed, not while it is open for a write operation.
Use the mv command to move the archiver log file within a UNIX file system.
This gives any sam-arfind or sam-arcopy operations time to finish writing to the archiver log file.
Use the mv command to move the previous day's archiver log file to the file system.
The notify directive sets the name of the archiver's event notification script file. This directive has the following format:
notify=filename
For filename, specify the name of the file containing the archiver event notification script or the full path to this file. The default file name is /etc/opt/SUNWsamfs/scripts/archiver.sh.
The archiver executes this script to process various events in a site-specific manner. The script is called with one of the following keywords for the first argument: emerg, alert, crit, err, warning, notice, info, and debug.
Additional arguments are described in the default script. For more information, see archiver.sh(1M) in Sun QFS and Sun Storage Archive Manager Reference Manual.
When volume overflow is enabled, the archiver can create archived files that span multiple volumes. When a file size exceeds the specified minimum size, the archiver writes the remaining portion of this file to another volume of the same type. The portion of the file written to each volume is called a section.
The sls command lists the archive copy, showing each section of the file on each volume.
Note - Use volume overflow with caution after assessing its effect on your site. Disaster recovery and recycling are much more difficult with files that span volumes.
The archiver controls volume overflow through the ovflmin directive. By default, volume overflow is disabled. To enable volume overflow, use the ovflmin directive in the archiver.cmd file. This directive has the following format:
ovflmin = media minimum-file-size
|
The ovflmin directive can also be set for an individual archive set.
Volume overflow files do not generate checksums. For more information on using checksums, see ssum(1) in Sun QFS and Sun Storage Archive Manager Reference Manual.
A site has many files with a significant mo media cartridge fraction length (such as 25 percent). These files leave unused space on each volume. To use volume space efficiently, set ovflmin for mo media to a size slightly smaller than the size of the smallest file. The following directive sets the value to 150 megabytes:
ovflmin=mo 150m
In this example, two volumes are loaded for archiving and staging the files because each file overflows onto another volume.
The following example shows the archiver log file when volume overflow is enabled. The file file50 spans three volumes with VSNs of DLT000, DLT001, and DLT005. The position on the volume and the size of each section is indicated in the seventh and tenth fields respectively (7eed4.1 and 477609472 for the first volume).
For a complete description of the archiver log entry, see archiver(1M) in Sun QFS and Sun Storage Archive Manager Reference Manual.
A 97/01/13 16:03:29 lt DLT000 big.1 7eed4.1 samfs1 13.7 477609472 00 big/file50 0 0 A 97/01/13 16:03:29 lt DLT001 big.1 7fb80.0 samfs1 13.7 516407296 01 big/file50 0 1 A 97/01/13 16:03:29 lt DLT005 big.1 7eb05.0 samfs1 13.7 505983404 02 big/file50 0 2
This portion of the archiver log file matches the sls -D output for file file50, as shown in the following example.
# sls -D file50 file50: mode: -rw-rw---- links: 1 owner: gmm group: sam length: 1500000172 admin id: 7 inode: 1407.5 offline; archdone; stage -n copy1: ---- Jan 13 15:55 lt section 0: 477609472 7eed4.1 DLT000 section 1: 516407296 7fb80.0 DLT001 section 2: 505983404 7eb05.0 DLT005 access: Jan 13 17:08 modification: Jan 10 18:03 changed: Jan 10 18:12 attributes: Jan 13 16:34 creation: Jan 10 18:03 residence: Jan 13 17:08
The scanlist_squash parameter controls scanlist consolidation. The default setting is off. This parameter can be either global or file system-specific.
When this option is enabled, the scan list entries for files in two or more subdirectories with the same parent directory that need to be scanned by sam-arfind at a much later time are consolidated. These directories are combined upwards to the common parent, which results in a deep recursive scan of many subdirectories. This consolidation can cause a severe performance penalty if archiving on a file system that has a large number of changes to many subdirectories.
The setarchdone parameter is a global directive that controls the setting of the archdone flag when the file is examined by sam-arfind. This directive has the following format:
setarchdone=on|off
When all archive copies for a file have been made, the archdone flag is set for that file to indicate that no further archive action is required. During directory scans, the archdone flag is also set for files that will never be archived. Because evaluating whether a file will ever be archived can affect performance, the setarchdone directive gives you control over this activity. This directive controls the setting of the archdone flag only on files that will never be archived. It does not affect the setting of the archdone flag after archive copies are made.
The default setting for the directive is off if the examine directive is set to scandirs or noscan.
The wait directive causes the archiver to wait for a start signal from samu(1M) or SAM-QFS Manager. By default, the archiver begins archiving when started by sam-fsd(1M). This directive has the following format:
wait
The wait directive can also be set for an individual file system.