check_nrpe event handler early exit

Aaron K. Moore amoore at dekalbmemorial.com
Thu Dec 2 17:48:30 CET 2004


 
I recently wrote an event handler for some processes that I monitor. I
set the event handler up to run locally on my Nagios sever.  Then I used
ssh to connect to the remote host and execute the restart command using
sudo.  That way I didn't have to worry about NRPE timing out because the
restart command was taking too long to execute.

--
Aaron Kent Moore
Information Technology Services
DeKalb Memorial Hospital, Inc.
Auburn, IN
Phone:  260.920.2808
E-mail:  amoore at dekalbmemorial.com

-----Original Message-----
From: nagios-users-admin at lists.sourceforge.net
[mailto:nagios-users-admin at lists.sourceforge.net] On Behalf Of
Robert.Lattanzi at fitchratings.com
Sent: Wednesday, December 01, 2004 3:26 PM
To: Andreas Ericsson
Cc: nagios-users at lists.sourceforge.net;
nagios-users-admin at lists.sourceforge.net
Subject: Re: [Nagios-users] check_nrpe event handler early exit



>NRPE only returns exactly one line of output. That's how nagios does
it,
>so that's how NRPE does it. Are you absolutely positive that the script
>doesn't continue to run, but you don't get any further output? It's
also
>more than likely that the script would need elevated privileges to be
>able to send signals to another process.

yes i'm sure. why would I post this if i wasn't? it runs as root via
sudo.

>Are you running it as the same user as NRPE runs as?

Of course- why would I do otherwise?

>You're possibly putting them too close together (in a wallclock sense
of
>speaking). Add a "sleep 5" line between them. That should allow all
>processes to clear away their pid- and lock-files.

Tried that


>That's just plain wrong.

That's just plain obnoxious.


>That won't help in the slightest.
And neither have you.

>You're welcome.
You've done nothing. If you're going to cop so much attitude you should
at
least make some useful suggestions.





Confidentiality Notice:  The information in this e-mail and any
attachment(s) is confidential and for the use of the addressee(s) only.
If you have received this e-mail in error, please delete this e-mail.
Unauthorized use, reliance, disclosure or copying of the contents of
this e-mail, or any similar action, is prohibited.



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when
reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list