[Nagiosplug-devel] Potential bug in check_fping nagios-plug-1.4alpha1/FreeBSD 4.9-RELEASE/fping 2.4b2_to

Stanley Hopcroft Stanley.Hopcroft at IPAustralia.Gov.AU
Sat Feb 14 14:49:01 CET 2004


Dear Folks,

Is this pilot error or something more sinister ?

tsitc> perl -e 'print `./check_fping rhea -v` while $i++ < 10'
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 1/0/100%
FPING CRITICAL - rhea (loss=100% )|loss=100%;;;0;100
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 1/0/100%
FPING CRITICAL - rhea (loss=100% )|loss=100%;;;0;100
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 1/0/100%
FPING CRITICAL - rhea (loss=100% )|loss=100%;;;0;100
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 1/0/100%
FPING CRITICAL - rhea (loss=100% )|loss=100%;;;0;100
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 1/0/100%
FPING CRITICAL - rhea (loss=100% )|loss=100%;;;0;100
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 1/0/100%
FPING CRITICAL - rhea (loss=100% )|loss=100%;;;0;100
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 1/0/100%
FPING CRITICAL - rhea (loss=100% )|loss=100%;;;0;100
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 1/0/100%
FPING CRITICAL - rhea (loss=100% )|loss=100%;;;0;100
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 1/0/100%
FPING CRITICAL - rhea (loss=100% )|loss=100%;;;0;100
/usr/local/sbin/fping -b 56 -c 1 rhea

rhea : xmt/rcv/%loss = 0/0/0%
FPING OK - rhea (loss=0% )|loss=0%;;;0;100

It is quite reproducible.

The synopsis is 'check_fping reports a down host as up, about 10% of the
time'.

This is _disastrous_ if check_fping is used as 'check-host-alive'.

The problem would appear to be in check_fping rather than fping since

tsitc> perl -e 'print `fping rhea` while $i++ < 10'
rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
tsitc> perl -e 'print `fping rhea` while $i++ < 10'
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
rhea error while sending ping: Host is down

rhea is unreachable
tsitc> 

A stupid guess is that check_fping is not dealing with the case of 0
packets transmitted (there is no arp reply so nothing is sent).

However, I can't see it in the code at this stage.

Problem environment

fping	fping: Version 2.4b2_to $Date: 2002/01/16 00:33:42 $
OS	4.9-RELEASE-p1 FreeBSD 4.9-RELEASE-p1 #13: Fri Dec 26 20:25:10
EST 2003 (i386)
plugins nagios-plug-1.4alpha1 compiled from source on this platform
        (compilation/config details avail on request)
check_fping
        check_fping (nagios-plugins 1.4.0alpha1) 1.11


Yours sincerely.

-- 
------------------------------------------------------------------------
Stanley Hopcroft
------------------------------------------------------------------------

'...No man is an island, entire of itself; every man is a piece of the
continent, a part of the main. If a clod be washed away by the sea,
Europe is the less, as well as if a promontory were, as well as if a
manor of thy friend's or of thine own were. Any man's death diminishes
me, because I am involved in mankind; and therefore never send to know
for whom the bell tolls; it tolls for thee...'

from Meditation 17, J Donne.




More information about the Devel mailing list