Re: i don't receive mail notification...
Posted: Mon Jun 09, 2014 3:05 am
i'm so confused about this command! ehehe
@eloyd @sreinhardt @Stuart Watts
anyway do you want a command like this?:
or like this? :
in the second case the notification arrives to account [email protected]
uff...i'm desperate
@eloyd @sreinhardt @Stuart Watts
anyway do you want a command like this?:
Code: Select all
root@backups:~# su - nagios /usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: PROBLEM\n\nService: HTTP\nHost: IpCop Milano ESA\nAddress: 192.168.33.1\nState: CRITICAL\n\nDate/Time: Thu Jun 5 14:51:10 CEST 2014\n\nAdditional Info:\n\nHTTP CRITICAL: HTTP/1.0 504 Gateway Time-out - 1937 bytes in 0,183 second response time\n" | /usr/bin/mail -s "** PROBLEM Service Alert: IpCop Milano ESA/HTTP is CRITICAL **" [email protected]
/usr/bin/printf: 1: /usr/bin/printf: Syntax error: ")" unexpected
Null message body; hope that's ok
Code: Select all
root@backups:~# su - nagios
$ /usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: PROBLEM\n\nService: HTTP\nHost: IpCop Milano ESA\nAddress: 192.168.33.1\nState: CRITICAL\n\nDate/Time: Thu Jun 5 14:51:10 CEST 2014\n\nAdditional Info:\n\nHTTP CRITICAL: HTTP/1.0 504 Gateway Time-out - 1937 bytes in 0,183 second response time\n" | /usr/bin/mail -s "** PROBLEM Service Alert: IpCop Milano ESA/HTTP is CRITICAL **" [email protected]
uff...i'm desperate