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

Storage FAQ has conflicting information about repairDatabase

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • Server_Docs_20231030
    • None
    • manual
    • None

    Description

      http://docs.mongodb.org/manual/faq/storage/#empty-records

      If you must reclaim disk space, you can use repairDatabase. This command rebuilds the database, de-fragmenting the associated storage in the process. This may release space to the operating system. repairDatabase requires up to 2 gigabytes of extra disk space to run. Do not use repairDatabase if you are critically low on disk space.

      Then immediately afterwards:

      repairDatabase requires enough free disk space to hold both the old and new database files while the repair is running. Be aware that repairDatabase will block all other operations and may take a long time to complete.

      Can we follow the wording on http://docs.mongodb.org/manual/reference/command/repairDatabase/

      repairDatabase requires free disk space equal to the size of your current data set plus 2 gigabytes. If the volume that holds dbpath lacks sufficient space, you can mount a separate volume and use that for the repair. When mounting a separate volume for repairDatabase you must run repairDatabase from the command line and use the --repairpath switch to specify the folder in which to store temporary repair files.

      Attachments

        Activity

          People

            kay.kim@mongodb.com Kay Kim (Inactive)
            joanna.cheng@mongodb.com Joanna Cheng
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              8 years, 36 weeks, 1 day ago