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

Assertion failure _a != -1 db/pdfile.h 425

    • Type: Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 1.8.0-rc0
    • Component/s: None
    • Labels:
      None
    • ALL

      Running a count on a newly created index caused an assertion. mongod then complained the db was corrupt and to run a repair, which I did, which resolved the issue.

      pb1:PRIMARY> use postbacks
      switched to db postbacks
      db.createCollection("postbacks",

      {capped:true, size:2147483648}

      ) // 2GB

      { "ok" : 1 }

      pb1:PRIMARY> db.postbacks.ensureIndex(

      { '_id' : 1}

      ,

      {background: true}

      )
      pb1:PRIMARY> db.postbacks.ensureIndex(

      { 'p' : 1}

      ,

      {background: true}

      )
      pb1:PRIMARY> db.postbacks.stats()
      {
      "ns" : "postbacks.postbacks",
      "count" : 0,
      "size" : 0,
      "storageSize" : 2147483904,
      "numExtents" : 2,
      "nindexes" : 2,
      "lastExtentSize" : 1057040,
      "paddingFactor" : 1,
      "flags" : 1,
      "totalIndexSize" : 16384,
      "indexSizes" :

      { "_id_" : 8192, "p_1" : 8192 }

      ,
      "capped" : 1,
      "max" : 2147483647,
      "ok" : 1
      }
      pb1:PRIMARY> db.postbacks.count(

      {p: false}

      )
      0
      pb1:PRIMARY> db.postbacks.count(

      {p: false}

      )
      0
      pb1:PRIMARY> db.postbacks.count(

      {p: false}

      )
      0
      pb1:PRIMARY> db.postbacks.count()
      3944
      pb1:PRIMARY> db.postbacks.stats()
      {
      "ns" : "postbacks.postbacks",
      "count" : 4522,
      "size" : 186458896,
      "avgObjSize" : 41233.72313135781,
      "storageSize" : 2147483904,
      "numExtents" : 2,
      "nindexes" : 2,
      "lastExtentSize" : 1057040,
      "paddingFactor" : 1,
      "flags" : 1,
      "totalIndexSize" : 278528,
      "indexSizes" :

      { "_id_" : 270336, "p_1" : 8192 }

      ,
      "capped" : 1,
      "max" : 2147483647,
      "ok" : 1
      }
      pb1:PRIMARY> db.postbacks.dropIndexes()
      {
      "nIndexesWas" : 2,
      "msg" : "non-_id indexes dropped for collection",
      "ok" : 1
      }
      pb1:PRIMARY> db.postbacks.ensureIndex(

      { 'p' : 1}

      ,

      {background: true}

      )
      interrupted at shutdown
      pb1:PRIMARY> use sd
      switched to db sd
      Thu Mar 3 00:32:42 DBClientCursor::init call() failed
      > use postbacks
      switched to db postbacks
      Thu Mar 3 00:32:45 trying reconnect to 127.0.0.1
      Thu Mar 3 00:32:45 reconnect 127.0.0.1 ok
      pb1:PRIMARY> db.repairDatabase()

      { "ok" : 1 }

      pb1:PRIMARY> db.postbacks.stats()
      {
      "ns" : "postbacks.postbacks",
      "count" : 12955,
      "size" : 548969696,
      "avgObjSize" : 42375.1212659205,
      "storageSize" : 2147483904,
      "numExtents" : 2,
      "nindexes" : 0,
      "lastExtentSize" : 1057040,
      "paddingFactor" : 1,
      "flags" : 0,
      "totalIndexSize" : 0,
      "indexSizes" : {

      },
      "capped" : 1,
      "max" : 2147483647,
      "ok" : 1
      }
      pb1:PRIMARY> db.postbacks.ensureIndex(

      { '_id' : 1}

      ,

      {background: true}

      )
      pb1:PRIMARY> db.postbacks.ensureIndex(

      { 'p' : 1}

      ,

      {background: true}

      )
      pb1:PRIMARY> db.postbacks.stats()
      {
      "ns" : "postbacks.postbacks",
      "count" : 12955,
      "size" : 548969696,
      "avgObjSize" : 42375.1212659205,
      "storageSize" : 2147483904,
      "numExtents" : 2,
      "nindexes" : 2,
      "lastExtentSize" : 1057040,
      "paddingFactor" : 1,
      "flags" : 1,
      "totalIndexSize" : 876544,
      "indexSizes" :

      { "_id_" : 491520, "p_1" : 385024 }

      ,
      "capped" : 1,
      "max" : 2147483647,
      "ok" : 1
      }
      pb1:PRIMARY> db.postbacks.count(

      {p: false}

      )
      12955

            Assignee:
            eliot Eliot Horowitz (Inactive)
            Reporter:
            boxedice David Mytton
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: