Ada*_*dam 5 email-server dovecot ubuntu-12.04
...这很难用标题来描述。此描述应突出问题。
10-master
....
service auth {
unix_listener auth-userdb {
mode = 0644
user = vmail
group = vmail
}
...
Run Code Online (Sandbox Code Playgroud)
编辑 - 附加配置信息(一些重叠)
service auth {
# auth_socket_path points to this userdb socket by default. It's typically
# used by dovecot-lda, doveadm, possibly imap process, etc. Its default
# permissions make it readable only by root, but you may need to relax these
# permissions. Users that have access to this socket are able to get a list
# of all usernames and get results of everyone's userdb lookups.
unix_listener auth-userdb {
mode = 0644
user = vmail
group = vmail
}
# Postfix smtp-auth
unix_listener /var/spool/postfix/private/auth {
mode = 0660
user = postfix
group = postfix
}
# Auth process is run as this user.
#user = $default_internal_user
user = dovecot
}
Run Code Online (Sandbox Code Playgroud)
身份验证-sql
userdb {
driver = static
args = uid=vmail gid=vmail home=/var/vmail/%d/%n allow_all_users=yes
}
Run Code Online (Sandbox Code Playgroud)
ls -la /var/run/dovecot/auth-userdb
srw-r--r-- 1 vmail vmail 0 Jun 20 13:04 /var/run/dovecot/auth-userdb
Run Code Online (Sandbox Code Playgroud)
后缀大师.cf
dovecot unix - n n - - pipe
flags=DRhu user=vmail:vmail argv=/usr/lib/dovecot/dovecot-lda -d ${recipient}
Run Code Online (Sandbox Code Playgroud)
我非常密切地遵循教程,只更改了一些小东西。我到达“测试邮件传递”并运行echo test | mail test@chefdovecot.com
邮件没有到达,因为find /var/vmail没有显示任何内容。
在服务器系统日志中存在以下错误:
postfix/pickup[16842]: 019023A06AB: uid=1000 from=<vagrant>
postfix/cleanup[19542]: 019023A06AB: message-id= <20130620140358.019023A06AB@mail-server-berkshelf>
postfix/qmgr[16843]: 019023A06AB: from=<vagrant@mail-server-berkshelf.localdomain>, size=382, nrcpt=1 (queue active)
dovecot: lda: Debug: Loading modules from directory: /usr/lib/dovecot/modules
dovecot: lda: Debug: Module loaded: /usr/lib/dovecot/modules/lib90_sieve_plugin.so
dovecot: lda: Error: userdb lookup: connect(/var/run/dovecot/auth-userdb) failed: Connection refused
dovecot: lda: Fatal: Internal error occurred. Refer to server log for more information.
postfix/pipe[19545]: 019023A06AB: to=<test@chefdovecot.com>, relay=dovecot, delay=1.2, delays=0.04/0.01/0/1.1, dsn=4.3.0, status=deferred (temporary failure)
Run Code Online (Sandbox Code Playgroud)
“连接被拒绝”错误应该是我攻击的错误,对吧?我在很多地方搜索过以了解这里发生的事情,但没有遇到任何有用的东西。
任何人都可以提供任何线索或见解吗?一个解决方案会很棒,但我很高兴接受一些新的想法来尝试。
连接拒绝错误确实是问题所在。unix 套接字上的连接被拒绝并不是非常直观,但它表明套接字上没有任何监听(通常,进程已死,或者作为地址给出的文件根本不是套接字)。这绝不应该是权限问题,除非 dovecot 由于权限原因无法打开套接字进行侦听。
尝试停止 dovecot 和 postfix,删除 处的套接字文件/var/run/dovecot/auth-userdb,然后再次启动 postfix 和 dovecot(确保用户 dovecot 正在以具有 权限的方式运行/var/run/dovecot)。通常这可以解决此类问题。
Netstat 还将显示 unix 域套接字。检查其输出(使用netstat -nvlap | less并搜索路径或 dovecot)以确保 dovecot 正在监听。