3ware 8000 Series CLI

Command Line Interface
PN 900-0024-00, Revision E
April 23, 2003
User Guide
CLI
for Linux

Copyright

Trademarks

3ware, the 3ware logo, Escalade, StorSwitch, TwinStor, R5 Fusion and 3DM are all registered trademarks of 3ware, Inc. All other trademarks herein are property of their respective owners.

Disclaimer

3ware, Inc. assumes no responsibility for errors or omissions in this docu­ment, nor does 3ware, Inc. make any commitment to update the informa­tion contained herein.
Contents
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Command Line Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
Ways to Run the CLI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4
1) Interactive with command interface . . . . . . . . . . . . . . . . . .4
2) Single command with output . . . . . . . . . . . . . . . . . . . . . . . .4
3) Multiple commands through an input file . . . . . . . . . . . . . .5
Controller Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5
The info command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5
Examples using Interactive Mode . . . . . . . . . . . . . . . . . . . . . .7
Settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .12
The set command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .12
Examples using Interactive Mode . . . . . . . . . . . . . . . . . . . . .12
Array Maintenance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .15
The maint command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .15
Examples using Interactive Mode . . . . . . . . . . . . . . . . . . . . .17
Alarms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .34
The alarms command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3 4
Examples using Interactive Mode . . . . . . . . . . . . . . . . . . . . .35
Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .36
The help command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .36
Examples using Interactive Mode . . . . . . . . . . . . . . . . . . . . .36
3ware Technical Support and Services . . . . . . . . . . . . . . . . . 40
Sales and ordering information . . . . . . . . . . . . . . . . . . . . . . . . . 40
Feedback on this manual . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .40
iii

Introduction

Introduction
The Command Line Interface (CLI) for Linux is provided to manage 7000 and 8000 series 3ware Esca lade trollers. Multipl e syst ems con taini ng Esca lade cont roll ers ma y be managed using the CLI via a command line or script. CLI is use­ful in environmen ts where a graphical user interface (GUI) is not available.
ATA RAID con-
1 www.3ware.com

Features

Features
The 3ware CLI provides the basic functionality of the 3ware Disk
®
Management (3DM You can view array status and version information, and perform maintenance functions like adding or removing dri ves. CLI also includes advanced featu res for reconfiguring RAID arrays online.
) utility through a Command Line Interface.
Note:
User’s Guide for complete information on 3DM and for configuring or upgrading your computer.
The CLI command set is listed below and described in detail in the Command Line Interface chapter of this guide:
• info - to view basic controller information
• alarms - to disp lay a list of AENs for all controllers
• set - to display and modify current settings
• maint - to perform drive and RAID arr ay maint enance opera­tions for a single controller
• help - to display a li st of commands and options
Refer to the Escalade ATA RAID Controller
www.3ware.com 2

Installation

Installation
You will need to be root or have root privileges to install the CLI to /usr/sbin and to run the CLI.
Filename: tw_cli.tar
To install the CLI, type the following as root:
tar xf tw_cli.tar -C /usr/sbin
To install the CLI to a different location, change /
usr/sbin/
to the
desired location.
Note:
The installation location needs to be in the envi­ronment path for root to execu te the CLI without using complete pa ths (i.e., if installed to /
usr/sbin/
, you can type tw_cli on the command line, otherwise you will have to type the com p le te path:
Warning!
/home/user/tw_cli
).
For all of the func ti ons of the CLI to work properly, you must have the proper CLI, firmware, and driver versi ons installed. Check www.3ware.com for the latest versions
and upgrade instructions. If the proper firmware and driver versions are not installed CLI will not report the controller when issuing the info command.
3 www.3ware.com

Command Line Interface

Command Line Interface
Note:
In this chapter, text surrounded by [] brackets
indicates optional par amet er s.

Ways to Run the CLI

1) Interactive with command interface
tw_cli
Description:
Execute tw_cli to get into a console where you can interactively enter commands to get, set or maintain your Escalade.
Example:
tw_cli 3ware CLI>
The main prompt is display ed when the program is awaiting a com­mand.
3ware CLI>
2) Single command with output
tw_cli <command line arguments>
CLI run command
Description:
This command doesn’t invoke the main CLI prompt if used with com­mand line arguments.
Syntax:
tw_cli <command line arguments>
www.3ware.com 4
3ware Escalade ATA RAID Controller CLI User Guide
Example:
tw_cli info c 0 u0
3) Multiple commands through an input file
tw_cli -f <filename>
CLI run command
Description:
This method executes a specific filename, where the filename is the name of a text file containing a list of CLI commands which the user types in advance. Each command should be on a separate line.
Syntax:
tw_cli -f <filename>
Example:
tw_cli -f clicommand.txt
Note:
All examples given in the follo w ing sections will
reflect the interactive mode method.

Controller Information

Note:
identification.
The
info
command
The info command provides information about the 3ware Escalade controller, the attached drives, and configured RAID arrays or units. This command is for querying purposes only. To make modi­fications use the set command to change the settings and the maint command to maintain the R A ID arrays.
5 www.3ware.com
Commands will be displayed in italics for easy
Command Line Interface
Specific options for the info command:
•Controller in formation options
- model - provides the controller model number
- firmware - provides the controller firmware version
- bios - provides the controller bios version
- monitor - provides the controller monitor version
- driver - provides the controller driver version.
- serial - provides the controller serial number
- pcb - provides the controller revision number
- achip - provides the controller achip version
- pchip - provides the contro ller pchip version
- numunits - provides the number of units on the controller
- numports - provides the number of ports on the controller
- numdrives - provides the number of drives on the controller
- allunitstatus - provides simple numeric status for all units
- drivestatus - provides the status of drives on the controller
•Unit information options
- status - provides the status of a specific unit
- rebuildstatus - provides percent complete of rebuild
- verifystatus - provides percent complete of verify
- initializestatus - provide percent complete of initialization.
•Port (drive) information options
- status - provides the status of a drive on the controller
- model - provides the drive manufacturer model number
- serial - provides the drive serial number
- capacity - provides drive capacity
- smart - provides SMART data in hex format for troubleshooting a drive
Syntax:
info [c<c>[u<u>|p<p>][item]]
www.3ware.com 6
3ware Escalade ATA RAID Controller CLI User Guide
Note:
Ιf c is not specified, information for all controllers is dis-
played, including a brief description of each.
Ιf only c is specified, information about the cth controller is
provided in detail.
Ιf c is specified and u is also specified, information about the uth unit on the cth controller is provided in detail.
Ιf c is specified and u is also specified with status, text and hex code of the status is displayed in the form OK (0xFF). Also, an error code is returned, bi t masking bad drives if any of the drives used by the array are bad. For example, if port 2 is bad, the return code would be 4 (in hex).
Ιf c is specified and u is also specified with rebuildstatus, then the status of the array is displayed (e.g., 0=array is not rebuilding, 1-99 = the percentage of the rebuild)
Ιf c is specified and p is also specified, information about
the pth port on the cth controller is displayed.
Examples using Interactive Mode
info
Example:
3ware CLI> info
Sample of output:
List of controllers
------------------­Controller 1: Escalade 7000-2 (2 ports) Controller 0: Escalade 7500-8 (8 ports)
7 www.3ware.com
Command Line Interface
info
for specific controller
Example:
3ware CLI> info c0
Sample of output:
Controller 0
-----------­Model: 7500-8 FW: FE7X 1.05.00.034 BIOS: BE7X 1.08.00.038 Monitor: ME7X 1.01.00.035 Serial #: D415TGZE PCB: Rev B Achip: 3.2 Pchip: 1.3
# of units: 3
Unit 0: RAID 5 60 .3 GB (117262 592 blocks ): REBUILDING (2%) Unit 3: JBOD 20.48 GB (40000464 blocks): OK Unit 4: RAID 1 81 .96 GB (16008 4480 block s) : VERIFYING (16%)
# of ports: 8
Port 0: MAXTOR 98196H8 V80EDX1C 81.96 GB (160086528 blocks): OK(unit 0) Port 1: Maxtor 98196H8 V80539XC 81.96 GB (160086528 blocks): OK(unit 0) Port 2: Maxtor 98196H8 V80539RC 81.96 GB (160086528 blocks): OK(unit 0) Port 3: Maxtor 92048D8 W802SE1A 20.48 GB (40000464 blocks): OK (unit 3) Port 4: Maxtor 98196H8 V80HRGRC 81.96 GB (160086528 blocks): OK (unit 4) Port 5: Maxtor 98196H8 V80HRGFC 81.96 GB (160086528 blocks): OK (unit 4) Port 6: DRIVE NOT PRESENT Port 7: DRIVE NOT PRESENT
www.3ware.com 8
3ware Escalade ATA RAID Controller CLI User Guide
info
Example:
3ware CLI> info c0 u0
for specific unit on a controller
Sample of output:
Controller 0, Unit 0
-------------------­Status: REBUILDING (54%) Unit type: RAID 5 Size: 60.3 GB (117262592 blocks) # of subunits: 3
Subunit 0: CBOD: OK Physical Port: 0 Logical Port: 0
Subunit 1: CBOD: OK Physical Port: 1 Logical Port: 1
Subunit 2: CBOD: OK Physical Port: 2 Logical Port: 2
info
Example:
3ware CLI> info c0 p0
9 www.3ware.com
for specific por t (dr ive)
Sample of output:
Controller 0, Port 0
---------------------­Status: OK Model: MAXTOR 98196H8 Size: 81.96 GB (160086528 blocks) FW: ZAH814Y0 Serial #: V80EDX1C Unit: 0
Command Line Interface
info
for specific code versions on a specific controller
(firmware, bios, monitor, model, driver)
Example:
3ware CLI> info c0 firmware
Sample of output:
FE7X 1.12.34.24
info
Example:
3ware CLI> info c0 p0 serial
info
Example:
3ware CLI> info c0 p0 smart
for specific por t (dr ive)
Sample of output:
D415TGZE
for SMART data on a specific drive
Sample of output:
10 00 01 0A 00 FD FC A8 00 00 00 00 00 00 03 27 00 C8 C8 52 53 00 00 00 00 00 04 32 00 FD FD 63 00 00 00 00 00 00 05 33 00 FD FD 00 00 00 00 00 00 00 06 01 00 FD FD 00 00 00 00 00 00 00 07 0A 00 FD FC 00 00 00 00 00 00 00 08 27 00 FC EF 49 BC 00 00 00 00 00 09 32 00 F6 F6 F4 69 00 00 00 00 00 0A 2B 00 FD FC 00 00 00 00 00 00 00 0B 2B
Note:
www.3ware.com 10
The SMART data is displayed in hex format.
3ware Escalade ATA RAID Controller CLI User Guide
drivestatus
Description:
To get a general status of the drives of a controller.
Example:
3ware CLI> info c0 drivestatus
Sample of output:
# of ports: 4
Port 0: Maxtor 98196H8 V8096CC C 81.96 GB (160 086528 blocks): OK (unit 0) Port 1: DRIVE NOT PRESENT Port 2: DRIVE NOT PRESENT Port 3: Maxtor 98196H 8 V805W6SC 81 .96 GB (16008 6528 blocks): OK (unit 0)
rebuildstatus
Example:
3ware CLI> info c0 u2 rebuildstatus
Sample of output:
60
Controller not found
Example:
3ware CLI> info c2
Sample of output:
Invalid controller id specified, no control­ler with id 2 exists.
11 www.3ware.com
Command Line Interface

Settings

The
set
command
The set command can be used to display and modify settings.
rebuild - sets the rebuild rate (per controller basis)
cache - enables or disables caching on a per array unit basis for RAID 1, 5, and 10 arrays.
Note:
A value of 1 indicates slowest I/O and fastest rebuild rate. A value of 5 indicates fastest I/O and slowest rebuild. Interim values scale linearly (e.g., a value of 3 indicates a rebuild rate half as fast as a rebuild of 1
Syntax:
set [ rebuild c<c> <1..5> | cache c<c> u<u> [on|off] ]
).
Examples using Interactive Mode
set
Description:
Using the set command without the rebuild or cache options dis­plays the current configuration, as shown below:
Example:
3ware CLI> set
Sample of output:
Controller 1 =======================================
Rebuild Rate setting for Controller 1
www.3ware.com 12
3ware Escalade ATA RAID Controller CLI User Guide
------------------------------------­1 (Fastest Rebuild)
Cache Settings for Controller 1
-------------------------------­Unit 0: ON
Controller 0 =======================================
Rebuild Rate setting for Controller 0
------------------------------------­1 (Fastest Rebuild)
Cache Settings for Controller 0
-------------------------------­Unit 0: ON
13 www.3ware.com
Command Line Interface
set cache
Example:
3ware CLI> set cache c0 u0 on
Sample of output:
Turning the c ache on for unit 0 on controller 0
set cache
Example:
3ware CLI> set cache c0 u0 off
Sample of output:
Turning the cache off for unit 0 on controller 0
Note:
enable
disable
The Escalade ATA RAID Controller gives you a choice of disabling the write cache for your disk arrays. Write ca che is used to store data lo cally on the d rive before it is written to the disk, allowing the computer to continue with its next task. Enabling the write cache results in the most efficient access times for you r comput er system. There may be instances when you always want the com­puter to wait for the drive to write all the data to disk before going on to it s next task. For this case, you must disable the write cache.
set rebuild
Description:
T o set the rebuild rate of controller 0 to 3 (the middle value).
www.3ware.com 14
3ware Escalade ATA RAID Controller CLI User Guide
Example:
3ware CLI> set rebuild c0 3
Sample of output:
Setting the rebuild rate of controller to 3 (Balanced rebuild and I/O)
Note:
Setting the rebuild rat e of a co n troller allo w s the user to set the relative perfor mance of normal IO and background tasks.

Array Maintenance

