If you are like me, you may be interested in monitoring a XenServer host’s local LSI RAID controller. In particular, I wanted to see the status via SNMP, in order to tie into monitoring systems. You can also use the MegaRAID Storage Manager for viewing and configuring remotely and without having to reboot the host.
Switch the system to shadow passwords. This is required for the Storage Manager application, and it’s insane the XenServer doesn’t already run this way by default.
Install the required packages. The .rpm files are all included in the download from LSI. Be sure to get the x86 version (not x64), as the XenServer dom0 is not 64 bit.
yum --enablerepo=base install net-snmp-utils rpm -ivh Lib_Utils-1.00-09.noarch.rpm rpm -ivh Lib_Utils2-1.00-02.noarch.rpm rpm -ivh MegaRAID_Storage_Manager-12.05.03-00.noarch.rpm rpm -ivh sas_ir_snmp-12.05-0201.i386.rpm
Add the following lines to /etc/sysconfig/iptables in order to allow Storage Manager and SNMP traffic. These lines should go right next to the similar lines for port 22, 80, etc.
-A RH-Firewall-1-INPUT -m state --state NEW -m udp -p udp --dport 161 -j ACCEPT -A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 3071 -j ACCEPT -A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 5571 -j ACCEPT
Apply the firewall changes
service iptables restart
Add the following line to /etc/snmp/snmpd.conf in order to permit reading LSI OIDs via the “public” community.
view systemview included .188.8.131.52.4.1.3582
Finally enable/start all the services, and try an snmp query to make sure it works:
chkconfig vivaldiframeworkd on chkconfig snmpd on service vivaldiframeworkd start service snmpd start snmpwalk -v2c -c public 127.0.0.1 .184.108.40.206.4.1.3582