Calculation of nagios latency in nagiostas

Yu Watanabe yu.watanabe at jp.fujitsu.com
Tue Feb 22 09:26:37 CET 2011


Thank you for the reply.

This logic seems to be deep ...
I will take time to digest this theory.

Thanks!
Yu

Yueh-Hung Liu さんは書きました:
>because at any moment in physical, not all checks will be performed,
>therefore Nagios only knows the "previous" average latency and the
>latency of services which have just finished.
>Nagios won't keep the latency of checks in somewhere so it has to
>calculate the "present" average latency right after each check while
>it has the newest latency of that check in hand.
>you can see the formula that while the total latency is restored, the
>number of checks will be decreased by 1, that means the latency of the
>check just finished will be added to calculate new average latency.
>this method can make sure the average latency is "dynamical" and "real time".
>
>
>On Tue, Feb 22, 2011 at 8:25 AM, Yu Watanabe <yu.watanabe at jp.fujitsu.com> wrote:
>> Hello all.
>>
>> I would like to ask question for the calculation with nagios latecy.
>> In the nagiostats.c , the calculation of 'average_active_service_latency' is
>> not doing the simple way, which is
>>
>> 1. Add up the latecy of each service
>> 2. Devide by the number of services
>>
>> rather than above it is caculating as,
>>
>> average_active_service_latency=(((average_active_service_latency*((double)active_service_checks-1.0))+latency)/(double)active_service_checks);
>>
>> 1. Revert the average sum by multiplying the previous average and number of checks
>> 2. Add up the latency of the current line
>> 3. Devide by the number of services
>>
>> Would there be a specific reason or thought in this calculation?
>>
>> Thanks,
>> Yu Watanabe
>>
>>
>> ------------------------------------------------------------------------------
>> Index, Search & Analyze Logs and other IT data in Real-Time with Splunk
>> Collect, index and harness all the fast moving IT data generated by your
>> applications, servers and devices whether physical, virtual or in the cloud.
>> Deliver compliance at lower cost and gain new business insights.
>> Free Software Download: http://p.sf.net/sfu/splunk-dev2dev
>> _______________________________________________
>> 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
>>
>
>------------------------------------------------------------------------------
>Index, Search & Analyze Logs and other IT data in Real-Time with Splunk 
>Collect, index and harness all the fast moving IT data generated by your 
>applications, servers and devices whether physical, virtual or in the cloud.
>Deliver compliance at lower cost and gain new business insights. 
>Free Software Download: http://p.sf.net/sfu/splunk-dev2dev
>_______________________________________________
>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
>


------------------------------------------------------------------------------
Index, Search & Analyze Logs and other IT data in Real-Time with Splunk 
Collect, index and harness all the fast moving IT data generated by your 
applications, servers and devices whether physical, virtual or in the cloud.
Deliver compliance at lower cost and gain new business insights. 
Free Software Download: http://p.sf.net/sfu/splunk-dev2dev
_______________________________________________
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