The
maint
command
The maint command enables a user to perform maintenan ce operations on the controller, its units, and drives. It is recommended that you use the info command first to query the controller information prior to using the maint command. The array maintenance feature supports:
add - adds a drive. The new dri ve can be s pecifie d as a hot spare , as a new JBOD after it is physically connected to the controller, or a CBOD, which is a configurable JBOD that can be used to rebuild a degraded array.
remove - removes a drive from a port. After this is done, a drive can safely be rem o ved from the controller.
createunit- cr eates a unit.
deleteunit - deletes a unit.
rebuild - rebuilds a degraded array. Specify a unit number on a controller you want to rebuild, along with the port number of an available disk drive . Specif ying the ignoreECC option continues the rebuild even if ECC errors are detected.
flush - flushes cache on the controller(s).
verify - verifies t he redundanc y of a RAID 1, RAID 10, or RAID 5 array.
15 www.3ware.com
Command Line Interface
Warning!
If you try to add a JBOD, you must add it to a port that was a JBOD prior to removal of the drive.
Syntax:
maint [
add c<c> p<p> [jbod|c bod|spare] | remove c<c> p<p> | createunit c<c> r<raid<0|1|10|5>|<j|c>bod|spare>
[k<stripe>] p<p:p..> [noscan] | deleteunit c<c> u<u> [noscan] | rebuild c<c> u<u> p<p> [ignoreECC] | flush c<c> [u<u>] | verify c<c> u<u> [stop]
]
Table 1: Createunit RAID Types and Stripe Sizes
RAID Type Stripe Size
Createunit
the following to be specified
allows
JBOD CBOD SPARE RAID10
For RAID1 and RAID10: 64k, 128k, 256k, 512, and 1024k.
RAID1
For RAID5: 64k.
Note:
RAID5
Do not specify a stripe size for JBOD, CBOD, or a spare. For more information regarding RAID types, see the Escalade User Guide available at www.3ware.com.
www.3ware.com 16
3ware Escalade ATA RAID Controller CLI User Guide
Examples using Interactive Mode
maint add
Description:
To add a disk drive that is at port 3 to controller 0.
Warning!
Adding a drive with the CLI, as with 3DM, requires an approved hot swap carrier. If you do not have a hot swap
carrier you must power down your system before adding any new drives. Refer to the Escalade User Guide’s Hardware Installation section for physically attaching new drives and using the Disk Array Configuration Utility. Attaching a new drive with­out a hot swap carrie r can cause a syste m hang and data corrup tion. You may even dam age the drive and compute r sy stem.
Adding a RAW drive
Newly added drives, which are not specified as a CBOD, JBOD, or a spare drive, wil l be added as a raw device with no unit number assigned. This drive can be used later as part o f the createunit command or for rebuilding a degraded array. If you reboot your system before using the raw drive it will automatically become a CBOD unit. To add a raw drive with the CLI, physically a dd the drive using an approved hot swap carrier and issue the following command:
Example:
3ware CLI> tw_cli maint add c0 p2
Sample of output:
Successfully a dded a raw drive to port 2 on controller 0
17 www.3ware.com
Command Line Interface
Adding a CBOD drive
A CBOD unit is a "configurable JBOD" that will be assigned a unit number when added. This number is usual ly the same as the port number unless the unit number is already in use as in the case of a degraded array. If this happens the new drive will be assigned the lowest available unit number.
This single CBOD unit can be used later for rebuilding a degraded array. To add a CBOD unit with the CLI, physically add the drive using an approved hot swap carrier and issue the following com­mand:
Example: 3ware CLI> tw_cli maint add c0 p1 cbod
Sample of output:
Successfully a dded a CBOD to port 1 on co n­troller 0
Adding a JBOD drive
JBOD units are “just a bunch of disks” and used just like an indi­vidual drive. This type of RAID unit is assigned a unit number when added and must be added to the same port t he JBOD unit was on before. JB ODs can al so be co nfigured later as part of a software RAID array instead of config uring them as a 3ware ha rdware RAID array. To add a JBOD unit with the CLI, physically add the drive using an approved hot swap carrier and issue the following com­mand.
Example: 3ware CLI> tw_cli maint add c0 p0 jbod
Sample of output:
Successfully a dded a JBOD to port 0 on co n­troller 0
www.3ware.com 18
3ware Escalade ATA RAID Controller CLI User Guide
When adding a JBOD dr ive t he phy sical driv e canno t be f rom a pre ­vious 3ware array including a CBOD or a spare drive. To use a drive from a previous array as a JBOD, add the drive as a raw device instead of a JBOD and then use the createunit com- mand to overwrite the old configuration.
Adding a SPARE drive
A SPARE unit is a drive that is reserved to replace a fa il ed drive in a redundant array. The degraded array is then au tomatically rebuilt. This type of RAID unit wil l be assigned a unit number when added. This number is usually the same as the port number unles s the unit number is already in use as in the case of a degraded array. If this happens, the new drive will be assign ed the lowe st available unit number.
Hot spares should be created immediately after creating a RAID-1, RAID-10, or RAID-5 arra y. To specify a hot spare with the CLI, physically add the drive using an approved hot swap carrier and issue the following comm a nd:
Example: 3ware CLI> tw_cli maint add c0 p0 spare
Sample of output:
Successfully a dded a JBOD to port 0 on co n­troller 0
Alert!
Hot spare drives must be eq ual to or la rg er than t he drives
used for the redundant array in order for the rebuild to
begin.
19 www.3ware.com
maint remove
Description:
T o remove a disk drive from port 3 of controller 0.
Command Line Interface
Note:
Drives cannot be removed if they are part of a degraded or non-redundant array, with the exception of JBOD drives.
Warning!
You must first unmount a JBOD drive before issuing the remove command. Failure to do so may res ult in a sys tem hang and data corruptio n.
Example:
3ware CLI> maint remove c0 p3
Sample of output:
Successfully removed drive from port 3 on con­troller 0
maint createunit
Description:
T o create raid array s. The following example illustrates the creation of a RAID 5 array with a 64k stripe size with drives on ports 0 through 7 on controller 0.
Note:
Before creating a unit you must first use the add command for the controller to recognize each drive afte r they are physically connected. Ports that have a unit num­ber already assigned cannot be used to cre at e a new unit.
Units include RAID arrays as well as CBOD, JBOD, and spare drives. Use the info command to d etermine i f a port a lready has a
www.3ware.com 20
3ware Escalade ATA RAID Controller CLI User Guide
unit number. Newly added drives, which are not specified as a CBOD, JBOD, or spare drive, will be added as a raw devi ce with no unit number assigned. Only raw drives can be used to create a new unit. When deleting a unit, the drives al so become raw devices, which can then be used to create a new unit.
Example:
3ware CLI> maint createunit c0 rraid5 k64
p0:1:2:3:4:5:6:7
Sample of output:
Created unit 0
maint createunit (with noscan option)
Description:
When creating a unit with the "noscan " option the unit will not be exported or seen by the OS.
Example:
3ware CLI> maint createunit c0 rraid10 k1024
p0:1:2:3:4 noscan
Sample of output: Created unit 0
Note:
Since "noscan" opti on was specified, de vice sda is
not available to the OS, as shown below:
linux:~ # fdisk /dev/sda Unable to open /dev/sda
21 www.3ware.com
Command Line Interface
Note:
If the device needs to be added at a later ti me there are two opt ions: 1) Reboot system, a t wh ich time the OS will scan a nd add detected arrays, or 2) Issue the fol­lowing command:
echo "scsi add-single-device 0 0 0 0 " >/proc/scsi/scsi
SCSI # (3ware controller #)
Channel
#(Always0)
ID Unit #
Port # (Always 0)
Echo "scsi add-single-device 0 0 0 0">/proc/scsi/scsi
Figure 1 . maint createunit (noscan) - Add device syntax options
maint deleteunit
Description:
To delete an existing RAID array unit.
Example:
3ware CLI> maint deleteunit c0 u2
Sample of output:
Deleted unit 2
Warning!
Backup any critical data pr ior to deleti ng a unit. Failur e to do so will re sult in lost data.
www.3ware.com 22
3ware Escalade ATA RAID Controller CLI User Guide
Warning!
You must first unmount the SCSI device in Linux before issuing the deleteunit command. CLI wil l not prevent you from deleting a mounted device.
Example: Deleting 3 RAID-1 Arrays and Creating a Single RAID-5 Array
3ware CLI> info c0 Controller 0
------------­Model: 7500-12 FW: FE7X 1.05.00.042 BIOS: BE7X 1.08.00.044 Serial #: M12600A2170030 PCB: Rev3 PCHIP: V1.30 ACHIP: V3.20
# of units: 5
Unit 0: RAID 1 30.01 GB (58631296 blocks): OK Unit 2: RAID 1 122.94 GB (240119680 blocks): OK Unit 4: RAID 1 122.94 GB (240119680 blocks): OK Unit 6: RAID 1 122.94 GB (240119680 blocks): OK Unit 8: RAID 5 245.88 GB (480253440 blocks): OK
# of ports: 12
Port 0: QUANTUM FIREBALLP LM30 186013438780
30.02 GB (58633344 blocks): OK (unit 0) Port 1: QUANTUM FIREBALLP LM30 186013534268
30.02 GB (58633344 blocks): OK (unit 0) Port 2: Maxtor 4G120J6 G6037FAE 122.94 GB (240121728 blocks): OK (unit 2) Port 3: Maxtor 4G120J6 G603GLDE 122.94 GB (240121728 blocks): OK (unit 2) Port 4: Maxtor 4G120J6 G603G1RE 122.94 GB
23 www.3ware.com
Command Line Interface
(240121728 blocks): OK (unit 4) Port 5: Maxtor 4G120J6 G6037FPE 122.94 GB (240121728 blocks): OK (unit 4) Port 6: Maxtor 4G120J6 G603FZRE 122.94 GB (240121728 blocks): OK (unit 6) Port 7: Maxtor 4G120J6 G603F9TE 122.94 GB (240121728 blocks): OK (unit 6) Port 8: Maxtor 98196H8 V80FZGRC 81.96 GB (160086528 blocks): OK (unit 8) Port 9: Maxtor 98196H8 V80HRGWC 81.96 GB (160086528 blocks): OK (unit 8) Port 10: Maxtor 98196H8 V80HRG2C 81.96 GB (160086528 blocks): OK (unit 8) Port 11: Maxtor 98196H8 V80GXC1C 81.96 GB (160086528 blocks): OK (unit 8)
Step 1:
Backup any data (not sho wn) and u nmount all arr ays being delet ed
linux:~ # umount /dev/sdb1 linux:~ # umount /dev/sdc1 linux:~ # umount /dev/sdd1
Step 2:
Delete RAID arrays or units in CLI
3ware CLI> maint deleteunit c0 u2 Deleted unit 2
3ware CLI> maint deleteunit c0 u4 Deleted unit 4
3ware CLI> maint deleteunit c0 u6 Deleted unit 6
www.3ware.com 24
3ware Escalade ATA RAID Controller CLI User Guide
Note:
sda and sde remains available, but sdb, sdc, and
sdd are no longer available to Linux:
linux:~ # fdisk /dev/sda
The number of cylinders for this disk is set to 3649.
There is nothing wrong with th at, but this is l arger than 1024, and could in certain setups cause prob­lems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs (e.g., DOS FDISK, OS/2 FDISK)
Command (m for help): q
linux:~ # fdisk /dev/sdb
Unable to open /dev/sdb linux:~ # fdisk /dev/sdc
Unable to open /dev/sdc linux:~ # fdisk /dev/sdd
Unable to open /dev/sdd
linux:~ # fdisk /dev/sde
Device contains neithe r a va lid DO S par titi on tabl e,
nor Sun, SGI or OSF disklabel Building a new DOS disklabel Changes will remain in memory only , unti l you deci de
to write them. After that, of course, the pre-
vious content won't be recoverable.
25 www.3ware.com
Command Line Interface
The number of cylinders for this disk is set to
29894.
There is nothing wrong with th at, but this is l arger
than 1024, and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs (e.g., DOS FDISK, OS/2 FDISK)
Command (m for help): q
Step 3:
Create new RAID-5 unit in CLI
3ware CLI> maint createunit c0 rraid5 k64
p2:3:4:5:6:7
Created unit 2
Step 4:
Partition and format new array
linux:~ # fdisk /dev/sdb
The number of cylinders for this disk is set to
74733.
There is nothing wrong with th at, but this is l arger
than 1024, and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs (e.g., DOS FDISK, OS/2 FDISK)
Command (m for help): n Command action e extended p primary partition (1-4)
www.3ware.com 26
3ware Escalade ATA RAID Controller CLI User Guide
p Partition number (1-4): 1 First cylinder (1-74733, default 1): Using default value 1 Last cylinder or +size or + sizeM or +sizeK (1 -74733,
default 74733): Using default value 74733
Command (m for help): w The partition table has been altered!
Calling ioctl() to re-read partition table. Syncing disks. linux:~ # mkfs /dev/sdb1 mke2fs 1.26 (3-Feb-2002) Filesystem label= OS type: Linux Block size=4096 (log=2 ) Fragment size=4096 (log=2) 75038720 inodes, 150073197 blocks 7503659 blocks (5.00%) reserved for the super user First data block=0 4580 block groups 32768 blocks per group, 32768 fragments per group 16384 inodes per group Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200 , 884736, 1605632, 2654208, 4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968, 102400000
Writing inode tables: 95/4580
Step 5:
Verify changes
3ware CLI> info c0 Controller 0
27 www.3ware.com
Command Line Interface
------------­Model: 7500-12 FW: FE7X 1.05.00.042 BIOS: BE7X 1.08.00.044 Serial #: M12600A2170030 PCB: Rev3 PCHIP: V1.30 ACHIP: V3.20
# of units: 3
Unit 0: RAID 1 30.01 GB (58631296 blocks): OK Unit 2: RAID 5 614.70 GB (1200598400 blocks): OK Unit 8: RAID 5 245.88 GB (480253440 blocks): OK
# of ports: 12
Port 0: QUANTUM FIREBALLP LM30 186013438780
30.02 GB (58633344 blocks): OK (unit 0) Port 1: QUANTUM FIREBALLP LM30 186013534268
30.02 GB (58633344 blocks): OK (unit 0) Port 2: Maxtor 4G120J6 G6037FAE 122.94 GB (240121728 blocks): OK (unit 2) Port 3: Maxtor 4G120J6 G603GLDE 122.94 GB (240121728 blocks): OK (unit 2) Port 4: Maxtor 4G120J6 G603G1RE 122.94 GB (240121728 blocks): OK (unit 2) Port 5: Maxtor 4G120J6 G6037FPE 122.94 GB (240121728 blocks): OK (unit 2) Port 6: Maxtor 4G120J6 G603FZRE 122.94 GB (240121728 blocks): OK (unit 2) Port 7: Maxtor 4G120J6 G603F9TE 122.94 GB (240121728 blocks): OK (unit 2) Port 8: Maxtor 98196H8 V80FZGRC 81.96 GB (160086528 blocks): OK (unit 8) Port 9: Maxtor 98196H8 V80HRGWC 81.96 GB (160086528 blocks): OK (unit 8) Port 10: Maxtor 98196H8 V80HRG2C 81.96 GB (160086528 blocks): OK (unit 8)
www.3ware.com 28
3ware Escalade ATA RAID Controller CLI User Guide
Port 11: Maxtor 98196H8 V80GXC1C 81.96 GB (160086528 blocks): OK (unit 8)
Warning!
When adding a new CBOD or SPARE drive to replace a defective drive the unit number may not be the same as the port number. Always double check
the unit number before deleting a unit
In the example bel ow removing port# 9 d egrade d the RAID-1 ar ray consisting of ports 9 and 10. One might assume that re-adding port# 9 back as a spare drive is now unit# 9. This is not correct since the original array retains the original unit number until the next reboot. The new spare is actually assigned the next available unit number, in this case unit# 0, since unit# 9 was still in use. Deleting unit# 9 to delete the newly added spare drive would actu­ally delete the remaining me mber of the RAID-1 array and your data!
.
Example: 3ware CLI> info c0 Controller 0
------------­Driver: 1.02.00.032 Model: 7500-12 FW: FE7X 1.05.00.043 BIOS: BE7X 1.08.00.045 Monitor: ME 7X 1.01.00.035 Serial #: M12600A2170030 PCB: Rev3 PCHIP: V1.30 ACHIP: V3.20
# of units: 4
29 www.3ware.com
Command Line Interface
Unit 1: RAID 10 60.03 GB (117262592 blocks): OK Unit 2: RAID 5 491.76 GB (960478720 blocks): DEGRADED Unit 3: CBOD 122.94 GB (240121728 blocks): OK OFFLINE Unit 9: RAID 1 81.96 GB (160084480 blocks): OK
# of ports: 12
Port 0: QUANTU M FIREBALLP LM30 18 6013438780 30.02
GB (58633344 blocks): OK (NO UNIT)
Port 1: QUANTU M FIREBALLP LM30 18 6013534268 30.02
GB (58633344 blocks): OK (unit 1)
Port 2: Maxtor 4G120J6 G6037FAE 122.94 GB
(240121728 blocks): OK (unit 2)
Port 3: Maxtor 4G120J6 G603GLDE 122.94 GB
(240121728 blocks): OK (unit 3)
Port 4: Maxtor 4G120J6 G603G1RE 122.94 GB
(240121728 blocks): OK (unit 2)
Port 5: Maxtor 4G120J6 G6037FPE 122.94 GB
(240121728 blocks): OK (unit 2)
Port 6: Maxtor 4G120J6 G603FZRE 122.94 GB
(240121728 blocks): OK (unit 1)
Port 7: Maxtor 4G120J6 G603F9TE 122.94 GB
(240121728 blocks): OK (unit 2)
Port 8: Maxtor 98196H8 V80FZGRC 81.96 GB
(160086528 blocks): OK (unit 1)
Port 9: Maxtor 98196H8 V80HRGWC 81.96 GB
(160086528 blocks): OK (unit 9)
Port 10: Maxtor 98196H8 V80HRG2C 81.96 GB
(160086528 blocks): OK (unit 9)
Port 11: Maxtor 98196H8 V80GXC1C 81.96 GB
(160086528 blocks): OK (unit 1)
3ware CLI> maint remove c0 p9 Successfully removed drive fr om port 9 on c ontrol-
ler 0
www.3ware.com 30
3ware Escalade ATA RAID Controller CLI User Guide
3ware CLI> maint add c0 p9 spare Successful ly added a SP ARE to port 9 on co ntroller 0
3ware CLI> maint deleteunit c0 u9 Deleted unit 9
3ware CLI> info c0 Controller 0
------------­Driver: 1.02.00.032 Model: 7500-12 FW: FE7X 1.05.00.043 BIOS: BE7X 1.08.00.045 Monitor: ME 7X 1.01.00.035 Serial #: M12600A2170030 PCB: Rev3 PCHIP: V1.30 ACHIP: V3.20
# of units: 4
Unit 0: SPARE 81.96 GB (160086528 blocks): OK OFFLINE Unit 1: RAID 10 60.03 GB (117262592 blocks): OK Unit 2: RAID 5 491.76 GB (960478720 blocks): DEGRADED Unit 3: CBOD 122.94 GB (240121728 blocks): OK OFFLINE
# of ports: 12
Port 0: QUANTUM FIREBALLP LM30 186013438780
30.02 GB (58633344 blocks): OK (NO UNIT) Port 1: QUANTUM FIREBALLP LM30 186013534268
30.02 GB (58633344 blocks): OK (unit 1) Port 2: Maxtor 4G120J6 G6037FAE 122.94 GB (240121728 blocks): OK (unit 2) Port 3: Maxtor 4G120J6 G603GLDE 122.94 GB (240121728 blocks): OK (unit 3)
31 www.3ware.com
Command Line Interface
Port 4: Maxtor 4G120J6 G603G1RE 122.94 GB (240121728 blocks): OK (unit 2) Port 5: Maxtor 4G120J6 G6037FPE 122.94 GB (240121728 blocks): OK (unit 2) Port 6: Maxtor 4G120J6 G603FZRE 122.94 GB (240121728 blocks): OK (unit 1) Port 7: Maxtor 4G120J6 G603F9TE 122.94 GB (240121728 blocks): OK (unit 2) Port 8: Maxtor 98196H8 V80FZGRC 81.96 GB (160086528 blocks): OK (unit 1) Port 9: Maxtor 98196H8 V80HRGWC 81.96 GB (160086528 blocks): OK (unit 0) Port 10: Maxtor 98196H8 V80HRG2C 81.96 GB (160086528 blocks): OK (NO UNIT) Port 11: Maxtor 98196H8 V80GXC1C 81.96 GB (160086528 blocks): OK (unit 1)
maint rebuild
Description:
successful
T o rebui ld a degraded array, unit 2 on controller 0, with a disk drive that is attached to port 3.
Example:
3ware CLI> maint rebuild c0 u2 p3
Sample of output:
Rebuild started on unit 2 on controller 0
Note:
When rebuilding a degraded RAID 10, the first degraded subunit mirrored pair that is found will be rebuilt. When issuing a rebuildstatus command immedi- ately after the rebuil d of a RAID 10 has star ted, th e overall percentage complete of that array will display 50%. How-
ever, the degraded subunit that is bei ng rebuilt will display 0%. If there are multiple degraded mirror pairs in a RAID 10 array, the
www.3ware.com 32
3ware Escalade ATA RAID Controller CLI User Guide
command will need to be issued again to initiate a rebuild on addi­tional degraded pairs.
maint flush
Description:
T o flush the cache on all units attached to controller 1.
Example:
3ware CLI> maint flush c1
Sample of output:
Flushed cache on controller 1 unit 0 Flushed cache on controller 1 unit 6 Flushed cache on controller 1 unit 8
maint flush
Description:
on specific unit
To flush the cache only on unit 6 of controller 1.
Example:
3ware CLI> maint flush c1 u6
Sample of output:
Flushed cache on controller 1 unit 6
maint verify
Description:
To start a verify on unit 3 of cont roller 2.
Example:
3ware CLI> maint verify c2 u3
Sample of output:
Verify success fully started on unit 3 on co n­troller 2
The Verif y feature verifies the redundancy of all RAID 1, 5 and 10 arrays. Arrays must be initialized and cannot be degraded to be verified. If the verify array process determines that the mirrored drives are not identical
33 www.3ware.com
Command Line Interface
or the parity is not correct, the array is degraded and the rebuild process is launched.
For RAID 1 or 10 Arrays: RAID 1 and 10 array s are not prof il ed when created, or initialized after booting into the OS. When the firmware receives the first verify request, given that the array was never initialized, the initialization will then begin. Any subsequent verify operations will then perform the verification of the array (check data consistency). An AEN will inform the user that the first verify is actually an initialization.

Alarms

The
alarms
The alarms command provides a log of alarms, also called Automatic Event Notifications (AENs), that have occurred on the disk arrays. An alarm occurs when the ATA RAID controller requires attention, such as when a disk array becomes degraded and is no longer fault tolerant. SMART notifications appear in this display . Alarm messages are catego­rized by the following levels of severity:
•Errors
•Warnings
• Information
command
Note:
When this command is execut ed, onl y AENs that have been logged since the last time the command was executed will be displayed. AENs are al so saved in a text
file at /var/ lo g/messages .
www.3ware.com 34
3ware Escalade ATA RAID Controller CLI User Guide
Warning!
3ware does not recommend installing both 3DM and CLI. Conflicts may occur. Alarms will only be captured by one utility if both are installed.
Warning!
3DM and CLI handle alarms differently. CLI does not timestamp or save alarms as 3DM does. When using CLI, save the alarm data. Once the alarms are viewed, they cannot be viewed again.
Examples using Interactive Mode
Example:
3ware CLI> alarms
Sample of output:
Controller 1 Alarms
-------------------­INFO: Verify started: Unit #0 ERROR: Drive error: Port #0 ERROR: Unit degraded: Unit #0 INFO: Rebuild started: Unit #0 INFO: Rebuild complete: Unit #0
---------------------
35 www.3ware.com
Command Line Interface

