I am not getting notified
Marc Powell
marc at ena.com
Fri Sep 23 22:43:35 CEST 2005
Sending these directly to me isn't necessary/appropriate.
> -----Original Message-----
> From: Efe Ohimor [mailto:eohimor at ipnxnigeria.net]
> Sent: Friday, September 23, 2005 12:40 PM
> To: nagios-users at lists.sourceforge.net
> Cc: Marc Powell
> Subject: I am not getting notified
>
> Hello Forum,
>
> When I set up nagios at first I used to get mail notifications but now
I
> don't.I checked the server logs and discovered the following messages
>
> Sep 22 19:55:34 nagios nagios: SERVICE NOTIFICATION:
> Efe;ipnxtwo;HTTP;CRITICAL;notify-by-email;Connection refused
That's a good thing and shows that Nagios is at least trying to execute
your notification command. Do you see a corresponding entry in your mail
logs? Is your MTA running and processing its queue? Are your disks full
again perhaps?
> I have the following config in my
>
> misccommands.cfg
>
> # '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: $OUTPUT$\n\nDate/Time:
> $DATETIME$\n" | /bin/mail -s "Host $HOSTSTATE$ alert for $HOSTNAME$!"
> $CONTACTEMAIL$
> }
The above notification attempt is a service notification, not a host
notification. The host-notify-by-email command above isn't used in this
case. What does your notify-by-email command look like? That's what
you've specified in the contact definition below for
service_notification_commands. Make sure you can run it from the command
line exactly as it's defined, as nagios, substituting in appropriate
values for the macros.
> contacts.cfg
>
> define contact{
> contact_name Efe
> alias Nagios Admin
> service_notification_period 24x7
> host_notification_period 24x7
> service_notification_options w,u,c,r
> host_notification_options d,u,r
> # service_notification_commands notify-by-email,
notify-by-epager
> # host_notification_commands host-notify-by-email, host-
> notify-by-epager
> service_notification_commands notify-by-email
> host_notification_commands host-notify-by-email
> email eohimor at ipnxnigeria.net
> <mailto:eohimor at ipnxnigeria.net>
> # pager 08028364123
> }
>
>
> hosts.cfg
>
> define host{
[chop host definitions]
Host definitions aren't pertinent in this case since it's a service
you're not receiving a notification for.
--
Marc
-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server.
Download it for free - -and be entered to win a 42" plasma tv or your very
own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
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