IMAP - IOERROR : Cannot allocate memory

me at chrisfleming.org me at chrisfleming.org
Sat Sep 17 23:33:30 CEST 2016


On 13/09/16 at 06:59pm, Andy Kopciuch wrote:
> Hi :
> 
> I have a client who contacted me with problems on their Kolab 3.4 server.
> It seems as though they can not create / rename folders any longer.
> 
> They sent me this snippet from the log :
> 
> <mail.log>
> Sep 13 10:52:24 mail imap[32214]: IOERROR: mapping /var/lib/imap/mailboxes.db.NEW file: Cannot allocate memory
> Sep 13 10:52:24 mail imap[32214]: Fatal error: failed to mmap /var/lib/imap/mailboxes.db.NEW file
> Sep 13 10:52:24 mail imap[32214]: twoskip: /var/lib/imap/mailboxes.db closed while still locked
> Sep 13 10:52:24 mail master[2168]: process type:SERVICE name:imap path:/usr/lib/cyrus-imapd/imapd age:56.459s pid:32214 exited, status 75
> </mail.log>

Having a look at the source code I think the code generating the error
is:



    *base = (char *)mmap((caddr_t)0, newlen, PROT_READ, flags, fd, 0L);
    if (*base == (char *)MAP_FAILED) {
        syslog(LOG_ERR, "IOERROR: mapping %s file%s%s: %m", name,
               mboxname ? " for " : "", mboxname ? mboxname : "");
        snprintf(buf, sizeof(buf), "failed to mmap %s file", name);
        fatal(buf, EC_IOERR);
    }


This means that the mmap system call is failing.  I would check actual free
memmory - On my server the imapd process never gets big. But I would start 
looking at overall memory use.

Cheers
Chris





> 
> 
> I have no idea what is going on here.  There is virtually no information I can find
> that directly relates to this.   This closest I found was this relating to logging region :
> 
> https://www.novell.com/support/kb/doc.php?id=3377220
> 
> This was relating ro dovecot, seemed like a parallell issue :
> http://www.dovecot.org/list/dovecot/2012-August/085148.html
> 
> This seemed relevant to mupdate, but with the same error message
> https://lists.andrew.cmu.edu/pipermail/info-cyrus/2005-September/019660.html
> 
> --
> 
> I did some experimenting, and even added a DB_CONFIG to /var/lib/imap/db, and set the
> cache size to 250MB ... that still did not fix the problem.
> 
> This looks like some kind of resource limit has been reached ... but which one?
> And how does it get increased.
> 
> Any help or advice on this?
> 
> 
> 
> Thanks,
> 
> 
> 
> Andy
> _______________________________________________
> users mailing list
> users at lists.kolab.org
> https://lists.kolab.org/mailman/listinfo/users


More information about the users mailing list