"mmap failed with out of memory" on 64-bit host

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Critical - P2
    • None
    • Affects Version/s: 1.2.2, 1.2.3, 1.3.2, 1.3.4
    • Component/s: Stability
    • None
    • Environment:
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      I'm currently evaluating MongoDB for storing large datasets. After inserting a significant amount of data (perhaps 4GB based on the mongod process size?) inserts start failing with messages like the following:

      Tue Feb 16 10:41:18 insert test_database.archive2 exception userassert:can't map file memory 0ms
      mmap() failed for /home/msmits/mongo-data/test_database.7 len:2146435072 errno:12
      mmap failed with out of memory, if you're using 32-bits, then you probably need to upgrade to 64
      Tue Feb 16 10:41:18 test_database.archive2 Caught Assertion insert, continuing

      I was under the impression that this should only happen on 32-bit systems. At the point of failure there is still several GB of physical memory available.

      I am able to reproduce this problem with all the 64-bit builds on the downloads page (1.2.2, 1.2 latest, 1.3.2 and 1.3 latest).

      See the attachment for a sample Python client script that reproduces the problem. On my machine it takes approx 15 mins for the failure to occur.

            Assignee:
            Eliot Horowitz (Inactive)
            Reporter:
            Menno Smits
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: