Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-9714

Clarify operation of compact command with WiredTiger

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • Server_Docs_20231030
    • None
    • Server
    • None

    Description

      The compact command doesn't free wasted space due to fragmentation under WiredTiger. I think this isn't clear from the documentation. Two suggested places to change:

      Rewrites and defragments all data and indexes in a collection. On WiredTiger databases, this command will release unneeded disk space to the operating system.

      Clarify that the "defragments" only applies to mmapv1, not to WT.

      On WiredTiger, compact will rewrite the collection and indexes to minimize disk space by releasing unused disk space to the system. This is useful if you have removed a large amount of data from the collection, and do not plan to replace it.

      Re-iterate that it may not reclaim unneeded disk space due to fragmentation.

      Attachments

        Activity

          People

            kevin.adistambha@mongodb.com Kevin Adistambha
            bruce.lucas@mongodb.com Bruce Lucas (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              6 years, 10 weeks, 3 days ago