Help

The
help
command
The help command displays a list of the CLI commands and options.
Examples using Interactive Mode
Example:
Esclade CLI> help
Sample of output:
Copyright (c) 2003 3ware, Inc. All rights reserved.
3ware CLI (version 2.00.00.006)
List of Commands
------------------------------------------­info - displays information about the controller
alarms - disp lays or deletes the list of AENs
set - displays or modifies controller settings
maint - performs maintenance operations on the
controllers
quit - e xits the CLI
Type help <command> to get more details about a par­ticular command
www.3ware.com 36
3ware Escalade ATA RAID Controller CLI User Guide
Example:
3ware CLI> help info
Sample of output:
This command will show you various pieces of informa­tion about controllers.
info [c<c> [u<u>|p<p>] [ite m ]]
c - the controller id u - the unit id p - the port id
- If u is specified, item can be one of the fol­lowing:
status, rebuildstatus, verifystatus, initializestatus
- If p is specified, item can be one of the fol­lowing:
status, model, serial, capac ity, smart
- If neither u or p is specified, item can be one of the following:
driver, model, firmware, bios, monitor, serial, pcb, pchip, achip, numports, numunits, numdrives, unitstatus, drivestatus
37 www.3ware.com
Command Line Interface
Example:
Esclade CLI> help alarms
Sample of output:
This command will display alarms for each controller
alarms
Example:
Esclade CLI> help set
Sample of output:
This command will adjust certain settings on the
controllers
set [ rebuild c<c> <1..5> | cache c<c> u<u> [on|off] ]
c - the controller id u - the unit id
If set is called without arguments, it will display rebuild and cache information for all controllers.
Example:
3ware CLI> help maint
Sample of output:
This command will perfor m certain maintenance func­tions on the controllers
maint [
add c<c> p<p> [jbod|cbod|spare] | remove c<c> p<p> |
www.3ware.com 38
3ware Escalade ATA RAID Controller CLI User Guide
createunit c<c> r<raid<0|1|10|5>|<j|c>bod|spare>
[k<stripe>] p<p:p..> [noscan] |
deleteunit c<c> u<u> [noscan] | rebuild c<c> u<u> p<p> [ignoreECC] | flush c<c> [u<u>] | verify c<c> u<u> [stop]
]
c - the controller id u - the unit id p - the port id
For createunit, the k argument (stripe) is only valid for the following:
raid0, raid10, raid5
Valid values for the k argument (stripe) are the following (in KB):
16, 32, 64, 128, 256, 512, 1024 (Note: Raid5 can only be 64kb.)
If no unit is specified for flush, it will flush the cache on all units.
The "noscan" option for “create” and “delete unit” tells the CLI to NOT notify of the creation or deletion of a logical volume.
Example:
Esclade CLI> help quit
Sample of output:
This command quits the CLI
quit
Synonyms: q exit
39 www.3ware.com

3ware Technical Support and Services

3ware Technical Support and Services
Product information, Frequently Asked Questions, software upgrades, driver files and other support are availa ble through the 3ware World Wide Web site at http://www.3ware.com ware library is accessible at: http://www.3ware.com/support/down­load.asp. For specific answers to questions or to give feedback about the product, vis it our Web site at http://www.3ware.com/sup­port and use our convenient e-mail form. 3ware also of fer s toll- free (877) 883-9273 and (408) 523-1111 direct phone support during normal business hour s.

Sales and ordering information

For sales information, send an electronic mail message to sales@3ware.com.
. 3ware's soft-

Feedback on this manual

Your feedback is welcome. If anyt hing in the guide seems unclear please let us know by sending e-mail to support@3ware.com.
40 www.3ware.com
3ware Escalade ATA RAID Controller CLI User Guide
www.3ware.com
41
Loading...