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

Shell: mongo port=XXXXX connects to default port but misleads user with message

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor - P4
    • Resolution: Unresolved
    • Affects Version/s: 3.0.14, 3.2.10, 3.4.0-rc3
    • Fix Version/s: Backlog
    • Component/s: Shell
    • Labels:
      None
    • Operating System:
      ALL
    • Steps To Reproduce:
      Hide

      mongod --dbpath . --logpath mongod.log --fork
      mongo port=27018
      

      Show
      mongod --dbpath . --logpath mongod.log --fork mongo port=27018

      Description

      The mongo shell connects to the default port when the connection string is incorrect and it prints a misleading message to the user leading them to believe they have connected correctly.

      • v3.0.14

        mongo port=27018
        MongoDB shell version: 3.0.14
        connecting to: port=27018
        

      • v3.2.10

        mongo port=27018
        MongoDB shell version: 3.2.10
        connecting to: port=27018
        

      • v3.4.0-rc3

        mongo port=27018
        MongoDB shell version v3.4.0-rc3
        connecting to: mongodb://127.0.0.1:27017/port=27018
        

      The latest version is probably the least likely to be confusing but perhaps a failure to connect would be more educational to the user.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated: