Page 1 of 1

FS monitoring not working fine on Cent-OS machine

Posted: Thu Aug 04, 2016 5:05 am
by jyoti22
Hi,
I have installed NRPE agent on cent-os server. This server has below FS however I can see only 1 FS on XI console.
Kindly help to monitor all 3 FS (/,/u1,/boot)
[root@Neagle ~]# df -k
/ (/dev/sda3 ): 2307056 blocks 256150 i-nodes
/dev/shm (tmpfs ): 1027172 blocks 256792 i-nodes
/boot (/dev/sda1 ): 66110 blocks 25650 i-nodes
/u1 (/dev/sda5 ): 64969616 blocks 4389802 i-nodes

In nrpe.cfg file, we have updated commands like this
command[check_disk]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /dev/sda1
command[check_disk]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /dev/sda3
command[check_disk]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /dev/sda5

On XI console, we get out as below. It shows only /u1 parameter and not /boot and /

Re: FS monitoring not working fine on Cent-OS machine

Posted: Thu Aug 04, 2016 9:56 am
by rkennedy
In NRPE's mind, you have defined the same command 3 times, you'll need to assign different ones to each check. Then, update your Nagios services to correspond with how you updated.

Code: Select all

command[check_disk]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /dev/sda1
command[check_disk]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /dev/sda3
command[check_disk]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /dev/sda5
Could be changed to this for example -

Code: Select all

command[check_disk1]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /dev/sda1
command[check_disk2]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /dev/sda3
command[check_disk3]=/usr/lib64/nagios/plugins/check_disk -w 20% -c 10% -p /dev/sda5
Then, update your XI service definition to use check_disk1 rather then check_disk. Do the same for the additional ones as well.

Re: FS monitoring not working fine on Cent-OS machine

Posted: Thu Aug 04, 2016 10:09 am
by bwallace
Not exactly on topic, but there is a Linux Server Wizard in XI which makes this very easy - you specify whatever mount points you want to monitor (provided you have NRPE installed on the target machine)--
https://www.youtube.com/watch?v=NjlDHvNkpes

Re: FS monitoring not working fine on Cent-OS machine

Posted: Fri Aug 05, 2016 12:34 am
by jyoti22
Thanks a lot!
My issue got resolved and I am able to monitor all FS on the server. You can lock this post.

Re: FS monitoring not working fine on Cent-OS machine

Posted: Fri Aug 05, 2016 9:04 am
by bwallace
Glad to hear its resolved! I'll go ahead and lock this thread now.