开发者社区> 问答> 正文

centos7 阿里云ECS环境,使用465端口发送邮件报错

centos7 阿里云ECS环境,使用465端口发送邮件报错:

1、配置文件如下:
[root@vrbp-task-pre woasis]# cat /etc/mail.rc
set smtp="smtps://smtp.163.com:465"
set smtp-auth-user="wuxxxx@163.com"
set smtp-auth-password="yuxxxx"
set smtp-auth=login

2、执行发送报错:
[root@vrbp-task-pre woasis]# echo message4 | mail -v -r "wuxxxxxx@163.com" -s "This is the subject" 47xxxxxx@qq.com
Resolving host smtp.163.com . . . done.
Connecting to 220.181.12.13:465 . . . connected.
Missing "nss-config-dir" variable.
"/root/dead.letter" 11/310
. . . message not sent.
[root@vrbp-task-pre woasis]#

求阿里云大神或者BBS大神,遇到过的帮助帮助!!!!!!!!!!!!

展开
收起
wuxianlvzhou 2017-05-20 20:09:36 13374 0
2 条回答
写回答
取消 提交回答
  • 旺旺:nectar2。

    题主您好,

    或许您可以参考一下这个问答:http://stackoverflow.com/questions/16799407/mailx-and-gmail-nss-config-dir

    即可能要设置 nss-config-dir 的值。


    您好,

    为您写了这个帖子,希望对您有用:

    《在CentOS 7系统里使用465端口发送邮件》 - https://bbs.aliyun.com/read/316576.html

    2019-07-17 21:12:03
    赞同 展开评论 打赏
  • 1、根据上面的错误更改配置:
    set smtp="smtps://smtp.163.com:465"
    set smtp-auth-user="wuxxxxx@163.com"
    set smtp-auth-password="yuxxxxx"
    set smtp-auth=login
    set ssl-verify=ignore
    set nss-config-dir=/etc/pki/nssdb/

    2、继续报错:
    [root@vrbp-task-pre etc]# echo message4 | mail -v -r "wuxxxxx@163.com" -s "This is the subject" 47xxxxxx@qq.com
    Resolving host smtp.163.com . . . done.
    Connecting to 220.181.12.13:465 . . . connected.

    Error in certificate: Peer's certificate issuer is not recognized.

    Comparing DNS name: "*.163.com"
    SSL parameters: cipher=missing, keysize=256, secretkeysize=256,
    issuer=CN=GeoTrust SSL CA - G3,O=GeoTrust Inc.,C=US
    subject=CN=*.163.com,OU=MAIL Dept.,O="NetEase (Hangzhou) Network Co., Ltd",L=Hangzhou,ST=Zhejiang,C=CN
    220 163.com Anti-spam GT for Coremail System (163com[20141201])

    EHLO vrbp-task-pre.woasis.com
    250-mail

    250-PIPELINING
    250-AUTH LOGIN PLAIN
    250-AUTH=LOGIN PLAIN
    250-coremail 1Uxr2xKj7kG0xkI17xGrU7I0s8FY2U3Uj8Cz28x1UUUUU7Ic2I0Y2UFPkoPMUCa0xDrUUUUj
    250-STARTTLS
    250 8BITMIME

    AUTH LOGIN

    334 dXNlcm5hbWU6

    d3Vrb25nZm9AMTYzLmNvbQ==

    334 UGFzc3dvcmQ6

    eXUxOTkzQUo=

    235 Authentication successful

    MAIL FROM:wuxxxxx@163.com

    250 Mail OK

    RCPT TO:47xxxxx@qq.com

    250 Mail OK

    DATA

    354 End data with .

    .

    250 Mail OK queued as smtp9,DcCowADnhlJdOyBZ0EIpFQ--.56836S2 1495284573

    QUIT

    221 Bye
    [root@vrbp-task-pre etc]#

    2019-07-17 21:12:03
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
如何运维千台以上游戏云服务器 立即下载
网站/服务器取证 实践与挑战 立即下载
ECS块储存产品全面解析 立即下载