MongoDB Questions and Answers – Cluster Architectures

This set of MongoDB Multiple Choice Questions & Answers (MCQs) focuses on “Cluster Architectures”.

1. MongoDB allows administrators to direct the balancing policy using ______ aware sharding.
a) tag
b) replica
c) rack
d) all of the mentioned
View Answer

Answer: c
Explanation: Administrators create and associate tags with ranges of the shard key, and then assign those tags to the shards.

2. Point out the correct statement.
a) Use sharded clusters if your data set approaches or exceeds the storage capacity of a single MongoDB instance
b) Use sharded clusters if a single MongoDB instance can meet the demands of your write operations, and all other approaches have not reduced contention
c) Use sharded clusters if the size of your system’s active working set will soon exceed the capacity of your system’s minimum RAM
d) All of the mentioned
View Answer

Answer: a
Explanation: The balancer is a background process that manages chunk migrations.

3. Tags are the primary mechanism to control the behavior of the _______ and the distribution of chunks in a cluster.
a) Balancer
b) Collector
c) Compactor
d) All of the mentioned
View Answer

Answer: a
Explanation: Tag aware sharding serves to improve the locality of data for sharded clusters that span multiple data centers

4. How many background process runs behind balanced cluster?
a) 1
b) 2
c) 3
d) All of the mentioned
View Answer

Answer: b
Explanation: MongoDB ensures a balanced cluster using two background process: splitting and the balancer.

advertisement
advertisement

5. Point out the wrong statement.
a) To create splits, MongoDB does migrate any data or affect the shards
b) The addition of new data or the addition of new servers can result in data distribution imbalances within the cluster
c) The balancer can run from any of the query routers in a cluster
d) All of the mentioned
View Answer

Answer: a
Explanation: The balancer is a background process that manages chunk migrations.

6. _________ is a background process that keeps chunks from growing too large.
a) Splitting
b) Balancing
c) Chunking
d) All of the mentioned
View Answer

Answer: a
Explanation: When a chunk grows beyond a specified chunk size, MongoDB splits the chunk in half. Inserts and updates triggers splits.

Sanfoundry Certification Contest of the Month is Live. 100+ Subjects. Participate Now!

7. The shards manage _______ migrations as a background operation between an origin shard and a destination shard.
a) cluster
b) shard
c) chunk
d) all of the mentioned
View Answer

Answer: c
Explanation: During a chunk migration, the destination shard is sent all the current documents in the chunk from the origin shard.

8. For most deployments, the default value of chunk is _____ megabytes is ideal.
a) 16
b) 32
c) 64
d) 72
View Answer

Answer: c
Explanation: Chunk size is user configurable.

advertisement

9. The ______ instances are the routers for the cluster.
a) mongod
b) mongos
c) collection
d) all of the mentioned
View Answer

Answer: b
Explanation: Typically, deployments have one mongos instance on each application server.

10. A single sharded cluster must have exclusive use of its _______ servers.
a) local
b) global
c) config
d) none of the mentioned
View Answer

Answer: c
Explanation: If you have multiple sharded clusters, you will need to have a group of config servers for each cluster.

advertisement

Sanfoundry Global Education & Learning Series – MongoDB.

Here’s the list of Best Books in MongoDB.

If you find a mistake in question / option / answer, kindly take a screenshot and email to [email protected]

advertisement
advertisement
Subscribe to our Newsletters (Subject-wise). Participate in the Sanfoundry Certification contest to get free Certificate of Merit. Join our social networks below and stay updated with latest contests, videos, internships and jobs!

Youtube | Telegram | LinkedIn | Instagram | Facebook | Twitter | Pinterest
Manish Bhojasia - Founder & CTO at Sanfoundry
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He lives in Bangalore, and focuses on development of Linux Kernel, SAN Technologies, Advanced C, Data Structures & Alogrithms. Stay connected with him at LinkedIn.

Subscribe to his free Masterclasses at Youtube & discussions at Telegram SanfoundryClasses.