Zabbix using Msmtp+mutt to send mail alerts

Source: Internet
Author: User

[[email protected] ~]# wget http://jaist.dl.sourceforge.net/project/msmtp/msmtp/1.4.32/msmtp-1.4.32.tar.bz2 Baidu Network disk: Http://pan.baidu.com/s/1o8w68ci [[email protected] msmtp-1.4.32]# pwd/root/msmtp-1.4.32[[email  Protected] msmtp-1.4.32]# mkdir-p/usr/local/msmtp/etc[[email protected] msmtp-1.4.32]#./configure--prefix=/ USR/LOCAL/MSMTP--with-ssl=openssl [[email protected] msmtp-1.4.32]# make && make install config msmtp[[email& Nbsp;protected] msmtp-1.4.32]# mkdir-p/usr/local/msmtp/etc vim/usr/local/msmtp/etc/msmtprcaccount defaulthost smtp.163.com//SMTP Server Port 25from [email protected]auth logintls offuser clnking//mailbox user name is clnking instead of [email  Protected]password xxxxxx #是授权码 Instead of the mailbox login password (the authorization code is the private password used to log in to the third-party mail client) Note the picture at the beginning of the article logfile/var/log/zabbix/msmtp.log//log path Test msmtp[[email protected] msmtp-1.4.30]#/usr/local/msmtp/bin/msmtp [email protected] (mailbox must be/usr/local/ MSMTP/ETC configuration of the mailbox) so the following will be an error!! Hellomsmtp:the server did not accept the Mailmsmtp:seRVer message:554 dt:spm 163 Smtp4,dtgowaaneru7+exxz+8haq--. 9856s2 1464662088,please See Http://mail.163.com/help/help _spam_16.htm?ip=123.57.36.227&hostid=smtp4&time=1464662088msmtp:could not send mail (account default from/ USR/LOCAL/MSMTP/ETC/MSMTPRC) [[email protected] msmtp-1.4.30]#/usr/local/msmtp/bin/msmtp [email  protected]kkkkkkkkkkkkk^[, but there's nothing in the mailbox. Cat/var/log/mmlogmay 10:47:00 host=smtp.163.com tls=off auth=on user=clnking [ Email protected] [email protected] mailsize=15 smtpstatus=250 smtpmsg= ' + Mail OK queued as SMTP4, Dtgowadxjjqp+0xx0lciaq--. 5878s2 1464662820 ' EXITCODE=EX_OK because there is no configuration: mutt[[email protected] msmtp-1.4.32]# Yum Install mutt [[email protected] ~]# vi/etc/muttrcset sendmail= "/USR/LOCAL/MSMTP/BIN/MSMTP" set Use_from=yesset Editor= "Vim" set Realname= "[email protected]" [[email protected] ~]# echo "Test Mail" content tom2 "|mutt-s "Test Kkkkk" [email protected] access to the mailbox received mail------"Testing success!

Zabbix using Msmtp+mutt to send mail alerts

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.