Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-5347

mongostat options to connect to a replica set are incorrectly documented

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • 01112017-cleanup
    • None
    • tools
    • None

    Description

      http://docs.mongodb.org/manual/reference/program/mongostat/#cmdoption--host

      To connect to a replica set, specify the replSetName and a seed list of set members, as in the following:

      <replSetName>/<hostname1><:port>,<hostname2><:port>,<...>

      Except this doesn't work:

      $ mongostat --host replset/penguin:27018,penguin:27019,penguin:27017
                           	insert  query update delete getmore command flushes mapped  vsize    res faults  locked db idx miss %     qr|qw   ar|aw  netIn netOut  conn     set repl       time
              penguin:27017	    *0     *0     *0     *0       0     2|0       0   336m  3.12g    10m      0 local:0.0%          0       0|0     0|0   218b     3k     7 replset  PRI   16:41:18
              penguin:27019	    *0     *0     *0     *0       0     2|0       0   336m  3.11g    10m      0 local:0.0%          0       0|0     0|0   218b     3k     3 replset  SEC   16:41:18
      replset/penguin:27018	socket exception [CONNECT_ERROR] for replset/penguin:27018 (replset/penguin) failed
      2015-05-05T16:41:18.622+1000 warning: Failed to connect to replset/penguin:0, reason: errno:2 No such file or directory
      

      $ mongostat --host penguin:27018,penguin:27019,penguin:27017
       
                   	insert  query update delete getmore command flushes mapped  vsize    res faults  locked db idx miss %     qr|qw   ar|aw  netIn netOut  conn     set repl       time
      penguin:27017	    *0     *0     *0     *0       1     1|0       0   336m  3.12g     8m      0 local:0.0%          0       0|0     0|0   109b     3k     7 replset  PRI   16:48:27
      penguin:27018	    *0     *0     *0     *0       0     3|0       0   336m  3.11g     9m      0 local:0.0%          0       0|0     0|0   374b     3k     3 replset  SEC   16:48:27
      penguin:27019	    *0     *0     *0     *0       0     3|0       0   336m  3.11g     8m      0 local:0.0%          0       0|0     0|0   374b     3k     3 replset  SEC   16:48:27
      

      Attachments

        Activity

          People

            kay.kim@mongodb.com Kay Kim (Inactive)
            joanna.cheng@mongodb.com Joanna Cheng
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              8 years, 37 weeks, 2 days ago