CentOS Dovecot Permission Denied

centoscentos6dovecotemail

I have a dovecot mail server setup with Virtualmin, and for some reason, out of the blue, yesterday, the mail server stopped working. I found that in the /var/log/maillog file, I have the following errors showing up when I try to connect to my server (ceres):

ceres dovecot: imap-login: Login: user=<some_username>, method=PLAIN, rip=176.250.217.87, lip=178.79.158.216, mpid=15552, TLS
ceres dovecot: imap(some_username): Error: opendir(/home/my_user_acc/email/max/Maildir/tmp) failed: Permission denied
ceres dovecot: imap(some_username): Error: open(/home/my_user_acc/email/max/Maildir/dovecot.index.log) failed: Permission denied (euid=504(some_username) egid=503(my_user_acc) missing +r perm: /home/my_user_acc/email/max/Maildir/dovecot.index.log, euid is not dir owner)
ceres dovecot: imap(some_username): Error: file_dotlock_create(/home/my_user_acc/email/max/Maildir/dovecot-uidlist) failed: Permission denied (euid=504(some_username) egid=503(my_user_acc) missing +w perm: /home/my_user_acc/email/max/Maildir, euid is not dir owner)
ceres dovecot: imap(some_username): Error: open(/home/my_user_acc/email/max/Maildir/dovecot-uidlist) failed: Permission denied
ceres dovecot: imap-login: Login: user=<some_username>, method=PLAIN, rip=176.250.217.87, lip=178.79.158.216, mpid=15554, TLS
ceres dovecot: imap(some_username): Connection closed bytes=16/392

I have tried setting the user group of the Maildir to some_username (not my actual username!), and that made no difference, and also, I chmod +rwx Maildir to try and fix the permission errors, but that did not work either. Please could you tell me how I can fix the error?

Here is my dovecot config file: https://gist.github.com/MaxKramer/4734734

Best Answer

You're probably missing +x permissions on some part of the path (+x on directories means permission to enter). There's a good reason real mailsystems don't store mail in /home :)

Related Topic