please explain what is node and primary node in mongodb? what are the differences between them.
Nodes are servers hosting a “mongod” instance containing your data.
The replication allows you to have several nodes : if one goes down, you can still access your data.
The primary node is a little bit different : in addition to containing your data, it receives all write operations.
You can read more here :
Hope having helped you !
In addition to @Geoffrey_91795.
In MongoDB, the concept of replication allows you to have multiple copies of the same data on different nodes/servers. This is to ensure redundancy and high availability of the data.
Primary node is also a data bearing node just like any other secondary node except it has some additional responsibility such as the primary node receives all write operations.
If you still have any query, please feel free to get back to us.
Curriculum Support Engineer