Filippo Zanardo's Blog

to blog or not to blog

Posts Tagged ‘Nagios

Nagios XenServer

with 4 comments

I use nagios to check my server, and most of the time i use xenserver 5.5 on them, so i have to trick up the machine to work with nagios and i use an example to check hardware raid on it.

Let’s start first of all execute this command, this download yum priorities and the rpm needed by rpmforge:

wget -c

then install it

rpm –import
rpm -i rpmforge-release-0.3.6-1.el5.rf.*.rpm

Then install some lib needed for nagios, and finally install nagios-plugins nrpe and xinetd.

yum -y install compat-libstdc++-296 compat-libstdc++-33
yum install nagios-plugins nagios-nrpe xinetd

i use a central nagios server and i check raid via nrpe, if u don’t know what is nrpe read this:
nrpe documentation


NRPE allows you to remotely execute Nagios plugins on other Linux/Unix machines. This allows you to monitor remote machine metrics (disk usage, CPU load, etc.). NRPE can also communicate with Windows agent addons like NSClient++, so you can check metrics on remote Windows machines as well.

next modify the file /etc/xinet.d/nrpe updating this line:

disable = no
only_from = #this is the ip of the nagios machine

allow nagios to run some script modify /etc/sudoers like:


this is not so secure on remote machine, modify to suit your needs, i use on lan machine.

next let xinetd start on startup

chkconfig xinetd on
service xinetd start

For example i sue hp prolaint server, so i explain how i check hardware raid on them, first install this rpm:

hp rpm

next i use this plugin to check raid:

raid check

modify nrpe config file (/etc/nagios/nrpe.cfg) adding this line:

command[check_raid]=/usr/lib/nagios/libexec/check_cciss -v

Finally we done set up the machine, and we can check his hardware raid on nagios central server, with the nrpe-plugin, my command on central nagios is:

$user1$/check_nrpe -H $HOSTADDRESS$ -c $ARG1$

and i use it in a service with



p.s. if someone is interested in nagios or in a particular argument related, post your wish and later i can blog on this.


Written by pipposan

December 1, 2009 at 19:11

Posted in Nagios, XenServer

Tagged with , ,