Problem using snpp.pl for notifications

Dave Augustus davea at support.kcm.org
Tue Aug 30 14:05:50 CEST 2005


Thanks Patrick for the information. A small light bulb has just appeared
above my head. :)



So using the embedded perl is *least expensive* ?

What about Quickpage versus Sendpage? Quickpage is compiled C program
and Sendpage is perl. Would embedded perl calling Quickpage be *less
expensive* than using Sendpage with /usr/bin/perl ?

Dave


On Tue, 2005-08-30 at 13:58 +0200, Patrick Proy wrote:
> Add /usr/bin/perl in the command definition.
> Benefits : script will work.
> Drawbacks : performance.
> 
> Patrick
> 
> -----Message d'origine-----
> De : nagios-users-admin at lists.sourceforge.net
> [mailto:nagios-users-admin at lists.sourceforge.net] De la part de Dave
> Augustus
> Envoyé : mardi 30 août 2005 13:26
> À : Russell Adams
> Cc : nagios-users at lists.sourceforge.net
> Objet : Re: [Nagios-users] Problem using snpp.pl for notifications
> 
> I am new to Nagios. So I am not sure how you *avoid embedded perl*. I just
> set up the misc commands according to what worked.
> 
> How does one avoid embedded perl and what are the benefits and drawbacks?
> 
> Dave
> 
> 
> 
> On Mon, 2005-08-29 at 19:12 -0500, Russell Adams wrote:
> > What if you avoid embedded perl?
> > 
> > Russell
> > 
> > On Mon, Aug 29, 2005 at 05:42:37PM -0500, Dave Augustus wrote:
> > > OK I tried your idea. Here is the response I got:
> > > 
> > > Enter file name: /usr/bin/snpp -m test davea embedded perl plugin 
> > > return code and output was: 3 & '**ePN /usr/bin/snpp: "Can't use 
> > > string ("") as a subroutine ref while"strict refs" in use at p1.pl 
> > > line 260,".
> > > 
> > > At this point, I appears that Sendpage will NOT work with Nagios 2.0 
> > > .... sigh....
> > > 
> > > So I can use quickpage at this point although sendpage looks more 
> > > mature.
> > > 
> > > Any ideas?
> > > 
> > > Dave
> > > 
> > > 
> > > 
> > > 
> > > 
> > > On Sun, 2005-08-28 at 17:13 -0400, Subhendu Ghosh wrote:
> > > > On Sun, 28 Aug 2005, Dave Augustus wrote:
> > > > 
> > > > > I woke up this morning to find that one of my servers died. 
> > > > > However, I didn't receive any notifications on my alpha pager.
> > > > >
> > > > > Checking /var/log/messages has numerous entries like the following:
> > > > >
> > > > > Aug 28 10:14:56 monitor nagios: **ePN failed to compile
> /usr/bin/snpp:
> > > > > "Global symbol "$cmd" requires explicit package name at (eval 6) 
> > > > > li ne 156, Global symbol "$arg" requires explicit package name 
> > > > > at (eval 6) line 163. Global symbol "$cmd" requires explicit 
> > > > > package name at ( eval 6) line 165. Global symbol "$arg" 
> > > > > requires expl" at /usr/bin/p1.pl line 153
> > > > >
> > > > > I use snpp.pl for alpha notifications. Here is my misc_command 
> > > > > for
> > > > > snpp:
> > > > >
> > > > > define  command {
> > > > >    command_name    host-notify-by-tap
> > > > >    command_line    /usr/bin/snpp -d -n -m "Service: $SERVICEDESC$
> Host:
> > > > > $HOSTALIAS$ Address: $HOSTADDRESS$ State: $SERVICESTATE$ Info: 
> > > > > $OUTPUT$
> > > > > Date: $DATETIME$"  $CONTACTPAGER$
> > > > >    }
> > > > >
> > > > > Running the following on Centos4:
> > > > > nagios-nrpe-2.0-3.2
> > > > > nagios-2.0-0.b4.1
> > > > > nagios-plugins-1.4.1-1.2
> > > > > nagios-plugins-nrpe-2.0-3.2
> > > > >
> > > > > If I run snpp from the command line, it works fine. Is there a 
> > > > > parameter that I need to pass for it to invoke snpp properly?
> > > > >
> > > > 
> > > > 
> > > > in the nagios tarball is a program call mini_epn.c - it mimics Nagios'
> 
> > > > embeded Perl interpreter.
> > > > 
> > > > You might want to try running snpp.pl thru that to see if it is ePN
> safe.
> > > > 
> > > --
> > > Dave Augustus <davea at support.kcm.org>
> > > 
> > > 
> > > 
> > > -------------------------------------------------------
> > > SF.Net email is Sponsored by the Better Software Conference & EXPO 
> > > September 19-22, 2005 * San Francisco, CA * Development Lifecycle 
> > > Practices Agile & Plan-Driven Development * Managing Projects & 
> > > Teams * Testing & QA Security * Process Improvement & Measurement * 
> > > http://www.sqe.com/bsce5sf 
> > > _______________________________________________
> > > 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
> > > 
> > > 
> > -----------------------------
> > Russell Adams
> > RLAdams at AdamsInfoServ.com
> > http://www.adamsinfoserv.com/
> > 
> > 
> > -------------------------------------------------------
> > SF.Net email is Sponsored by the Better Software Conference & EXPO 
> > September 19-22, 2005 * San Francisco, CA * Development Lifecycle 
> > Practices Agile & Plan-Driven Development * Managing Projects & Teams 
> > * Testing & QA Security * Process Improvement & Measurement * 
> > http://www.sqe.com/bsce5sf 
> > _______________________________________________
> > 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.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
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