Hi,
Is there a way I can get historic cpu data for all hosts monitored in Nagios? Min, Max, Average usage for over a year? Ideally exported as a csv.
Any help is appreciated.
Historic CPU data
Re: Historic CPU data
Do you want to see the CPU usage of ALL hosts aggregated in one CSV file?
With the new version of XI coming up, you would be able to download perf graph (for example, CPU Usage for the "Last 365 Days") as CSV. This is done on "per host/service" basis. I don't know if there is a way of aggregating all hosts in one file. This could be a new feature request.
With the new version of XI coming up, you would be able to download perf graph (for example, CPU Usage for the "Last 365 Days") as CSV. This is done on "per host/service" basis. I don't know if there is a way of aggregating all hosts in one file. This could be a new feature request.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Historic CPU data
Aap,
If you can't wait or have the scripting skills, you can in fact achieve this with rrdtool. For example:
SRV_CPU is in my XI the service which monitors CPU usage.
Grtz
Willem
If you can't wait or have the scripting skills, you can in fact achieve this with rrdtool. For example:
SRV_CPU is in my XI the service which monitors CPU usage.
Code: Select all
Average value of SRV_CPU.rrd
rrdtool graph dummy -s -1month -e start+1month DEF:test=_HOST_.rrd:1:AVERAGE PRINT:test:AVERAGE:'average - %.0lf'
Willem
Nagios XI 5.8.1
https://outsideit.net
https://outsideit.net
Re: Historic CPU data
Former Nagios Employee.
me.
me.
Re: Historic CPU data
Hi,
Thanks for both your inputs.
Scripting skills are pretty basic so not sure where to start really.
I do think being able to get this data out from XI would be a great feature. Can we put it in the list?
@WillemDH I have a standard install of XI with little modifications, how can I use the rrdtool to get this data out. Permit my ignorance.
Thanks again.
Thanks for both your inputs.
Scripting skills are pretty basic so not sure where to start really.
I do think being able to get this data out from XI would be a great feature. Can we put it in the list?
@WillemDH I have a standard install of XI with little modifications, how can I use the rrdtool to get this data out. Permit my ignorance.
Thanks again.
Re: Historic CPU data
Look into /usr/local/nagios/share/perfdata/, and from there cd into the host you're looking to check.
From there, you can run the command Willem mentioned -
From there, you can run the command Willem mentioned -
Code: Select all
rrdtool graph dummy -s -1month -e start+1month DEF:test=_HOST_.rrd:1:AVERAGE PRINT:test:AVERAGE:'average - %.0lf'
Former Nagios Employee