C H A P T E R 4

File System Operations

This chapter presents topics related to file system operations. This chapter contains the following sections:

- Initializing a File System

- Propagating Configuration File Changes to the System

- Mounting a File System

- Unmounting a File System

- Checking File System Integrity and Repairing File Systems

- Preserving Information for an Upgrade

- Preparing for a Hardware Device Upgrade

- Adding Disk Cache to a File System

- Replacing Disks in a File System

- Upgrading a Host System

- Upgrading the Solaris OS

Certain other types of operations and upgrades also need to be performed within Sun StorEdge QFS and Sun StorEdge SAM-FS environments. The following publications describe these other types of operations:

- The Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide describes installing, upgrading, and configuring Sun StorEdge QFS and Sun StorEdge SAM-FS software. It also describes how to create dump files of Sun StorEdge QFS and Sun StorEdge SAM-FS file systems.

- The Sun StorEdge SAM-FS Storage and Archive Management Guide describes how to add slots in an automated library, how to upgrade or replace an automated library, and how to upgrade DLT tape drives.

- The Sun QFS, Sun SAM-FS, and Sun SAM-QFS Disaster Recovery Guide describes how to restore Sun StorEdge QFS and Sun StorEdge SAM-FS file systems.

##

Initializing a File System

You can use the `sammkfs`(1M) command to initialize or reinitialize a Sun StorEdge QFS or Sun StorEdge SAM-FS file system. The following example shows the `sammkfs`(1M) command in its simplest form, with the file system name as its only argument:

    # sammkfs samqfs1

The preceding command builds a version 2 superblock for a standalone Sun StorEdge QFS or Sun SAM-QFS file system. The Sun StorEdge QFS and Sun StorEdge SAM-FS file systems support two different superblocks. The Sun StorEdge QFS and Sun StorEdge SAM-FS 4.2 releases support existing file systems with version 1 superblocks but do not allow you to create a version 1 superblock.

For more information about the`sammkfs`(1M) command, its options, and the implications of the version 1 and version 2 superblocks, see Initializing a File System, or see the`sammkfs`(1M) man page. For information about using the `sammkfs`(1M) command to initialize a shared Sun StorEdge QFS file system, see the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

##

Propagating Configuration File Changes to the System

This section contains procedures that describe how to propagate configuration file changes out to the system. The procedures describe propagating changes for the following files:

- `mcf` file

- `defaults.conf` file

- `archiver.cmd` file (Sun SAM-QFS file systems only)

- `stager.cmd` file (Sun SAM-QFS file systems only)

- shared hosts file (Sun StorEdge QFS shared and Sun SAM-QFS shared file systems only)

You must perform these procedures under the following circumstances:

- If you update any of these files in order to add, delete, or correct information.

- If you create or update an `archiver.cmd`, `defaults.conf`, or `stager.cmd` file after your Sun StorEdge QFS or Sun StorEdge SAM-FS system is already operational.

The following sections describe the procedures:

- To Change mcf(4) or defaults.conf(4) Information in a Sun StorEdge QFS Environment

- To Change mcf(4) or defaults.conf(4) File System Information in a Sun StorEdge SAM-FS or Sun SAM-QFS Environment

- To Change mcf(4) or defaults.conf(4) Removable Media Drive Information

- To Change archiver.cmd(4) or stager.cmd(4) Information

- To Change the Shared Hosts File Information on a Mounted File System

- To Change the Shared Hosts File Information on an Unmounted File System

### To Change `mcf`(4) or `defaults.conf`(4) Information in a Sun StorEdge QFS Environment

To change the `mcf` or the `defaults.conf` information for a shared file system that is configured for high availability in a Sun Cluster environment, perform this procedure on all participating nodes in the Sun Cluster.

1. Use `vi`(1) or another editor to edit the file and change the file system information.

2. Use the `sam-fsd`(1M) command to check the `mcf` file for errors. (Optional)

Perform this step if you are changing an `mcf` file. For example:

    # sam-fsd

If the output from this command shows errors, correct them prior to proceeding to the next step.

3. Use the `samd`(1M) `config` command to propagate the `mcf` or `defaults.conf` file changes.

For example:

    # samd config

For more information about these files, see the `defaults.conf`(4) or `mcf`(4) man pages.

### To Change `mcf`(4) or `defaults.conf`(4) File System Information in a Sun StorEdge SAM-FS or Sun SAM-QFS Environment

1. Use `vi`(1) or another editor to edit the file and change the file system information.

2. Use the `sam-fsd`(1M) command to check the `mcf` file for errors. (Optional)

Perform this step if you are changing an `mcf` file. The format of this command is as follows:

    # sam-fsd

If the output from this command shows errors, correct them prior to proceeding to the next step.

3. Issue a `samcmd`(1M) `aridle` command to idle the archiver for each file system defined in the `mcf` file. (Optional)

You must perform this step if you are removing or changing information related to one or more file systems. Use this command in the following format:

    samcmd aridle fs.fsname

For fsname, specify the name of a file system defined in the `mcf` file. Issue this command for every file system in the `mcf` file that is affected by the change.

4. Issue a `samcmd`(1M) `idle` command to idle the archiver for each equipment ordinal assigned to a drive in the `mcf` file. (Optional)

You must perform this step if you are removing or changing information related to one or more drives. Use this command in the following format:

    samcmd idle eq

For eq, specify the Equipment Ordinal of a drive defined in the `mcf` file. Repeat this command as necessary for all drives in your `mcf` file affected by the change.

5. Issue the `umount`(1M) command to unmount the file system(s) affected by the changes.

For more information about unmounting the file system, see Unmounting a File System.

6. Use the `samd`(1M) `config` command to propagate the changes.

For example:

    # samd config

7. Use the `mount`(1M) command to remount the file system(s) you unmounted.

For more information about these files, see the `defaults.conf`(4) or `mcf`(4) man pages.

### To Change `mcf`(4) or `defaults.conf`(4) Removable Media Drive Information

1. Edit the file and change the removable media drive information.

2. Use the `sam-fsd`(1M) command to check the `mcf` file for errors. (Optional)

Perform this step if you are changing an `mcf` file. Use this command in the following format:

    # sam-fsd

If the output from this command shows errors, correct them prior to proceeding to the next step.

3. Issue a `samcmd`(1M) `aridle` command to idle the archiver for each file system defined in the `mcf` file. (Optional)

Perform this step if you are removing or changing information related to one or more file systems. Use this command in the following format:

    samcmd aridle fs.fsname

For fsname, specify the name of a file system defined in the `mcf` file. Issue this command for every file system in the `mcf` file that is affected by the change.

4. Issue a `samcmd`(1M) `idle` command for each Equipment Ordinal assigned to a drive in the `mcf` file. (Optional)

