MegaCli : commandes utiles

MegaCli est probablement l’un des pires utilitaires CLI jamais écrit. Voici quelques commandes très utiles.

# Show status
MegaCli -AdpAllInfo -aAll

# Get physical drive info
MegaCli -PDList -aAll

# Get virtual disk info
MegaCli -LDInfo -Lall -aAll

# Display configuration
MegaCli -CfgDsply -aAll

# Dump eventlog events to file 'events' and open it
MegaCli -AdpEventLog -GetEvents -f events -aAll && less events

# Disable autoLearnMode for the RAID battery
echo "autoLearnMode=1" > tmp.txt \
  && MegaCli -AdpBbuCmd -SetBbuProperties -f tmp.txt -a0

# Disable cache when battery broken
MegaCli -LDSetProp NoCachedBadBBU -LALL -aALL