average CPU and memory

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
anish
Posts: 161
Joined: Tue Jul 19, 2016 5:29 am

average CPU and memory

Post by anish »

Hi Team,

We are getting CPU & Memory Average report from Nagios Xi. it show more average value. please find the example below.

If the server is shutdown, does the CPU and Mem average calculation in Nagios take this in to account?

So as an example, in a 10 day period, an Server is running for 5 days with avg CPU of 50%.
So Nagios reports shows 10 days value or 5 days value average.
we need exact value server uptime value only. How to calculate it.

we have attached example performance report.
You do not have the required permissions to view the files attached to this post.
kyang

Re: average CPU and memory

Post by kyang »

I just looked into this, and I think it does average it out based on your timeframe.

It does not take into account of when the server was up or down.

Assuming this check is using NSClient (check_nt) correct?
anish
Posts: 161
Joined: Tue Jul 19, 2016 5:29 am

Re: average CPU and memory

Post by anish »

Hi,

Please find the below screen shot. We have configured check_nt for cpu parameter.

Please check and let us know.
You do not have the required permissions to view the files attached to this post.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: average CPU and memory

Post by lmiltchev »

I believe you misunderstood how this check works. It doesn't calculate the CPU average for 5 or 10 days as you cannot use more than 1440 min or 1 day (24*60). The check only calculates the CPU average for the "last x minutes", whatever you passed to the "-l" flag ( 2 minutes in your particular case). Then, the result is plotted on the graph.

See the usage of the check_nt with the CPULOAD option below:
CPULOAD =
Average CPU load on last x minutes.
Request a -l parameter with the following syntax:
-l <minutes range>,<warning threshold>,<critical threshold>.
<minute range> should be less than 24*60.
Thresholds are percentage and up to 10 requests can be done in one shot.
ie: -l 60,90,95,120,90,95
If you didn't want the check to be run at all when the server is down, you could set up a service dependency - make this service dependent on another (master) service (the Ping service), and set the execution failure criteria = c,u. In this case, the dependent service (CPU Average) will not be actively checked if the master service (Ping) is in either CRITICAL, or an UNKNOWN state. You can read more about host/service dependencies here:

https://assets.nagios.com/downloads/nag ... ncies.html

Hope this helps.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked