[Dovecot] assertion failed: (need_space == (uoff_t)-mails[idx].space)

David King dking at ketralnis.com
Sun Nov 12 07:15:46 UTC 2006


I'm running Dovecot dovecot-1.0.r13 on FreeBSD (FreeBSD 6.1-RELEASE- 
p10). Mail is stored in mbox format (dovecot.conf after the msg).

Procmail delivers mail to subfolders under ~/.mail, locking using  
dotfiles. One folder in particular for one user has an mbox file  
~/.mail/Cron.

Quite often, I'll see that procmail processes are stacking up because  
~/.mail/Cron.lock exists, and they (rightly) refuse to deliver to a  
locked mailbox. It seems that dovecot is creating these lock files  
and then dying. The .lock file's contents refer to a PID that, by the  
time I see the lockfile, doesn't exist.

It appears that dovecot is leaving behind the lock files, after  
exiting with a signal 6 (sometimes 11) and leaving behind messages  
in /var/log/maillog (and the end of this message).

In dovecot.conf I have mail_drop_priv_before_exec = no, but I can't  
find the core file that I would expect it to dump, so I can't give  
you a backtrace. Hopefully the assertion in /var/log/maillog is enough.

With ~/.mail/Cron perpetually locked, I'm not able to receive mail in  
this folder, and with any IMAP client that tries to access that  
folder having the IMAP server shut down, it keeps me from getting  
mail. Any ideas?

# tail /var/log/maillog
Nov 11 23:05:32 melchoir dovecot: imap-login: Login:  
user=<ketralnis>, method=PLAIN, rip=10.0.1.239, lip=10.0.0.1, TLS
Nov 11 23:05:32 melchoir dovecot: IMAP(ketralnis): Disconnected:  
Logged out
Nov 11 23:06:52 melchoir dovecot: IMAP(ketralnis): file mbox-sync- 
rewrite.c: line 405 (mbox_sync_read_and_move): assertion failed:  
(need_space == (uoff_t)-mails[idx].space)
Nov 11 23:06:52 melchoir dovecot: child 16929 (imap) killed with  
signal 6


Here is dovecot.conf:

# cat /usr/local/etc/dovecot.conf | sed -E 's/^(.*)#.*$/\1/' | grep - 
Ev '(^#|^[ 	]*$'
protocols = imap pop3 imaps pop3s
ssl_cert_file = /etc/ssl/mail-cert.pem
ssl_key_file = /etc/ssl/private/mail-key.pem
disable_plaintext_auth = no
login_user = dovecot
verbose_proctitle = yes
first_valid_gid = 0
mail_extra_groups = mail
default_mail_env = mbox:%h/.mail:INBOX=/var/mail/%u
mmap_disable = no
lock_method = fcntl
mbox_read_locks = dotlock
mbox_write_locks = dotlock fcntl
mail_drop_priv_before_exec = no
protocol imap {
   login_greeting_capability = yes
   imap_client_workarounds = delay-newmail outlook-idle netscape-eoh  
tb-extra-mailbox-sep
}
protocol pop3 {
   pop3_uidl_format = %08Xu%08Xv
   pop3_client_workarounds = outlook-no-nuls oe-ns-eoh
}
auth default {
   mechanisms = plain login
   passdb pam {
   }
   userdb passwd {
   }
   userdb prefetch {
   }
   user = root
}



More information about the dovecot mailing list