我在使用 PostFix 和 Dovecot 时遇到问题。我遵循了本指南:https : //github.com/opensolutions/ViMbAdmin/wiki/Mail-System-Install-on-Ubuntu ,当邮件发送到服务器时,这在 mail.log 中
Oct 26 12:40:11 vps31465 postfix/smtpd[13551]: connect from nm3-vm2.bt.bullet.mail.ir2.yahoo.com[212.82.99.122]
Oct 26 12:40:11 vps31465 postfix/smtpd[13551]: warning: SASL: Connect to private/dovecot-auth failed: No such file or directory
Oct 26 12:40:11 vps31465 postfix/smtpd[13551]: fatal: no SASL authentication mechanisms
Oct 26 12:40:12 vps31465 postfix/master[13383]: warning: process /usr/lib/postfix/smtpd pid 13551 exit status 1
Oct 26 12:40:12 vps31465 postfix/master[13383]: warning: /usr/lib/postfix/smtpd: bad command startup -- throttling
Run Code Online (Sandbox Code Playgroud)
这是我从 postfix -n 的输出:
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
append_dot_mydomain = no
biff = no
broken_sasl_auth_clients = yes
config_directory = /etc/postfix
home_mailbox = Maildir/
inet_interfaces = all
mailbox_command = /usr/lib/dovecot/deliver -c /etc/dovecot/dovecot.conf -m "${EXTENSION}"
mailbox_size_limit = 0
mydestination = polynet.me, vps31465.vps.ovh.ca, localhost.vps.ovh.ca, localhost
myhostname = vps31465.vps.ovh.ca
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
myorigin = /etc/mailname
readme_directory = no
recipient_delimiter = +
relayhost =
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
smtp_use_tls = yes
smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
smtpd_recipient_restrictions = reject_unknown_sender_domain, reject_unknown_recipient_domain, reject_unauth_pipelining, permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_authenticated_header = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_path = private/dovecot-auth
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_sender_restrictions = reject_unknown_sender_domain
smtpd_tls_auth_only = yes
smtpd_tls_cert_file = /etc/dovecot/dovecot.pem
smtpd_tls_key_file = /etc/dovecot/private/dovecot.pem
smtpd_tls_mandatory_ciphers = medium
smtpd_tls_mandatory_protocols = SSLv3, TLSv1
smtpd_tls_received_header = yes
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtpd_use_tls = yes
tls_random_source = dev:/dev/urandom
Run Code Online (Sandbox Code Playgroud)
我的输出来自 doveconf -n
root@vps31465:~# doveconf -n
# 2.2.9: /etc/dovecot/dovecot.conf
# OS: Linux 2.6.32-042stab093.5 x86_64 Ubuntu 14.04.1 LTS
mail_location = mbox:~/mail:INBOX=/var/mail/%u
managesieve_notify_capability = mailto
managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave
namespace inbox {
inbox = yes
location =
mailbox Drafts {
special_use = \Drafts
}
mailbox Junk {
special_use = \Junk
}
mailbox Sent {
special_use = \Sent
}
mailbox "Sent Messages" {
special_use = \Sent
}
mailbox Trash {
special_use = \Trash
}
prefix =
}
passdb {
driver = pam
}
plugin {
sieve = ~/.dovecot.sieve
sieve_dir = ~/sieve
}
protocols = " imap lmtp sieve pop3"
ssl_cert = </etc/dovecot/dovecot.pem
ssl_key = </etc/dovecot/private/dovecot.pem
userdb {
driver = passwd
}
Run Code Online (Sandbox Code Playgroud)
域是mail.polynet.me。
我不知道我哪里出错了。
非常感谢帮助:)
好的,首先看起来您的传入邮件交易遇到了 SASL 身份验证问题。
Oct 26 12:40:11 vps31465 postfix/smtpd[13551]: warning: SASL: Connect to private/dovecot-auth failed: No such file or directory
Run Code Online (Sandbox Code Playgroud)
这条路径看起来来自这里,我假设是postconf
输出(与您描述如何获得它的方式相反):
smtpd_sasl_path = private/dovecot-auth
Run Code Online (Sandbox Code Playgroud)
这是一个套接字的路径,它是相对于 $queue_directory 的。我不确定为什么这不在您的(假设的)postconf 输出中。在我的系统上它是 /var/spool/postfix。
因此,请检查该路径是否存在(可能不存在)
你的doveconf -n
输出实际上看起来像是你 postconf 输出的重复,所以我只能做这么多。在我的系统上,我有一个像这样的节:
service auth {
unix_listener /var/spool/postfix/private/auth {
group = postfix
mode = 0660
user = postfix
}
}
Run Code Online (Sandbox Code Playgroud)
它创建了 postfix 与之通信以发送电子邮件的套接字。您已将套接字文件命名dovecot-auth
为auth
,这似乎很合理。我猜你在为 postfix 配置那个套接字时有问题。
请修复您问题中的配置列表,否则我可能不得不投反对票。
编辑:我查看了您一直在使用的链接。它指的是带有 dovecot 设置说明的要点,我认为您已经完全错过了。
归档时间: |
|
查看次数: |
780 次 |
最近记录: |