dwarf,
I don't believe you can check the swap on remote servers with the check_swap plugin. You have to use something else to achieve this task. Are you still having problems checking remote hosts with nagios? If so here are the steps:
1. Add the host in hosts.cfg
2. Make sure the plugin is defined checkcommands.cfg
3. In services.cfg, that's where you define the check for the host.
4. reload nagios and that's it.
If that doesn't help you, paste the configs above and let me take a look at it. Also, let me know the service that you want to check.
DAVID ROSS,
I have a question for you if you don't mind
. Ok, I read the plugin guidelines and I still cannot get output when nagios runs my custom plugin. It just gives me (No Output!). Grrr. Below is my plugin called check_trd:
#!/bin/sh
ps -ef | grep nagios > /dev/null 2>&1
if [ $? -eq 0 ]; then
STATE_OK=0
/bin/echo "OK: Process is up\n"
fi
exit $STATE_OK
As you can see, it just checks to make sure nagios process is up and running. It does print "OK....." on STDOUT but nagios doesn't see it. It also gives me a warning when I don't believe it should as I exitted with 0 (that should return the state to be 'OK'). I don't know what I'm doing wrong. Can you please help? Thank you.
-twantrd