3ware 9500S Series Guide

3ware®
Serial ATA RAID Controller
Command Line Interface
Supports the 9000 Series
PN: 720-0115-01 March 2005
Copyright
©2003-2005 AMCC. All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted in any form by any means, electronic, mechanical, photocopying, recording or otherwise, without the proper written consent of AMCC, 455 West Maude Ave., Sunnyvale, CA
94085.
Trademarks
3ware, Escalade, and 3DM are all registered trademarks of AMCC. The 3ware logo, 3BM, StorSwitch, TwinStor, and R5 Fusion are all trademarks of AMCC. All other trademarks herein are property of their respective owners.
Disclaimer
AMCC assumes no responsibility for errors or omissions in this document, nor does AMCC make any commitment to update the information contained herein.
Table of Contents
About This Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
How this Guide is Organized . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1
Introduction to the 3ware Command Line Interface . . . . . . . . . . . . . . . 3
Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Supported Operating Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4
Terminology . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4
Installing the 3ware CLI. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
Installing the 3ware CLI on Windows . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5
Installing the 3ware CLI on Linux and FreeBSD . . . . . . . . . . . . . . . . . . . . . . . . . .6
Working with 3ware CLI. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
Using the command interface interactively . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7
Using a single command with output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .8
Using an input file to execute a script . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .8
Outputting the CLI to a Text File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .9
Understanding RAID Concepts and Levels. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
RAID Configurations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .11
Determining What RAID Level to Use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .14
Primary CLI Syntax Reference . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
Common Tasks Mapped to CLI Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
Primary Syntax Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Conventions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
Shell Object Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
focus Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .21
show . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .22
show ver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .22
show alarms [reverse] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .23
show diag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .23
show rebuild . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .23
show verify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .23
show selftest . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .24
flush . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .24
rescan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .24
commit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .25
Controller Object Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
/cx show . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .26
/cx show attribute [attribute ...] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .27
/cx show driver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .27
/cx show model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .28
/cx show firmware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .28
/cx show bios . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .28
/cx show monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .28
/cx show serial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .28
/cx show pcb . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .28
/cx show pchip . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .29
/cx show achip . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .29
/cx show numports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .29
/cx show numunits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .29
/cx show numdrives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .29
www.3ware.com i
/cx show exportjbod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .30
/cx show spinup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .30
/cx show stagger . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .30
/cx show ondegrade . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .30
/cx show autocarve . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
/cx show memory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .31
/cx show unitstatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
/cx show allunitstatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .32
/cx show drivestatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .32
/cx show all . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .32
/cx add type=<RaidType> disk=<p:-p> [stripe=Stripe] [noscan] [group=<3|4|5|6>]
[nocache] [autoverify] [ignoreECC] [name=string] . . . . . . . . . . . . . . . . . . . .33
/cx rescan [noscan] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .36
/cx commit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .37
/cx flush . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .37
/cx show alarms [reverse] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .37
/cx show diag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .37
/cx show rebuild . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .38
/cx show verify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .40
/cx show selftest . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .41
/cx add rebuild=ddd:hh:duration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .42
/cx add verify=ddd:hh:duration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .43
/cx add selftest=ddd:hh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .44
/cx del rebuild=slot_id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .44
/cx del verify=slot_id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .45
/cx del selftest=slot_id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .45
/cx set rebuild=enable|disable|1..5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .45
/cx set verify=enable|disable|1..5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .46
/cx set selftest=enable|disable [task=UDMA|SMART] . . . . . . . . . . . . . . . . . . . .46
/cx set exportjbod=on|off . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .46
/cx set ondegrade=cacheoff|follow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .46
/cx set spinup=nn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .47
/cx set stagger=nn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .47
/cx set autocarve=on|off . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .47
/cx start mediascan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .48
/cx stop mediascan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .48
Unit Object Commands. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
/cx/ux show . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .49
/cx/ux show attribute [attribute ...] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50
/cx/ux show status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50
/cx/ux show rebuildstatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .50
/cx/ux show verifystatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .51
/cx/ux show initializestatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .51
/cx/ux show name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .51
/cx/ux show serial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .51
/cx/ux show volumes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
/cx/ux show all . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .51
/cx/ux export [noscan] [quiet] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .52
/cx/ux del [noscan] [quiet] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
/cx/ux start rebuild disk=p<p:-p...> [ignoreECC] . . . . . . . . . . . . . . . . . . . . . . . . .53
/cx/ux start verify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
/cx/ux pause rebuild . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .54
/cx/ux resume rebuild . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .54
/cx/ux stop verify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .54
/cx/ux flush . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .55
ii 3ware 9000 Series Serial ATA Controller CLI Guide
/cx/ux set autoverify=on|off . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .55
/cx/ux set cache=on|off [quiet] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
/cx/ux set ignoreECC=on|off . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .55
/cx/ux set name=string . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .56
/cx/ux migrate type=RaidType [disk=p:-p]
[exclude=p:-p] [group=3|4|5|6] [stripe=Stripe] [noscan] [nocache] [autoverify] 56
Port Object Commands. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
/cx/px show . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .61
/cx/px show attribute [attribute ...] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .61
/cx/px show status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .61
/cx/px show model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .62
/cx/px show serial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .62
/cx/px show firmware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .62
/cx/px show capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .62
/cx/px show smart . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
/cx/px show all . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .63
/cx/px export [noscan] [quiet] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .63
BBU Object Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
/cx/bbu show . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .64
/cx/bbu show attribute [attribute ...] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .65
/cx/bbu show status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .65
/cx/bbu show batinst . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .65
/cx/bbu show lasttest . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .66
/cx/bbu show volt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .66
/cx/bbu show temp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .66
/cx/bbu show cap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .66
/cx/bbu show serial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .66
/cx/bbu show fw . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .66
/cx/bbu show pcb . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .67
/cx/bbu show bootloader . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .67
/cx/bbu show all . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .67
/cx/bbu test [quiet] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .67
/cx/bbu enable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .68
/cx/bbu disable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .68
Help Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
Help with specific commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .68
Help with attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .69
help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .70
help show . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .70
help flush . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .71
help rescan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .71
help commit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .71
help focus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .71
help /cx . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .71
help /cx/ux . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .71
help /cx/px . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .71
help /cx/bbu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .71
Environment Variables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Return Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Legacy CLI Syntax Reference . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
Conventions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76
Screen Reporting Style . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
Info Commands. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
info . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .78
info cid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .78
www.3ware.com iii
info cid driver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .79
info cid model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .80
info cid firmware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .80
info cid bios . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .80
info cid monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .80
info cid serial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .81
info cid pcb . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .81
info cid pchip . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .81
info cid achip . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .81
info cid numports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
info cid numunits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .81
info cid numdrives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .82
info cid unitstatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .82
info cid allunitstatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .82
info cid drivestatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .83
info cid exportjbod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .83
info cid ondegrade . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .83
info cid spinup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
info cid stagger . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .84
info cid uid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .84
info cid uid status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .84
info cid uid rebuildstatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .85
info cid uid verifystatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .85
info cid uid initializestatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .85
info cid pid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .85
info cid pid status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86
info cid pid model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86
info cid pid serial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86
info cid pid capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86
info cid pid smart . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .86
info cid diag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .87
Maint Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88
[maint] rescan [cid ...] [noscan] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .88
[maint] remove cid uid [noscan] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .89
[maint] remove cid pid [noscan] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .90
[maint] deleteunit cid uid [noscan] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .90
[maint] createunit
[autoverify] [ignoreECC] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .91
[maint] rebuild cid uid pid_l i st [ignoreECC] . . . . . . . . . . . . . . . . . . . . . . . . . . . . .93
[maint] rebuild cid uid pause . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .93
[maint] rebuild cid uid resume . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .93
[maint] flush cid [uid ...] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .94
[maint] verify cid uid [stop] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .94
[maint] mediascan cid start|stop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .94
[maint] commit cid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .94
Sched Commands. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
Syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .96
sched rebuild cid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .97
sched rebuild cid add day hour duration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .97
sched rebuild cid remove slot_id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .97
sched rebuild cid enable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .98
sched rebuild cid disable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .98
sched verify cid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .98
sched verify cid add day hour duration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .98
sched verify cid remove slot_id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .99
cid rRAIDType pid_list [kStripe] [noscan] [Dsk_Grp] [nocache]
iv 3ware 9000 Series Serial ATA Controller CLI Guide
sched verify cid enable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .99
sched verify cid disable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .99
sched selftest cid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .99
sched selftest cid add day hour . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .100
sched selftest cid remove slot_id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .100
sched selftest cid enable selftest_task_id . . . . . . . . . . . . . . . . . . . . . . . . . . . . .100
sched selftest cid disable selftest_task_id . . . . . . . . . . . . . . . . . . . . . . . . . . . .101
Alarms Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
Syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .102
alarms [cid ...] . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .102
Set Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103
set rebuild cid 1..5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .103
set verify cid 1..5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .103
set cache cid uid on|off . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .104
set autoverify cid uid on|off . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .104
set overwriteECC cid uid on|off . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .104
Help Commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .105
help info . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .105
help alarms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .105
help set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .105
help maint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .105
help sched . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .105
help quit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .106
Return Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106
www.3ware.com v
vi 3ware 9000 Series Serial ATA Controller CLI Guide

About This Guide

3ware 9000 Series Serial ATA Controller CLI Guide provides instructions for configuring and maintaining your 3ware controller using 3ware’s command line interface (CLI).
This guide assumes that you have already installed your controller in your system. If you have not yet done so, see 3ware 9000 Series Serial ATA RAID Controller Installation Guide for instructions.

How this Guide is Organized

There are often multiple ways to accomplish the same configuration and maintenance tasks for your 3ware controller. While this manual includes instructions for performing tasks using the command line interface, two additional tools are available:
3ware BIOS Manager
®
3DM For information about these tools, see 3ware 9000 Series Serial ATA RAID
Controller User Guide.
2 (3ware Disk Manager)
Table 1: Sections in this Guide
Section Description
Introduction to 3ware Command Line Interface
Primary CLI Syntax Reference Describes individual commands using the
Legacy CLI Syntax Reference Describes individual commands using the
www.3ware.com 1
Installation, features, concepts
primary syntax
legacy syntax
About This Guide
2 3ware 9000 Series Serial ATA Controller CLI Guide

Introduction to the 3ware Command Line Interface

The 3ware SATA RAID Controller Command Line Interface (CLI) for Linux, Windows, and FreeBSD is provided to manage 7000, 8000, and 9000-series 3ware ATA and Serial ATA RAID controllers. Multiple 3ware RAID controllers can be managed using the CLI via a command line or script.
Note: All information contained in this document that describes
usage for the 3ware 9000 series products will not work with 3ware 7000 or 8000 series controllers.
Warning!
For all of the functions of the 3ware CLI to work properly, you must have the proper CLI, firmware, and driver versions installed. Check www.3ware.com for the latest versions and upgrade instruc­tions.

Features

3ware CLI is a command line interface storage management application for 3ware RAID Controllers. It provides controller, logical unit, drive, and BBU (Battery Backup Unit) management. It can be used in both interactive and batch mode, providing higher level API functionalities.
The 3ware CLI provides the functionality of the 3ware Disk Management
®
(3DM unit status and version information and perform maintenan ce functions such as adding or removing drives. 3ware CLI also includes advanced features for creating and deleting RAID units online.
www.3ware.com 3
2) utility through a command line interface. You can use it to view
Introduction to the 3ware Command Line Interface
Note: For complete information on 3DM 2 and for information
about configuring or upgrading your computer, refer to the 3ware 9000 Series Serial ATA RAID Controller User Guide.

Supported Operating Systems

Windows. Windows 2000 with SP3 or newer, Windows XP with SP1 or
newer, and Windows Server 2003, both 32-bit and 64-bit x64.
Linux. Redhat, SuSE FreeBSD
For specific versions of Linux and FreeBSD that are supported for the 3ware CLI, see the Release Notes.

Terminology

This document uses the following terminology:
Logical Units. Usually shortened to “units.” These are block devices
presented to operating systems. A logical unit can be a one-tier, two-tier, or three-tier arrangement. JBOD, Spare, and Single logical units are examples of one-tier units. RAID 1 and RAID 5 are examples of two-tier units and as such will have sub-units. RAID 10 and RAID 50 are examples of three-tier units and as such will have sub-sub-units.
Port. A controller has one or many ports (typically 4, 8, 12 ). Each port can be
attached to a single disk drive. For additional information about 3ware controller concepts and terminology,
see 3ware 9000 Series Serial ATA RAID Controller User Guide.
4 3ware 9000 Series Serial ATA Controller CLI Guide

Installing the 3ware CLI

Warning!
AMCC does not recommend installing both 3DM 2 and CLI on the same system. Conflicts may occur. For example, if both are installed, alarms will be captured only by 3DM. You should use either CLI or 3DM 2 to manage your 3ware RAID controllers.

Installing the 3ware CLI on Windows

3ware CLI can be installed or run directly from the 3ware software CD, or the latest version can be downloaded from the 3ware web site, www.3ware.com. Online manual pages are also available in nroff and html formats. These are located in
To install 3ware CLI on Windows, copy the file tw_cli.exe to the directory from which you want to run the program. CLI is located on the 3ware CD in the directory
/packages/cli/tw_cli.8.html or tw_cli.8.nroff.
\packages\cli\windows
Installing the 3ware CLI
Note: CLI comes in both 32-bit and 64-bit versions. Be sure to copy the
correct version for the version of the operating system you are using. CLI can only be run by an administrator or a user with administrator rights.
Without the correct privileges, CLI will prompt and then exit when the application is executed.
To start CLI, do one of the following:
Start the 3ware CD and at the 3ware Escalade menu, click Run CLI. Or, open a console window and at the command prompt, enter
tw_cli
OR, double-click the CLI icon in a folder.
The CLI prompt is displayed in a DOS console window.
www.3ware.com 5
Introduction to the 3ware Command Line Interface

Installing the 3ware CLI on Linux and FreeBSD

3ware CLI can be installed or run directly from the 3ware software CD, or the latest version can be downloaded from the 3ware web site, www.3ware.com.
T o install the 3ware CLI, copy tw_cli to the directory from which you want to run the program. CLI is located on the 3ware CD in or /packages/cli/linux.
Online manual pages are also available in nroff and html formats. These are located in
/packages/cli/tw_cli.8.html or tw_cli.8.nroff.
/packages/cli/freebsd
You will need to be root or have root privileges to install the CLI to
/usr/sbin
Filename: tw_cli
and to run the CLI.
To install the CLI to a different location, change /usr/sbin/ to the desired location.
Notes:
The installation location needs to be in the environment path for root to execute the CLI without using complete paths (i.e., if installed to
/usr/sbin/, you can type tw_cli on the command
line, otherwise you will have to type the complete path:
/home/user/tw_cli
The 3ware CLI comes in both 32-bit and 64-bit versions. Be sure to copy the correct version for the version of the operating system you are using.
6 3ware 9000 Series Serial ATA Controller CLI Guide

Working with 3ware CLI

You can work with the 3ware CLI in different ways:
Interactively, entering commands at the main prompt As a series of single commands By creating a script—an input file with multiple commands
This first section shows examples of each of these ways. Examples shown in the CLI Reference chapters reflect the interactive method. There are two command syntaxes available for the 3ware CLI:
The primary command syntax.
The current CLI version of the 3ware CLI includes a new command syntax to improve usability . This is now considered the primary syntax for use in the 3ware CLI, and includes commands for features new in the 3ware RAID controller software version 9.1.5, such as those that are used with the Battery Backup Unit (BBU).
Working with 3ware CLI
Details of the primary syntax are described under “Primary CLI Syntax Reference” on page 17.
Legacy command syntax.
In the current CLI version, the command syntax used in previous versions of the 3ware CLI is still supported, to make sure that scripts written with the old syntax will still operate. New functions (such as BBU-related commands) are not available in the legacy syntax. The legacy command syntax will be supported for a limited time.
Details of the legacy syntax are described under “Legacy CLI Syntax Reference” on page 75.

Using the command interface interactively

You can use 3ware CLI interactively, entering commands at the main prompt and observing the results on the screen.
To use the CLI interactively
1 Enter the following command:
# tw_cli
The main prompt is displayed, indicating that the program is awaiting a command.
//localhost>
2 At the CLI prompt, you can enter commands to show or act on 3ware
controllers, units, and drives.
www.3ware.com 7
Introduction to the 3ware Command Line Interface
For example,
//localhost> show
displays all controllers in the system and shows details about them, like this:
Ctl Model Ports Drives Units NotOpt RRate VRate BBU
-----------------------------------------------------------­c0 7500-12 12 8 3 1 2 - ­c1 9506S-12 12 6 1 0 3 5 TESTING

Using a single command with output

You can use 3ware CLI with line arguments, processing a single command at a time. To do so, simply enter the command and the arguments.
Single commands can be useful when you want to perform a task such as redirecting the output of the command to a file. It also allows you to use the command line history to eliminate some typing.
Syntax
tw_cli <command line arguments>
Example
tw_cli /c0 show diag > /tmp/3w_diag.out

Using an input file to execute a script

You can operate 3ware CLI scripts by executing a file. The file is a text file containing a list of CLI commands which you have entered in advance. Each command must be on a separate line.
Syntax
tw_cli -f <filename>
Where <filename> is the name of the text file you want to execute.
Example
tw_cli -f clicommand.txt
This example executes the file clicommand.txt, and runs the CLI commands included in that file.
Scripting example
Following is a a scripting example using a text file called config_array.txt, containing three commands. This example sets up a 12-port controller with two units: one with the first 2 drives mirrored, and another with the remaining drives in a RAID 5 array. In then prints the configurations for verification. The commands included in the script file are:
8 3ware 9000 Series Serial ATA Controller CLI Guide
/c0 add type=raid1 disk=0-1 /c0 add type=raid5 disk=2-11 /c0 show
To run the script, enter:
tw_cli -f config_array.txt

Outputting the CLI to a Text File

You can have the output of the 3ware CLI, including errors, sent to a text file by adding 2>&1 to the end of the line. This could be useful, for example, if you want to email the output to AMCC Technical Support.
Examples
tw_cli /c2/p0 show >> controller2port0info.txt 2>&1 or tw_cli /c0 show diag >> Logfile.txt 2>&1
Working with 3ware CLI
www.3ware.com 9
Introduction to the 3ware Command Line Interface

Understanding RAID Concepts and Levels

The next few pages introduce RAID concepts you may find useful. For additional information about installing and managing your 3ware controller, see the 3ware 9000 Series Serial ATA RAID Controller User Guide.
3ware controllers use a Redundant Array of Inexpensive Disks (RAID) to increase your storage system’s performance and provide fault tolerance (protection against data loss).
The following concepts are important to understand when working with a RAID controller:
Arrays and Units. In the storage industry, the term “array” is used to
describe two or more disk drives that appear to the operating system as a single unit. When you work with 3ware software, “unit” is the term used to refer to an array of disks that is configured and managed through the 3ware software. Single-disk units can also be configured in the 3ware software.
Mirroring. Mirrored arrays write data to paired drives simultaneously. If
one drive fails, the data is preserved on the paired drive. Mirroring provides data protection through redundancy . In addition, mirroring using a 3ware controller provides improved performance because 3ware’s TwinStor technology reads from both drives simultaneously.
Striping. Striping across disks allows data to be written and accessed on
more than one drive, at the same time. Striping combines each drive’s capacity into one large volume. Striped disk arrays achieve highest transfer rates and performance at the expense of fault tolerance.
Distributed Parity. Parity works in combination with striping on RAID 5
and RAID 50. Parity information is written to each of the striped drives, in rotation. Should a failure occur, the data on the failed drive can be reconstructed from the data on the other drives.
Hot Swap. The process of swapping out a drive without having to shut
down the system. This is useful when you need to swap out a degraded drive, manually or automatically, with a pre-designated spare.
Array Roaming. The process of swapping out or swapping in a
configured unit without having to shut down the system. This is useful if you need to move the unit to another controller.
Disk Roaming. The process of removing a unit from a controller and
putting it back later, either on the same controller, or a different one, and having it recognized as a unit. The disks may be in a different order than they initially occupied, without harm to the data. The disks may be attached to the same ports or different ports on the controller.
10 3ware 9000 Series Serial ATA Controller CLI Guide

RAID Configurations

The following RAID levels and configurations are available for drives attached to a 3ware controller:
RAID 0 RAID 1 RAID 5 RAID 10 RAID 50 Single Disk JBOD Hot Spare
RAID 0
Provides striping, but no mirroring. Striped disk arrays achieve high transfer rates because they can read and write data on more than one drive simultaneously . The stripe size is configurable in the 3ware CLI, 3ware BIOS Manager (3BM) and in the 3ware Disk Manager (3DM 2). Requires a minimum of two drives.
Understanding RAID Concepts and Levels
When drives are configured in a striped disk array (see Figure 1), large files are distributed across the multiple disks using RAID 0 techniques.
Striped disk arrays give exceptional performance, particularly for data intensive applications such as video editing, computer aided design and geographical information systems.
RAID 0 arrays are not fault tolerant. The loss of any drive results in the loss of all the data in that array, and can even cause a system hang, depending on your operating system. RAID 0 arrays are not recommended for high availability systems unless additional precautions are taken to prevent system hangs and data loss.
Figure 1. RAID 0 Configuration Example
RAID 1
Also known as a mirrored array. Mirroring is done on pairs of drives. Mirrored disk arrays write data to two drives using RAID 1 algorithms (see
www.3ware.com 11
Introduction to the 3ware Command Line Interface
Figure 2). This gives your system fault tolerance by preserving the data on one drive if the other drive fails. Fault tolerance is a basic requirement for mission critical systems like web and database servers.
3ware uses a patented technology, TwinStor®, on RAID 1 arrays for improved performance during sequential read operations. With TwinStor technology, read performance is twice the speed of a single drive during sequential read operation.
The adaptive algorithms in TwinStor technology boost performance by distinguishing between random and sequential read requests. For the sequential requests generated when accessing large files, both drives are used, with the heads simultaneously reading alternating sections of the file. For the smaller random transactions, the data is read from a single optimal drive head.
Figure 2. RAID 1 Configuration Example
RAID 5
Combines striping data with parity (exclusive OR) to restore data in case of a drive failure. This array type provides performance, fault tolerance, high capacity, and storage efficiency. Requires a minimum of three drives.
Parity information is distributed across all drives rather than being concentrated on a single disk (see Figure 3). This avoids throughput loss due to contention for the parity drive.
RAID 5
0 parity
A1
A2
A3
A4
A Blocks
B0
1 parity
B2
B3
B4
B Blocks C Blocks D Blocks
C0
C1
2 parity
C3
C4
Figure 3. RAID 5 Configuration Example
D0
D1
D2
3 parity
D4
E0
E1
E2
E3
4 parity
E Blocks
RAID 10
This array is a combination of RAID 1 with RAID 0. Striped and mirrored arrays for fault tolerance and high performance. Requires a minimum of four drives to use both RAID 0 and RAID 1 techniques.
12 3ware 9000 Series Serial ATA Controller CLI Guide
Understanding RAID Concepts and Levels
When drives are configured as a striped mirrored array, the disks are configured using both RAID 0 and RAID 1 techniques, thus the name RAID 10 (see Figure 4). A minimum of four drives are required to use this technique. The first two drives are mirrored as a fault tolerant array using RAID 1. The third and fourth drives are mirrored as a second fault tolerant array using RAID 1. The two mirrored arrays are then grouped as a striped RAID 0 array using a two tier structure. Higher data transfer rates are achieved by leveraging T winS tor and striping the arrays. RAID 10 is av ailable on the four, eight, and twelve port 3ware Serial ATA RAID Controllers.
Figure 4. RAID 10 Configuration Example
RAID 50
This array is a combination of RAID 5 with RAID 0. This array type provides fault tolerance and high performance. Requires a minimum of six drives.
Several combinations are available with RAID 50. For example, on a 12-port controller, you can hav e a grouping of 3, 4, or 6 drives. A grouping of 3 means that the RAID 5 arrays used have 3 disks each; four of these 3-drive RAID 5 arrays are striped together to form the 12-drive RAID 50 array.
Single Disk
A single drive that has been configured as a unit through 3ware software (3BM, 3DM2, or CLI). Like disks in other RAID configurations, single disks contain 3ware Disk Control Block (DCB) information and are seen by the OS as available units.
Single drives are not fault tolerant and therefore not recommended for high availability systems unless additional precautions are take to prevent system hangs and data loss.
JBOD
A JBOD is an unconfigured disk attached to your 3ware RAID controller. 3ware recommends that you use Single Disk as a replacement for JBOD, to take advantage of future advanced features such as RAID level migration (RLM).
JBOD units are not fault tolerant and therefore not recommended for high availability systems unless additional precautions are taken to prevent system hangs and data loss.
www.3ware.com 13
Introduction to the 3ware Command Line Interface
Hot Spare
A single configured drive, available so that a redundant array can be automatically rebuilt in case of drive failure.
For additional information about RAID levels, see the article “RAID Primer” on the 3ware website, at: http://www.3ware.com/products/pdf/ RAID_Primer.pdf.

Determining What RAID Level to Use

Select the RAID configuration to use based on the applications to be used on the system, whether performance or data protection is of primary importance, and the number of disk drives available for use.
Review the information under “Understanding RAID Concepts and Levels” on page 10 to determine the type of RAID configuration most appropriate for your needs and use the tables below to determine what RAID levels are available, based on your particular controller model and the number of available drives.
The RAID configurations available to you are determined by the number of ports on your controller, and the number drives attached to those ports. You can configure all drives in one unit, or you can configure multiple units, if you have enough drives.
Table 2: Possible Configurations Based on Number of Drives
# Drives Possible RAID Configurations
1 Single or spare drive 2 RAID 0 or RAID 1 3 RAID 0, RAID 5, or RAID 1 + spare 4 RAID 5 + hot spare
RAID 10 Combination of RAID 0, RAID 1, single disk
5 RAID 5 + hot spare
RAID 10 + hot spare Combination of RAID 0, RAID 1, hot spare
6 or more RAID 50
Depending on the number of drives, a RAID 50 may contain from 2 to 4 subunits. For example, with 12 drives, possible RAID 50 configurations include 2 subunits of 6, 3 subunits of 4, or 4 subunits of 3. With 10 drives, a RAID 50 will contain 2 subunits of 5 drives each.
Combination of RAID 0, 1, 5, 10, hot spare, and single disk
14 3ware 9000 Series Serial ATA Controller CLI Guide
Understanding RAID Concepts and Levels
Drive Capacity Considerations
The capacity of each drive is limited to the capacity of the smallest drive in the array. The total array capacity is defined as follows:
Table 3: Drive Capacity
RAID Level Capacity
RAID 0 (number of drives) X (capacity of the smallest drive) RAID 1 capacity of the smallest drive RAID 5 (number of drives - 1) X (capacity of the smallest drive)
Storage efficiency increases with the number of disks:
storage efficiency = (number of drives -1) / (number of drives) RAID 10 (number of drives / 2) X (capacity of smallest drive) RAID 50 (number of drives - number of groups of drives) X (capacity of the
smallest drive)
Support for Over 2 Te rabytes
Windows 2000, Windows XP, and Linux 2.4 do not currently recognize unit capacity in excess of 2 TB.
If the combined capacity of the drives to be connected to a unit exceeds 2 Terabytes (TB), you can enable auto-carving using the
set autocarve
command. Auto-carving divides the available unit capacity into multiple chunks of 2 TB
or smaller that can be addressed by the operating systems as separate volumes.
www.3ware.com 15
Introduction to the 3ware Command Line Interface
16 3ware 9000 Series Serial ATA Controller CLI Guide

Primary CLI Syntax Reference

Note: Information contained in this document that describes usage
only for the 3ware 9000 series products does not work with 3ware 7000 or 8000 series controllers.
This chapter provides detailed information about using the primary command syntax for the 3ware CLI. (The legacy syntax is still supported for a limited time. For details see, “Legacy CLI Syntax Reference” on page 75.)
Throughout this chapter the examples reflect the interactive method of executing 3ware CLI.

Common Tasks Mapped to CLI Commands

The table below lists many of the tasks people use to manage their RAID controllers and units, and lists the primary CLI command associated with those tasks.
Table 4: Common Tasks Mapped to CLI Commands
T ask CLI Command Page
Controller Configuration Tasks
View information about different controllers
View controller policies /cx show [attribute] [attribute] 27
www.3ware.com 17
/cx show 26
Primary CLI Syntax Reference
Table 4: Common Tasks Mapped to CLI Commands
T ask CLI Command Page
Set policies for a controller
Export JBODs Enable staggered spinup Disable write cache on unit
degrade
Enable autocarving
Unit Configuration Tasks
Create a new unit /cx add 33 Create a hot spare /cx add 33 Enable/disable unit write cache /cx/ux set cache 55
Changes to an Existing Configuration
Change RAID level /cx/ux migrate 56
/cx set exportjbod /cx set stagger and /cx set spinup /cx set ondegrade
/cx set autocarve
46 47
46 47
Change stripe size /cx/ux migrate 56 Expand unit capacity /cx/ux migrate 56 Delete a unit /cx/ux del 53 Remove a unit (export) /cx/ux export 52 Name a unit /cx/ux set name 56
Units Mainenance Tasks
Add a time slot to a rebuild schedule
Add a time slot to a verify schedule
Add a time slot to a selftest schedule
Enable/disable the rebuild/migrate schedule and set the task rate
Enable/disable the verify schedule and set the task rate
Enable/disable the selftest schedule
/cx add rebuild 42
/cx add verify 43
/cx add selftest 44
/cx set rebuild 45
/cx set verify 46
/cx set selftest 46
Start a rebuild /cx/ux start rebuild 53 Start a verify /cx/ux start verify 54 Pause/resume rebuild /cx/ux pause rebuild and /cx/ux
resume rebuild
18 3ware 9000 Series Serial ATA Controller CLI Guide
54
Table 4: Common Tasks Mapped to CLI Commands
T ask CLI Command Page
Stop verify /cx/ux stop verify 54 Enable/disable autoverify /cx/ux set autoverify 55 Allow/disallow write caching /cx/ux set cache 55 View Alarms /cx show alarms 37

Primary Syntax Overview

The primary command syntax uses the general form:
Object Command Attributes
Objects are shell commands, controllers, units, ports (drives), and BBUs
(battery backup units).
Commands can either select (show , get, present, read) attributes or alter (add,
change, set, alter, write) attributes.
Primary Syntax Overview
Attributes are either Boolean Attributes or Name-Value Attributes.
The value of a boolean attribute is deduced by presence or lack of—that
is, the attribute is either specified, or not. For example, the command show alarms by default lists alarms with the most recent alarm first. If you include the attribute reverse (show alarms reverse), alarms are listed in reverse order.
The value of name-value attributes are expressed in the format
attribute=value.
Example: When adding (creating) a unit to the controller with the following
command string,
/c1 add type=raid1 disk=0-1 c1
is the object, add is the command, type (for type of array) is an attribute
with
raid1 is the value of the attribute, and disk is another attribute with
0-1 as the value (ports 0 through 1).
Information about commands is organized by the object on which commands act:
Shell Object Commands. Shell object commands set the focus or provide
information (such as alarms, diagnostics, rebuild schedules, and so forth) about all controllers in the system. For details, see “Shell Object Commands” on page 21.
Controller Object Commands. Controller object commands provide
information and perform actions related to a specific controller. For example, you use controller object commands for such tasks as seeing alarms specific to a controller, creating schedules during which background tasks are run, and
www.3ware.com 19
Primary CLI Syntax Reference
setting policies for the controller. You also use the controller object command
/cx add type to create RAID arrays. For details, see “Controller Object
Commands” on page 25.
Unit Object Commands. Unit object commands provide information and
perform actions related to a specific unit on a specific controller. For example, you use unit object commands for such tasks as seeing the rebuild, verify, or initialize status of a unit, starting, stopping, and resuming verifies, starting and stopping rebuilds, and setting policies for the unit. You also use the controller object command of a RAID array. For details, see “Unit Object Commands” on page 49.
Port Object Commands. Port object commands provide information and
perform actions related to a drive on a specific port. For example, you use port object commands for such tasks as seeing the status, model, or serial number of the drive. For details, see “Port Object Commands” on page 61.
BBU Object Commands. BBU object commands provide information and
perform actions related to a Battery Backup Unit on a specific controller. For details, see “BBU Object Commands” on page 64.
cx/ux migrate type to change the configuration
Help Commands. Help commands allow you to display help information for
all commands and attributes. For details, see “Help Commands” on page 68.

Conventions

The following conventions are used through this guide:
In text, monospace font is used for code and for things you type. In commands, an italic font indicates items that are variable, but that you
In commands, brackets around an item indicates that it is optional. In commands, ellipses (. . .) indicate that more than one parameter can be
In commands, a vertical bar (|) indicates an 'or' situation where the user
For example, in the command to rescan all ports and reconstitute all units, the syntax appears as rescan [cid ...] [noscan]. The italic cid indicates that you need to supply a controller ID. The ellipses indicate that you can specify more than one controller ID, separated by spaces. The brackets indicate that you may omit the controller ID, to rescan all controllers, and the noscan parameter, so that the operation will be reported to the operating system.
must specify, such as a controller ID, or a unit ID.
included.
has a choice between more than one attribute, but only one can be specified.
20 3ware 9000 Series Serial ATA Controller CLI Guide

Shell Object Commands

Shell object commands are either applicable to all the controllers in the system (such as show, rescan, flush, commit), or redirect the focused object.
Syntax
focus Object show [attribute [modifier]]
ver alarms [reverse] diag rebuild verify
selftest rescan flush commit
Shell Object Commands
focus
Object
The focus command is active in interactive mode only and is provided to reduce typing.
The focus command will set the specified object in focus and change the prompt to reflect this. This allows you to enter a command that applies to the focus, instead of having to type the entire object name each time.
For example, where normally you might type:
//hostname/c0/u0 show
if you set the focus to //hostname/c0/u0, the prompt changes to reflect that, and you only have to type location in a filesystem and requesting a listing of the current directory .
object
can have the following forms:
//hostname/cx/ux specifies the fully qualified URI (Universal Resource
Identifier) of an object on host
//hostname specifies the root of host hostname. .. specifies one level up (the parent object). / specifies the root at the current focused hostname.
./obj specifies the next level of the object.
show. The concept is similar to being in a particular
hostname, controller cx, unit ux.
/c0/bbu specifies a relative path with respect to the current focused
hostname. For example:
//localhost> focus //elvis.amcc.com //elvis.amcc.com>
www.3ware.com 21
Primary CLI Syntax Reference
//elvis.amcc.com> focus /c0/u0 //elvis.amcc.com/c0/u0>
//elvis.amcc.com/c0/u0> focus .. //elvis.amcc.com/c0>
//elvis.amcc.com/c0/> focus u0 //elvis.amcc.com/c0/u0>
//elvis.amcc.com/c0> focus / //elvis.amcc.com>
The focus command is available by default. You can disable focus by setting TW_CLI_INPUT_STYLE to old. (See “Environment Variables” on page 72.)

show

This command shows a general summary of all detected controllers. Note that the device drivers for the appropriate operating system should be
loaded for the list to show all controllers. The intention is to provide a global view of the environment.
Typical output of the Show command looks like:
//localhost> show
Ctl Model Ports Drives Units NotOpt RRate VRate BBU
----------------------------------------------------------------------­ c0 7500-12 12 8 3 1 2 - ­ c1 9506S-12 12 6 1 0 3 5 TESTING
Indicating that Controller 0 is a 7500 model with 12 Ports, with 8 Drives detected (attached), total of 3 Units, with one unit in a NotOpt (Not Optimal) state, RRate (Rebuild Rate) of 2, VRate (Verify Rate) of '-' (Not Applicable), BBU of '-' (Not Applicable). Not Optimal refers to any state except OK and VERIFYING. Other states include VERIFY-PAUSED, INITIALIZING, INIT­PAUSED, REBUILDING, REBUILD-PAUSED, DEGRADED, MIGRATING, MIGRATE-PAUSED, RECOVERY, INOPERABLE, and UNKNOWN.
RRate also applies to initializing, migrating, and recovery background tasks.

show ver

This command will show the CLI and API version. Example:
//localhost> show ver CLI Version = 2.00.00.0xx API Version = 2.00.00.0xx
22 3ware 9000 Series Serial ATA Controller CLI Guide
Loading...
+ 84 hidden pages