Timo Sirainen wrote:
On 1.8.2012, at 22.32, Daniel Parthey wrote:
Jun 29 15:40:31 10.129.3.249 dovecot: doveadm(user31@domain1.example.org): Error: user user31@domain1.example.org: Error reading configuration: net_connect_unix(/var/run/dovecot/config) failed: Permission denied The change in 2.1.8 didn't fix it and still does not iterate *all* users. My current workaround is to list all users, run a for-loop over the userlist and flush one mailbox after another via the director.
Any hints how to solve this?
The error is still the same "config permission denied" shown above? I found that also from my server and added a debug patch, but it hasn't crashed yet. Could you try the attached patch and getting a gdb backtrace from the resulting core file? (Or at least the raw backtrace - getting a core file might be tricky.)
Running command on a four host setup with mailbox+director instance each: /usr/bin/doveadm -c /etc/dovecot-director/dovecot-director.conf -D purge -A
Output is: doveadm(username@example.org): Error: doveadm server failure doveadm: Error: Failed to iterate through some users
Log says: dovecot: doveadm(username@example.org): Error: userdb lookup: connect(/var/run/dovecot/auth-userdb) failed: Permission denied (euid=501(vmail) egid=123(vmail) missing +r perm: /var/run/dovecot/auth-userdb, we're not in group 122(dovecot), dir owned by 0:0 mode=0755) dovecot: doveadm(username@example.org): Error: purge: User lookup failed: Internal error occurred. Refer to server log for more information.
Here are the directory permissions:
mail01:~# id vmail uid=501(vmail) gid=123(vmail) groups=123(vmail)
mail01:~# id dovecot uid=120(dovecot) gid=122(dovecot) groups=122(dovecot)
mail01:~# ls -ld /var/run/dovecot drwxr-xr-x 4 root root 660 2012-07-11 18:35 /var/run/dovecot
mail01:~# ls -l /var/run/dovecot total 8 srw------- 1 root root 0 2012-07-10 18:29 anvil srw------- 1 root root 0 2012-07-10 18:29 anvil-auth-penalty srw------- 1 root root 0 2012-07-11 18:35 auth-client srw------- 1 dovecot root 0 2012-07-11 18:35 auth-login srw------- 1 root root 0 2012-07-11 18:35 auth-master srw-rw---- 1 dovecot dovecot 0 2012-07-11 18:35 auth-userdb srw------- 1 dovecot root 0 2012-07-11 18:35 auth-worker srw------- 1 root root 0 2012-07-11 18:35 config srw-rw---- 1 root vmail 0 2012-07-11 18:35 dict srw------- 1 root root 0 2012-07-11 18:35 director-admin srw------- 1 root root 0 2012-07-10 10:19 director-userdb srw-rw-rw- 1 root root 0 2012-07-11 18:35 dns-client srw------- 1 root root 0 2012-07-11 18:35 doveadm-server lrwxrwxrwx 1 root root 25 2012-07-10 18:29 dovecot.conf -> /etc/dovecot/dovecot.conf drwxr-xr-x 2 root root 40 2012-07-10 10:19 empty srw------- 1 root root 0 2012-07-11 18:35 imap-postlogin srw-rw-rw- 1 root root 0 2012-07-11 18:35 indexer srw------- 1 dovecot root 0 2012-07-11 18:35 indexer-worker srw------- 1 root root 0 2012-07-11 18:35 ipc srw-rw-rw- 1 root root 0 2012-07-11 18:35 lmtp srw------- 1 root root 0 2012-07-11 18:35 log-errors drwxr-x--- 2 root nogroup 180 2012-07-11 18:35 login -rw------- 1 root root 5 2012-07-10 18:29 master.pid -rw-r--r-- 1 root root 71 2012-07-10 18:29 mounts srw------- 1 root root 0 2012-07-11 18:35 pop3-postlogin srw------- 1 vmail root 0 2012-07-11 18:35 quota-warning srw------- 1 root root 0 2012-07-11 18:35 replication-notify prw------- 1 root root 0 2012-07-11 18:35 replication-notify-fifo srw------- 1 dovecot root 0 2012-07-11 18:35 replicator srw------- 1 root root 0 2012-07-11 18:35 stats prw------- 1 vmail root 0 2012-08-01 22:20 stats-mail
Please see mailbox and director config attached.
Any help is appreciated.