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

Drop collection, restart mongod, create index results in unnecessary creation of data files

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 1.3.0
    • Component/s: None
    • Labels:
      None
    • Environment:
      Linux 64 bit (Ubuntu)

      Reproduction steps:

      (using the default 'test' database)
      1. db.dropDatabase() – ensure no data files already present for 'test'
      2. db.test.ensureIndex(

      {j:1}

      )
      3. db.test.drop()
      4. ls -l mongo data dir and observe that test.0 and test.1 are present (and on subsequent iterations test.2, test.3 etc)
      5. restart mongod
      6. goto 2.

      Each iteration creates an additional test.X datafile even though no data is stored. Curiously without the restart of mongod the drop & ensureIndex behave as expected and no additional data files are created.

      I have observed this behaviour with 1.3 release and the 2010-01-13 1.3 nightly.

      1.2.1 appears to be ok, only .0 and .1 files are created.

            Assignee:
            aaron Aaron Staple
            Reporter:
            goosmurf Yun Huang Yong
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: