JavaScript is required to for searching.
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
search filter icon
search icon

Document Information

Preface

1.  About SAM-QFS

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

6.  Populating the Catalog

7.  Managing Automated Libraries and Manually Loaded Drives

8.  Managing Vendor-Specific Libraries

9.  About Archiving

10.  Configuring the Archiver

11.  Archive Directives (archiver.cmd)

12.  Archive Set Directives (archiver.cmd)

13.  Data Integrity Validation in SAM-QFS

14.  About Releasing

15.  Configuring the Stager

16.  Configuring the Recycler

17.  Advanced SAM-QFS Topics

Using Device Logging

When to Use the Device Log

How to Enable the Device Log by Using the samset Command

How to Enable the Device Log by Editing the defaults.conf File

Using Removable Media Files

Creating a Removable Media or Volume Overflow File

Using Segmented Files

Archiving Segmented File

Using System Error Facility Reporting

How to Enable SEF Reporting

How to Generate SEF Report Output

Managing the SEF Log File

SEF sysevent Functionality

How to Create the SEF sysevent Handler

18.  Using the Sun SAM-Remote Software

Using System Error Facility Reporting

The system error facility (SEF) reporting system captures log sense data from tape devices in an automated library, writes it to a log file, and translates it into human-readable form. This utility consists of the following:

SEF is not supported for stand-alone tape drives. SEF reporting is most useful for older SCSI-2 devices that do not support the tapealert functionality. For more information, see tapealert(1M) in Sun QFS and Sun Storage Archive Manager Reference Manual.

How to Enable SEF Reporting

  1. Become superuser.
  2. Issue the mkdir command to create the SEF directory.

    For example:

    # mkdir /var/opt/SUNWsamfs/sef
  3. Use the touch command to create the log file.

    You can enable SEF reporting any time after installation by creating the sefdata log file. Initially, the SEF log file must be empty. The following command shows the SEF log file being created in the default location.

    # touch /var/opt/SUNWsamfs/sef/sefdata
  4. Use the samd stop and samd start commands to initialize SEF reporting.
    # samd stop
    # samd config
    # samd start
    1. Wait until the tape drives are idle. Then unload the tape drives.

      For eq, specify the Equipment Number of the drive.

    2. Use the samd unload command to unload all removable media:
      # samd unload eq
  5. Repeat steps 1 through 4 for each tape drive.

    SEF data is appended to the log file as it is generated.


    Note - SEF reporting is enabled as long as the sefdata log file exists. To disable SEF reporting, rename or remove this file.


    You can configure SEF reporting to log and read log sense data from an alternate location. For more information about reading log sense data from an alternate location, see sefreport(1M) in Sun QFS and Sun Storage Archive Manager Reference Manual.

How to Generate SEF Report Output

The SEF report output consists of header lines and log sense data.

  1. Verify that /opt/SUNWsamfs/sbin is in your command path.
  2. Use the sefreport command to generate SEF output.

    The following are the most commonly used options with the sefreport command:

    • The -d option. The -d option generates additional device information. It writes an additional header line that contains the equipment ordinal and path name to the device for each record. This process makes searching for and locating SEF records that pertain to a specific device easier.

    • The -v option or the -t option. Do not specify the -t and -v options on the same command line. They are mutually exclusive.

      • The -v option generates information in verbose mode. It appends information regarding the equipment ordinal, page code, and VSN to each line of a record. This method enables selecting only those lines that pertain to a specific device or a specific volume.

      • The -t option generates log sense output with text descriptions. For each line of log sense data output, the report includes an additional string containing the equipment ordinal, page code, VSN, and parameter code description.

        For example, the following SEF command reads the SEF log file from the default location, writes the device number and path name for each device, and generates output:

        # sefreport -d /var/opt/SUNWsamfs/sef/sefdata > sef.output

Example 17-3 Content of sef.output File

