Showing posts from May, 2021

Change Shard Key and Migrate to Atlas Using MongoPush

Changing the shard key of a large data size collection is a time consuming task and painful experience in MongoDB.  For whom plan to migrate their clusters to Atlas, one would wish if changing the shard keys of collections was possible together with migrating data to Atlas.  MongoPush makes it possible in four simple steps.  For the MongoPush introduction, please see MongoPush - Push-Based MongoDB Atlas Migration Tool . Use Case The atlanta.vehicles collection is one of many collections in a 2-shard MongoDB cluster, and the shard key is {"year " : 1, "brand": 1} .  The collection data size has grown over 5TB.  The engineering team plans to migrate to Atlas with a new configuration of a 3-shard cluster.  However, with the existing shard key, they have experienced a "hot shard" problem when importing inventory data of new vehicles because the "year" field of the shard key.  The marketing department advises that car buying is a both practical and