开发者社区> 问答> 正文

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

wuxianlvzhou 2017-05-20 20:09:36 7400

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大神,遇到过的帮助帮助!!!!!!!!!!!!

弹性计算 Linux vr&ar
分享到
取消 提交回答
全部回答(2)
  • dongshan8
    2019-07-17 21:12:03

    题主您好,

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

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


    您好,

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

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

    0 0
  • wuxianlvzhou
    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]#

    0 0
添加回答
+ 订阅

时时分享云计算技术内容,助您降低 IT 成本,提升运维效率,使您更专注于核心业务创新。

推荐文章
相似问题
推荐课程