Uploaded image for project: 'MongoDB Database Tools'
  1. MongoDB Database Tools
  2. TOOLS-385

mongodump --repair on sharded cluster should return a helpful error

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 2.8.0-rc1
    • Affects Version/s: 2.8.0-rc0
    • Component/s: mongodump
    • Labels:
      None
    • Completed

      Start a one shard cluster and run mongodump -repair. The error is that the repairCursor does not exist on mongos, but the error message says that -repair cannot be used on mongo version before 2.7.8.

      The repairCursor is not implemented for mongos (which is OK), but it should return a helpful error message saying so.

      dan:(git)mongo-tools[master]/$ ./bin/mongodump --repair -d test --port 30999
      2014-11-18T01:36:14.468-0500	writing repair of test.system.indexes to dump/test/system.indexes.bson
      ==> 2014-11-18T01:36:14.468-0500	error reading from db: no such cmd: repairCursor
      ==> 2014-11-18T01:36:14.468-0500	error: --repair flag cannot be used on mongodb versions before 2.7.8.
      

            Assignee:
            kyle.erf Kyle Erf
            Reporter:
            dan@mongodb.com Daniel Pasette (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: