check_ping can't interpret output

Hugo van der Kooij hvdkooij at vanderkooij.org
Tue Jul 29 08:07:44 CEST 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Dave Close wrote:
| I have the same version of Nagios installed on a dozen systems (not
| machines, full systems with several hundred machines each). Except for
| the specific list of machines, the configuration is identical between
| them. All are installed by yum from the Fedora 7 RPMs, version
| 2.10-3.fc7. All the plugins were installed the same way and are version
| 1.4.11-2.fc7.

Hmm. Please read the various comments on the lifespan of fedora releases
on this and other mailinglists. Is this what you want in a corporate
environment?

| On one system only, check_host_alive (which calls check_ping) reports
| that all machines are down, while at the same time Nagios reports that
| most services on those machines are up. Running check_ping as root from
| the command line gets a successful response. Digging further, I have
| enabled user "apache", which is the user httpd runs as, then tried the
| command as user apache. Here is the result.

I am a bit puzzled. Plugins are run as nagios user and not as apache
user so why test as apache user. Unless your nagios setup deviates quite
a bit in this regard bt I find that rather unlikely at this momemt.
|
| # /usr/lib/nagios/plugins/check_ping -H machine -w 3000.0,80% -c
| 5000.0,100% -p 1
| PING OK - Packet loss = 0%, RTA = 0.16 ms
| # su - apache -c "/usr/lib/nagios/plugins/check_ping -H machine -w
| 3000.0,80% -c 5000.0,100% -p 1"
| /bin/ping -n -U -w 10 -c 1 machine
| CRITICAL - Could not interpret output from ping command
|
| Some online references appear to suggest this could be caused by a LANG
| environment variable. I temporarily replaced the check_ping command with
| a wrapper script that saved the environment to a file before calling the
| actual command. There was no difference in LANG and the only other
| differences had to do with the name of the last machine tested. All
| systems report LANG=en_US.UTF-8.

This would only matter if these variables differ for various users.

If you want to compare system properly compare the binaries wih MD5
hashes and things like that.

Also read the suggestions to drop check_ping for better checks in the
archives of this mailinglist.

Hugo.

- --
hvdkooij at vanderkooij.org               http://hugo.vanderkooij.org/
PGP/GPG? Use: http://hugo.vanderkooij.org/0x58F19981.asc

	A: Yes.
	>Q: Are you sure?
	>>A: Because it reverses the logical flow of conversation.
	>>>Q: Why is top posting frowned upon?

Bored? Click on http://spamornot.org/ and rate those images.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)

iD8DBQFIjrOuBvzDRVjxmYERAjJFAJ9QRAqSSB1jRnGeuz4DrJ7az4qKBwCdG3i9
yp2LgvjQYWUnzsqgqZxG2FY=
=Rd2f
-----END PGP SIGNATURE-----

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
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