How do I change the from: address on the email notifications?

Skip Montanaro skip at pobox.com
Tue Oct 7 20:45:16 CEST 2003


    Demian> My exchange admin would like a real address associated with the
    Demian> notification emails that get sent from Nagios.  Currently they
    Demian> are from nagios at hostname.  Is there somewhere I can set this?
    Demian> I've looked through the config files pretty thoroughly.

Take a look at your notify-by-email and host-notify-by-email commands.  They
probably look something like

    /usr/bin/printf blah blah blah | mail -s blahblahblah

The From: field will be set based upon the user running Nagios.  This is
usually "nagios".  That's a real user as far as Unix is concerned.  Your
easiest path will probably be to create a .forward file in ~nagios which
contains one or more emails which you want to catch those mails:

    demian.m.ginther at boeing.com
    skip at pobox.com

You can likely (depending on the mailer you run on the Nagios machine) also
edit /etc/aliases or /etc/mail/aliases appropriately and then tickle your
mailer (newaliases does the trick on machines running Sendmail).

-- 
Skip Montanaro
Got gigs? http://www.musi-cal.com/
          http://www.mojam.com/
Got spam? http://spambayes.sf.net/


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
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