Notification using notify-html-email.sh

Thomas Guyot-Sionnest dermoth at aei.ca
Sun Jul 27 06:08:16 CEST 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 25/07/08 12:58 PM, Jonathan Williams wrote:
> Reposted with apologies:
> 
>  
> 
> After giving up on the send_mail.pl script I am going with the
> notify-html-email.sh add-on.  I seems pretty straight forward.  One
> question on a command.  The command to run when notifying service alerts
> 
> reads:
> 
>  
> 
> define command {
> 
>       command_name    notify-html-email
> 
>       command_line    /usr/local/nagios/libexec/notify-html-email.sh
> 
> service
> 
>       }
> 
>  
> 
> I get this error in the nagios log:
> 
>  
> 
> [1217000677] Warning: Attempting to execute the command
> "/usr/local/nagios/libexec/notify-html-email.sh service" resulted in a
> return code of 127.  Make sure the script or binary you are trying to
> execute actually exists...
> 
>  
> 
> Sounds familiar.  Nagios is the owner and I also ran "chmod
> 
> 0755 /usr/local/nagios/libexec/notify-html-email.sh".  That is
> definately where the file is and permissions are good. 
> 
>  
> 
> I am wondering about the fact that "service" is after it.  There is no -
> or / or anything before that.  The error looks like it's trying to find
> a file called "notify-html-email.sh service" rather than the file
> notify-html-email.sh" with a parameter of "service". 
> 
>  
> 
> I have attached the script it is running. 

If you think it's your nagios configuration you could try running a
no-op bash script instead and see if it works.

Another suggestion would be to look at every programs called from
/usr/local/nagios/libexec/notify-html-email.sh and make sure the full
path is used,

Thomas
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFIi/Sw6dZ+Kt5BchYRAlXMAJ9b1QWdLjVs4wcj4zVwwQk+4ikYXgCfWPA3
9TufPp2u6fRhU0DrRoE5jDs=
=Oe/o
-----END PGP SIGNATURE-----

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
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