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

running compact resets systemFlag to 0

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Minor - P4 Minor - P4
    • None
    • 2.6.3
    • Index Maintenance, Storage
    • None
    • ALL
    • Hide

      db.createCollection( "x2")
      db.x2.stats().systemFlags
      //db.runCommand({collMod:"x2",usePowerOf2Sizes:false})
      db.runCommand({compact:"x2"})
      db.x2.stats().systemFlags

      Show
      db.createCollection( "x2") db.x2.stats().systemFlags //db.runCommand({collMod:"x2",usePowerOf2Sizes:false}) db.runCommand({compact:"x2"}) db.x2.stats().systemFlags

    Description

      The symptom is that:
      When compact is run, the systemFlags bit is set to 0.

      I believe it is because in
      collection_compact.cpp

       Status status = _indexCatalog.dropAllIndexes( true );

      leads to
      index_catalog.cpp

                  _details->clearSystemFlag( NamespaceDetails::Flag_HaveIdIndex );

      But then it's never re-set for the rebuild of the _id index again.

      Attachments

        Activity

          People

            Unassigned Unassigned
            rohit.nijhawan@10gen.com rohit.nijhawan@10gen.com
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: