ゴジラ

LSI RAID Documentation

Listing missing physical drives

megacli -pdgetmissing -a0

Sample output,

[root@box ~]# megacli -pdgetmissing -a0

Adapter 0 - Missing Physical drives

No.   Array   Row   Size Expected
0     0       0     915200 MB

Exit Code: 0x00

Fixing a drive with Firmware state: Unconfigured(bad)

Firmware state: Unconfigured(bad)
Secured: Unsecured
Locked: Unlocked
Foreign State: None
Device Speed: 6.0Gb/s
Link Speed: 6.0Gb/s
Drive's NCQ setting : Enabled
Port status: Active
Port's Linkspeed: 6.0Gb/s
Drive has flagged a S.M.A.R.T alert : No

With force,

megacli -PDMakeGood -PhysDrv '[252:4]' -Force -a0

Ideal output,

[root@box ~]# megacli -PDMakeGood -PhysDrv '[252:4]' -Force -a0

Adapter: 0: EnclId-252 SlotId-4 state changed to Unconfigured-Good.

Exit Code: 0x00

Without force,

megacli -PDMakeGood -PhysDrv[252:4] -a0

Now check if a drive is still missing,

[root@box ~]# megacli -pdgetmissing -a0

Adapter 0 - No Missing Drive is Found.

Exit Code: 0x00

Check for drives in Foregin State

[root@box ~]# megacli -CfgForeign -Scan -a0

There are 1 foreign configuration(s) on controller 0.

Exit Code: 0x00

As seen above, 1 drive is in a foregin state.

Let's clear the foregin state,

[root@box ~]# megacli -CfgForeign -Clear -a0

Foreign configuration 0 is cleared on controller 0.

Exit Code: 0x00

Replace the missing drive in the array with this drive,

[root@box ~]# megacli -PdReplaceMissing -PhysDrv[252:4] -array0 -row0 -a0

Adapter: 0: Missing PD at Array 0, Row 0 is replaced.

Exit Code: 0x00

Start the rebuild process,

[root@box ~]# megacli -PDRbld -Start -PhysDrv[252:4] -a0

Started rebuild progress on device(Encl-252 Slot-4)

Exit Code: 0x00

Check rebuild progress %,

[root@box ~]# megacli -PDRbld -ShowProg -PhysDrv [252:4] -aAll

Rebuild Progress on Device at Enclosure 252, Slot 4 Completed 0% in 0 Minutes.

Exit Code: 0x00

Last modified: December 06 2019 14:21:55