Re: [Nagios-devel] host flapping weighting not always accurate
Posted: Sat Feb 07, 2009 7:14 am
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.
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
> -----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.
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]