Zabbix mstmp+Mutt發郵件注意權限

root@tw-mtj-223:~# su zabbix

$ cd ^H^H^H^H^C

$ echo "test"|mutt -s "test" [email protected]

msmtp: authentication failed (method LOGIN)

msmtp: server message: 550 User has no permission

msmtp: could not send mail (account default from /home/zabbix/.msmtprc)

msmtp: cannot log to /usr/local/msmtp/msmtp.log: cannot open: Permission denied

msmtp: log info was: host=smtp.163.com tls=off auth=on [email protected] [email protected] [email protected] smtpstatus=550 smtpmsg='550 User has no permission' errormsg='authentication failed (method LOGIN)' exitcode=EX_NOPERM

Error sending message, child exited 77 (Insufficient permission.).

Could not send the message.

$ exit

root@tw-mtj-223:~# cp .msmtprc /home/zabbix/

root@tw-mtj-223:~# chown -R zabbix:zabbix /home/zabbix/

root@tw-mtj-223:~# chown -R zabbix:zabbix /usr/local/msmtp/

root@tw-mtj-223:~# su zabbix

$ ^[[A^[[A^C

$ echo "test"|mutt -s "test" [email protected]


發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章