| Languages: |
English • Deutsch |
|
It is easy to test your plugin before actually using it. Just be sure to do it the same way that Nagios would do it. The easiest way to ensure this is to be the Nagios user.
For example:
su - nagios cd /tmp /usr/local/nagios/libexec/check_icmp -H www.nagioswiki.org ; echo "Plugin Return Code: $?"
However please note the following
Use the plugin as a Nagios check command as follows with a dynamic host address:
define command{
command_name check_icmp
command_line $USER1$/check_icmp -H $HOSTADDRESS$
}
Define a Nagios service to actually use the check_icmp command:
define service{
host_name nagioswiki_server
service_description www.nagioswiki.org icmp echo
check_command check_icmp
}