Perform this step if you are removing or changing information related to one or more drives. Use this command in the following format:

    samcmd idle eq

For eq, specify the Equipment Ordinal of a drive defined in the `mcf` file. Repeat this command as necessary for all drives in your `mcf` file affected by the change.

5. Use the `samd`(1M) `stop` command to stop all removable media activity.

For example:

    # samd stop

6. Use the `samd`(1M) `config` command to propagate the changes and restart the system.

For example:

    # samd config

7. Use the `samd`(1M) `start` command to start all removable media activity.

For example:

    # samd start

For more information about these files, see the `defaults.conf`(4) or `mcf`(4) man pages.

### To Change `archiver.cmd`(4) or `stager.cmd`(4) Information

1. Use `vi`(1) or another editor to edit the `archiver.cmd`(4) or `stager.cmd`(4) file.

2. Use the `archiver`(1M) `-lv` command to validate the changes you made in the `archiver.cmd`(4) file. (Optional)

Perform this step only if you are changing an existing `archiver.cmd`(4) file.

3. Save and close the file.

4. Use the `samd`(1M) `config` command to propagate the file changes and restart the system.

For example:

    # samd config

### To Change the Shared Hosts File Information on a Mounted File System

Use this procedure to add new host entries or change columns 2 through 5 of the existing shared hosts file entries.

1. If you do not know the host that is acting as the metadata server, issue the `samsharefs`(1M) file-system-name command to view the metadata server name.

Issue this command from any host that has the file system configured.

For example:

    # samsharefs sharefs1

2. On the metadata server, save the shared hosts file to a temporary working file.

For example:

    # samsharefs sharefs1 > /tmp/file

3. Save a copy of the shared hosts file. (Optional)

For example:

    # cp /tmp/file /var/opt/SUNWsamfs/hosts.date

4. Use `vi`(1) or another editor to edit the `/tmp/file` file.

For mounted file systems, you can add new host entries to the end of the file and you can make changes to columns 2 through 5 of the existing entries.

Note - You cannot change the host names, reorder the entries, or insert entries in the shared hosts file on a mounted file system. To make these changes, unmount the file system on all clients, unmount the metadata server, and then follow the instructions in To Change the Shared Hosts File Information on an Unmounted File System.

5. Save and close the shared hosts file.

6. Copy the new shared hosts file to the `SUNWsamfs` directory.

For example:

    # cp /tmp/file /var/opt/SUNWsamfs/hosts.sharefs1

7. Apply the new shared hosts file to the file system.

For example:

    # samsharefs -u sharefs1

### To Change the Shared Hosts File Information on an Unmounted File System

Use this procedure to change host names, reorder entries, and insert entries in the shared hosts file.

1. If you do not know the host that is acting as the metadata server, issue the `samsharefs`(1M) `-R` file-system-name command to view the metadata server name.

Issue this command from any host that has the file system configured.

For example:

    # samsharefs -R sharefs1

2. Unmount the file system on each participating client, and then on the metadata server.

3. On the metadata server, save the shared hosts file to a temporary working file.

For example:

    # samsharefs -R sharefs1 > /tmp/file

4. Save a copy of the shared hosts file. (Optional)

For example:

    # cp /tmp/file /var/opt/SUNWsamfs/hosts.date

5. Use `vi`(1) or another editor to edit the `/tmp/file` file.

For unmounted file systems, you can change host names, reorder entries, insert entries, add new host entries, and edit columns 2 through 5 of existing entries.

6. Save and close the shared hosts file.

7. Copy the new shared hosts file to the `SUNWsamfs` directory.

For example:

    # cp /tmp/file /var/opt/SUNWsamfs/hosts.sharefs1

8. Apply the new shared hosts file to the file system.

For example:

    # samsharefs -uR sharefs1

9. Mount the file system on the metadata server, and then on the clients.

##

Mounting a File System

You can mount a Sun StorEdge QFS or Sun StorEdge SAM-FS file system by using the Solaris OS `mount`(1M) command. This section describes the various ways that mount options can be specified.

Mount parameters are used to manipulate file system characteristics. There are several ways to specify mount parameters, and some specification methods override others. You can specify mount options in the following ways:

1. With the `mount`(1M) command using command line options. Highest priority. Options specified on the Solaris OS `mount`(1M) command line override other options specified in the `/etc/vfstab` file, directives specified in the `samfs.cmd` file, and system default settings.

2. As `/etc/vfstab` file settings. Second priority.

3. In the `samfs.cmd` file using directives. Third priority.

4. System defaults. Fourth (lowest) priority. The default system settings are the configurable settings already defined for your Solaris OS. You can override the system settings with specifications in the `samfs.cmd` file, in the`/etc/vfstab` file, and on the`mount`(1M) command.

You can also specify mount options by using the the `samu`(1M) operator utility or the `samcmd`(1M) command. Mount options enabled or disabled by using any of these utilities persist until the file system is unmounted.

The following sections describe the ways to specify mount options in more detail, explain when to use these files and commands, and show the order in which they take precedence. In addition to the following sections, the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide includes information about mounting a file system.

### The `mount`(1M) Command

The Solaris OS `mount`(1M) command mounts the file system and enables you to specify settings that override the settings specified in the`/etc/vfstab` file and in the`/etc/opt/SUNWsamfs/samfs.cmd` file. For example, you can specify the stripe width, readahead, writebehind, high and low water marks for disk cache utilization, and so on.

One way to use the`mount`(1M) command in conjunction with the`samfs.cmd` file is to use the`samfs.cmd` file as your main location for mount options and to use options on the`mount`(1M) command when experimenting with or tuning your system. The`mount`(1M) command options override both the`/etc/vfstab` entries and the directives in the`samfs.cmd` file.

Example. The following command mounts file system`qfs1` at`/work` with `setuid` execution disallowed and `qwrite` enabled. The`qfs1` file system name is the Equipment Identifier. This also appears in the`mcf` file's Equipment Identifier field for this file system. To specify more than one mount option, separate each with a comma.

    # mount -o nosuid,qwrite qfs1 /work

If you are mounting a Sun StorEdge QFS or Sun SAM-QFS shared file system, you must mount the file system on the metadata server first, and then mount the file system on each participating client host. Include the shared option with the `mount` command, and keep in mind that the command is identical on the metadata server and on the participating hosts.

For more information about the`mount`(1M) command, see the`mount_samfs`(1M) man page.

### The `/etc/vfstab` File

The `/etc/vfstab` Solaris OS system file must contain a line for each Sun StorEdge QFS or Sun StorEdge SAM-FS file system that is defined in the mcf file. This is required to mount the file system. For each file system, you must provide information for the seven fields shown in TABLE 4-1.

TABLE 4-1 Fields in the `/etc/vfstab` File
Field Number | Content
--- | ---
1 | The file system family set name.
2 | The file system to `samfsck`(1M).
3 | The mount point.
4 | The file system type. This is always`samfs`, even for Sun StorEdge QFS file systems.
5 | The `samfsck`(1M) pass.
6 | Mount at boot options.
7 | Mount parameters.

The fields in the`/etc/vfstab` file must be separated by either space or tab characters. The mount parameters in the seventh field, however, must each be separated by a comma character (,) without any intervening spaces.

Example. The following is an example of an `/etc/vfstab` file.

    qfs1    -    /qfs    samfs    -    yes    stripe=0

The mount parameters field can contain any of the mount parameters listed as arguments to the`-o` option on the`mount_samfs`(1M) man page. These parameters are nearly identical to those that you can specify as directive lines in the`samfs.cmd` file or as arguments to the`-o` option on the`mount`(1M) command. As with the`samfs.cmd` file, you can include specifications for various I/O settings, readahead, writebehind, the stripe width, various storage and archive management (SAM) settings, Qwrite, and other features.

For more information about possible mount parameters, see the`mount_samfs`(1M) man page. For more information about modifying the`/etc/vfstab` file, see the`vfstab`(4) man page.

### The`samfs.cmd` File

The`/etc/opt/SUNWsamfs/samfs.cmd` file enables you to specify mount parameters for all your Sun StorEdge QFS and Sun StorEdge SAM-FS file systems. This file can be useful when you have multiple file systems configured and you want to specify the same mount parameters for them.

The list of possible mount parameters is very comprehensive. The possible mount parameters you can specify pertain to I/O settings, readahead, writebehind, the stripe width, various storage and archive management (SAM) settings, Qwrite, and other features.

Using this file enables you to define all your mount parameters in one place in an easily readable format. Directives specified toward the beginning of this file are global directives, and they apply to all Sun StorEdge QFS and Sun StorEdge SAM-FS file systems. The second part of this file enables you to indicate the specific parameters that you want to apply to each individual file system. The ability to specify the common parameters once, and only in one place, differentiates this file from the`/etc/vfstab` file, in which you must specify all mount parameters for each file system in the seventh field.

The mount parameters that can be specified in the`samfs.cmd` file are nearly identical to those that you can specify in the`/etc/vfstab` file or as arguments to the`-o` option on the`mount`(1M) command. For more information about the mount parameters that can be specified in this file, see the`samfs.cmd`(4) man page.

In the`samfs.cmd` file, the directives are written one per line. The file can contain comments, which must begin with a pound character (`#`). Characters that appear to the right of the pound character are treated as comments.

Directives that appear before any`fs =` line apply globally to all file systems. A line that starts with`fs =` must precede directives that are specific to a particular file system. Directives specific to a particular file system override global directives.

CODE EXAMPLE 4-1 is a sample `samfs.cmd` file that sets the low and high water marks for disk cache utilization and specifies individualized parameters for two file systems.

CODE EXAMPLE 4-1 Example `samfs.cmd` File
    low = 50
    high = 75
    fs = samfs1
       high = 65
       writebehind = 512
       readahead = 1024
    fs = samfs5
       partial = 64

The directives in the`samfs.cmd` file serve as defaults and override any default system settings, but arguments to the`mount`(1M) command override any directives in this file. Entries in the`/etc/vfstab` file also override directives specified in the`samfs.cmd` file.

For information about which directives can be entered in the`samfs.cmd` file, see the`samfs.cmd`(4) man page. For information about the`mount`(1M) command, see the`mount_samfs`(1M) man page.

##

Unmounting a File System

You can use the Solaris OS `umount`(1M) command to unmount Sun StorEdge QFS and Sun StorEdge SAM-FS file systems.

On Sun StorEdge SAM-FS and Sun SAM-QFS file systems, you must issue commands to stop the archiver prior to unmounting the file system. The following procedure shows you how to idle the archiver and unmount the file system. You do not need to idle the archiver if you are using a Sun StorEdge QFS file system.

### To Unmount Standalone Sun StorEdge SAM-FS and Sun SAM-QFS File Systems

1. Issue a `samcmd`(1M) `aridle fs.`fsname command for the file system. (Optional)

Perform this step if you are unmounting a Sun StorEdge SAM-FS or Sun SAM-QFS file system. For example:

    # samcmd aridle fs.samqfs2

This step in the procedure cleanly halts the archiving for file system `samqfs2`. Specifically, it allows archiving operations to halt at a logical place before stopping the daemons.

2. Issue a `samd`(1M) `stop` command. (Optional)

For example:

    # samd stop

3. Unmount the file system.

    # umount /samqfs

Several conditions can be present in a file system at unmounting time, so you might need to issue the `umount`(1M) command a second time. If the file system still does not unmount, use `unshare`(1M), `fuser`(1M), or other commands in conjunction with the `umount`(1M) command. Unmounting procedures are also described in the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

### To Unmount Sun StorEdge QFS and Sun SAM-QFS Shared File Systems

The `umount`(1M) command unmounts a shared file system from a Solaris system. For more information about the `umoun`t(1M) command, see the `umount`(1M) man page.

1. Use the `umount`(1M) command to unmount the file system on every participating client host.

    # umount /samqfs

2. On the metadata server, halt the archiving for the file system at a logical place by issuing the `samcmd`(1M) `aridle fs.`fsname`` command. (Optional)

Perform this step in a Sun SAM-QFS file system environment.

For example:

    # samcmd aridle fs.samqfs2

This example halts the archiving for file system `samqfs2`.

3. Unmount the file system on the metadata server.

    # umount /samqfs

Unmount the metadata server only after unmounting all client hosts.

Several conditions can be present in a file system at unmounting time, so you might need to issue the `umount`(1M) command a second time. If the file system still does not unmount, use `unshare`(1M), `fuser`(1M), or other commands in conjunction with the `umount`(1M) command. Unmounting procedures are also described in the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

##

Checking File System Integrity and Repairing File Systems

Sun StorEdge QFS and Sun StorEdge SAM-FS file systems write validation records in the following records that are critical to file system operations: directories, indirect blocks, and inodes. If the file system detects corruption while searching a directory, it issues an EDOM error, and the directory is not processed. If an indirect block is not valid, it issues an ENOCSI error, and the file is not processed. TABLE 4-2 summarizes these error indicators.

TABLE 4-2 Error Indicators
Error | Solaris OS Meaning | Sun StorEdge QFS and Sun StorEdge SAM-FS Meaning
--- | --- | ---
EDOM | Argument is out of domain. | Values in validation records are out of range.
ENOCSI | No CSI structure is available. | Links between structures are invalid.

In addition, inodes are validated and cross checked with directories.

You should monitor the following files for error conditions:

- The log file specified in `/etc/syslog.conf` for the errors shown in TABLE 4-2.

- The`/var/adm/messages` file for device errors.

