host flapping weighting not always accurate

Hiren Patel hir3npatel at gmail.com
Sat Feb 7 08:13:59 CET 2009


Hendrik Baecker wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Hi Hiren,
> 
> can you please describe the way to rebuild the error?
> I am not familar enough with the flapping code, but dealing with your
> int y for recalculate looks a little bit funny to me.
> If I would be able to reproduce this thing I would approve this patch as
> well as your last.
> 
> 

hi,
the issue is that the current flapping calculation for hosts doesn't 
always give the latest check results the highest weight. the latest 
states are stored in an array, but when the array fills up, it starts 
populating from the beginning again. the flapping calculation in turn 
gives weighting as lowest from the start of the array, to highest at the 
end of the array, when new states wrap around to start being stored in 
the start of the array, they start getting the lowest weighting.
looking at the way the service flapping calculation is done, it looks 
like it is doing it correctly, so that patch takes how service flap 
calculation is done, and does the same for host calculations.

you can refer to function check_for_service_flapping() in 
base/flapping.c line 116.

thanks for the replies.

------------------------------------------------------------------------------
Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM)
software. With Adobe AIR, Ajax developers can use existing skills and code to
build responsive, highly engaging applications that combine the power of local
resources and data with the reach of the web. Download the Adobe AIR SDK and
Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com




More information about the Developers mailing list