Hello! I'm sorry about this long email. I just want to describe below everything that I have tried, so you won't have to ask about it.
I'm a long time FreeBSD user, but I had to switch OS because I got problems with my main work tool tmux after upgrading to FreeBSD 10. OpenBSD tmux seems fine, but another very important tool (dovecot) is giving me problems in OpenBSD. I have pkg_added dovecot-2.2.10 and mutt-1.5.22p0v0-sidebar-compressed, and I have merged my few changes to the dovecot configuration into the OpenBSD dovecot files. I get this in /var/log/maillog when I start mutt: Sep 21 13:21:27 xxx dovecot: imap(yyy): Fatal: pool_system_realloc(4294967296): Out of memory Sep 21 13:21:30 xxx dovecot: imap(yyy): Fatal: master: service(imap): child 17371 returned error 83 (Out of memory (service imap { vsz_limit=4096 MB }, you may need to increase it) - set CORE_OUTOFMEM=1 environment to get core dump) And while mutt is trying to login, before dovecot reaches the memory limit, the server freezes up completely with load average above 8. I have entered this line in /etc/dovecot/dovecot.conf, and tried gradually increasing it from 256 M: default_vsz_limit = 4096 M I also entered this in /etc/login.conf, as the pkg-readmes file states: dovecot:\ :openfiles-cur=4096:\ :openfiles-max=4096:\ :tc=daemon: (As you can see I tried increasing those values as well.) I tried logging out and logging in, and then (as root) stopping and starting dovecot. My server has 1 GB RAM. My mail directory is 2.3 GB, with a little more than 10.000 files. But this doesn't matter, because dovecot seems to never reach those files. I even tried removing that whole directory tree and replacing it with an empty mail directory, but had the same memory problem. The only thing that helps is if I comment out this line in my .muttrc: set spoolfile="imap://localhost/INBOX" Then I can at least see all email in my mailbox in /var/mail. When the spoolfile line is active, or when I try to change to an imap mailbox in mutt, I get the memory error. I have never had this problem in FreeBSD, or in DragonFlyBSD which I also tried. I diffed the entire dovecot configuration between DragonFlyBSD and OpenBSD. These are the diffs that seem important: diff -r conf.d/10-mail.conf /etc/dovecot/conf.d/10-mail.conf 136,137c136,138 < # filesystems (NFS or clustered filesystem). < #mmap_disable = no --- > # filesystems (NFS or clustered filesystem) or for some operating systems > # which use a separate cache for mmap, such as OpenBSD. > mmap_disable = yes 285c289 < #mbox_write_locks = dotlock fcntl --- > mbox_write_locks = fcntl diff -r conf.d/20-imap.conf /etc/dovecot/conf.d/20-imap.conf 49c49 < #imap_client_workarounds = --- > imap_client_workarounds = delay-newmail tb-extra-mailbox-sep tb-lsub-flags I tried setting mmap_disable = no and commenting out imap_client_workarounds, but that didn't help. I also tried changing from fcntl to dotlock, but that didn't help either. I diffed /etc/mutt/Muttrc from Muttrc in DragonFlyBSD, but found no interesting changes. I tried starting dovecot with -F, but get no interesting output there. Any ideas about what I can try? I would prefer to keep using dovecot if possible, it has been very stable in FreeBSD. If I can't solve this dovecot problem I will consider alternatives, but I would really like to stay with my current mbox format. Not that I have anything against maildir, I would just like to avoid converting at this moment. I'm getting a bit desperate here. :) I have ruled out FreeBSD, DragonFlyBSD and NetBSD, and I won't go to Linux. So OpenBSD might be my last option. (Or I might have to split my server into DragonFly for email and OpenBSD for tmux, but that seems a bit silly.) Thanks! Peter