<div>Hi,</div>
<div> </div>
<div>Please help me in sending notifications. I have only one configuration file for contactfgroup,hostsgroup etc.  "minimal.cfg"</div>
<div> </div>
<div>minimal.cfg :</div>
<div> </div>
<div>define timeperiod{<br>        timeperiod_name 24x7<br>        alias           24 Hours A Day, 7 Days A Week<br>        sunday          00:00-24:00<br>        monday          00:00-24:00<br>        tuesday         00:00-24:00 
<br>        wednesday       00:00-24:00<br>        thursday        00:00-24:00<br>        friday          00:00-24:00<br>        saturday        00:00-24:00<br>        }<br> </div>
<div>
<p>define command{<br>        command_name    notify-by-email<br>       command_line    /usr/bin/printf "%b" "***** Nagios  *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $LONGDATETIME$\n\nAdditional Info:\n\n$OUTPUT$" | /bin/mail -s "** $NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$ 
<br>                }</p>
<p><br># This is a sample host notification command that can be used to send email<br># notifications (about host alerts) to contacts.</p>
<p>define command{<br>        command_name    host-notify-by-email<br>       command_line    /usr/bin/printf "%b" "***** Nagios  *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo: $OUTPUT$\n\nDate/Time: $LONGDATETIME$\n" | /bin/mail -s "Host $HOSTSTATE$ alert for $HOSTNAME$!" $CONTACTEMAIL$ 
<br>        }<br></p>
<p>define contact{<br>        contact_name                    nagios<br>        alias                           Nagios Admin<br>        service_notification_period     24x7<br>        host_notification_period        24x7 
<br>        service_notification_options    w,u,c,r<br>        host_notification_options       d,r<br>        service_notification_commands   notify-by-email<span></span> <br>        host_notification_commands      host-notify-by-email 
<br>        email                           <a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:nagios@localhost" target="_blank">nagios@localhost</a><br>        }</p>
<p>define contact{<br>        contact_name                    chandresh<br>        alias                           Administrator<br>        service_notification_period     24x7<br>        host_notification_period        24x7 
<br>        service_notification_options    w,u,c,r<br>        host_notification_options       d,r<br>        service_notification_commands   notify-by-email<br>        host_notification_commands      host-notify-by-email 
<br>        email                           "personalemail id"<br>        }</p>
<p>define contactgroup{<br>        contactgroup_name       admins<br>        alias                   Nagios Administrators<br>        members                 nagios<br>        }</p>
<p>define contactgroup{<br>        contactgroup_name       admingrp<br>        alias                   Administrators<br>        members                 chandresh<br>        }<br></p>
<p>define host{<br>        name                            generic-host    ; The name of this host template<br>        notifications_enabled           1       ; Host notifications are enabled<br>        event_handler_enabled           1       ; Host event handler is enabled 
<br>        flap_detection_enabled          1       ; Flap detection is enabled<br>        failure_prediction_enabled      1       ; Failure prediction is enabled<br>        process_perf_data               1       ; Process performance data 
<br>        retain_status_information       1       ; Retain status information across program restarts<br>        retain_nonstatus_information    1       ; Retain non-status information across program restarts<br>        register                        0       ; DONT REGISTER THIS DEFINITION - ITS NOT A REAL HOST, JUST A TEMPLATE! 
<br>        }</p>
<p><br>define host{<span></span> <br>        use                     generic-host            ; Name of host template to use<br>        host_name               <a onclick="return top.js.OpenExtLink(window,event,this)" href="http://webmail.com/" target="_blank">
webmail.com</a><br>        alias                   localhost <br>        address                 <a onclick="return top.js.OpenExtLink(window,event,this)" href="http://127.0.0.1/" target="_blank">127.0.0.1</a><br>        check_command           check-host-alive
<br>        max_check_attempts      10<br>        notification_interval   120<br>        notification_period     24x7 <br>        notification_options    d,r<br>        contact_groups          admingrp<br>        }<br>define service{
<br>        use                             generic-service         ; Name of service template to use<br>        host_name                       <a onclick="return top.js.OpenExtLink(window,event,this)" href="http://webmail.com/" target="_blank">
webmail.com</a><br>        service_description             HTTP<br>        is_volatile                     0<br>        check_period                    24x7<br>        max_check_attempts              4 <br>        normal_check_interval           5
<br>        retry_check_interval            1<br>        contact_groups                  admingrp<br>        notification_interval           960<br>        notification_period             24x7 <br>        check_command                   check_http
<br>        }<br></p>
<p>I am able to send mails to my persoanl email id by "mail" command. But notification is not going. I have configured sendmail. I am not even receiving mails on local system at <a onclick="return top.js.OpenExtLink(window,event,this)" href="mailto:nagios@localhost" target="_blank">
nagios@localhost</a>( I tried). I am even not getting any error messages in logs of nagios.</p>
<p>Please help.</p></div>