Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-15241

replSetReconfig command asserts when one of the members has a priority setting

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • None
    • 2.7.6
    • Replication, Shell
    • ALL
    • Hide

      var replSet = new ReplSetTest({ name: 'reconfig', nodes: 3 });
      replSet.startSet({nojournal: "" });
      replSet.initiate();
      var primary = replSet.getPrimary();
      var conf = primary.getDB("local").system.replset.findOne();
      conf.members[0].priority = 100;
      conf.version++;
      primary.adminCommand({replSetReconfig: conf});

      Show
      var replSet = new ReplSetTest({ name: 'reconfig', nodes: 3 }); replSet.startSet({nojournal: "" }); replSet.initiate(); var primary = replSet.getPrimary(); var conf = primary.getDB("local").system.replset.findOne(); conf.members[0].priority = 100; conf.version++; primary.adminCommand({replSetReconfig: conf});

    Description

      If the command replSetReconfig is invoked with a member that has a priority setting, the command throws an error:

      2014-09-12T13:12:10.609-0400 I QUERY Error: error doing query: failed
      at DBQuery._exec (src/mongo/shell/query.js:83:36)
      at DBQuery.hasNext (src/mongo/shell/query.js:114:10)
      at DBCollection.findOne (src/mongo/shell/collection.js:185:19)
      at DB.runCommand (src/mongo/shell/db.js:58:41)
      at Mongo.adminCommand (src/mongo/shell/mongo.js:52:34)
      at reconfigReplSet (/tmp/reconfig_wc.js:11:30)
      at addTagset (/tmp/reconfig_wc.js:35:5)
      at /tmp/reconfig_wc.js:227:1 at src/mongo/shell/collection.js:57

      Attachments

        Activity

          People

            milkie@mongodb.com Eric Milkie
            jonathan.abrahams Jonathan Abrahams
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: