MegaRAID: Difference between revisions

From DaqWiki
Jump to navigation Jump to search
(Created page with "= MegaRAID = * install MegaCli64 <pre> read https://gist.github.com/fxkraus/595ab82e07cd6f8e057d31bc0bc5e779 wget https://docs.broadcom.com/docs-and-downloads/raid-controllers/raid-controllers-common-files/8-07-14_MegaCLI.zip or get a copy from /home/olchansk/sysadm/MegaRAID as root: unzip 8-07-14_MegaCLI.zip cd Linux alien MegaCli-8.07.14-1.noarch.rpm dpkg -i megacli_8.07.14-2_all.deb cd ~root ln -s /opt/MegaRAID/MegaCli/MegaCli64 . </pre> * get logical drives: ./MegaC...")
 
Line 17: Line 17:
* get physical drives: ./MegaCli64 -pdList -aALL
* get physical drives: ./MegaCli64 -pdList -aALL


= Recover from =
= Recover from "unconfigured bad" =
 
* this means disk was removed at the wrong time
* ./MegaCli64 -pdList -aALL | grep -i for ### should show no foreign configs available
* ./MegaCli64 -PDMakeGood -PhysDrv[134:0] -a0 ### make it "unconfigured good", first number is "Enclosure device id", second number is "slot number" (0 to 7)
* run -pdList again, it should find a foreign config
* repeat for all disks, they all should show foreign config available
* ./MegaCli64 -CfgForeign -Preview -aALL ### examine it
* ./MegaCli64 -CfgForeign -Import -aALL ### import it
* ./MegaCli64 -LDInfo -lALL -aALL ### observe logical drives exist
* ls -l /sys/block ### observe block devices sda, sdb, etc now exist
* blkid ### show disk labels
* mount /dev/sda1 /mnt/tmp ### try to mount

Revision as of 00:59, 23 February 2024

MegaRAID

  • install MegaCli64
read https://gist.github.com/fxkraus/595ab82e07cd6f8e057d31bc0bc5e779
wget https://docs.broadcom.com/docs-and-downloads/raid-controllers/raid-controllers-common-files/8-07-14_MegaCLI.zip
or get a copy from /home/olchansk/sysadm/MegaRAID
as root:
unzip 8-07-14_MegaCLI.zip
cd Linux
alien MegaCli-8.07.14-1.noarch.rpm
dpkg -i megacli_8.07.14-2_all.deb
cd ~root
ln -s /opt/MegaRAID/MegaCli/MegaCli64 .
  • get logical drives: ./MegaCli64 -LDInfo -lALL -aALL
  • get physical drives: ./MegaCli64 -pdList -aALL

Recover from "unconfigured bad"

  • this means disk was removed at the wrong time
  • ./MegaCli64 -pdList -aALL | grep -i for ### should show no foreign configs available
  • ./MegaCli64 -PDMakeGood -PhysDrv[134:0] -a0 ### make it "unconfigured good", first number is "Enclosure device id", second number is "slot number" (0 to 7)
  • run -pdList again, it should find a foreign config
  • repeat for all disks, they all should show foreign config available
  • ./MegaCli64 -CfgForeign -Preview -aALL ### examine it
  • ./MegaCli64 -CfgForeign -Import -aALL ### import it
  • ./MegaCli64 -LDInfo -lALL -aALL ### observe logical drives exist
  • ls -l /sys/block ### observe block devices sda, sdb, etc now exist
  • blkid ### show disk labels
  • mount /dev/sda1 /mnt/tmp ### try to mount