Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Has anyone ever added a link into the nagios alert messages that allows the receiver to just click the link to put the alert into the acknowledgement state. I've had a look around but cant see anything.

share|improve this question
up vote 3 down vote accepted

Add a notes_url into service definition:

notes_url $HOSTNAME$&service=$SERVICEDESC$

And append the $SERVICENOTESURL$ macro to the end of alert message, in notify-service-by-email command, Eg:

define command{
    command_name    notify-service-by-email
    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: $SERVICEOUTPUT$\n\nURL: $SERVICENOTESURL$" | /bin/mail -s "** $NOTIFICATIONTYPE$ Service Alert: $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$ 

Do the same for host.

share|improve this answer

You'd need to add a link to your alert script similar to what's below.



What exactly needs to be done depends on your alert script's logic. Keep in mind that the Nagios UI uses frames and these links will only show the Acknowledgement form page without the Nagios navigation bar on the left.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.