I've got a 5GB database I wish to compact and repair. Regrettably, I've an energetic application running on that database.
I am wondering if managing a
mongod --repair task with MongoDB 1.8 will block the rest of the write procedures around the database.
I'd rather not shutdown the whole application for hrs...
You might have a look at --journal key. It keeps binary log for last procedures and recovery might take a smaller amount time than repair.
repairDatabase is really a obstructing operation, meaning you will need to get it done throughout a scheduled maintenance window.
Alternately, if you work with a duplicate set, you can repair without any down-time if you take one member from the replica set, repairing it, re-adding it towards the replica set, and repeating until each one is fixed. See the note in yellow at the end of this section for more information and caveats.