Terminology: Cluster, Replica, Instance, Server (Atlas)

Hi, I’m taking M001 course.

Faced some new terms: Cluster, Replica, Instance, Server in context of Atlas.

Lecture says, that instance is machine, that’s running Mongodb. There’s also servers, that are storing data. Replica set is few connected instances.

So my question is: Is instance same as server in this context (each server is running an instance)? Means, having available 3 servers I would have 3 instances running, which are basically (combined together) my replica set? If yes, that would mean, that cluster is basically the same configured replica set?

Hi @_N_A15,

Welcome to the MongoDB Community Forums,

Thanks for asking such a nice question. :+1:

I would simply say Mongodb instance is a single copy of the software running on a single server. It has a single configuration (ideally in a configuration file) that it uses to define where it keeps its files and what port it answers on when something tries to connect to it.

However you can have multiple instances on one server. In that case, they can share the same software package but they cannot share a port, they cannot share data files, and they don’t have the same configuration (which defines those things and others).

So the unique thing is the configuration, and from there, the instance runs as a unique process.

Replica set is a group of mongod instances that host the same data set, means 3 or (any odd numbered upto 50) instance (also called members) running on either same server or different servers.

repset

For more info read here

Whereas cluster just consists of multiple instances and in the context of MongoDB, “cluster” is the word usually used for either a replica set or a sharded cluster.

So, the conclusion is 3 instance means 3 process running on same or different server with separate configuration files is called a replica set. And by saying cluster we are referring to the same replica set.

Hope it clarifies your doubt.

In case of any further questions please feel free to reach out.

Thanks,
Kushagra

4 Likes

Thank you so much!

Just a small question. Is there any way to check how many servers (not instances) were created by Atlas (using free tier for learning, so not sure if this info is included somewhere in my charts/infographics)? I just want to see e.g. 1 server and 3 instances running on them or 3 servers with 3 instances, this would help me to better understand the concept

Hi @_N_A15,

On the free Atlas tier, it does not create servers, you share an existing large 3 node replica set with other people invisibly. It is 3 instances on 3 servers as it’s a proper replica set. Type rs.status() to see the different hostnames.

Hope it helps, In case of any further questions please feel free to reach out.

Thanks,
Kushagra

2 Likes

thank you very much! You helped a lot

2 Likes

Thanks for your appreciation @_N_A15.

We wish you Good luck with the rest of the course.

Regards,
Kushagra

1 Like

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.