diff options
Diffstat (limited to 'src/mongo/shell/shardingtest.js')
-rw-r--r-- | src/mongo/shell/shardingtest.js | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mongo/shell/shardingtest.js b/src/mongo/shell/shardingtest.js index 0116254e67b..78472d843d5 100644 --- a/src/mongo/shell/shardingtest.js +++ b/src/mongo/shell/shardingtest.js @@ -1354,6 +1354,7 @@ var ShardingTest = function(params) { } var rs = this._rs[i].test; + rs.awaitNodesAgreeOnPrimary(); rs.getPrimary().getDB("admin").foo.save({x: 1}); if (keyFile) { @@ -1422,6 +1423,7 @@ var ShardingTest = function(params) { this.configRS.initiateWithAnyNodeAsPrimary(config); // Wait for master to be elected before starting mongos + this.configRS.awaitNodesAgreeOnPrimary(); var csrsPrimary = this.configRS.getPrimary(); // If 'otherParams.mongosOptions.binVersion' is an array value, then we'll end up constructing a |