If a discrepancy is noted, you should unmount the file system and check it using the`samfsck`(1M) command.

Note - The `samfsck`(1M) command can be issued on a mounted file system, but the results cannot be trusted. Because of this, you are encouraged to run the command on an unmounted file system only.

### To Check a File System

Use the `samfsck`(1M) command to perform a file systems check.

Use this command in the following format:

    samfsck -V family_set_name

For family_set_name, specify the name of the file system as specified in the `mcf` file.

You can send output from`samfsck`(1M) to both your screen and to a file by using it in conjunction with the`tee`(1) command, as follows.

- C shell:

    # samfsck -V family_set_name |& tee file

- Bourne shell:

    # samfsck -V family_set_name 2>&1 | tee file

Nonfatal errors returned by`samfsck`(1M) are preceded by`NOTICE`. Nonfatal errors are lost blocks and orphans. The file system is still consistent if`NOTICE` errors are returned. You can repair these nonfatal errors during a convenient, scheduled maintenance outage.

Fatal errors are preceded by`ALERT`. These errors include duplicate blocks, invalid directories, and invalid indirect blocks. The file system is not consistent if these errors occur. Notify Sun if the`ALERT` errors cannot be explained by a hardware malfunction.

If the`samfsck`(1M) command detects file system corruption and returns `ALERT` messages, you should determine the reason for the corruption. If hardware is faulty, repair it prior to repairing the file system.

For more information about the`samfsck`(1M) and`tee`(1) commands, see the`samfsck`(1M) and`tee`(1) man pages.

### To Repair a File System

1. Use the `umount`(1M) command to unmount the file system.

Run the `samfsck`(1M) command when the file system is not mounted. For information about unmounting a file system, see Unmounting a File System.

2. Use the `samfsck`(1M) command to repair a file system. If you are repairing a shared file system, issue the command from the metadata server.

You can issue the `samfsck`(1M) command in the following format to repair a file system:

    # samfsck -F -V fsname

For fsname, specify the name of the file system as specified in the `mcf` file.

##

Preserving Information for an Upgrade

If you are about to add or change disks, controllers, or other equipment in your environment, it can be difficult to correct or regenerate all the file system descriptions in the`mcf` file. The`samfsconfig`(1M) command can help you by generating information about your file system and file system components after making these changes.

The`samfsconfig`(1M) command examines devices and determines if any of them have Sun StorEdge QFS or Sun StorEdge SAM-FS superblocks on them. It uses information from the discovered superblocks and aggregates the devices into a format similar to an `mcf` file. You can save this format and edit it to recreate a damaged, missing, or incorrect `mcf` file.

This command returns information about each device that you specify and writes this information to`stdout`. The command can retrieve the family set number of the base device (the file system itself), the file system type (`ma` or `ms`), and whether the file system is a Sun StorEdge QFS shared file system.

Irregularities are flagged with one of the following:

- A pound sign (`#`). This indicates incomplete family set information.

- A greater-than sign (`>`). This indicates that more than one device name refers to a particular file system element.

If necessary, this command's output can be used to help regenerate the file system portions of your`mcf` file if your system is reconfigured or experiences a disaster. The following examples show output from the `samfsconfig`(1M) command.

### Example 1

In this example, the system administrator has put a list of device names into a file. These device names are not accounted for in the environment. The system administrator wants to examine only these devices for Sun StorEdge QFS and Sun StorEdge SAM-FS family sets. The results show some old fragments of family sets and several complete instances.

CODE EXAMPLE 4-2 Example 1 - Output From `samfsconfig` (1M) Command
    mn# samfsconfig -v `cat /tmp/dev_files`
    Device '/dev/dsk/c0t0d0s0' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c0t0d0s1' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c0t0d0s3' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c0t0d0s4' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c0t0d0s5' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c0t0d0s6' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c0t0d0s7' doesn't have a SAM-FS superblock (SBLK).
    Couldn't open '/dev/dsk/c0t1d0s0';  errno=5.
    Couldn't open '/dev/dsk/c0t1d0s1';  errno=5.
    Device '/dev/dsk/c0t1d0s3' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c0t1d0s4' has a SAM-FS superblock.
    Device '/dev/dsk/c0t1d0s5' has a SAM-FS superblock.
    Device '/dev/dsk/c0t1d0s6' has a SAM-FS superblock.
    Couldn't open '/dev/dsk/c0t1d0s7';  errno=5.
    Couldn't open '/dev/dsk/c0t6d0s0';  errno=16.
    Couldn't open '/dev/dsk/c0t6d0s1';  errno=16.
    Couldn't open '/dev/dsk/c0t6d0s3';  errno=16.
    Couldn't open '/dev/dsk/c0t6d0s4';  errno=16.
    Couldn't open '/dev/dsk/c0t6d0s5';  errno=16.
    Couldn't open '/dev/dsk/c0t6d0s6';  errno=16.
    Couldn't open '/dev/dsk/c0t6d0s7';  errno=16.
    Couldn't open '/dev/dsk/c1t0d0s3';  errno=5.
    Couldn't open '/dev/dsk/c1t0d0s4';  errno=5.
    Couldn't open '/dev/dsk/c1t0d0s5';  errno=5.
    Device '/dev/dsk/c1t0d0s6' doesn't have a SAM-FS superblock (SBLK).
    Couldn't open '/dev/dsk/c1t0d0s7';  errno=5.
    Couldn't open '/dev/dsk/c1t1d0s0';  errno=2.
    Couldn't open '/dev/dsk/c1t2d0s3';  errno=5.
    Couldn't open '/dev/dsk/c1t2d0s4';  errno=5.
    Couldn't open '/dev/dsk/c1t2d0s5';  errno=5.
    Device '/dev/dsk/c1t2d0s6' doesn't have a SAM-FS superblock (SBLK).
    Couldn't open '/dev/dsk/c1t2d0s7';  errno=5.
    Could not read from device '/dev/dsk/c1t3d0s0'; errno=5.
    Couldn't open '/dev/dsk/c1t4d0s3';  errno=5.
    Couldn't open '/dev/dsk/c1t4d0s4';  errno=5.
    Couldn't open '/dev/dsk/c1t4d0s5';  errno=5.
    Device '/dev/dsk/c1t4d0s6' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c1t4d0s7' doesn't have a SAM-FS superblock (SBLK).
    Couldn't open '/dev/dsk/c1t5d0s3';  errno=5.
    Couldn't open '/dev/dsk/c1t5d0s4';  errno=5.
    Couldn't open '/dev/dsk/c1t5d0s5';  errno=5.
    Device '/dev/dsk/c1t5d0s6' doesn't have a SAM-FS superblock (SBLK).
    Couldn't open '/dev/dsk/c1t5d0s7';  errno=5.
    Device '/dev/dsk/c3t0d0s0' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c3t0d0s1' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c3t0d0s3' has a SAM-FS superblock.
    Device '/dev/dsk/c3t0d0s4' has a SAM-FS superblock.
    Couldn't open '/dev/dsk/c3t0d0s7';  errno=5.
    Device '/dev/dsk/c3t1d0s0' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c3t1d0s1' doesn't have a SAM-FS superblock (SBLK).
    Device '/dev/dsk/c3t1d0s3' has a SAM-FS superblock.
    Device '/dev/dsk/c3t1d0s4' has a SAM-FS superblock.
    Couldn't open '/dev/dsk/c3t1d0s7';  errno=5.
    Device '/dev/dsk/c4t0d0s0' has a SAM-FS superblock.
    Could not read from device '/dev/dsk/c4t0d0s1'; errno=5.
    Could not read from device '/dev/dsk/c4t0d0s3'; errno=5.
    Could not read from device '/dev/dsk/c4t0d0s4'; errno=5.
    Could not read from device '/dev/dsk/c4t0d0s5'; errno=5.
    Device '/dev/dsk/c4t0d0s6' has a SAM-FS superblock.
    Device '/dev/dsk/c4t0d0s7' has a SAM-FS superblock.
    Device '/dev/dsk/c4t1d0s0' has a SAM-FS superblock.
    Could not read from device '/dev/dsk/c4t1d0s1'; errno=5.
    Could not read from device '/dev/dsk/c4t1d0s3'; errno=5.
    Could not read from device '/dev/dsk/c4t1d0s4'; errno=5.
    Could not read from device '/dev/dsk/c4t1d0s5'; errno=5.
    Device '/dev/dsk/c4t1d0s6' has a SAM-FS superblock.
    Device '/dev/dsk/c4t1d0s7' has a SAM-FS superblock.
    Device '/dev/dsk/c4t2d0s0' has a SAM-FS superblock.
    Could not read from device '/dev/dsk/c4t2d0s1'; errno=5.
    Could not read from device '/dev/dsk/c4t2d0s3'; errno=5.
    Could not read from device '/dev/dsk/c4t2d0s4'; errno=5.
    Could not read from device '/dev/dsk/c4t2d0s5'; errno=5.
    Device '/dev/dsk/c4t2d0s6' has a SAM-FS superblock.
    Device '/dev/dsk/c4t2d0s7' has a SAM-FS superblock.
    Device '/dev/dsk/c4t3d0s0' has a SAM-FS superblock.
    Could not read from device '/dev/dsk/c4t3d0s1'; errno=5.
    Could not read from device '/dev/dsk/c4t3d0s3'; errno=5.
    Could not read from device '/dev/dsk/c4t3d0s4'; errno=5.
    Could not read from device '/dev/dsk/c4t3d0s5'; errno=5.
    Device '/dev/dsk/c4t3d0s6' has a SAM-FS superblock.
    Device '/dev/dsk/c4t3d0s7' has a SAM-FS superblock.
    19 SAM-FS devices found.
    #
    # Family Set 'samfs2' Created Mon Jun 25 10:37:52 2001
    #
    # Missing slices
    # Ordinal 1
    # /dev/dsk/c0t1d0s6    12    md   samfs2  -
    #
    # Family Set 'samfs1' Created Wed Jul 11 08:47:38 2001
    #
    # Missing slices
    # Ordinal 1
    # /dev/dsk/c0t1d0s4    12    md   samfs1  -
    # Ordinal 2
    # /dev/dsk/c0t1d0s5    13    md   samfs1  -
    #
    # Family Set 'samfs2' Created Sat Nov  3 17:22:44 2001
    #
    samfs2 ma 30 samfs2 - shared
    /dev/dsk/c4t0d0s6    31    mm   samfs2  -
    /dev/dsk/c4t1d0s6    32    mr   samfs2  -
    /dev/dsk/c4t2d0s6    33    mr   samfs2  -
    #
    # Family Set 'qfs1' Created Wed Nov  7 15:16:19 2001
    #
    qfs1 ma 10 qfs1 -
    /dev/dsk/c3t0d0s3    11    mm   qfs1  -
    /dev/dsk/c3t0d0s4    12    g0   qfs1  -
    /dev/dsk/c3t1d0s3    13    g0   qfs1  -
    /dev/dsk/c3t1d0s4    14    g0   qfs1  -
    #
    # Family Set 'sharefsx' Created Wed Nov  7 16:55:19 2001
    #
    sharefsx ma 200 sharefsx - shared
    /dev/dsk/c4t0d0s0    210    mm   sharefsx  -
    /dev/dsk/c4t1d0s0    220    mr   sharefsx  -
    /dev/dsk/c4t2d0s0    230    mr   sharefsx  -
    /dev/dsk/c4t3d0s0    240    mr   sharefsx  -
    #
    # Family Set 'samfs5' Created Tue Nov 27 16:32:28 2001
    #
    samfs5 ma 80 samfs5 -
    /dev/dsk/c4t3d0s6    82    mm   samfs5  -
    /dev/dsk/c4t3d0s7    83    g0   samfs5  -
    /dev/dsk/c4t0d0s7    84    g0   samfs5  -
    /dev/dsk/c4t1d0s7    85    g1   samfs5  -
    /dev/dsk/c4t2d0s7    86    g1   samfs5  -

### Example 2

In this example, the devices flagged with a greater-than sign (>) are duplicated. The `s0` slice starts at the start of disk, as does the whole disk (`s2`) slice. This is the style of output obtained in a Solaris 9 OS.

CODE EXAMPLE 4-3 shows the `samfsconfig`(1M) command and output.

CODE EXAMPLE 4-3 Example 2 - Output from `samfsconfig` Command
    # samfsconfig /dev/dsk/c3t*
    #
    # Family Set 'shsam1' Created Wed Oct 17 14:57:29 2001
    #
    shsam1 160 ma shsam1 shared
    > /dev/dsk/c3t50020F23000055A8d0s2    161    mm   shsam1  -
    > /dev/dsk/c3t50020F23000055A8d0s0    161    mm   shsam1  -
    /dev/dsk/c3t50020F23000055A8d0s1    162    mr   shsam1  -
    > /dev/dsk/c3t50020F23000078F1d0s0    163    mr   shsam1  -
    > /dev/dsk/c3t50020F23000078F1d0s2    163    mr   shsam1  -
    /dev/dsk/c3t50020F23000078F1d0s1    164    mr   shsam1  -

### Example 3

In this example, the whole disk slice (slice 2) is left off of the command line. This is the style of output obtained in a Solaris 9 OS.

CODE EXAMPLE 4-4 shows the `samfsconfig`(1M) command and output.

CODE EXAMPLE 4-4 Example 3 - Output from `samfsconfig` (1M) Command
    # samfsconfig /dev/dsk/c3t*s[013-7]
    #
    # Family Set 'shsam1' Created Wed Oct 17 14:57:29 2001
    #
    shsam1 160 ma shsam1 shared
    /dev/dsk/c3t50020F23000055A8d0s0    161    mm   shsam1  -
    /dev/dsk/c3t50020F23000055A8d0s1    162    mr   shsam1  -
    /dev/dsk/c3t50020F23000078F1d0s0    163    mr   shsam1  -
    /dev/dsk/c3t50020F23000078F1d0s1    164    mr   shsam1  -

For more information about this command, see the`samfsconfig`(1M) man page.

##

Preparing for a Hardware Device Upgrade

Whether upgrading a server, adding a new tape drive, adding an automated library, or installing a different drive into an existing automated library, it is best to plan in advance. This section prepares you for hardware upgrades to devices within your environment.

Sun Microsystems recommends the following actions prior to the upgrade:

- Determine if the hardware addition or change requires a new license from Sun Microsystems.

Examples of changes that do not require a license upgrade include adding memory and increasing disk cache. Examples of changes that require a license upgrade include adding more slots in an automated library and changing the model of your server.

- Read the hardware manufacturer's installation instructions carefully. Also read the documentation on adding hardware in your Solaris OS system administrator documentation.

- Check the Equipment Ordinals between your old and new `mcf` files. For information about the `mcf` file, see the `mcf`(4) man page.

- Decide whether or not the backup copies you have on hand are sufficient. For information about backing up your data and metadata, see the procedures described in the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

- In a Sun StorEdge QFS environment, the `qfsdump`(1M) command dumps all data and metadata. For more information about this process, see the `qfsdump`(1M) man page.

- In Sun StorEdge SAM-FS and Sun SAM-QFS environments, the `samfsdump`(1M) command dumps all metadata. You must ensure that all files that need to be archived have an archive copy. Use the `archive_audit`(1) command on each Sun StorEdge SAM-FS or Sun SAM-QFS file system to see which files do not have an archive copy. In the following example, `/sam` is the mount point.

    # archive_audit /sam

- Ensure that the system is quiet with no users logged in.

- In Sun StorEdge SAM-FS and Sun SAM-QFS environments, ensure that the archiver is in `wait` mode. The archiver must be in `wait` mode, and not running, during an upgrade.

You can idle the archiver in one of the following ways:

- By inserting a `wait` directive into the `/etc/opt/SUNWsamfs/archiver.cmd` file. For more information about the `wait` directive and the `archiver.cmd` file, see the `archiver.cmd`(4) man page.

- By using the `samu`(1M) operator utility.

- By issuing the following command:

    # samcmd aridle

For more information, see the `samcmd`(1M) man page.

##

Adding Disk Cache to a File System

At some point, you might want to add disk partitions or disk drives in order to increase the disk cache for a file system. You accomplish this by updating the`mcf` file and using the`samgrowfs`(1M) command. You do not need to reinitialize or restore the file system.

In Sun StorEdge SAM-FS and Sun SAM-QFS environments, note that when adding disks or partitions, the system might update the Equipment Ordinal of the historian. The system automatically generates the Equipment Ordinal of the historian unless you specifically call it out. For more information, see the`historian`(7) man page.

### To Add Disk Cache to a File System

1. Use the `umount`(1M) command to unmount the file system you want to expand. If the file system is shared, unmount the file system on all client hosts and then on the metadata server. You can then perform the remaining steps in this procedure on the metadata server.

For information about unmounting a file system, see Unmounting a File System.

2. If you want to rename the file system during this procedure, use the `samfsck`(1M) command with its `-R` and `-F` options to rename the file system. (Optional)

For more information about this command, see the `samfsck`(1M) man page.

3. Edit the `/etc/opt/SUNWsamfs/mcf` file.

You can configure up to 252 disk partitions in a file system.

To increase the size of a Sun StorEdge QFS file system, at least one new metadata partition must be added. Metadata partitions require an Equipment Type of`mm`. Zero or more data partitions can be added.

If you want to add new partitions for metadata or for data, add them to the `mcf` file after the existing disk partitions. Save the changes, and quit the editor.

Do not change the Equipment Identifier name in the `/etc/opt/SUNWsamfs/mcf` file. If the name in the `mcf` file does not match the name in the superblock, the file systems can no longer be mounted. Instead, the following message is logged in`/var/adm/messages`:

    WARNING SAM-FS superblock equipment identifier <id>s on eq <eq> does not match <id> in mcf

4. Type the `sam-fsd`(1M) command to check for errors in the `mcf` file.

For example:

    # sam-fsd

If the `sam-fsd`(1M) command output indicates that there are errors in the `mcf` file, fix them before proceeding to the next step in this procedure.

5. Type the `samd`(1M) `config` command to propagate the `mcf` file changes to the system.

For example:

    # samd config

For more information about the `samd`(1M) command, see the `samd`(1M) man page.

6. Type the `samgrowfs`(1M) command on the file system that is being expanded.

For example, type the following command to expand file system `samfs1`:

    # samgrowfs samfs1

If you renamed your file system, run the `samgrowfs`(1M) command on the new name. For more information about this command, see the `samgrowfs`(1M) man page.

7. Mount the file system.

If you renamed your file system, enter the new name in the `mcf` file and then issue the `sam-fsd(1M)` and the `samd(1M) config` commands as described in steps 4 and 5.

8. For Sun StorEdge QFS shared file systems only, edit the `mcf` file on each participating client host to match the metadata server's `mcf` file.

##

Replacing Disks in a File System

At some point, you might want to perform the following tasks:

- Change disks or partitions

- Add disks or partitions

- Remove disks or partitions

To accomplish these tasks, you need to back up and recreate the file system by following the steps in this procedure.

### To Back Up and Recreate a File System

1. Back up all site-customized system files and configuration files.

Depending on your software, these files can include `mcf`, `archiver.cmd`, `defaults.conf`, `samfs.cmd`,`inquiry.conf`, and so on. Back up these files for all file systems in your Sun StorEdge QFS and Sun StorEdge SAM-FS environments. Also make sure that you have backup copies of files in the `/etc/opt/SUNWsamfs` directory, files in the `/var/opt/SUNWsamfs` directory, library catalogs, the historian, shared hosts files, and any parameter files for network-attached automated libraries.

In Sun StorEdge SAM-FS and Sun SAM-QFS environments, if you do not know the names and locations of your catalog files, examine the `mcf` file with `vi`(1) or another viewing command and find the first `rb` entry in the `mcf` file. That entry contains the name of the library catalog file. If no catalog file location is specified, then the system is using the default location (`/var/opt/SUNWsamfs/catalog)`.

2. Ensure that each file system to be modified is backed up.

The file systems should be backed up regularly according to your site's policies. This is described as the last step in the installation procedure. If you are comfortable with the backup files that already exist for your file systems, there is no need to back them up again now. If, however, you need to back up your file systems to preserve information created since the last dump file was created, do so now. For information about how to create a dump file, see the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

Note that if you are using the Sun StorEdge SAM-FS or Sun SAM-QFS file system, the `samfsdump`(1M) command issues warnings when creating the dump file if it encounters unarchived files in the file system. If warnings are issued, these files need to be archived before unmounting the file systems.

3. Unmount the file system.

For information about unmounting a file system, see Unmounting a File System.

4. If you want to rename the file system during this procedure, use the `samfsck`(1M) command with its `-R` and `-F` options to rename the file system. (Optional)

For more information about this command, see the `samfsck`(1M) man page.

5. Edit the `/etc/opt/SUNWsamfs/mcf` file.

You can configure up to 252 disk partitions in a file system. Edit the `mcf` file to add or delete disks or partitions. New partitions must be added after existing disk partitions. Save the changes, and quit the editor.

To increase the size of a Sun StorEdge QFS file system, at least one new metadata partition must be added. Metadata partitions require an Equipment Type of`mm`. Zero or more data partitions can be added.

Do not change the Equipment Identifier name in the `/etc/opt/SUNWsamfs/mcf` file. If the name in the `mcf` file does not match the name in the superblock, the file systems can no longer be mounted. Instead, the following message is logged in`/var/adm/messages`:

    WARNING SAM-FS superblock equipment identifier <id>s on eq <eq> does not match <id> in mcf

6. Type the `sam-fsd`(1M) command to check for errors in the `mcf` file.

For example:

    # sam-fsd

If the `sam-fsd`(1M) command output indicates that there are errors in the `mcf` file, fix them before proceeding to the next step in this procedure.

For more information, see the `sam-fsd`(1M) man page.

7. Type the `samd`(1M) `config` command to propagate the `mcf` file changes.

For example:

    # samd config

For more information, see the `samd`(1M) man page.

8. Type the `sammkfs`(1M) command to make a new file system.

For example, the following command creates `samfs10`:

    # sammkfs samfs10

9. Type the `mount`(1M) command to mount the file system.

For information about mounting a Sun StorEdge QFS or Sun StorEdge SAM-FS file system, see the `mount_samfs`(1M) man page.

10. Type the `cd`(1) command to change to the mount point of the file system.

11. Use the `samfsrestore`(1M) or `qfsrestore`(1M) command to restore each file.

Restore from the the dump file you had or from the dump file created in Step 2.

For information about using these commands, see the `samfsdump`(1M) or `qfsdump`(1M) man pages, or see the Sun QFS, Sun SAM-FS, and Sun SAM-QFS Disaster Recovery Guide.

12. Use the `restore.sh`(1M) script to stage back all files that had been online.

Use this command in the following format:

    # restore.sh log_file mount_point

For log_file, specify the name of the log file that was created by the `sammkfs`(1M) or the `samfsrestore`(1M) commands.

For mount_point, specify the mount point of the file system being restored.

For information about the `restore.sh`(1M) script, see the `restore.sh`(1M) man page.

##

Upgrading a Host System

When it comes time to upgrade the host system being used for the file system, take the following into account:

- It is wise to move to the new host while the existing host is still in operation. This allows time to install, configure, and test the new hardware platform with your applications.

- Moving to a new host system is equivalent to installing the Sun StorEdge QFS or Sun StorEdge SAM-FS software for the first time. In Sun StorEdge SAM-FS and Sun SAM-QFS environments, you need to reinstall the software and update the configuration files (specifically the`mcf` file, the`/kernel/drv/st.conf` file, and the`/etc/opt/SUNWsamfs/inquiry.conf` file). In addition, you need to copy your existing`archiver.cmd` and`defaults.conf` files to the new system, configure system logging, and so on.

You can use the installation instructions in the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide when re-installing the software.

- You might need to update your license key. License keys are tied to the CPU host ID. Replacing the system requires a new license.

- Before powering down the old host system, decide whether or not the backup copies you have on hand are sufficient. You might need to create new dump files at this time. A dump file is used to recreate the file system on the new server. For more information about creating a dump file, see the`qfsdump`(1M) or`samfsdump`(1M) man pages or see the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

##

Upgrading the Solaris OS

The following sections describe how to upgrade your Solaris OS:

- To Upgrade Your Solaris OS in a Sun StorEdge SAM-FS or Sun SAM-QFS Environment

- To Upgrade Your Solaris OS in a Sun StorEdge QFS Environment

### To Upgrade Your Solaris OS in a Sun StorEdge SAM-FS or Sun SAM-QFS Environment

Many of the steps involved in upgrading your Solaris OS level are identical to the steps involved in upgrading your Sun StorEdge SAM-FS or Sun SAM-QFS environment. Some of the steps in this procedure reference procedures in the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

1. Obtain the software upgrade.

The Sun StorEdge SAM-FS and Sun SAM-QFS software supports various levels of the Solaris OS. You should not reinstall your old Sun StorEdge SAM-FS or Sun SAM-QFS software onto your newly upgraded Solaris OS.

In addition, depending on the revision level currently installed and the level to which you are upgrading, you might need a new software license.

Contact your ASP or Sun Microsystems to obtain new copies of the software and to determine whether or not your site needs a new license.

2. Back up all site-customized system files and configuration files.

These files include `mcf`, `archiver.cmd`, `defaults.conf`, `samfs.cmd`,`inquiry.conf`, and so on. Back up these files for all file systems in your Sun StorEdge SAM-FS and Sun SAM-QFS environments.

Also make sure that you have backup copies of files in the `/etc/opt/SUNWsamfs` directory, files in the `/var/opt/SUNWsamfs` directory, library catalogs, the historian, and any parameter files for network-attached automated libraries.

If you do not know the names and locations of your catalog files, examine the `mcf` file with `vi`(1) or another viewing command and find the first `rb` entry in the `mcf` file. That entry contains the name of the library catalog file. If no catalog file location is specified, then the system is using the default location (`/var/opt/SUNWsamfs/catalog)`.

3. Ensure that each file system affected is backed up.

The file systems should be backed up regularly according to your site's policies. This is one of the the last steps in the installation procedure. If you are comfortable with the backup files that already exist for your file systems, there is no need to back them up again now. If, however, you need to back up your file systems to preserve information created since the last dump file was created, do so now.

Note that if you are using the Sun StorEdge SAM-FS or Sun SAM-QFS file system, the `samfsdump`(1M) command issues warnings when creating the dump file if it encounters unarchived files in the file system. If warnings are issued, these files need to be archived before unmounting the file systems.

4. Unmount the file systems.

For information about unmounting a file system, see Unmounting a File System.

5. Issue a `samd`(1M) `stop` command to stop all archiving and SAM activity. (Optional)

Perform this step if you are unmounting a Sun StorEdge SAM-FS or Sun SAM-QFS file system. For example:

    # samd stop

6. Remove existing Sun StorEdge SAM-FS or Sun SAM-QFS software.

Use the`pkgrm`(1M) command to remove the existing software. You must remove all existing Sun StorEdge SAM-FS and Sun SAM-QFS packages before installing either the new packages or the new operating system level.

For example, the following command removes the `SUNWsamtp`, `SUNWsamfsu`, and the `SUNWsamfsr` packages in a Sun StorEdge SAM-FS or Sun SAM-QFS environment. The `SUNWsamfsr` package must be removed last. Note that the `SUNWsamtp` package is an optional tools package, and it might not be installed on your system. An example `pkgrm`(1M) command is as follows:

    # pkgrm SUNWsamtp SUNWsamfsu SUNWsamfsr

The information in this step assumes that you are removing software packages at the 4.2 release level or later. The software package names changed as of the 4.2 releases. If you have earlier releases of the software packages on your system, see the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide for information about removing them.

7. Upgrade the Solaris OS.

Install the new Solaris OS revision using the Sun Solaris upgrade procedures for the OS level you are installing.

8. Add the `SUNWsamfsr` and `SUNWsamfsu` packages that you obtained in Step 1.

The Sun StorEdge SAM-FS and Sun SAM-QFS software packages use the Solaris OS packaging utilities for adding and deleting software. You must be logged in as superuser to make changes to software packages. The`pkgadd`(1M) command prompts you to confirm various actions necessary to upgrade the Sun StorEdge SAM-FS and Sun SAM-QFS package.

On the installation CD-ROM, the Sun StorEdge SAM-FS and Sun SAM-QFS package resides in the`/cdrom/cdrom0` directory.

Run the `pkgadd`(1M) command, as follows, to upgrade the packages, answering `yes` to each question:

    # pkgadd -d . SUNWsamfsr SUNWsamfsu

During the installation, the system detects the presence of conflicting files and prompts you to indicate whether or not you want to continue with the installation. You can go to another window and copy the files you wish to save to an alternate location.

9. Update the license keys. (Optional)

Depending on the Sun StorEdge SAM-FS and Sun SAM-QFS software revision you had, and the revision to which you are upgrading, you might need to obtain new license keys for your software. Contact your ASP or Sun Microsystems for help on determining if you need a new license.

If you are upgrading from a release prior to 4.2, you need to place a new license key in the following file:

    /etc/opt/SUNWsamfs/LICENSE.4.2

For more information, see the licensing information in the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

10. Mount the file system(s). (Optional)

You must perform this step if you have not modified the`/etc/vfstab` file to have`yes` in the Mount at Boot field.

Use the `mount`(1M) command to mount the file systems and continue operation with the upgraded Sun SAM-FS or Sun SAM-QFS software.

In the following example,`samfs1` is the name of the file system to be mounted.

    # mount samfs1

### To Upgrade Your Solaris OS in a Sun StorEdge QFS Environment

Many of the steps involved in upgrading your Solaris OS level are identical to the steps involved in upgrading your Sun StorEdge QFS environment. Some of the steps in this procedure reference procedures in the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

1. Obtain the software upgrade.

Sun StorEdge QFS software supports various levels of the Solaris OS. You should not reinstall your old Sun StorEdge QFS software onto your newly upgraded Solaris OS.

In addition, depending on the revision level currently installed and the level to which you are upgrading, you may need a new Sun StorEdge QFS license.

Contact your ASP or Sun Microsystems to obtain new copies of the software and to determine whether or not your site needs a new license.

2. Back up all site-customized system files and configuration files.

These files include `mcf`, `defaults.conf`, `samfs.cmd`, the shared hosts files, and so on. Back up these files for all file systems in your Sun StorEdge QFS environment. Also make sure that you have backup copies of files in the `/etc/opt/SUNWsamfs` directory.

3. Ensure that each file system affected is backed up.

The file systems should be backed up regularly according to your site's policies. This is described as the last step in the installation procedure. If you are comfortable with the backup files that already exist for your file systems, there is no need to back them up again now. If, however, you need to back up your file systems to preserve information created since the last dump file was created, do so now. For information about how to create a dump file, see the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

4. Unmount the file systems.

For information about unmounting a file system, see Unmounting a File System.

5. Remove existing Sun StorEdge QFS software.

Use the`pkgrm`(1M) command to remove the existing software. You must remove the existing Sun StorEdge QFS package before installing either the new package or the new operating system level.

For example, the following command removes the Sun StorEdge QFS software:

    # pkgrm SUNWqfsu SUNWqfsr

The information in this step assumes that you are removing a software package at the 4.2 release level or later. The software package names changed as of the 4.2 releases. If you have earlier releases fo the software packages on your system, see the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide for information about removing them.

6. Upgrade the Solaris OS.

Install the new Solaris OS revision using the Sun Solaris upgrade procedures for the Solaris OS level you are installing.

7. Add the packages that you obtained in Step 1.

The Sun StorEdge QFS software package uses the Solaris OS packaging utilities for adding and deleting software. You must be logged in as superuser to make changes to software packages. The`pkgadd`(1M) command prompts you to confirm various actions necessary to upgrade the Sun StorEdge QFS package.

On the installation CD-ROM, the Sun StorEdge QFS package resides in the `/cdrom/cdrom0` directory.

Run the `pkgadd`(1M) command to upgrade the package, answering `yes` `t`o each question:

    # pkgadd -d . SUNWqfsr SUNWqfsu

During the installation, the system detects the presence of conflicting files and prompts you to indicate whether or not you want to continue with the installation. You can go to another window and copy any files you want to save to an alternate location.

8. Update the license keys. (Optional)

Depending on the Sun StorEdge QFS software revision you had, and the revision to which you are upgrading, you might need to obtain new license keys for your Sun StorEdge QFS software. Contact your ASP or Sun Microsystems for help on determining if you need a new license.

If you are upgrading from a Sun StorEdge QFS release prior to 4.2, you need to place a new license key in the following file:

    /etc/opt/SUNWsamfs/LICENSE.4.2

For more information, see the licensing information in the Sun StorEdge QFS and Sun StorEdge SAM-FS Software Installation and Configuration Guide.

9. Update the `mcf` file. (Optional)

If device names have changed, it might be necessary to update the `mcf` file to match the new device names. Veryify the new device names, and then follow the procedure in Propagating Configuration File Changes to the System.

10. Mount the file system(s). (Optional)

Perform this step if you have not modified the `/etc/vfstab` file to have `yes`.

Use the procedure described in Mounting a File System. Continue operation with the upgraded Sun StorEdge QFS software.

Copyright © 2004, Sun Microsystems, Inc. All rights reserved.