C H A P T E R  3

Controller, Disks, and Battery Commands

This chapter provides the available controller, disks, and battery commands with sample code. Topics covered in this chapter include:



Note - To prevent unauthorized access to administrative functions of the RAID controller, the CLI requires superuser or system administrator privileges for in-band access, and uses the controller password to authorize users of the out-of-band interface.





Note - If no command is entered on the command line, the CLI enters an interactive mode, prompting you to enter commands until the quit command is entered. All commands operate on the currently-selected device.




Controller Commands

The following commands are explained in this section:



Note - The secondary controller in dual-controller configurations does not support any administrative functions. In active/active configurations where LUNs are assigned to both the primary and secondary controllers, the CLI command can be used only with those LUNs assigned to the primary controller.



fail

The fail command simulates a controller failure and causes all the LUNs assigned to the specified controller to fail over to the redundant controller.



Note - Before running this command, perform a show redundancy command to make sure a secondary controller exists.



fail {primary | secondary}

TABLE 3-1 Arguments for fail

Argument

Description

primary

Fails the logical drive to the primary controller (default).

secondary

Fails the logical drive to the secondary controller.


 

The following example fails the secondary controller if Y is specified at the prompt. Specify N to cancel the failure.

sccli> fail secondary
Are you sure?

mute controller

The mute controller command silences the controller's audible alarm. After the fault condition that caused the alarm to sound is cleared, the next fault condition causes the alarm to sound again.

mute [controller]

For details on alarms, refer to the Sun StorEdge 3000 Family Installation, Operation, and Service Guide for your array.



Note - This command works on RAID subsystems. It does not work on JBODs. To manually silence a JBOD alarm, push the Reset button on the right ear of the array.



password

Use the password command to supply the password assigned to the array controller. The user must specify the correct password when issuing potentially dangerous commands to the array over a network connection. For interactive sessions, the CLI prompts the user for this password only when necessary; the password command is provided for non-interactive applications where the password must be embedded in a script. No password is required when accessing the array using in-band SCSI. For details on setting the password, see set password.



Note - Use quotation marks around password strings that contain spaces or apostrophes.



password password

The following example supplies the controller password, test.

sccli> password "test"

reset controller

The reset controller command shuts down the controller, flushes its cache to disk, and then restarts the controller. This temporarily causes the array to go offline, which might affect applications running on any hosts connected to the array. Also see shutdown controller.



caution icon

Caution - All reset commands are potentially dangerous. Use only as instructed.





caution icon

Caution - All reset commands cause the array to stop responding to I/O requests from the host for a period of time. This might result in data loss unless all I/O activity is suspended by halting all applications that are accessing the array, and unmounting any file systems that are mounted from the array. In redundant-controller configurations, these commands affect all LUNs on both controllers. After running a reset command, to stay in prompt mode, run the select command to reselect the device.



reset controller

# sccli /dev/rdsk/c0t5d0s2 reset controller
WARNING: This is a potentially dangerous operation. The controller will go offline for several minutes. Data loss may occur if the controller is currently in use. 
Are you sure? y
sccli: resetting controller...
sccli: controller has been reset
sccli: /dev/rdsk/c0t5d0s2: waiting for device to be ready
sccli: /dev/rdsk/c0t5d0s2: device reset
sccli: /dev/rdsk/c0t5d0s2: device is ready

 

set cache-policy

This command sets cache mode (write-back or write-through) and optimization (sequential or random-access).

set cache-policy [random-access | sequential] [write-through | write-back]

TABLE 3-2 Arguments for set cache-policy

Argument

Description

random-access

Optimizes for random access.

sequential

Optimizes for sequential access.

write-through

Disables the write cache (writes go through to the disk drives before being acknowledged).

write-back

Enables write caching (also known as "write-back" or "write-behind" caching).


 

The following example sets the cache mode to write-back.

sccli> set cache-policy write-back

The following example sets the cache mode to write-back and the optimization to sequential.

sccli> set cache-policy sequential write-back

set controller-name

The set controller-name command specifies a name for the array. The name can be between 1 and 15 characters, but the number of characters plus the length of the current controller password must not be more than 16 characters.

set controller-name controller-name

The following example sets the controller name as testname:

# sccli c2t0d0 set controller-name "testname"

set controller-password

This command sets the controller password. The password must be fewer then 8 characters.

set controller-password password

The following example sets the controller password as sun123:

# sccli c2t0d0 set controller-password "sun123"

set icl

This command is a shortcut for the set inter-controller-link command.

set icl [upper | lower] channel channel [connected | disconnected]

TABLE 3-3 Arguments for set icl

Argument

Description

{upper | lower}

The upper or lower keyword specifies the array controller slot to which the command is directed.

channel ch

The channel argument specifies the channel to be modified by the command. Valid values include 0, 1, 4, and 5.

{connected | disconnected}

The final argument specifies the desired state for the port bypass circuit.

This command is used to specify that the port bypass circuit for the specified channel on the RAID controller in the specified slot (upper or lower) is to be enabled or disabled. Normally, all inter-controller-links on both the upper and lower controllers should be connected; disconnecting the upper or lower controllers' inter-controller-link on any given host channel breaks the internal connection between the two controllers, and between the upper controller and the external connector on the lower controller and vice versa. This potentially doubles aggregate bandwidth because the controllers do not have to share bandwidth on each channel, but also prevents controller failover from working in a transparent fashion.


 

The following example sets the port bypass circuit for channel 5 on the upper controller slot to enabled.

# sccli c2t0d0 set icl upper channel 5 connected

set password

This command specifies a password that protects the RS-232 character interface, Telnet, and FTP services from unauthorized use. The string can be any alphanumeric string up to 15 characters in length, provided that the sum of the lengths of the password and the controller-name parameter is not more than 16.

set password string

To remove an existing password, specify a zero-length string with a pair of double-quote characters. For example:

# sccli c2t0d0 set password ""

set rs232-configuration

This command specifies the speed, in bits per second, for the specified RAID controller port. Single controller configurations have a single RS232 port (port 1). Redundant controllers have a second port (port 2). Usually, both ports are connected to support controller failover, so both should be set to the same speed. The default speed is 38400. The controller must be reset for this change to take effect.



caution icon

Caution - All reset commands cause the array to stop responding to I/O requests from the host for a period of time. This might result in data loss unless all I/O activity is suspended by halting all applications that are accessing the array, and unmounting any file systems that are mounted from the array. In redundant-controller configurations, these commands affect all LUNs on both controllers. After running a reset command, to stay in prompt mode, run the select command to reselect the device.



set rs232-configuration port-number speed

In the following example, the RAID controller RS232 port 1 band rate is set to 38400:

# sccli c2t0d0 set rs232-configuration 38400

set unique-identifier

This command specifies the unique identifier for the array subsystem as a 6-digit hexadecimal number from 0 to 0xfffff. This identifier is initialized from the chassis serial number automatically, and should not be changed unless the chassis is replaced.

This value is used to construct unique values for Ethernet address, FC WWNs, and other identifiers, and changing it unnecessarily might cause the logical units to become inaccessible to hosts. The controller must be reset for this change to take effect.



caution icon

Caution - All reset commands cause the array to stop responding to I/O requests from the host for a period of time. This might result in data loss unless all I/O activity is suspended by halting all applications that are accessing the array, and unmounting any file systems that are mounted from the array. In redundant-controller configurations, these commands affect all LUNs on both controllers. After running a reset command, to stay in prompt mode, run the select command to reselect the device.





Note - If the value 0 is specified, it is interpreted as a request to set the controller unique ID to match the chassis serial number, which is obtained from the enclosure services device in the chassis.



set unique-identifier

The following example sets the controller unique identifier as 0x1234:

# sccli c2t0d0 set unique-identifier 0x12345

The following example sets the controller unique identifier to the default value based on the chassis serial number. This command must be followed by the reset controller command before the change takes effect.

