Test Plan: Storage Controller Certification Level 1

### Storage Controller Certification
Level 1 Test Plan

  Introduction
  Required Hardware and Software

  Required Hardware Configuration
  Required Software Configuration

  Hardware Certification Tests

  Manual Tests
  Automated Tests

### Introduction

This document provides detailed descriptions of the manual storage controller certification tests. After you successfully complete the manual tests described in this document, use the HCTS to run the automated tests.

When a driver supports multiple controllers, the controller that supports the most extensive feature set is designated the primary controller. Additional controllers supported by the same device driver are known as supplementary controllers.

The tests described in this document are used for one of these three purposes:

- Functional testing of controllers at Level 1

- Certifying supplementary controllers supported by the same driver under test as a primary controller

- Certifying USB hard drives

Note: The tests described in the Storage Controller Certification Level 2 Test Plan are for functional testing of controllers at Level 2 or for certifying a primary controller that has supplementary controllers supported by the same driver under test.

Run all tests on both system configurations described in the following section.

### Required Hardware and Software

Make sure your system meets the general hardware and software requirements for all certifications stated in the Hardware Certification Test Suite Installation Guide.

This section describes additional hardware and software required to execute the storage controller certification tests.

#### Required Hardware Configuration

The minimum requirements for this configuration are as follows:

Fibre Channel

- System
  - Diskette drive
- HBAs
  - One Fibre Channel HBA supported by the driver under test
- Fibre channel disks
  - At least one LUN (at least 20 Gbytes each) created on the Fibre Channel disks
  - One disk on which the operating system resides
- Peripheral
  - CD-COM

RAID

- System
  - Diskette drive
- HBAs
  - One RAID controller supported by the driver under test
- SCSI disks
  The disks will utilize the highest SCSI protocol that the driver supports.
  - At least one LUN (at least 20 Gbytes each) created on the SCSI disks
  - One disk on which the operating system resides
- Peripherals
  - SCSI CD-ROM
  - SCSI tape
- Connection
  - If HBA is a single-channel controller:
    - At least one disk drive on one controller
    - CD-ROM and tape on the controller
  - If HBA is a multi-channel controller:
    - At least one disk drive per channel (at least 20 Gbytes)
    - At least one disk drive connected to one of the internal channels
    - CD-ROM and tape can be connected to a separate channel or can be on the same channel as the disk drives if this configuration is supported by the driver

SATA

- Disk Drives
  - At least one SATA hard drive (at least 20 Gbytes)
  - One disk on which the operating system resides
- Controllers
  - One SATA controller

SCSI

- System
  - Diskette drive
- HBAs
  - One SCSI HBA supported by the driver under test
- Disk Drives
  - At least one SCSI disk (at least 20 Gbytes)
    The disks will utilize the highest SCSI protocol that the driver supports.
  - One disk on which the operating system resides
- Peripherals
  - SCSI CD-ROM
  - SCSI tape
- Connection
  - If HBA is a single-channel HBA:
    - At least one disk drive on the HBA (at least 20 Gbytes)
    - CD-ROM and tape drives on the HBA
  - If HBA is a multi-channel HBA:
    - At least one target on each channel (at least 20 Gbytes)
    - CD-ROM and tape drives can be connected to a separate channel, or they can be on a channel with disk drives present

USB Hard Drives

- Disk Drives
  - One USB hard drive (at least 20 Gbytes). If the USB hard drive does not have enough power, make sure the USB hard drive is attached to external power.
  - One disk on which the operating system resides
- Controllers
  - One USB controller

Back to Top

#### Required Software Configuration

- The size of the Solaris partition of test hard drives must be at least 20 Gbytes.
- Each test system must have a `/` (root) slice of 1 Gbyte and a `/usr` slice of 800 Mbytes.
- Any disk that has any `/` (root directory), `/usr`, `/opt`, `/var`, or `/export/home` mount point must have at least 5 Gbytes free space.
- SUNWpkgd. Click on the "Download" line near the top of the Solaris Third-Party Packaging Tools page to download the SUNWpkgd package. To install the SUNWpkgd package, see Installing the SUNWpkgd Tools.

Back to Top

### Hardware Certification Tests

Run all tests as user `root` unless otherwise indicated in the HCTS test ReadMe file.

#### Manual Tests

First run the set of tests for all controllers, then run the tests specific to the storage technology of the driver under test.

Note: If you are only certifying a USB hard disk, the first set of tests for controllers does not have to be run.

All Controllers

- Verify Driver Diskette Format and Contents
- Testing New Installation of Solaris and the Driver
- Driver Post-Installation Checklist

SCSI

- CD-ROM Support Test
- Tape Support Test

RAID

- RAID Support Test
- CD-ROM Support Test
- Tape Support Test

USB Hard Drives

- USB Hard Drive Verification Test
- USB Hard Drive Partition and Format Test
- USB Hard Drive Mount, Read, and Write Test

SATA

- SATA Hard Drive Verification Test

Back to Top

#### Verify Driver Diskette Format and Contents

You only need to perform this test if you are doing one of the following:

- Certifying a bootable device driver
- Delivering an ITU for your driver

Required Hardware

- Test machine with a diskette drive

Required Software

- The `audit_itu`(1M) utility, which is in the SUNWpkgd package.

Test Strategy

The `audit_itu`(1M) utility verifies the format and contents of a driver diskette created using `pkg_drv`(1M) or `pkg_drv2patch`(1M).

Test Procedure

1. Insert the driver diskette into the diskette drive.

2. Verify the driver diskette format and contents.

   `# volcheck`
   `# audit_itu`

Expected Results

- No error messages appear.
- The `audit_itu`(1M) command returns a value of 0.

Back to Top

#### Testing New Installation of Solaris and the Driver

This test verifies that the driver can be installed on the system and removed properly.

Required Hardware

- Test machine as described in "Required Hardware and Software"
- Controllers supported by the driver under test installed in the test machine
- CD-ROM drive supported by the driver under test
- 3-Gbyte or larger disk drives connected to the controllers

Required Software

- Driver under test in the Solaris `pkg_drv`(1M) format.

Test Strategy

- This test is performed after the Verify Driver Diskette Format and Contents test, to eliminate the possibility of encountering problems caused by a defective driver diskette.

- Solaris will be installed using the Solaris Installation CD. If the CD-ROM is supported by the new driver, this installation tests that the CD-ROM drive using the driver can perform a CD installation.

- Solaris will be installed on the disk drive supported by the new driver.

- During Solaris installation, a driver can be installed using the Configuration Assistant. This method will be used to test the driver installation using the driver diskette, and a new Solaris installation with the driver loaded.

- The realmode portion of the driver will be tested by seeing if the controllers using the new driver are listed using the Configuration Assistant.

Test Procedure

1. Install the test machine with the Solaris release and the driver under test.

2. At the initial Solaris Device Configuration Assistant screen, press `F4_Add Driver` and follow the instructions provided.

3. After the driver is installed, continue installing the Solaris OS.

4. Ensure that the test system is sliced correctly.

   - 1-Gbyte `/` (root) slice
   - `/swap` slice size at least twice the amount of RAM in the machine
   - 800-Mbyte `/usr` slice

   Note: To specify slice layout during Solaris installation, do the following:

   - Choose Manual Layout from the Automatically Layout File System menu.
   - Choose Customize from the File System and Disk Layout menu.

5. After the Solaris installation completes, reboot the system and enter the Configuration Assistant by pressing Escape when this prompt is displayed:

       SunOS Secondary Boot version xx

           Solaris Booting System

       Running Configuration Assistant...
       Press ESCape to interrupt autoboot in 5 seconds...

6. When the Solaris Device Configuration Assistant screen appears, press `F2_Continue` to display a list of device drivers loaded from the driver media that have been associated with controllers in the system.

7. Examine the Solaris Boot screen to verify that all physical devices connected to the driver under test appear in the list.

8. When prompted, reinsert the driver media.

9. Use the Driver Post-Installation Checklist to verify that the driver is installed correctly.

10. Verify that all devices connected to the controller under test can be accessed.

11. Remove the driver from the system (see the `pkgrm`(1M) man page) and verify that there are no error messages.

12. Add the driver to the system (see the pkgadd(1M) man page) and use the Driver Post-Installation Checklist to verify that the driver is installed correctly.

13. Verify that all devices connected to the controller under test can be accessed.

14. Reboot the system, and ensure that no error messages appear.

Expected Results

- Solaris is installed using the CD-ROM drive and it works properly.

- Solaris is installed on the disk drive supported by the driver under test.

- All physical devices connected to the driver under test have corresponding software entries.

- The driver installed and it works properly.

- The driver passes the Driver Post-Installation Checklist.

- The driver, all entries made by the installation process, and any man pages installed during the driver installation process are successfully removed from the system.

Back to Top

#### Driver Post-Installation Checklist

Required Hardware

- Test machine as described in "Required Hardware and Software"

Test Strategy

- After a driver is installed, certain files specific to the driver are created and other files are modified. By checking these files, you can determine whether the driver is properly installed.

Test Procedure

1. Verify that one of these two sets of files are present.
   driver_name is the name of the driver under test.

   - `/kernel/drv/`driver_name
   - `/kernel/drv/`driver_name`.conf`
   or:
   - `/platform/i86pc/kernel/drv/`driver_name
   - `/platform/i86pc/kernel/drv/`driver_name`.`conf

2. Verify that entries for the installed driver appear in these files:

   - `/boot/solaris/devicedb/master` (realmode drivers only)
   - `/etc/driver_aliases`
   - `/etc/driver_classes`
   - `/etc/name_to_major`
   - `/etc/path_to_inst`

   For example, to locate the `ncrs` driver entry in the `/etc/name_to_major` file, type:

   `# grep ncrs /etc/name_to_major`
   `ncrs 20`

Expected Results

- The files `/kernel/drv/`driver_name and `/kernel/drv/`driver_name`.conf` exist
  or
  The files `/platform/i86pc/kernel/drv/`driver_name and `/platform/i86pc/kernel/drv/`driver_name`.conf` exist.

- Each of these files contains an entry for the driver installed:

  - `/boot/solaris/devicedb/master` (realmode drivers only)
  - `/etc/driver_aliases`
  - `/etc/driver_classes`
  - `/etc/name_to_major`
  - `/etc/path_to_inst`

Back to Top

#### CD-ROM Support Test

Required Hardware

- Test machine as described in "Required Hardware and Software"
- HBA supported by the driver under test
- CD-ROM drive connected to the HBA

Test Strategy

- This test verifies that a CD-ROM drive supported by the driver under test is usable.

- This test is performed on a machine running the appropriate Solaris release, with the driver under test installed. The CD-ROM drive is connected to the HBA under test and is one of its SCSI targets.

- If the driver supports HBAs that have more than one channel, connect the CD-ROM drive to several different channels and repeat the test procedures for each.

Test Procedure

1. Reboot the system.

2. Press Escape to interrupt autoboot.

3. When the Solaris Boot screen is displayed, locate the CD-ROM SCSI target ID.
   The SCSI target ID is a number between 0 and 15. Following is a sample Solaris Boot screen:

       [ ] NET : Intel Pro100/B Fast Ethernet
           on Board PCI bus 1, at Dev 1
       [ ] DISK: (*) Target 0, QUANTUM VIKING II 4.5 WSE 4110
           on Symbios Logic 53c875 SCSI on Board PCI Bus 1, atDev

   Then reboot the system again, and verify that the controller is configured correctly.

4. After the system reboots, insert a CD into the CD-ROM drive and type these commands:

   `# volcheck`
   `# df -k`

   Examine the `df` command output, looking for an entry similar to this:

       /vol/dev/dsk/c1t0d0/x/y 253974 253974 0 100% /cdrom/x/y

   where x and y are directories and file names.

5. Type:

   `# mount`

   Look for a CD-ROM entry similar to this:

   `/cdrom/sol_9_404_x86/s0 on /vol/dev/dsk/c1t0d0/sol_9_404_x86/s0 readonly/nosetuid/nodevices/intr/largefiles/xattr/onerror=panic/dev=1740002 on Thu Sep 9 08:58:00 2004`
6. List the directory contents of the CD-ROM.

   `# ls -lR /cdrom`

Expected Results

- The CD-ROM drive has a valid SCSI target ID (0-15) on the Solaris Boot screen.
- The CD-ROM is mounted and usable.

Back to Top

#### Tape Support Test

Required Hardware

- Test machine as described in "Required Hardware and Software"
- HBA supported by the driver under test
- Tape drive connected to the HBA

Test Strategy

- This test verifies that a tape drive supported by the driver under test is usable.

- The `tar` command is used to write a file to a tape, read the same file from the tape, and store it on a disk drive. Then, the `sum` command is used to verify that there are no differences between the two files.

- This test is performed on a machine running the appropriate Solaris release, with the driver under test installed. The tape drive is connected to the HBA under test and is one of its SCSI targets.

- If the driver supports HBAs that have more than one channel, connect the tape drive to several different channels and repeat the test procedures for each.

Test Procedure

1. Verify that the system is running.

2. Insert a tape into the tape drive and reboot the system.

3. At the shell prompt, type the following:

   `# ls -l /dev/rmt`

   Output similar to the following is displayed, where n is the tape drive instance:

       lrwxrwxrwx 1 root root 55 Oct 28 12:32 /dev/rmt/n ->
         ../../devices/pci@0,0/pci1011,26@a/pci1069,20@8/st@4,0:

4. If the files are not displayed, type these commands:

   `# tapes -r /dev`
   `# ls /dev/rmt`

5. View the output and select the tape drive device file.

   If only one tape drive is installed on the system, use `/dev/rmt/0` for the file.

6. To verify that I/O operations can be performed on the tape, type the following commands, where `ksh` can be substituted by the name of any file:

   `# cd /tmp`
   `# tar cvf /dev/rmt/0 -C /bin ksh`
   `# tar xvf /dev/rmt/0`
   `# sum /bin/ksh ksh`

Expected Results

- The tape drive is accessible and usable.
- The output of the `sum` command is the same for both files.

Back to Top

#### RAID Support Test

Required Hardware

- Test machine as described in "Required Hardware and Software"
- All models of controllers supported by the driver under test
- At least three disk drives connected to the RAID controller, and configured at different RAID levels

Required Software

- RAID management utility supplied by the hardware manufacturer

Test Strategy

Exercise the different levels of RAID supported by the controller.

Note: The Hardware Certification Test Suite does not test the RAID management utility functions (see the Solaris Operating System Driver Design Guidelines).

Definitions for some of the different RAID types are provided for reference:

RAID 0
  This RAID type is also referred to as striping. Allow at least two disk drives for this RAID level. This RAID level provides no fault tolerance. Recovering lost data is not part of this RAID implementation.
RAID 1
  This RAID type is referred to as mirrored. Allow at least two disk drives for this RAID level testing. One disk is operational, and the other disk is a mirror image of the first.
RAID 5
  This RAID type is referred to as Disk Striping With Distributed Parity. Allow at least three disk drives to configure this RAID level.

Test Procedure

1. Configure RAID types using the RAID management utility available with the controller.

   Note: You must configure all the RAID types that the RAID management utility supports. If any of the RAID levels cannot be configured, the controller will not pass certification.

2. On multi-channel controllers, you must configure packs across channels.

Expected Results

- All RAID levels that the RAID management utility supports can be configured.

Back to Top

#### USB Hard Drive Verification Test

Test Strategy

This test verifies that Solaris can recognize the USB hard drive as a storage device.

Required Hardware

- One machine that meets the minimum requirements stated in the Hardware Certification Test Suite Installation Guide
- One disk on which the operating system resides
- One USB controller
- One USB hard drive. If the USB hard drive does not have enough power, make sure the USB hard drive is attached to external power.

Test Procedure

1. Hot plug a USB hard drive into your system.

2. Type the following command to ensure that the USB hard drive is configurable:

       # format -e

   The output from this command is similar to the following:

       c0d0 <DEFAULT cyl 23523 alt 2 hd 64 sec 63>
       /pci@0,0/pci-ide@1f,1/ide@0/cmdk@0,0
       c2t0d0 <DEFAULT cyl 1264 alt 2 hd 10 sec 258>
       /pci@0,0/pci103c,12bc@1d,2/storage@1/disk@0,0

   The second disk named `c2t0d0` is a USB disk.

3. Type the following command to verify that there is a USB disk entry:

   `# cfgadm`

   The output of this command is similar to the following:

       Ap_Id Type Receptacle Occupant Condition
       usb0/1 unknown empty unconfigured ok
       usb0/2 unknown empty unconfigured ok
       usb1/1 unknown empty unconfigured ok
       usb1/2 unknown empty unconfigured ok
       usb2/1 usb-storage connected configured ok
       usb2/2 unknown empty unconfigured ok

   The sixth row starting with usb2/1 is a USB disk.

4. Unplug the USB hard drive.

5. Verify that the USB disk is no longer present by typing the following command:

       # cfgadm

   The USB disk usb2/1 should no longer be there.

Expected Results

- Solaris recognizes the USB hard drive as a storage device.

Back to Top

#### USB Hard Drive Partition and Format Test

Test Strategy

This test verifies that the Solaris partitions, slices, and UFS file system can be built on the USB hard drive.

Required Hardware

- One machine that meets the minimum requirements stated in the Hardware Certification Test Suite Installation Guide
- One disk on which the operating system resides
- One USB controller
- One USB hard drive. If the USB hard drive does not have enough power, make sure the USB hard drive is attached to external power.

Test Procedure

1. Verify that the USB hard drive under test is not mounted.

2. Create a partition on the USB hard drive by using the following command, where `c2t0s0p0` is the name of the USB disk under test:

   `# fdisk /dev/rdsk/c2t0s0p0`

3. Create two slices on the partition created in the previous step using the following command:

   `# format`

   This command produces a list of available disks.

4. Select the USB disk you wish to format.

5. At the `format>` prompt, type `partition`.

   `format>partition`

   A partion menu displays.

6. Select the `0 - change '0' partition` option by typing `0` and follow the instructions to make the two slices.

7. Create a UFS file system on the slices.

   `# newfs /dev/rdsk/c2t0d0s0`

   where `c2t0d0s0` is the USB hard disk under test.

   If the `newfs` command completes successfully, a UFS file system can be built on the USB hard drive and the test has completed successfully.

Expected Results

- The USB hard drive can be partitioned.
- The USB hard drive can have slices created on it.
- The USB hard drive can have a UFS file system built on it.

Back to Top

#### USB Hard Drive Mount, Read, and Write Test Procedure

Test Strategy

This test verifies that the USB hard drive can be mounted, unmounted, read, and written to successfully.

Required Hardware

- One machine that meets the minimum requirements stated in the Hardware Certification Test Suite Installation Guide
- One disk on which the operating system resides
- One USB controller
- One USB hard drive. If the USB hard drive does not have enough power, make sure the USB hard drive is attached to external power.

Test Procedure

1. Mount one slice of the USB hard drive.

   `# mount /dev/dsk/c2t0d0s0 /mp`

   where `c2t0d0s0` is the slice of the USB hard drive under test.

