Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-3361

mongod crashes after starting with --master

    • Type: Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Priority: Icon: Critical - P2 Critical - P2
    • None
    • Affects Version/s: 1.8.2
    • Component/s: Replication
    • Environment:
      CentOS 5.5, 64-bit
    • Linux

      I've been running MongoDB fine for the past week or so. I shut it down and tried to restart it with the following:

      ./mongod --dbpath /etc/mongodb/data --fork --logpath /var/log/ mongodb.log --logappend --quiet --journal --bind_ip 127.0.0.1 – nohttpinterface

      However, the mongod process quickly disappeared and I had to restart without --master to get it running again. This is what I got in my log (my database has less than 500MB of data since I've just been doing testing with it, and the box it is on has 8GB of RAM):

      Fri Jul 1 21:15:09 [initandlisten] waiting for connections on port 27017
      Fri Jul 1 21:15:09 [initandlisten] master=true
      Fri Jul 1 21:15:09 BackgroundJob starting: snapshot
      Fri Jul 1 21:15:09 BackgroundJob starting: ClientCursorMonitor
      Fri Jul 1 21:15:09 [initandlisten] ******
      Fri Jul 1 21:15:09 [initandlisten] creating replication oplog of size: 20447MB...
      Fri Jul 1 21:15:09 [initandlisten] create collection local.oplog.$main

      { size: 21440500326.4, capped: true, autoIndexId: false }

      Fri Jul 1 21:15:09 [FileAllocator] allocating new datafile /etc/mongodb/data/local.ns, filling with zeroes...
      Fri Jul 1 21:15:09 [FileAllocator] done allocating datafile /etc/mongodb/data/local.ns, size: 16MB, took 0.032 secs
      Fri Jul 1 21:15:09 [FileAllocator] allocating new datafile /etc/mongodb/data/local.0, filling with zeroes...
      Fri Jul 1 21:15:09 [FileAllocator] done allocating datafile /etc/mongodb/data/local.0, size: 64MB, took 0.155 secs
      Fri Jul 1 21:15:09 [FileAllocator] allocating new datafile /etc/mongodb/data/local.1, filling with zeroes...
      Fri Jul 1 21:15:10 [FileAllocator] done allocating datafile /etc/mongodb/data/local.1, size: 128MB, took 0.293 secs
      Fri Jul 1 21:15:10 [FileAllocator] allocating new datafile /etc/mongodb/data/local.2, filling with zeroes...
      Fri Jul 1 21:15:17 [FileAllocator] done allocating datafile /etc/mongodb/data/local.2, size: 2047MB, took 7.342 secs
      Fri Jul 1 21:15:17 [FileAllocator] allocating new datafile /etc/mongodb/data/local.3, filling with zeroes...
      Fri Jul 1 21:15:24 [FileAllocator] done allocating datafile /etc/mongodb/data/local.3, size: 2047MB, took 7.239 secs
      Fri Jul 1 21:15:24 [FileAllocator] allocating new datafile /etc/mongodb/data/local.4, filling with zeroes...
      Fri Jul 1 21:15:31 [FileAllocator] done allocating datafile /etc/mongodb/data/local.4, size: 2047MB, took 6.981 secs
      Fri Jul 1 21:15:31 [FileAllocator] allocating new datafile /etc/mongodb/data/local.5, filling with zeroes...
      Fri Jul 1 21:15:38 [FileAllocator] done allocating datafile /etc/mongodb/data/local.5, size: 2047MB, took 5.9 secs
      Fri Jul 1 21:15:38 [initandlisten] ERROR: New namespace: local.oplog.$main
      New namespace: local.system.namespaces
      mmap private failed with out of memory. (64 bit build)
      Fri Jul 1 21:15:38 [initandlisten] Assertion: 13636:createPrivateMap failed (look in log for error)
      0x55f5aa 0x629030 0x62999c 0x7826aa 0x769d0b 0x76a02e 0x76a0d3 0x76a2a0 0x77c89a 0x77d553 0x717034 0x698d0f 0x8a70b6 0x8ad38c 0x8ada88 0x8b36bf 0x2b14ef4fe994 0x4e10c9
      ./mongod(_ZN5mongo11msgassertedEiPKc+0x12a) [0x55f5aa]
      ./mongod(_ZN5mongo8MongoMMF13finishOpeningEv+0x60) [0x629030]
      ./mongod(_ZN5mongo8MongoMMF6createESsRyb+0x6c) [0x62999c]
      ./mongod(_ZN5mongo13MongoDataFile4openEPKcib+0x13a) [0x7826aa]
      ./mongod(_ZN5mongo8Database7getFileEiib+0x17b) [0x769d0b]
      ./mongod(_ZN5mongo8Database8addAFileEib+0x2e) [0x76a02e]
      ./mongod(_ZN5mongo8Database12suitableFileEib+0x63) [0x76a0d3]
      ./mongod(_ZN5mongo8Database11allocExtentEPKcib+0x70) [0x76a2a0]
      ./mongod(_ZN5mongo13_userCreateNSEPKcRKNS_7BSONObjERSsPb+0x53a) [0x77c89a]
      ./mongod(_ZN5mongo12userCreateNSEPKcNS_7BSONObjERSsbPb+0x103) [0x77d553]
      ./mongod(_ZN5mongo11createOplogEv+0x624) [0x717034]
      ./mongod(_ZN5mongo16startReplicationEv+0x36f) [0x698d0f]
      ./mongod(_ZN5mongo6listenEi+0xb6) [0x8a70b6]
      ./mongod(_ZN5mongo14_initAndListenEiPKc+0x8dc) [0x8ad38c]
      ./mongod(_ZN5mongo13initAndListenEiPKc+0x18) [0x8ada88]
      ./mongod(main+0x5acf) [0x8b36bf]
      /lib64/libc.so.6(__libc_start_main+0xf4) [0x2b14ef4fe994]
      ./mongod(__gxx_personality_v0+0x3a1) [0x4e10c9]
      Fri Jul 1 21:15:38 [initandlisten] exception in initAndListen std::exception: createPrivateMap failed (look in log for error), terminating
      Fri Jul 1 21:15:38 dbexit:
      Fri Jul 1 21:15:38 [initandlisten] shutdown: going to close listening sockets...
      Fri Jul 1 21:15:38 [initandlisten] shutdown: going to flush diaglog...
      Fri Jul 1 21:15:38 [initandlisten] shutdown: going to close sockets...
      Fri Jul 1 21:15:38 [initandlisten] shutdown: waiting for fs preallocator...
      Fri Jul 1 21:15:38 [initandlisten] shutdown: lock for final commit...
      Fri Jul 1 21:15:38 [initandlisten] shutdown: final commit...
      Fri Jul 1 21:15:59 [initandlisten] shutdown: closing all files...
      Fri Jul 1 21:15:59 closeAllFiles() finished

            Assignee:
            mathias@mongodb.com Mathias Stearn
            Reporter:
            goldfire James Simpson
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: