Nagios 2.03b, plugins 1.4 - no status changes
bru1n at comcast.net
bru1n at comcast.net
Thu Apr 21 21:54:13 CEST 2005
Greetings nagios gurii,
I have a single remote service configured, and it works from the command line. I use check_by_ssh configured with ~/.ssh/authorized_keys. I am specifically forcing the plugin to return a warning|critical.
$ id
uid=1003(nagios) gid=101(nagios)
$ uname -a
SunOS monitor 5.10 Generic sun4u sparc SUNW,Sun-Fire-V210
$ pwd
/usr/local/nagios/libexec
./check_by_ssh -H target -s 18 -C "/usr/local/nagios/libexec/check_disk -w 99% -c 90% -p /tmp"
DISK WARNING - free space: /tmp 6763 MB (93%);| /tmp=521MB;72;728;0;7283
>From the target:
root at target: df -k /tmp
Filesystem kbytes used avail capacity Mounted on
swap 7458984 533232 6925752 8% /tmp
So it works from the shell, and it works according to the monitor; "service detail" view. The result from above is exactly what I see in the "Status Information" column next to host "tradev".
The problem:
In the "Status" column, I see "OK" in green. Obviously not what I'd expect.
I have the default remote-ping working on several hosts-- but it works correctly and the status' change accordingly; red or green.
/usr/local/nagios/var/status.dat has this entry for the service:
plugin_output=DISK WARNING - free space: /var/run 6763 MB (100%): /tmp 6763 MB (93%):
Here is my hosts.cfg entry:
define host{
host_name target
alias tradev
address xxx.xxx.xxx.xxx
check_command check-host-alive
max_check_attempts 10
notification_interval 120
notification_period 24x7
notification_options d,r
contact_groups unix-admins
}
Here is my services.cfg entry:
define service{
host_name target
service_description unix-swap-space
is_volatile 0
check_period 24x7
max_check_attempts 4
normal_check_interval 5
retry_check_interval 1
contact_groups unix-admins
notification_interval 960
notification_period 24x7
check_command check-unix-swap
}
and the checkcommands.cfg entry:
# 'check-unix-swap' command definition
define command{
command_name check-unix-swap
command_line $USER1$/check_by_ssh -H $HOSTADDRESS$ -s 18 -C "$USER1$/check_disk -w 99% -c 90% -p /tmp"
}
--Yes, I know there are cleaner ways to do this, but I wanted to take out as many variables as I could til it got running right. ;)
I have searched docs, mail-lists, googled, stopped and restarted everything. I do not seem to be able to get the status to change on critical|warning.
1) Do I have to add authorized_keys on the monitor_host for each target_host?
-- I didn't try because the command as user 'nagios'returns just fine from the shell.
2) 2.03b is compiled on sol10 with gd, host is compiled on sol9, just the plugin;
./configure --prefix=/usr/local/nagios --with-nagios-user=nagios --with-nagios-group=nagios ;make ;make install -- no errors at all.
3) The monitor displays the same on IE 6.needs.patching.bleh.0, Mozilla Firefox 1.02 (shh... I know about 1.03), and Netscape 4.7 (sparc).
Thanks for your time, patience with my brevity, and hopefully direction or solution.
-Marc
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
More information about the Users
mailing list