Page 1 of 2

n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 9:05 am
by xcalibur
Hello,

I'd recently installed Nagios and have went through the following tutorial in order to enable Using autoIT scripts with NRPE checks:

http://assets.nagios.com/downloads/nagi ... Nagios.pdf

I did everything perfectly accordingly but the thing is...I have no idea what to do now. How do I monitor the data coming from NSclient? How do I choose the frequency? How do I make it into alerts? How do I report it?

Thanks!

Re: n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 9:09 am
by slansing
Hey Xcalibur, you should now be able to see the check_autoit_timer check as a service from your Views screen. Are you able to see this? Frequency of checks can be set in the Service's setting from the Nagios Core Configuration Manager, or by clicking on the service from the Views screen and then selecting Configure from the tabs in the middle.

By creating a service, the autoIT script's data is being sent to Nagios to be viewed by you already, if you scroll down to the very bottom of the document there is an example of what this looks like.

Re: n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 10:25 am
by xcalibur
slansing wrote:Hey Xcalibur, you should now be able to see the check_autoit_timer check as a service from your Views screen. Are you able to see this? Frequency of checks can be set in the Service's setting from the Nagios Core Configuration Manager, or by clicking on the service from the Views screen and then selecting Configure from the tabs in the middle.

By creating a service, the autoIT script's data is being sent to Nagios to be viewed by you already, if you scroll down to the very bottom of the document there is an example of what this looks like.
Hey Slansing,

Thanks for the quick response!
Check_autoit_timer is defined in Nagios Core Config Manager --> Services.
But under "Views" I get a "No matching services found".
What did I do wrong?

Re: n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 10:26 am
by scottwilkerson
Did you assign a host to it?
Did you Apply Configuration?

Re: n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 10:39 am
by xcalibur
scottwilkerson wrote:Did you assign a host to it?
Did you Apply Configuration?
Oh dear god...
What do I do if "waiting for configuration verification..." fails?

Re: n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 10:41 am
by mguthrie
Start with our general troubleshooting steps outlined below:
http://support.nagios.com/wiki/index.ph ... leshooting

Re: n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 10:48 am
by slansing
The document mguthrie suggested generally helps you self correct any issues. You may also try manually writing the configuration files to see what errors you are recieving. Do this by using the Write Config Files Tool under the Core Config Manager. If you have any problems let us know.

Re: n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 11:38 am
by xcalibur
slansing wrote:The document mguthrie suggested generally helps you self correct any issues. You may also try manually writing the configuration files to see what errors you are recieving. Do this by using the Write Config Files Tool under the Core Config Manager. If you have any problems let us know.
Well, I ran the Write Config Files Tool and got this:

Error: Invalid max_check_attempts value for host 'AutoIT Machine'
Error: Could not register host (config file '/usr/local/nagios/etc/hosts/AutoIT Machine.cfg', starting on line 14)
Error processing object config files!

I looked at that cfg file and all and failed to spot anything resembling "max_check_attempts".

Anyone?

Re: n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 11:44 am
by scottwilkerson
Go to configure -> Core Config Manager -> Hosts -> AutoIT Machine -> Modify -> Check Settings Tab

Set
Max. check attempts=5
Retry interval=1
Check interval=5

Save
Apply Configuration

Re: n00b requesting desperate help please!

Posted: Tue Jun 26, 2012 12:20 pm
by xcalibur
scottwilkerson wrote:Go to configure -> Core Config Manager -> Hosts -> AutoIT Machine -> Modify -> Check Settings Tab

Set
Max. check attempts=5
Retry interval=1
Check interval=5

Save
Apply Configuration
Well, that's much better now!
It would have taken me ages to figure that out, thanks.

One more question though,
when looking in "View" I get the screenshot attached ("Error: Script returned with an error code of 2").
I suppose there's something wrong with the plugin script or the settings at the other end.
How do I start investigating what causes this?