2. Verify that the USB hard drive is mounted and verify that the `c2t0d0s0` USB Hard drive slice appears in the list of mounted file systems.

   `# mount`

3. Copy a file to the USB hard drive.

   `# cp -rf /`testfile `/`test.c2t0d0s0

   In this command, testfile is a generic file on your system that can be copied to the mounted slice on the USB hard drive and `test.c2t0d0s0` is the USB mount point.

   Validate that the file was copied successfully.

4. Copy a file from the USB hard drive.

   `# cp -rf /test.c2t0d0s0 /tmp/`

   In this command, `test.c2t0d0s0` is the USB mount point. Validate that the file was copied successfully from the mount point to the destination directory.

5. Unmount the slice.

   `# umount /dev/dsk/c2t0d0s0`

6. Verify that the hard drive is no longer mounted.

   `# mount`

   Validate that the entry for the USB hard drive is no longer in the output.

Expected Results

- The USB hard drive slice can be mounted.
- The USB hard drive can have files written to it.
- The USB hard drive can write files from it.
- The USB hard drive slice can be unmounted.

Back to Top

#### SATA Hard Drive Verification Test

Test Strategy

This test verifies that the SATA hard drive can be recognized successfully by the system.

Required Hardware

- One machine that meets the minimum requirements stated in the Hardware Certification Test Suite Installation Guide
- One disk on which the operating system resides
- One SATA controller
- Two SATA disk drives of equal size

Test Procedure

1. Reboot or reset the power of the test machine.

2. When the system is powering on, get into the BIOS setup. If you do not see a message telling you how to get into the BIOS setup, read the documentation for your machine. When you are in the BIOS setup, enable the support for SATA hard drives.

   For example, on the Dell OptiPlex GX270 Desktop, press F2 to get into the BIOS, and then go to the following item:

   >     Drive Configuration
   >       SATA Primary Drive

   and:

   >     Drive Configuration
   >       SATA Secondary Drive

   Change the setting of "Drive Type" from "OFF" to "AUTO".

   Change other settings if needed.

   Save changes and exit BIOS setup.

3. Perform a verbose reconfiguration reboot of the system. To do this, enter `b -rv` at the prompt when the following screen messages are displayed:

   >     <<< Current Boot Parameters >>>

   >     Boot Path :/pci@0,0/pci-ide@1f,1/ide@0/cmdk@0,0:a
   >     Boot args:

   >     Type b[file name] [boot-flags] <Enter> to boot with options
   >     i <Enter>                         to enter boot with interpreter
   >     <Enter>                           to boot with defaults

   >     <<< time out in 5 seconds >>>

   >     Select (b)oot or (i)nterpreter: b -rv

When the system is up, log in as user `root` and open a terminal to execute the following command:

>     # format -e

The output from this command should be messages such as the following about the hard disks that are recognized by the system:

>     Searching for disks...done

>     AVAILABLE DISK SELECTIONS:
>            0. c0d0 <DEFAULT cyl 26005 alt 2 hd 64 sec 63>
>               /pci@0,0/pci-ide@1f,1/ide@0/cmdk@0,0
>            1. c2d0 <DEFAULT cyl 58118 alt 2 hd 64 sec 63>
>               /pci@0,0/pci-ide@1f,2/ide@0/cmdk@0,0
>            2. c3d0 <DEFAULT cyl 55872 alt 2 hd 64 sec 63>
>               /pci@0,0/pci-ide@1f,2/ide@1/cmdk@0,0
>     Specify disk (enter its number):

Verify that this list includes the SATA disks. In the above example, `c0d0` is the IDE disk that the system resides on, and `c2d0` and `c3d0` are the SATA disks attached to the SATA controller.

Expected Results

- The SATA hard drives are recognized successfully.

Back to Top

Copyright 2005 Sun Microsystems, Inc. All rights reserved.