This is an ongoing project I needed a place to keep notes I can easily access from a bootable Linux live. I will update this with full details once the entire project is completed.
Systems:
Running older versions of Linux seemed like it would be no issue since this card’s drivers and command line utility are kind of old. The most recent update to the MegaCli is 2013. However, I had my first bit of success with the newest Puppy Linux and after that switched to Ubuntu since I couldn’t get the installer to act right in the live environment. I’m sure that is an easy fix, but not one I’m willing to spend time on right now.
Hardware:
PERC H730P with the newest firmware (25.5.9.0001). This is very important. I couldn’t see the drives in HBA mode no matter what I did until I updated the firmware. I do have a few new tactics I picked up along the way that I will outline below. Lucky for me I also have a duplicate system with a card that isn’t yet updated. So I will be able to test this later.
Random Dell server. I had two IBM System X servers that I was working with but the cards they had required flashing and many people warned of issues with the flashing process.
Command-List:
All of the following commands are ones I found helpful either they are essential to the process and I’m using them or they are helpful for troubleshooting.
lsblk
lsmod | grep mega
lspci | grep raid
wget https://docs.broadcom.com/docs-and-downloads/raid-controllers/raid-controllers-common-files/8-07-14_MegaCLI.zip
unzip 8-07-14_MegaCLI.zip
cd Linux
sudo apt install alien
sudo dpkg -i megacli_8.07.14-2_all.deb
Test:
/opt/MegaRAID/MegaCli/MegaCli64 -h
I would get an error about libtinfo.so.5 not being found or something similar. After way too much time trying to find the older version to install I ended up making a symbolic link.
sudo ln -s /usr/lib/x86_64-linux-gnu/libncurses.so.6 /usr/lib/x86_64-linux-gnu/libncurses.so.5
Maybe needs libinfo.so.5 as well?
Test:
/opt/MegaRAID/MegaCli/MegaCli64 -h
If things are working you get the help output.
Next I want to know what information I can see.
/opt/MegaRAID/MegaCli/MegaCli64 -AdpAllInfo -aAll
This got me the adapter number which you will want to write down or remember.
For the rest of these, I’m still testing the best order and approach. I also made an alias /opt/MegaRAID/MegaCli64
to megalul
specifically, when possible we want to leave as much of the disk intact as possible including the metadata. When the drives are bad that may not be possible. When I come back and update this post with all my details I will include as much information about my findings as possible.
megalul -CfgForeign -Scan -aAll
megalul -CfgForeign -Dsply -aAll
megalul -PDList -a0
megalul -PDMakeJBOD -PhysDrv[32:0] -a0
sudo apt install gddrescue
sudo ddrescue -d -n -b 4096 /dev/sdb /media/ubuntu/4TB/drive3raw.img /media/ubuntu/4TB/ddrescue.log
Some of the issues I ran into during this process had to do with physical damage to one of the drives. Logical damage is easier to deal with. I will be testing with 2 other RAID arrays to see if I can find a clear path to an easier time with this. I’ll also add pictures.