Use slaveOk read in mongodump to allow dumping of secondaries. SERVER-3854.

This commit is contained in:
Spencer T Brody
2011-09-23 16:30:45 -04:00
parent 7ce5d643a0
commit 99b2d74eb9
2 changed files with 32 additions and 1 deletions

View File

@@ -402,7 +402,7 @@ namespace mongo {
// findOne throws an AssertionException if it's not authenticated.
if (_coll.size() > 0) {
// BSONTools don't have a collection
conn().findOne(getNS(), Query("{}"));
conn().findOne(getNS(), Query("{}"), 0, QueryOption_SlaveOk);
}
return;
}