[SERVER-2264] make repairDatabase work on secondary, using maintenanceMode Created: 21/Dec/10  Updated: 19/Feb/15  Resolved: 19/Feb/15

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Eliot Horowitz (Inactive) Assignee: Matt Dannenberg
Resolution: Done Votes: 10
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by SERVER-11540 db.repairDatabase() doesn't work on S... Closed
Related
related to SERVER-3427 add maintainence mode for commands Closed
related to SERVER-7824 Have reIndex put a secondary into mai... Closed
is related to DOCS-3601 repairDatabase can be run on the seco... Closed
Sprint: RPL 0 3/13/15
Participants:

 Description   

Should go into maintenance mode while running. Should be able to run in SafeRepairDatabase mode where only validation and compaction are allowed.



 Comments   
Comment by Matt Dannenberg [ 19/Feb/15 ]

I can run repairDatabase against a secondary at HEAD of master right now. Citing this as evidence: https://github.com/mongodb/mongo/blob/ae341c89d09b634047dd080af0f9e173e6d8b6e5/src/mongo/db/dbcommands.cpp#L236

Comment by Kristina Chodorow (Inactive) [ 08/Nov/12 ]

The repair function predates the compact command. Data compaction happens to be a side-effect of repairing, but it is not related to the compact command. However, since Eliot made that comment, compact has been modified to work on secondaries.

Comment by Paul Gregoire [ 08/Nov/12 ]

I'm fairly certain that "compact" is part of what "repairDatabase" does; at least from what I've read.

Comment by Eliot Horowitz (Inactive) [ 14/Apr/11 ]

Should make sure compact also works on a secondary

Generated at Thu Feb 08 02:59:26 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.