What is replication and the types with brief explanation
Hemantkairam1
0 views
17 slides
Aug 31, 2025
Slide 1 of 17
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
About This Presentation
About replication.
This is a topic of mongodb
Size: 269.32 KB
Language: en
Added: Aug 31, 2025
Slides: 17 pages
Slide Content
What is Replication in MongoDB? Data (Primary) Data(Secondary) Data(Secondary) Data(Secondary) Replica1 Replica2 Replica3 Replica-Set MongoDB replication is a mechanism that creates multiple copies of your data across different servers, enhancing data availability and fault tolerance
Availability Redundancy Disaster recovery Reporting. Backup Fault tolerance What is Replication in MongoDB? Why we need Replication?
Understanding Replication Architecture Oplog (Operation log) The primary records all changes to its data sets in its operation log. Secondaries replicate the primary's oplog and apply the operations to their data sets asynchronously.
Understanding Arbiter and Heartbeat Replica set members send heartbeats (pings) to each other every two seconds. If a heartbeat does not return within 10 seconds, the other members mark the delinquent member as inaccessible.
Understanding Arbiter and Heartbeat In some circumstances (such as you have a primary and a secondary but cost constraints prohibit adding another secondary), you may choose to add a mongod instance to a replica set as an arbiter . An arbiter participates in elections but does not hold data (i.e. does not provide data redundancy). An arbiter will always be an arbiter whereas a primary may step down and become a secondary and a secondary may become the primary during an election.
Understanding Arbiter and Heartbeat Primary Secondary Secondary
Understanding Arbiter and Heartbeat Primary Secondary Secondary Secondary
Election for Primary - Replica Set Elections
Voting And Non-voting Members in Replica Set
Priority – 1 State – Primary / Secondary / Recovering / Rollback / Arbiter Node is eligible for Voting if the below condition are met Voting And Non-voting Members in Replica Set
Primary Secondary Secondary Secondary Secondary Secondary Secondary Secondary Secondary Secondary Secondary Secondary 1 1 1 1 1 1 1 Voting And Non-voting Members in Replica Set
Configure Non-Voting Replica Set Member Non-voting members allow you to add additional members for read distribution beyond the maximum seven voting members Non-voting members must have priority of 0. Members with priority greater than 0 cannot have 0 votes. To configure a member as non-voting, set both its votes and priority values to 0 Voting And Non-voting Members in Replica Set
Voting And Non-voting Members in Replica Set
Oplog MongoDB achieves replication by the use of replica set . A replica set is a group of mongod instances that host the same data set. In a replica, one node is primary node that receives all write operations. All other instances, such as secondaries, apply operations from the primary so that they have the same data set. Replica set can have only one primary node. Primary Secondary1 Secondary2 3 Nodes ReplicaSet Primary Single Node ReplicaSet How Setup Single Node Replica Set in MongoDB?
How Setup Single Node Replica Set in MongoDB?
Oplog MongoDB achieves replication by the use of replica set . A replica set is a group of mongod instances that host the same data set. In a replica, one node is primary node that receives all write operations. All other instances, such as secondaries, apply operations from the primary so that they have the same data set. Replica set can have only one primary node. Primary Secondary1 Secondary2 3 Nodes ReplicaSet Primary Single Node ReplicaSet How Setup Single Node Replica Set in MongoDB?