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

adding tags on 2.4 config DB from 2.6 mongo shell is no-op

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 2.6.3, 2.7.3
    • Component/s: Sharding, Shell, Write Ops
    • None
    • ALL
    • Hide

      2.6 shell, 2.4 config DB/shards
      sh.addShardTag("shard0000","ZERO");
      /* no effect */
      db.getSiblingDB("config").shards.update(db.getSiblingDB("config").shards.update({_id:"shard0000"},{$addToSet:{"tags":"ZERO"}}
      ... )
      WriteResult({
      "writeError" :

      { "code" : undefined, "errmsg" : "no such cmd: update" }

      })

      Show
      2.6 shell, 2.4 config DB/shards sh.addShardTag("shard0000","ZERO"); /* no effect */ db.getSiblingDB("config").shards.update(db.getSiblingDB("config").shards.update({_id:"shard0000"},{$addToSet:{"tags":"ZERO"}} ... ) WriteResult({ "writeError" : { "code" : undefined, "errmsg" : "no such cmd: update" } })

      It seems that mongo shell helpers in 2.6 send updates as 2.6 update commands, but 2.4 config DB doesn't know what those are.

      This makes some sharding helpers like sh.addShardTag() silently fail.

            Assignee:
            Unassigned Unassigned
            Reporter:
            asya.kamsky@mongodb.com Asya Kamsky
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: