Re: [Dovecot] deliver stopped working
Note to all: If you are running Dovecot on a system where any of the mailboxes are nfs v4 mounted from a RHEL (or derivative) server DO NOT upgrade that server to an unpatched 2.6.18-164 kernel, it is very broken at this time. Not only will Dovecot fail but you're likely to have a myriad of other problems. https://bugzilla.redhat.com/show_bug.cgi?id=523797 https://bugzilla.redhat.com/show_bug.cgi?id=524520 On Mon, 2009-10-05 at 10:30 -0400, vwc72...@voicenet.com wrote: So, it is reproducible. Now, if you take O_EXCL out it works even for the user: .. Why I suddenly get the behavior I don't know. Clearly its not deliver, but deliver tries to do something that behaves badly on this system. I've no idea. Never heard of O_EXCL failing in that way. You could always just remove the O_EXCL uses from Dovecot sources, Dovecot doesn't rely on them.
Re: [Dovecot] deliver stopped working
On Oct 4, 2009, at 1:58 AM, vwc72...@voicenet.com wrote: Its the O_EXCL in the open call! How can I make it not use O_EXCL? Thanks, -Ted- strace.out.6700:open(/home/vmail/mydomain.net/myaccount/tmp/ 1254635441.M259070P6700.myserver.mydomain.net, O_WRONLY|O_CREAT|O_EXCL|O_TRUNC|O_LARGEFILE, 0777) = -1 EACCES (Permission denied) I'd instead suggest changing SELinux policy to allow O_EXCL. Anyway, there is a setting for that (for now): dotlock_use_excl = no
[Dovecot] deliver stopped working
Hi: I have been using Dovecot for well over a year now and it has always worked with few problems. The mail setup is not simple... Postfix+MailScanner+ClamAV+Docvecot+MySql+postfix.admin... just to mention the major things. The system is CentOS 5.3 on VMware. The maildir is on an NFS share, index and control is local. About a month ago I thought I upgraded from 1.1.x to 1.2.x. by doing an rpmbuild and deploying. I say thought because today I determined the binaries were still 1.1x. Today a reboot was done after a kernel upgrade (2.6.18-128.x - 2.6.18-164). The mail system never came back up. My assumption is that the working binaries were in memory but the images on disk were changed. Anyway, the problem is with deliver writing to the mail dir. The error is: Oct 3 21:33:58 myserver dovecot: auth(default): master in: USER 1 myacco...@mydomain.net service=deliver Oct 3 21:33:58 myserver dovecot: auth(default): prefetch(myacco...@mydomain.net): passdb didn't return userdb entries, trying the next userdb Oct 3 21:33:58 myserver dovecot: auth-worker(default): sql(myacco...@mydomain.net): SELECT '/home/vmail/mydomain.net/myaccount' as home, 'maildir:/home/vmail/mydomain.net/myaccount:INDEX=/var/indexes/mydomain.net/myaccount:CONTROL=/var/indexes/mydomain.net/myaccount' as mail, 5000 AS uid, 5000 AS gid, concat('dirsize:storage=', quota) AS quota FROM mailbox WHERE username = 'myacco...@mydomain.net' AND active = '1' Oct 3 21:33:58 myserver dovecot: auth(default): master out: USER 1 myacco...@mydomain.net home=/home/vmail/mydomain.net/myaccount mail=maildir:/home/vmail/mydomain.net/myaccount:INDEX=/var/indexes/mydomain.net/myaccount:CONTROL=/var/indexes/mydomain.net/myaccount uid=5000gid=5000quota=dirsize:storage=0 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: home=/home/vmail/mydomain.net/myaccount Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: mail=maildir:/home/vmail/mydomain.net/myaccount:INDEX=/var/indexes/mydomain.net/myaccount:CONTROL=/var/indexes/mydomain.net/myaccount Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: uid=5000 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: gid=5000 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: quota=dirsize:storage=0 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): maildir: data=/home/vmail/mydomain.net/myaccount:INDEX=/var/indexes/mydomain.net/myaccount:CONTROL=/var/indexes/mydomain.net/myaccount Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): maildir++: root=/home/vmail/mydomain.net/myaccount, index=/var/indexes/mydomain.net/myaccount, control=/var/indexes/mydomain.net/myaccount, inbox=/home/vmail/mydomain.net/myaccount Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): Namespace : Using permissions from /home/vmail/mydomain.net/myaccount: mode=0770 gid=-1 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): open(/home/vmail/mydomain.net/myaccount/tmp/1254620038.M241510P27678.myserver.mydomain.net) failed: Permission denied Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): msgid=200910040116.n941gjtj001...@nm2srvp01.mydomain.net: save failed to INBOX: Internal error occurred. Refer to server log for more information. [2009-10-03 21:33:58] Oct 3 21:33:58 myserver postfix/pipe[27677]: 89A24914CB: to=myacco...@mydomain.net, orig_to=server@mydomain.net, relay=dovecot, delay=1033, delays=1032/0.16/0/0.31, dsn=4.3.0, status=deferred (temporary failure) The files are being created: (r...@myserver:/home/vmail/mydomain.net/myaccount/tmp)# ls -la total 156 drwxrwx--- 2 vmail vmail 4096 Oct 3 21:49 . drwxrwx--- 9 vmail vmail 4096 Oct 3 20:19 .. -- 1 vmail vmail0 Nov 30 1970 1254620038.M241510P27678.myserver.mydomain.net The user does have permission: (r...@myserver:/home/vmail/mydomain.net/myaccount/tmp)# su - vmail -bash-3.2$ pwd /home/vmail/mydomain.net/myaccount/tmp -bash-3.2$ ls -la total 160 drwxrwx--- 2 vmail vmail 4096 Oct 3 21:54 . drwxrwx--- 9 vmail vmail 4096 Oct 3 20:19 .. -- 1 vmail vmail0 Nov 30 1970 1254620038.M241510P27678.myserver.mydomain.net -bash-3.2$ rm 1254620038.M241510P27678.myserver.mydomain.net rm: remove write-protected regular empty file `1254620038.M241510P27678.myserver.mydomain.net'? y -bash-3.2$ echo this 1254620038.M241510P27678.myserver.mydomain.net -bash-3.2$ ls -la 1254620038.M241510P27678.myserver.mydomain.net -rw-r--r-- 1 vmail vmail 5 Oct 3 21:58 1254620038.M241510P27678.myserver.mydomain.net -bash-3.2$ cat 1254620038.M241510P27678.myserver.mydomain.net this -bash-3.2$ rm 1254620038.M241510P27678.myserver.mydomain.net -bash-3.2$ If you delete the directory it does get recreated. I upgraded to 1.2.5 but it did not help. There were a lot of errors in the audit.log,
Re: [Dovecot] deliver stopped working
Its the O_EXCL in the open call! How can I make it not use O_EXCL? Thanks, -Ted- strace.out.6700:open(/home/vmail/mydomain.net/myaccount/tmp/1254635441.M259070P6700.myserver.mydomain.net, O_WRONLY|O_CREAT|O_EXCL|O_TRUNC|O_LARGEFILE, 0777) = -1 EACCES (Permission denied) Hi: I have been using Dovecot for well over a year now and it has always worked with few problems. The mail setup is not simple... Postfix+MailScanner+ClamAV+Docvecot+MySql+postfix.admin... just to mention the major things. The system is CentOS 5.3 on VMware. The maildir is on an NFS share, index and control is local. About a month ago I thought I upgraded from 1.1.x to 1.2.x. by doing an rpmbuild and deploying. I say thought because today I determined the binaries were still 1.1x. Today a reboot was done after a kernel upgrade (2.6.18-128.x - 2.6.18-164). The mail system never came back up. My assumption is that the working binaries were in memory but the images on disk were changed. Anyway, the problem is with deliver writing to the mail dir. The error is: Oct 3 21:33:58 myserver dovecot: auth(default): master in: USER 1 myacco...@mydomain.net service=deliver Oct 3 21:33:58 myserver dovecot: auth(default): prefetch(myacco...@mydomain.net): passdb didn't return userdb entries, trying the next userdb Oct 3 21:33:58 myserver dovecot: auth-worker(default): sql(myacco...@mydomain.net): SELECT '/home/vmail/mydomain.net/myaccount' as home, 'maildir:/home/vmail/mydomain.net/myaccount:INDEX=/var/indexes/mydomain.net/myaccount:CONTROL=/var/indexes/mydomain.net/myaccount' as mail, 5000 AS uid, 5000 AS gid, concat('dirsize:storage=', quota) AS quota FROM mailbox WHERE username = 'myacco...@mydomain.net' AND active = '1' Oct 3 21:33:58 myserver dovecot: auth(default): master out: USER 1 myacco...@mydomain.net home=/home/vmail/mydomain.net/myaccount mail=maildir:/home/vmail/mydomain.net/myaccount:INDEX=/var/indexes/mydomain.net/myaccount:CONTROL=/var/indexes/mydomain.net/myaccount uid=5000gid=5000quota=dirsize:storage=0 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: home=/home/vmail/mydomain.net/myaccount Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: mail=maildir:/home/vmail/mydomain.net/myaccount:INDEX=/var/indexes/mydomain.net/myaccount:CONTROL=/var/indexes/mydomain.net/myaccount Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: uid=5000 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: gid=5000 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): auth input: quota=dirsize:storage=0 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): maildir: data=/home/vmail/mydomain.net/myaccount:INDEX=/var/indexes/mydomain.net/myaccount:CONTROL=/var/indexes/mydomain.net/myaccount Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): maildir++: root=/home/vmail/mydomain.net/myaccount, index=/var/indexes/mydomain.net/myaccount, control=/var/indexes/mydomain.net/myaccount, inbox=/home/vmail/mydomain.net/myaccount Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): Namespace : Using permissions from /home/vmail/mydomain.net/myaccount: mode=0770 gid=-1 Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): open(/home/vmail/mydomain.net/myaccount/tmp/1254620038.M241510P27678.myserver.mydomain.net) failed: Permission denied Oct 3 21:33:58 myserver dovecot: deliver(myacco...@mydomain.net): msgid=200910040116.n941gjtj001...@nm2srvp01.mydomain.net: save failed to INBOX: Internal error occurred. Refer to server log for more information. [2009-10-03 21:33:58] Oct 3 21:33:58 myserver postfix/pipe[27677]: 89A24914CB: to=myacco...@mydomain.net, orig_to=server@mydomain.net, relay=dovecot, delay=1033, delays=1032/0.16/0/0.31, dsn=4.3.0, status=deferred (temporary failure) The files are being created: (r...@myserver:/home/vmail/mydomain.net/myaccount/tmp)# ls -la total 156 drwxrwx--- 2 vmail vmail 4096 Oct 3 21:49 . drwxrwx--- 9 vmail vmail 4096 Oct 3 20:19 .. -- 1 vmail vmail0 Nov 30 1970 1254620038.M241510P27678.myserver.mydomain.net The user does have permission: (r...@myserver:/home/vmail/mydomain.net/myaccount/tmp)# su - vmail -bash-3.2$ pwd /home/vmail/mydomain.net/myaccount/tmp -bash-3.2$ ls -la total 160 drwxrwx--- 2 vmail vmail 4096 Oct 3 21:54 . drwxrwx--- 9 vmail vmail 4096 Oct 3 20:19 .. -- 1 vmail vmail0 Nov 30 1970 1254620038.M241510P27678.myserver.mydomain.net -bash-3.2$ rm 1254620038.M241510P27678.myserver.mydomain.net rm: remove write-protected regular empty file `1254620038.M241510P27678.myserver.mydomain.net'? y -bash-3.2$ echo this 1254620038.M241510P27678.myserver.mydomain.net -bash-3.2$ ls -la 1254620038.M241510P27678.myserver.mydomain.net -rw-r--r--