not receiving the nagios notifications
Mike Emigh
maemigh at gmail.com
Fri Jul 28 18:53:42 CEST 2006
On 7/28/06, Aaron Segura <Aaron.Segura at cabelas.com> wrote:
>
> Shameless plug:
>
>
> http://www.nagiosexchange.org/Notifications.35.0.html?&tx_netnagext_pi1[p_view]=627
>
> Maybe try this? That way you don't have to put anything "tricky" on the
> cmdline. It all just goes into the template. No worries about escaping
> special shell characters, etc...
>
> -----Original Message-----
> From: nagios-users-bounces at lists.sourceforge.net [mailto:
> nagios-users-bounces at lists.sourceforge.net] On Behalf Of Felipe Tocchetto
> Sent: Tuesday, July 25, 2006 3:31 PM
> To: Marc Powell
> Cc: Nagios Users Mailinglist
> Subject: Re: [Nagios-users] not receiving the nagios notifications
>
> Hi Marc
>
> Here some tests
>
> The command:
>
> id;/usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: Host
> Notification\nHost: teste.xxx.xxxx.br\nState: CRITICAL\nAddress:
> 200.xxx.xx.xx\nInfo: CRITICAL - Plugin timed out after 10
> seconds\n\nDate//Time: 24/07/2006 11:11:11\n" | /usr/bin/mail -s
> "alert" felipe at tocchetto.com
>
> just 1 line!
>
> The output for the command:
>
> uid=100(nagios) gid=1(other)
>
> And I receive the email:
>
> ***** Nagios *****
>
> Notification Type: Host
> Notification
> Host: teste.xxx.xxxx.br
> State: CRITICAL
> Address:
> 200.xxx.xx.xx
> Info: CRITICAL - Plugin timed out after 10
> seconds
>
> Date/Time: 24/07/2006 11:11:11
>
> All commands are in just 1 line...
>
> I am using the default commands from the nagios instalation, I didn´t
> change anything.
>
>
>
> 2006/7/24, Marc Powell <marc at ena.com>:
> >
> >
> > > -----Original Message-----
> > > From: nagios-users-bounces at lists.sourceforge.net [mailto:nagios-users-
> > > bounces at lists.sourceforge.net] On Behalf Of Felipe Tocchetto
> > > Sent: Monday, July 24, 2006 3:34 PM
> > > To: Nagios Users Mailinglist
> > > Subject: Re: [Nagios-users] not receiving the nagios notifications
> > >
> > > I am using the default command.
> > >
> > > Manually it works, without the vars.
> > > Thanks a lot.
> > >
> > > I really dont know how to fix it.
> >
> >
> > I see a couple more things that I originally attributed to my mail
> > client formatting of your original message. They may actually be
> > problems with your config.
> >
> > # 'host-notify-by-email' command definition
> > define command{
> > command_name host-notify-by-email
> > command_line /usr/bin/printf "%b" "***** Nagios
> > *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\
> > nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo:
> > $HOSTOUTPUT$\n\nDate/Time: $LONGDATETIME$\n" | /usr/bin/mail -s "Host
> > $HOS
> > TSTATE$ alert for $HOSTNAME$!" $CONTACTEMAIL$
> > }
> >
> > In the above definition I see a carriage returns between "$HOSTNAME\"
> > and "nState:" as well as between "Host $HOS" and "TSTATE$". Do they
> > really exist in your config file? They should not. If no, can you send
> > the output of the following command when run as the nagios user?
> >
> > id;/usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: Host
> > Notification\nHost: teste.xxx.xxxx.br\nState: CRITICAL\nAddress:
> > 200.xxx.xx.xx\nInfo: CRITICAL - Plugin timed out after 10
> > seconds\n\nDate/Time: 24/07/2006 11:11:11\n" | /usr/bin/mail -s "Host
> > CRITICAL alert for Test Machine!" felipe at tocchetto.com
> >
> >
> >
> > ------
> >
> > # 'notify-by-email' command definition
> > define command{
> > command_name notify-by-email
> > command_line /usr/bin/printf "%b" "***** Nagios
> > *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVI
> > CEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState:
> > $SERVICESTATE$\n\nDate/Time: $LONGDATETIME$\n\nAdditional Info:\n\
> > n$SERVICEOUTPUT$" | /usr/bin/mail -s "** $NOTIFICATIONTYPE$ alert -
> > $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTE
> > MAIL$
> > }
> >
> > In the above command I see a carriage returns between "$SERIV" and
> > "CEDESC$" as well as between "$CONTACTE" and "MAIL$". Do they really
> > exist in your config file? They should not.
> >
> > --
> > Marc
> >
> >
> -------------------------------------------------------------------------
> > Take Surveys. Earn Cash. Influence the Future of IT
> > Join SourceForge.net's Techsay panel and you'll get the chance to share
> your
> > opinions on IT & business topics through brief surveys -- and earn cash
> >
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> > _______________________________________________
> > 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
> >
>
>
> --
> Felipe L. Tocchetto
> http://felipe.tocchetto.com
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share
> your
> opinions on IT & business topics through brief surveys -- and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> 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
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share
> your
> opinions on IT & business topics through brief surveys -- and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> 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
>
Since you are using Solaris, you may need to change the command to use
/usr/bin/mailx instead of /usr/bin/mail
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20060728/de5f2cac/attachment.html>
-------------- next part --------------
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
-------------- next part --------------
_______________________________________________
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