O'Reilly logo

MongoDB High Availability by Afshin Mehrabani

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Learning about replication and oplog changes

Clients send write operations to the primary node, and it applies the operation and writes it to its oplog. The secondary members will copy and apply primary's oplog in order to duplicate the primary's dataset. This procedure happens in an asynchronous replication.

Clients can't send the write operation to secondary nodes, but they can send read operations to secondaries. By default, all clients send both read/write operations to the primary node. However, modifying the configurations can change this.

Understanding nodes' failover

In order to get information about each node's availability, nodes direct ping messages to each other to show their availability, as illustrated in the following diagram:

In some ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required