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

Error message in rs.add() is confusing, should be just "Connection refused"

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Minor - P4 Minor - P4
    • None
    • 3.2.0-rc0
    • Replication
    • None
    • Replication

    Description

      319test:PRIMARY> rs.add("ip-172-31-42-223")
      {
      	"ok" : 0,
      	"errmsg" : "Quorum check failed because not enough voting nodes responded; required 2 but only the following 1 voting nodes responded: ip-172-31-42-224:27017; the following nodes did not respond affirmatively: ip-172-31-42-223:27017 failed with Connection refused",
      	"code" : 74
      }
      

      The above error is simple: mongod isn't running on the node I'm attempting to add. The error message about quorum check is confusing.

      Two things need fixing or at least checking:

      • If the relevant code path (didn't read) really does some kind of quorum check, that is superfluous. A pre-condition to adding a node should be that I can connect to it. Doing any quorum check only makes sense after that condition is satisfied.
      • The error message is confusing and irrelavant. It should just say "Connection refused".

      Attachments

        Activity

          People

            backlog-server-repl Backlog - Replication Team
            henrik.ingo@mongodb.com Henrik Ingo (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: