Sharding and Replication

DBMS 252 views Nov 14, 2025 1 min read

Sharding and Replication

Sharding partitions a dataset across multiple servers to scale horizontally. Replication copies data across nodes to improve availability and read scalability.

Sharding Strategies

  • Range-based: Based on key ranges
  • Hash-based: Hash partitioning evenly distributes keys
  • Directory-based: Central mapping of keys to shards

Replication Models

  • Master-Slave (Primary-Replica): One writable node, many read replicas
  • Multi-Master: Multiple writable nodes with conflict resolution
  • Asynchronous vs Synchronous Replication

Operational Concerns

  • Rebalancing shards as data grows
  • Handling cross-shard transactions
  • Monitoring replication lag
Some advanced sections are available for Registered Members
Share this Post
🚀 Want to Test Your Knowledge?

Take quizzes related to this topic and see where you stand!

Start Quiz Now
Back to Tutorials