[Dovecot] Segfault problem when using TWO dovecot servers!

Adam M. Dunn adunn at hgsc.bcm.tmc.edu
Thu Mar 9 23:15:55 EET 2006


Forgive me if this gets submitted twice.  I had issues signing up for the
listserv but I think I'm strait now.



Hi all,
  I just started working with Dovecot and I'd like to use it for my
organization, but I've run into a little problem.  So far I love it and it
does what I need.  One thing we need is to be able to write to multiple
mailbox formats on a per user basis (mbox or Maildir), and it does just
that.  I want users to be able to choose their format, and I can let it
autodetect for me.  The way I do that is I have Maildrop filters check for
the presence of a ~Maildir, and if it finds that it writes to it, 
otherwise it writes to ~mbox.  Dovecot is the only IMAP server I've found
to read either or without hard coding one or the other in the config file.


The problem:
We also want failover.  Mail/home directories are NFS mounted.  I was
planning to setup two dovecot servers, and noticed that whenever one
server writes its temp files to the mail directory, if another server
tries to read it you get a segfault and the child process fails and dies.
So it basically looks like only one server can own the files, and it won't
share.  I considered trying to set the INDEX option on the mail boxes to
write local indexes, but if I try to specify something like:
default_mail_env = INDEX=/var/indexes/%d/%n, it doesn't work.  Sure I can
make it work by putting in a mailbox format before the INDEX, but then I
can't use the autodetect which I need.

Here's the syslog error:

kernel: imap[13689]: segfault at 00007fffffe38000 rip 00002aaaaad3823f rsp 00007fffffe351f0 error 4


Any solutions?  I really need this to work badly, or we may have to
rethink our entire mail strategy.  I'm also using the latest version
1.0beta3.  

I considered namespaces, but correct me if I'm wrong, you can't setup
two namespaces and have it pick the first mailbox format available like
the autodetect feature does.  I tried seting up namespaces for both mbox
and Maildir, but it just creates both.



Please help someone.  I need a solution to present to my boss, even if
that means we have to run one server until the bug is fixed in the next
version.



Thanks,
Adam




More information about the dovecot mailing list