Page 2 of 2
Re: Plugin that checks filesystem
Posted: Wed Nov 20, 2013 12:07 pm
by srikanth.kallu
I have applied configuration and how do i make sure my service is enabled ?
I have attached a screenshot to show it runs when i click on test command.
Re: Plugin that checks filesystem
Posted: Wed Nov 20, 2013 12:48 pm
by BanditBBS
Did you add it to the host? go into the service's config and click the "Manage Hosts" button. make sure the host is listed there.
Re: Plugin that checks filesystem
Posted: Wed Nov 20, 2013 1:08 pm
by lmiltchev
BanditBBS is correct - click on the "Manage Hosts" button under the "Common Settings" tab and see if the host has been assigned.
Re: Plugin that checks filesystem
Posted: Wed Nov 20, 2013 3:19 pm
by srikanth.kallu
Thank you after adding the hostname and adding generic serive i can see this service under the host list.
It also alerts me when i run the script from the server. But for some reason the scrvice i created is not calling the script in the server.
To explain this in detail
This is my script
#!/bin/sh
FILE=/tmp/nfs.txt
df -h | grep mnt > $FILE
if [ -s $FILE ]
then
echo "/mnt is OK"
stateid=0
else
echo "/mnt is missing "
stateid=2
fi
exit $stateid
When i run this manually as ./check_nfs_mount.sh it is alerting me when /mnt is missing but serive itself is not calling the script in the server.
Re: Plugin that checks filesystem
Posted: Wed Nov 20, 2013 4:11 pm
by BanditBBS
Is that on the same server as your NagiosXI install? if not, then you need to use NRPE or whatever other method you may be using, to run the check on the remote system.
Re: Plugin that checks filesystem
Posted: Thu Nov 21, 2013 10:33 am
by srikanth.kallu
I did these changes.
1.Added host ( Manage Hosts)
2. Added generic service ( Manage Templete)
But still id did not work. After Disabling and enabling Active schedule it started working great
Thank you very much for all your advices.
Re: Plugin that checks filesystem
Posted: Thu Nov 21, 2013 11:23 am
by slansing
Great! Keep in mind NRPE checks are going to be active checks, always.