Page 2 of 2
Re: Changing the from e-mail address in Nagios
Posted: Fri May 09, 2014 10:17 am
by povachon
I have try the SMTP and still the same issue!
All my alert notification on hosts or services come from
[email protected] for some reason ! But when i make a test, it come from
[email protected]
Im using contact for notification !
Re: Changing the from e-mail address in Nagios
Posted: Fri May 09, 2014 10:22 am
by slansing
You need to answer all of our questions, so we can get the the resolution as fast as possible.....
Yes, but have you tested actual notifications from your hosts/services yet? With this address?
We need to know what steps you are using to test this.
You might also try changing the following in CCM > Commands > notify-host-by-email, and notify-service-by-email
You will have to modify "notify-host-by-email" and "notify-service-by-email" by adding "-f <your from address>" at the end of each command. This *should* work with sendmail.
Apply configuration, then send a notification from one of your hosts/services from Home > Hosts > 'host name' > Advanced Tab > Send Custom Notification.
Re: Changing the from e-mail address in Nagios
Posted: Fri May 09, 2014 10:28 am
by povachon
Yes i did test using custum notification on a host that allrdy have a problem !
Otherwise i dont understand what you mean :Yes, but have you tested actual notifications from your hosts/services yet? With this address?
You want me to change the cmd
from:
/usr/bin/printf "%b" "***** Nagios Monitor XI Alert *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo: $HOSTOUTPUT$\n\nDate/Time: $LONGDATETIME$\n" | /bin/mail -s "** $NOTIFICATIONTYPE$ Host Alert: $HOSTNAME$ is $HOSTSTATE$ **" $CONTACTEMAIL$
to:
/usr/bin/printf "%b" "***** Nagios Monitor XI Alert *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo: $HOSTOUTPUT$\n\nDate/Time: $LONGDATETIME$\n" | /bin/mail -s "** $NOTIFICATIONTYPE$ Host Alert: $HOSTNAME$ is $HOSTSTATE$ **" $CONTACTEMAIL$ -f
[email protected]
Is that right?
PO
Re: Changing the from e-mail address in Nagios
Posted: Fri May 09, 2014 10:31 am
by povachon
IT WORK ! THX for you patient !