Page 1 of 5

Nagios Host Configuration Options

Posted: Sat Nov 17, 2012 12:07 pm
by chris2ferz
I had some questions I could not find answers to yet so i'm hoping for some help. This is for the agent running on windows hosts.

1- Is there anyway for Nagios to know if a computer was rebooted or shutdown vs a locked or crashed system? It would be offline either way but one would be intended. This way a false notification would not be sent.

2- For remote monitoring is there a way that the agent could "check-in" to the server rather than the other way around. This would avoid firewall configs if it was a passive connection. If this is not possible then what ports would need to be forwarded? Could combo a dynamic registration service for hosts without a static IP

3- Is there a way for Nagios to monitor a log file for certain strings of text? Also could it run a command or script based on a finding of a string? Or is it just able to notify?

4- Lastly is there a way Nagios can query the SMART status of a hard drive. Typically this check is only done at boot time but for systems that have extended uptimes this duration may be too long. I know vendor tools for hard drives are able to determine the SMART status from within windows. This would help from possible data loss since files could be copied from the system while its still running rather than risking a reboot and possibly losing data.

Thanks to anyone for any help or insight.

Re: Nagios Host Configuration Options

Posted: Sat Nov 17, 2012 12:29 pm
by scottwilkerson
chris2ferz wrote:1- Is there anyway for Nagios to know if a computer was rebooted or shutdown vs a locked or crashed system? It would be offline either way but one would be intended. This way a false notification would not be sent.
1.) Not really however this is where the retry interval comes in. If you aren't sending alerts immediately, it gives an opportunity for the machine to come back online before it sends a notification.
chris2ferz wrote: 2- For remote monitoring is there a way that the agent could "check-in" to the server rather than the other way around. This would avoid firewall configs if it was a passive connection. If this is not possible then what ports would need to be forwarded? Could combo a dynamic registration service for hosts without a static IP
2.) Yes. Take a look at NRDS, this is preinstalled on XI 2012
http://exchange.nagios.org/directory/Ad ... 29/details
chris2ferz wrote:3- Is there a way for Nagios to monitor a log file for certain strings of text? Also could it run a command or script based on a finding of a string? Or is it just able to notify?
3.) yes, it depends on the type of system but there are plugins here
http://exchange.nagios.org/directory/Plugins/Log-Files
chris2ferz wrote:4- Lastly is there a way Nagios can query the SMART status of a hard drive. Typically this check is only done at boot time but for systems that have extended uptimes this duration may be too long. I know vendor tools for hard drives are able to determine the SMART status from within windows. This would help from possible data loss since files could be copied from the system while its still running rather than risking a reboot and possibly losing data
4. http://exchange.nagios.org/directory/Tu ... os/details

Re: Nagios Host Configuration Options

Posted: Sun Nov 18, 2012 5:02 pm
by chris2ferz
Thank you very much. That was alot of good information.

From what checking I did it seems the logfile monitor and the SMART status plugins were non-windows based. I was hoping for a windows agent being able to work with this. I may have misunderstood if it does indeed do that but it wasn't looking that way to me.

Again thanks for the reply especially about the passive check-ins. I am running XI2012 and will read up on that feature.

Re: Nagios Host Configuration Options

Posted: Mon Nov 19, 2012 1:04 am
by scottwilkerson
Here's one that can be used with Windows utilizing NSClient ++'s NRPE

http://exchange.nagios.org/directory/Pl ... rs/details

Re: Nagios Host Configuration Options

Posted: Wed Nov 21, 2012 11:13 am
by chris2ferz
Is there a nice windows based log file checker that would work well with Nagios? Those seem to be linuxed based too. Thanks again you have been very helpful :)

Re: Nagios Host Configuration Options

Posted: Wed Nov 21, 2012 1:08 pm
by lmiltchev

Re: Nagios Host Configuration Options

Posted: Thu Nov 22, 2012 10:35 am
by chris2ferz
That is pretty handy but I was actually looking for something that would monitor or check a text based log file for a string of text. Such as error or failed and then report when those strings are present. I know they have this for linux hosts but i'm having trouble finding this for windows hosts. Thanks and Happy Thanksgiving :)

Re: Nagios Host Configuration Options

Posted: Fri Nov 23, 2012 8:06 am
by scottwilkerson
I think this will do what you want
http://labs.consol.de/nagios/check_logfiles/

The zip download has a windows exe that you can use with NSClient++

Re: Nagios Host Configuration Options

Posted: Wed Jan 23, 2013 12:29 am
by chris2ferz
having an issue where i'm getting a host down when it is online
WINPING CRITICAL - time<1ms
seems like a strange notification

Could someone explain what may be happening?
Also how can I configure the low and high threshold for being notified
as an example if I want to configure to where 90 process is normal rather than too high.

Thanks

Re: Nagios Host Configuration Options

Posted: Wed Jan 23, 2013 10:23 am
by slansing
Can you run the command from your nagios terminal to the windows machine? What does it report back? "This is the easiest way to check things like this sometimes."