Hello all. My question is actually simple, but i cannot find the answer (maybe i'm not searching deeply enough). I have users that run experiments in my topology consisting of the localhost and several nodes connected to it. Of course the localhost runs the Nagios core where i monitor given services from the web interface. The users run experiments for specific time periods e.g. a user ran an experiment today from 10 a.m to 11 a.m. I want somehow manually (not from the web interface) to fetch the uptime percentage for the specific time period (this 1 hour) of the nodes that the user used.
Is there a command line way that can fetch the uptime for specific hosts and for specific time period?
Host availability fetching
Re: Host availability fetching
You could use one of the uptime checkers on the exchange like http://exchange.nagios.org/directory/Pl ... me/details.
You will then need to build a script to run it against the remote host (through nrpe) and then cron job it.
You will then need to build a script to run it against the remote host (through nrpe) and then cron job it.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Re: Host availability fetching
First of all, thank you for looking at my problem. Maybe i was not very clear about the question i have. I have installed Nagios and NDOUtils. I want somehow, either with a command or a query to the database, to fetch for a specific time period the check_ping service. Say for example, for a specific host (HostA) i want you to tell me for the 25th January 2013 between 12.00pm and 16.00pm what the check_ping service produced. The output i want to be something like 91%. A percentage for specific host and specific time. The time will not be the always the same so the crontab solution is not viable.
Re: Host availability fetching
You would have to parse the checkdata from the nagios.log file. The actual performance data (if you are using pnp4nagios), is stored in rdds - these files get less granular with time. This functionality does not exist by default and will have to be added by installing pnp4nagios. Unfortunately, this will still not give you all the information you are after, but wit will get you closer.
http://www.pnp4nagios.org/
http://www.pnp4nagios.org/
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.