[CSHARP-1058] Force replSetReconfig in mongodb C# driver Created: 08/Sep/14 Updated: 05/Apr/19 Resolved: 04/Apr/15 |
|
| Status: | Closed |
| Project: | C# Driver |
| Component/s: | API, BSON, Configuration |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Blocker - P1 |
| Reporter: | Stephen Weaver | Assignee: | Unassigned |
| Resolution: | Done | Votes: | 0 |
| Labels: | c#, question | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
I've been on forums talking with several people for the last few days and no one has been able to give me an answer. Is there anyway to reconfigure a replica set in the event the primary as well as a majority of the servers are down? For example if data center 1 goes down, a procedure can be run to reconfigure and set a new primary with the remaining servers? I tried the eval method on the database object and I get this: )" I also tried this: }} var response = database.RunCommand(reconfigCommand); And RunCommand throws the following MongoCommandException Command 'replSetReconfig' failed: replSetReconfig command must be sent to the current replica set primary. (response: { "ok" : 0.0, "errmsg" : "replSetReconfig command must be sent to the current replica set primary." }) From what I can tell in the documentation, force = true should allow reconfig against a non-primary database. Any suggestions? |