峯言凬语 My life is brilliant~
本无意与众不同,怎奈何口味太重。
文章分类
友情链接

apt-get install postfix

vi /etc/postfix/main.cf

sudo apt-get install dovecot-common dovecot-imapd dovecot-pop3d

vi /etc/dovecot/dovecot.conf

这里配置邮件的存放目录,这里和Postfix设置的要一致,都是在用户主目录下的Maildir目录下。

mail_location = maildir:~/Maildir

监听所有的端口

listen= *

允许明文密码验证

disable_plaintext_auth = no

使用ssl加密

ssl = required

ssl秘钥存放路径,目前这两个文件也是不存在的,也需要按照后面的步骤我们手动生成

ssl_cert =< /etc/ssl/certs/ssl-cert-snakeoil.pem
ssl_key =< /etc/ssl/private/ssl-cert-snakeoil.key

设置认证的默认选项,auth是一个socket文件,通过该文件dovecot和postfix进行通信,来传递postfix的认证信息,这里面的path要和postfix设置的一致。

auth default {
socket listen {
client {
path =/var/spool/postfix/private/auth
mode = 0660
user = postfix
group = postfix
}
}

service postfix restart
service dovecot restart

已有 2 条评论
    Adam Gun
    Adam Gun
    2018-08-20 23:44

    Port 25 unblocked on Vultr VPS. I need it open, but helpdesk tell me that In order to combat spam and spamlike activities, they system requires a properly completed and vetted CC authorization form to confirmclients’ identities prior to SMTP block removal...

    2018-08-20 23:36

    我配置后经常出现邮件无法送达,或者超时。

添加新评论