Record no. 1
Mon Mar 26 11:17:48 2001 STK 9840 1.25 VSN 002981
Eq no. 32 Dev name /dev/rmt/1cbn
PAGE CODE 2
param code control param value
00h 74h 0x0
01h 74h 0x0
02h 74h 0x0
03h 74h 0x0
04h 74h 0x0
05h 74h 0x40050
06h 74h 0x0
PAGE CODE 3
param code control param value
00h 74h 0x0
01h 74h 0x0
02h 74h 0x0
03h 74h 0x0
04h 74h 0x0
05h 74h 0x140
06h 74h 0x0
PAGE CODE 6
param code control param value
00h 74h 0x0
Record no. 2
Mon Mar 26 11:30:06 2001 STK 9840 1.25 VSN 002999
Eq no. 31 Dev name /dev/rmt/0cbn
PAGE CODE 2
param code control param value
00h 74h 0x0
01h 74h 0x0
02h 74h 0x0
03h 74h 0x0
04h 74h 0x0
05h 74h 0x1400a0
06h 74h 0x0

PAGE CODE 3
param code control param value
00h 74h 0x0
01h 74h 0x0
02h 74h 0x0

03h 74h 0x0
04h 74h 0x0
05h 74h 0x190
06h 74h 0x0
PAGE CODE 6
param code control param value
00h 74h 0x0
Record no. 3
Mon Mar 26 11:30:23 2001 STK 9840 1.25 VSN 002981
Eq no. 32 Dev name /dev/rmt/1cbn
PAGE CODE 2
param code control param value
00h 74h 0x0
01h 74h 0x0
02h 74h 0x0
03h 74h 0x0
04h 74h 0x0
05h 74h 0x18400f0
06h 74h 0x0

PAGE CODE 3
param code control param value
00h 74h 0x0
01h 74h 0x0
02h 74h 0x0
03h 74h 0x0
04h 74h 0x0
05h 74h 0x1e0
06h 74h 0x0
PAGE CODE 6
param code control param value
00h 74h 0x0
.
.
.

For more information about the SEF log file, including its content and format, see sefdata(4) in Sun QFS and Sun Storage Archive Manager Reference Manual. For more information about optional SEF report formats, see sefreport(1M) in Sun QFS and Sun Storage Archive Manager Reference Manual.

Managing the SEF Log File

You manage the SEF log file just as you manage any other SAM-QFS log file. You can run a cron job periodically to save the current log file to another location, to delete old SEF files, to create new (empty) SEF files, or to perform other file management tasks.

You can also use the log_rotate.sh utility to rotate this log file.

For more information about tools for managing the SEF log file, see the cron(1M) or log_rotate.sh(1M) man pages.

SEF sysevent Functionality

In addition to using the SEF log file, you can use the Oracle Solaris sysevent feature to obtain tape drive SCSI log sense error counter pages 2 and 3 for media analysis. By default, the SEF sysevent feature is enabled and set to poll once before unload. The SEF sysevent behavior is controlled by defaults.conf and samset.

In the defaults.conf file, the sef parameter can be used to enable SEF sysevent feature by equipment ordinal, or to specify the log sense polling frequency. For more information, see defaults.conf(4) in Sun QFS and Sun Storage Archive Manager Reference Manual.

How to Create the SEF sysevent Handler

  1. Create a /var/tmp/xx file.

    For example:

    # !/bin/ksh
    echo "$@" >> /var/tmp/xx.dat
    exit 0
  2. Make the /var/tmp/xx file executable.
    # chmod a+rwx /var/tmp/xx

    Add the SEF sysevent handler to the syseventd file by adding the following information.

    # syseventadm add -vSUNW -pSUNWsamfs -cDevice -sSEF 
    /var/tmp/xx "$VENDOR" "$PRODUCT" "$USN" "$REV" 
    $TOD $EQ_ORD "$NAME" $INQ_TYPE "$MEDIA_TYPE" "$VSN" 
    $LABEL_TIME $LP2_PC0 $LP2_PC1 $LP2_PC2 $LP2_PC3 $LP2_PC4 
    $LP2_PC5 $LP2_PC6 $LP3_PC0 $LP3_PC1 $LP3_PC2 $LP3_PC3 
    $LP3_PC4 $LP3_PC5 $LP3_PC6 $WHERE $sequence
    # syseventadm restart

    This command creates the /etc/sysevent/config/SUNW,SUNWsamfs,Device,sysevent.conf file containing the SEF sysevent handler /var/tmp/xx and loads the event handler into the syseventd daemon.

  3. To load the SEF sysevent handler, issue the following command:
    # pkill -HUP syseventd 

    For more information, see sefsysevent(4) in Sun QFS and Sun Storage Archive Manager Reference Manual.