# sccli c2t0d0 set unique-identifier 0

show cache-policy

This command displays the cache write policy for the controller. Values returned include: write through or write back.

show cache-policy

The following example shows the cache policy is set to write back.

sccli> show cache-policy
 mode: write-back
 optimization: sequential

show controller-name

This command displays the RAID controller name. If the RAID controller name is not set, the command returns "not set."

show controller-name

The following example shows the controller name is test.

sccli> show controller-name
 controller-name: test

show inquiry-data

This command displays the SCSI INQUIRY data returned by the array controller. The output of this command varies from one product to another, and from one channel to another.

show inquiry-data

The following example shows an in-band Sun StorEdge 3510 inquiry:

sccli> show inquiry-data
 Vendor: SUN
 Product: StorEdge 3510
 Revision: 327R
 Peripheral Device Type: 0x0
 NVRAM Defaults: 327R 3510 v2.54
 Bootrecord version: 1.31H
 Page 80 Serial Number: 0001870043BF5000
 Page 83 Logical Unit Device ID: 600C0FF0000000000001870043BF5000
 Page 83 Target Device ID: 206000C0FF000187
 IP Address: 199.249.246.28
 Page D0 Fibre Channel Address: EF (id 0)
 Page D0 Node Name: 206000C0FF000187
 Page D0 Port Name: 216000C0FF000187
 Ethernet Address: 00:C0:FF:00:01:87
 Device Type: Primary

show redundancy-mode

The show-redundancy mode command shows whether the two controllers are operating correctly as a redundant pair. Returned values include: Active-Active, disabled, enabled, primary, or secondary.

show redundancy-mode

The following example shows the controller mode is Active-Active.

sccli> show redundancy-mode
 Primary controller serial number: 3341097
 Redundancy mode: Active-Active
 Redundancy status: Enabled
 Secondary controller serial number: 3341045

show unique-identifier

This command displays the controller unique identifier, which defaults to the enclosure serial number. A valid controller unique identifier is a hexidecimal number from 0 to 0xfffff. It is displayed as a 6-digit value, where the first digit is always 0 for consistency with the presentation of FRU serial numbers. The default value for the unique ID is the FRU serial number of the midplane/chassis in which the controller resides.

show unique-identifier

The following example shows the unique identifier is 00476F.

sccli> show unique-id
 unique-identifier: 00476F

shutdown controller

This command shuts down the RAID controller and stops I/O processing. This temporarily causes the array to go offline, which might affect applications running on any hosts connected to the array. Data in the controller cache is flashed to logical drives. After issuing this command, issue the reset controller command.



caution icon

Caution - The shutdown command causes the array to stop responding to I/O requests from the host. This might result in data loss unless all I/O activity is suspended by halting all applications that are accessing the array, and unmounting any file systems that are mounted from the array. In redundant-controller configurations, these commands affect all LUNs on both controllers.





Note - Use this command whenever the RAID controller is powered off. It ensures that all data is written to disk, and that the backup battery (if present) will not be drained by the cache memory.



shutdown controller

# sccli /dev/rdsk/c0t5d0s2 shutdown controller
WARNING: This is a potentially dangerous operation. The controller will go offline for several minutes. Data loss may occur if the controller is currently in use. 
Are you sure? y
sccli: shutting down controller...
sccli: controller is shut down

 

unfail

The unfail command reverses the fail secondary command, permitting the secondary controller to resume operation and restore the controller pair to normal (redundant) operation.



Note - When a primary controller fails, the secondary controller becomes the primary controller. The unfail command makes the initial primary controller the secondary controller.



 unfail

The following example reverses the fail secondary command.

sccli> unfail
Are you sure? y


Disk Commands

The following commands are explained in this section:

configure global-spare

This command specifies a global spare disk. The disk drive status is set to standby.

configure global-spare disk

TABLE 3-4 Arguments for configure global-spare

Argument

Description

disk

Specify the disk to create. For example, specify the disk with target ID 1 on channel 2 as 2.1.


 

