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

Primary shard of existing databases

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • v1.3.7
    • None
    • manual
    • None

    Description

      http://docs.mongodb.org/manual/core/sharded-cluster-shards/

      When you deploy a new sharded cluster, the “first” shard becomes the primary shard for all existing databases before enabling sharding. Databases created subsequently may reside on any shard in the cluster.

      Let's say you have a server A with database foo (and lots of data), and servers B and C which do not have the database foo. You then set up a sharded cluster and addShards in this order: B, C, A. Once you enable sharding for foo, the primary is server A, even though it's not the first shard.

      I tested this on 2.4.8, happy to do more testing if needed.

      Attachments

        Activity

          People

            sam.kleinman Sam Kleinman (Inactive)
            joanna.cheng@mongodb.com Joanna Cheng
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              9 years, 33 weeks, 1 day ago