MongoDB Questions and Answers Part-6

1. To install the latest stable version of MongoDB on SUSE, issue ______________
a) sudo zypper install mongodb-enterprise
b) sudo zypper update mongodb-enterprise
c) sudo zyp install mongodb-enterprise
d) None of the mentioned

Answer: a
Explanation: When you install the packages, you choose whether to install the current release or a previous one. This step provides the commands for both.

2. Point out the correct statement.
a) MongoDB can be installed on SUSE which is a Linux flavour
b) MongoDB Enterprise is available on select platforms and contains support for several features related to security and monitoring
c) A commercial edition of MongoDB that includes additional features
d) all of the mentioned

Answer: d
Explanation: MongoDB is a server process that runs on Linux, Windows and OS X.

3. The MongoDB instance stores its _________ files in /var/lib/mongo by default.
a) log
b) data
c) replica
d) all of the mentioned

Answer: b
Explanation: You can specify alternate log and data file directories in /etc/mongod.conf.

4. The MongoDB process listens on port _________ by default.
a) 27017
b) 27170
c) 27107
d) 26017

Answer: a
Explanation: Clients connect to the MongoDB process, optionally authenticate themselves if security is turned on, and perform a sequence of actions, such as inserts, queries and updates.

5. Point out the wrong statement.
a) If you change the user that runs the MongoDB process, you must modify the access control rights
b) The MongoDB instance stores its data files in /var/log/mongodb by default
c) MongoDB uses memory mapped files for data management for efficiency
d) None of the mentioned

Answer: b
Explanation: The MongoDB instance stores its data files in /var/lib/mongo and its log files in /var/log/mongodb by default.

6. Which of the following file is a MongoDB configuration file?
a) mongodb.conf
b) mongod.conf
c) mongodb.con
d) none of the mentioned

Answer: b
Explanation: The Enterprise packages include an example SNMP configuration file named mongod.conf.

7. User account running mongod has _______ permissions for the directory.
a) write only
b) read only
c) read and write
d) none of the mentioned

Answer: c
Explanation: To run MongoDB, run the mongod process at the system prompt.

8. ___________ allows you to scale your cluster linearly by adding more machines.
a) Vertical sharding
b) Autosharding
c) Horizontal sharding
d) all of the mentioned

Answer: b
Explanation: It is possible to increase capacity without any downtime, which is very important on the web when load can increase suddenly and bringing down the website for extended maintenance can cost your business large amounts of revenue.

9. MongoDB is installed unattended on Windows from the command line using ____________
a) msi.exe
b) msiexec.exe
c) exec.exe
d) none of the mentioned

Answer: b
Explanation: MongoDB requires a data directory to store all data. MongoDB’s default data directory path is \data\db.

10. Sometimes mongod.exe is visible on public networks without running in _________ Mode with the auth setting.
a) Permanent
b) Secure
c) Primary
d) Protected

Answer: b
Explanation: MongoDB is designed to be run in trusted environments, and the database does not enable “Secure Mode” by default.