Environment Information
OS : ubuntu12.04RAID Card Model: LSI SAS 9285CV-8e
Ubuntu Package/command : megacli & megasasctl
Megacli Command
#Show RAID Card Info.$ sudo megacli -CfgDsply -a0
==============================================================================
Adapter: 0
Product Name: LSI MegaRAID SAS 9285CV-8e
Memory: 1024MB
BBU: Absent
Serial No: SV21810332
==============================================================================
Number of DISK GROUPS: 0
#Show Physical HDD
$ sudo megacli -PDList -a0
Adapter #0
Enclosure Device ID: 19
Slot Number: 0
Drive's position: DiskGroup: 0, Span: 0, Arm: 0
Enclosure position: 1
Device Id: 27
WWN: 5000CCA01AB577F3
Sequence Number: 2
Media Error Count: 0
Other Error Count: 0
Predictive Failure Count: 0
Last Predictive Failure Event Seq Number: 0
PD Type: SAS
Raw Size: 2.728 TB [0x15d50a3b0 Sectors]
Non Coerced Size: 2.728 TB [0x15d40a3b0 Sectors]
Coerced Size: 2.728 TB [0x15d400000 Sectors]
Sector Size: 512
Logical Sector Size: 512
Physical Sector Size: 512
Firmware state: Online, Spun Up
Commissioned Spare : No
Emergency Spare : No
Device Firmware Level: A222
Shield Counter: 0
Successful diagnostics completion on : N/A
SAS Address(0): 0x5000cca01ab577f1
SAS Address(1): 0x0
Connected Port Number: 0(path0)
Inquiry Data: HITACHI HUS723030ALS640 A222YHK6TV1G
FDE Capable: Not Capable
FDE Enable: Disable
Secured: Unsecured
Locked: Unlocked
Needs EKM Attention: No
Foreign State: None
Device Speed: 6.0Gb/s
Link Speed: 6.0Gb/s
Media Type: Hard Disk Device
Drive: Not Certified
Drive Temperature :44C (111.20 F)
...
#for example, build RAID 0 using 3 HDD
( note: E: Enclosure Device ID / S: Slot Number)
$ sudo megacli -CfgLDadd -r0 [E0:S0, E1:S1, E2:S2] -a0
#Show Logical Disk (build RAID 0 using 30 HDD)
$ sudo megacli -LDInfo -Lall -a0
Adapter 0 -- Virtual Drive Information:
Virtual Drive: 0 (Target Id: 0)
Name :
RAID Level : Primary-0, Secondary-0, RAID Level Qualifier-0
Size : 81.855 TB
Sector Size : 512
Is VD emulated : No
Parity Size : 0
State : Optimal
Strip Size : 256 KB
Number Of Drives : 30
Span Depth : 1
Default Cache Policy: WriteBack, ReadAdaptive, Direct, No Write Cache if Bad BBU
Current Cache Policy: WriteThrough, ReadAdaptive, Direct, No Write Cache if Bad BBU
Default Access Policy: Read/Write
Current Access Policy: Read/Write
Disk Cache Policy : Disk's Default
Encryption Type : None
PI type: No PI
Is VD Cached: No
Exit Code: 0x00
ubuntu@ubuntu:~$
#Full Initialize Logical Disk 0
$ sudo megacli -LDInit -start -full -L0 -A0
#Check Status of Logical Disk Initialization
$ sudo megacli -LDInit -ShowProg -L0 -a0
#Delete Logical Disk 0
$ sudo megacli -CfgLdDel -L0 -a0
Adapter 0: Deleted Virtual Drive-0(target id-0)
Exit Code: 0x00
#Delete all Logical Disk
$ sudo megacli -CfgLdDel -Lall -a0
#Set Physical Disk to be be the Hot Spare
$ sudo megacli -PDHSP -Set -PhyDrv [E:S] -a0
#Remove Physical Disk from Hot Spare Status
$ sudo megacli -PDHSP -Rmv -PhyDrv [E:S] -a0
No comments:
Post a Comment