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

Mongo databases fileSize grows without bound, even though total dataSize doesn't change

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Critical - P2
    • Resolution: Duplicate
    • 2.2.1
    • None
    • None
    • None
    • Linux

    Description

      I have a mongod node which is using much more disk space than stored object space. On Wednesday, I --repair'd the database, which brought the storageSize down to ~dataSize, now storageSize is back to 44x the dataSize!

      In this case, dataSize is ~480Mb, storageSize is ~21Gb, and there are ~24Gb of database files.

      > db.stats()
      {
              "db" : "dbname",
              "collections" : 8,
              "objects" : 4729,
              "avgObjSize" : 101896.2233030239,
              "dataSize" : 481867240,
              "storageSize" : 21079039904,
              "numExtents" : 39,
              "indexes" : 11,
              "indexSize" : 1332688,
              "fileSize" : 25204097024,
              "nsSizeMB" : 16,
              "ok" : 1
      }

      I'll attach some python code that reproduces the problem.

      Attachments

        1. mongo_hammer.py
          2 kB
          James Blackburn
        2. mongo_hammer2.py
          1 kB
          James Blackburn

        Issue Links

          Activity

            People

              sam.helman@10gen.com sam.helman@10gen.com
              jblackburn James Blackburn
              Votes:
              3 Vote for this issue
              Watchers:
              15 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: