<html><body><div style="color:#000; background-color:#fff; font-family:arial, helvetica, sans-serif;font-size:12pt"><div>Hi All ,</div><div><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">I was trying to configure to send alert mails for failed services in Nagios . For this , I tried the following configuration</div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">=====<br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family:
arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"> /usr/local/nagios/etc/objects/contacts.cfg <br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">define contact{<br> contact_name zamanl ; Short name of user<br> use
generic-contact ; Inherit default values from generic-contact template (defined above)<br> alias Nagios Admin ; Full name of user<br><br> email zaman@server.example.com ; <<***** CHANGE THIS TO YOUR EMAIL ADDRESS ******<br> }</div><div style="color: rgb(0, 0, 0); font-size: 16px;
font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">define contactgroup{<br> contactgroup_name nagiosadmins<br> alias Nagios Administrators<br> members
zamanl<br> }<br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">Restarted nagios service without any errors and it looks like notifications are generated for failed services by looking at system log file</div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style:
normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">[@server ~]# tail -f /var/log/messages<br>Apr 17 11:26:52 server nagios: SERVICE NOTIFICATION: zamanl;mgthost;Total Processes;CRITICAL;notify-service-by-email;PROCS CRITICAL: 312 processes<br>Apr 17 11:27:22 server nagios: SERVICE NOTIFICATION: zamanl;host1;Total Processes;CRITICAL;notify-service-by-email;PROCS CRITICAL: 313 processes<br>Apr 17 11:27:22 server nagios: SERVICE NOTIFICATION: zamanl;host2;Total Processes;CRITICAL;notify-service-by-email;PROCS CRITICAL: 313 processes<br><br>But I have not received any mail messages for the notification .</div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif;
background-color: transparent; font-style: normal;">[@server ~]$ id<br>uid=501(zaman) gid=501(zaman) groups=501(zaman)<br>[@server ~]# mail<br>No mail for zaman<br>[@server ~]# hostname <br>server.example.com</div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">Kindly suggest what needs to be done to receive alert mail for failed services ? <br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">Any help will be highly appreciated .</div><div style="color: rgb(0,
0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;"><br></div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">Thanks</div><div style="color: rgb(0, 0, 0); font-size: 16px; font-family: arial,helvetica,sans-serif; background-color: transparent; font-style: normal;">Zaman<br></div></div></body></html>