The following example configures disk drive ID 5 on SCSI channel 2 as a global spare:

# sccli c2t0d0 configure global-spare 2.5

set led

SCSI arrays only. This command illuminates the drive LED for the specified disk (or slot). For JBODs, specify a disk device using a Solaris device name such as sd31 or c1t0d0s2, or specify a slot number. Use the show led-status command to show the status of the identified disk drive.



Note - Selecting a slot by disk name is not supported in dual-bus enclosure configurations because the enclosure services processor resides on only one of the internal buses and the CLI might not be able to unambiguously determine the slot location of a particular device. In such configurations, use the show enclosure-status command and the documentation provided with your enclosure to determine the correct slot number instead.



To illuminate a specific drive LED in a RAID array, use the following parameters:

set led disk ch.id {on | off}

To illuminate a specific drive LED in a JBOD, use the following parameters:

set led {slot n | disk sdn | disk cXtYdZ} {on | off}

TABLE 3-5 Arguments for set led

Argument

Description

slot n

Illuminates the drive LED for the specified disk drive slot.

disk sdn

Illuminates the drive LED for the specified Solaris disk drive slot.

disk cXtYdZ

Illuminates the drive LED for the specified Solaris disk drive slot.

ch.id

Illuminates the drive LED for the specified drive within a RAID subsystem.

{on | off}

Specify whether to illuminate the LED.


 

In the following example, assume the user wants to identify the drive with SCSI address 8 in the enclosure associated with the enclosure device /dev/es/ses0:

sccli> set led disk 0.8 on
 (enclosure sn 005362) led-slot-0: on

show disks

This command displays information about the disk drives in the array enclosure and any expansion chassis.

show disks [disk-list | channel {ch} | free | all] [-b | --buffer-size] 

TABLE 3-6 Arguments for show disks

Argument

Description

disk-list

Shows specific disks. Use any of the following formats: ch.id, ch.idm-n.

ch is physical device channel and id is the SCSI ID of the device and m to n represents a contiguous range of IDs on the same channel. For example, 2.0, 2.3 or 2.2-5.

channel ch

Shows all disks on the specified channel.

all

Shows all disk drives.

free

Shows all unassigned disks.

-b, --buffer-size

Shows the disk buffer size.


 

The following example returns information for disks ID 0, ID 3, and ID 7 on SCSI channel 2:

# sccli c2t0d0 show disks 2.0,2.3,2.7

The following example returns information for disks on SCSI channel 2 for disks 3 through 7, and for SCSI channel 1 disk 4:

# sccli c2t0d0 show disks 2.3-7,1.4

Returned values include: channel number, disk SCSI ID, size, speed (megabytes per second), LD assignment, status, vendor and product ID. If the -b option is specified, the drive buffer size and drive serial number are displayed.

LD assignment values include:

Status values include:

The following example shows all disk information.

# sccli s28 show disks
sccli: selected se3000://199.249.246.28:58632 [SUN StorEdge 3510  SN#000187]
Ch  Id      Size   Speed  LD     Status   IDs
-----------------------------------------------------------------------
 2   0   33.92GB   200MB  ld0    ONLINE   SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET10CZK00007325
 2   1   33.92GB   200MB  ld0    ONLINE   SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET0RSCH00007309
 2   2   33.92GB   200MB  ld0    ONLINE   SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET109TH00007325
 2   3   33.92GB   200MB  ld1    STAND-BY SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET1097C00007325
 2   4   33.92GB   200MB  ld1    ONLINE   SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET0ZZYZ00007325
 2   5   33.92GB   200MB  ld1    ONLINE   SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET0QQHK00007307
 2   6   33.92GB   200MB  ld2    ONLINE   SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET0TJL300007303
 2   7   33.92GB   200MB  ld2    ONLINE   SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET0TM3100007312
 2   8   33.92GB   200MB  NONE   NEW      SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET0T3L000007229
 2   9   33.92GB   200MB  GLOBAL STAND-BY SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET0SX7400007312
 2  10   33.92GB   200MB  GLOBAL STAND-BY SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET0TJFT00007313
 2  11   33.92GB   200MB  ld3    ONLINE   SEAGATE ST336752FSUN36G 0205
                                              S/N 3ET0TJSD00007309

show led-status

This command displays the status of the LED adjacent to the specified disk drive slot in the array enclosure or expansion chassis.

To display the status of LEDs in LVD RAID enclosures, use the following syntax:

show led-status disk ch.id

To show the status of LVD JBOD enclosures, use the following parameters:

show led-status {slot n | disk sdn | disk cXtYdZ}

TABLE 3-7 Arguments for show led

Argument

Description

slot n

Shows the status for the LED adjacent to the specified disk drive slot. This argument is not accepted for RAID controllers.

disk sdn

Shows the status for the LED adjacent to the specified Solaris disk drive slot. This argument is not accepted for split-bus chassis.

disk cXtYdZ

Shows the status for the LED adjacent to the specified Solaris disk drive slot. This argument is not accepted for split-bus chassis.

ch.id

Shows the status for the LED adjacent to the specified drive within a RAID subsystem.


 

The following example shows the status of the LED adjacent to the disk assigned to drive slot 3 for an expansion chassis:

sccli> show led slot 3
 led-slot-3: on

unconfigure global-spare

This command unconfigures a global spare disk.

unconfigure global-spare disk

TABLE 3-8 Arguments for unconfigure global-spare

Argument

Description

disk

Specify the disk to create. For example, specify the disk with target ID 1 on channel 2 as 2.1.


 

The following example unconfigures disk drive ID 5 on SCSI channel 2 as a global spare:

# sccli c2t0d0 unconfigure global-spare 2.5


Battery Commands

The show battery-status command is explained in this section.

show battery-status

Fibre Channel arrays only. This command displays the status of the battery modules, which preserve the nonvolatile cache memory in each RAID controller. For redundant controllers, status for both batteries is shown. Status values include: Expired, Warning, or Good. A status of Warning indicates that the battery will expire within 21 days.



Note - If the battery in-service-date is not set, you are prompted to set the in-service date to the system clock date when you run the show battery-status command. If you replace a battery, run this command immediately to ensure the battery status is accurate when you run the command in the future. For details on replacing the battery, refer to the Sun StorEdge 3000 Family FRU Installation Guide.



If the battery type is an early board module, then battery expiration monitoring is not supported. In this case, a message displays that says, "battery board type is not supported."

show battery-status

The following example shows one good battery and one expired battery:

sccli> show battery-status
 Upper Battery Type: 1
 Upper Battery Manufacturing Date: Sat Jan 04 00:00:00 2003
 Upper Battery Placed In Service:  Thu Jan 22 10:59:58 2004
 Upper Battery Expiration Date:    Tue Jan 03 06:00:00 2006
 Upper Battery Status: good
 
 
 Lower Battery Type: 1
 Lower Battery Manufacturing Date: Tue Jan 02 00:00:00 2001
 Lower Battery Placed In Service: Sun Dec 09 00:00:00 2001
 Lower Battery Expiration Date: Tue Dec 09 00:00:00 2003
 Lower Battery Status: expired

The following example shows one good battery one and one battery that is set to expire within the next week:

sccli> show battery-status
 Upper Battery Type: 1
 Upper Battery Manufacturing Date: Sat Jan 04 00:00:00 2003
 Upper Battery Placed In Service:  Thu Jan 22 10:59:58 2004
 Upper Battery Expiration Date:    Tue Jan 03 06:00:00 2006
 Upper Battery Status: good
 
 
 Lower Battery Type: 1
 Lower Battery Manufacturing Date: Tue Jan 02 00:00:00 2001
 Lower Battery Placed In Service: Sat Dec 29 00:00:00 2001
 Lower Battery Expiration Date: Mon Dec 29 00:00:00 2003
 Lower Battery Status: warning