logo
  • Home
  • About
  • Training
  • Programming
  • CS
  • IT
  • IS
  • ECE
  • EEE
  • EE
  • Civil
  • Mechanical
  • Chemical
  • Metallurgy
  • Instrumentation
  • Aeronautical
  • Aerospace
  • Biotechnology
  • Agriculture
  • MCA
  • BCA
  • Internship
  • Contact

MongoDB Multiple Choice Questions | MCQs | Quiz

MongoDB Interview Questions and Answers
Pratice MongoDB questions and answers for interviews, campus placements, online tests, aptitude tests, quizzes and competitive exams.

Get Started

•   MongoDB Basics
•   Big Data & MongoDB
•   NoSQL Databases
•   MongoDB Installation - 1
•   MongoDB Installation - 2
•   MongoDB Enterprise - 1
•   MongoDB Enterprise - 2
•   MongoDB Packages
•   MongoDB Getting Started-1
•   MongoDB Getting Started-2
•   Test Data Generation
•   CRUD Concepts
•   Read Operations - 1
•   Read Operations - 2
•   Write Operations - 1
•   Write Operations - 2
•   Analyze Query Performance
•   Data Modeling Basics
•   Data Modeling Concepts - 1
•   Data Modeling Concepts - 2
•   Data Model Patterns
•   Model Tree Structures
•   Model Data Operations
•   Model Monetary & Time
•   GridFS
•   BSON
•   ObjectId
•   MongoDB Documents - 1
•   MongoDB Documents - 2
•   MongoDB Administration
•   Operational Strategies
•   MongoDB Backup
•   MongoDB Monitoring
•   Database Configuration
•   MongoDB Maintenance
•   MongoDB Production
•   Data Management
•   Operational Segregation
•   Capped Collections
•   Data Collections
•   Optimization Strategies - 1
•   Optimization Strategies - 2
•   Optimization Strategies - 3
•   System Collections
•   Database Profiler
•   Exit Codes & Statuses
•   Authentication
•   Authorization
•   Collection Access Control
•   Network Security
•   MongoDB API Interfaces
•   Auditing
•   Kerberos Authentication
•   Security Checklist
•   Access Control
•   User & Role Management
•   Aggregation
•   Aggregation Pipeline
•   Map-Reduce
•   Aggregation Operations
•   Aggregation Mechanics
•   Pipeline Optimization
•   Pipeline Limits
•   Pipeline & Sharded
•   Map-Reduce & Sharded
•   Pipeline Operators - 1
•   Pipeline Operators - 2
•   SQL - Aggregation Mapping
•   Aggregation Commands
•   MongoDB Indexes
•   Index Types - 1
•   Index Types - 2
•   Index Types - 3
•   Index Properties
•   Index Management
•   Geospatial Index
•   Text Search
•   Indexing Strategies
•   Indexing Methods
•   MongoDB Replication
•   Replica Set Members
•   Replica Architectures
•   Replica Set High Availability
•   Read & Write Semantics
•   Master Slave Replication
•   Replication Processes - 1
•   Replication Processes - 2
•   Replication Maintenance
•   Troubleshooting
•   Member Configuration
•   Sharding Introduction
•   Sharding Concepts
•   Cluster Architectures
•   Sharded Cluster Behavior
•   Sharding Mechanics
•   Cluster Deployment
•   ↓ Sharded Cluster ↓
•   Maintenance
•   Troubleshooting
•   Data Management - 1
•   Data Management - 2

Best Reference Books

MongoDB Books
« Prev Page
Next Page »

MongoDB Questions and Answers – Exit Codes and Statuses

Posted on March 8, 2015 by Manish

This set of MongoDB Multiple Choice Questions & Answers (MCQs) focuses on “Exit Codes and Statuses”.

1. Which of the following code is used for successful exit of task ?
a) 0
b) 1
c) 2
d) 3
View Answer

Answer: a
Explanation: 0 is returned by MongoDB applications upon successful exit.

2. Point out the correct statement :
a) 2 is returned by mongod if there is a mismatch between hostnames specified on the command line and in the local.sources collection
b) When an index covers a query, MongoDB can both match the query conditions and return the results using only the index keys
c) Both 2 and 4 are returned by mongod if there is a mismatch between hostnames specified on the command line and in the local.sources collection
d) All of the mentioned
View Answer

Answer: a
Explanation: mongod may also return this status if oplog collection in the local database is not readable.

3. Instance exits cleanly is represented by ___ exit code
a) 4
b) 1
c) 2
d) 3
View Answer

Answer: a
Explanation: Restart mongod with the –upgrade option to upgrade the database to the version supported by this mongod instance.

4. Which of the follwing code is returned by mongod if a moveChunk operation fails to confirm a commit ?
a) 5
b) 6
c) 7
d) 3
View Answer

Answer: a
Explanation: Exit codes 6 and 7 does not exist.

5. Point out the correct statement :
a) Exit code 10 is for abnormal exit
b) 4 is returned when the version of the database is different from the version supported by the mongod (or mongod.exe) instance
c) The server socket is on port 27017 by default
d) None of the mentioned
View Answer

Answer: b
Explanation: Exit code 10 is not in use.

6. Which of the following code represents exit cleanly following a large clock skew (32768 milliseconds) event ?
a) 45
b) 20
c) 47
d) 100
View Answer

Answer: c
Explanation: 100 is returned by mongod when the process throws an uncaught exception.

7. 49 code is returned by mongod from _________ Service control Manager.
a) Linux
b) Windows
c) Ubuntu
d) All of the mentioned
View Answer

Answer: a
Explanation: Custom read preferences and write concerns evaluate tags sets in different ways.

8. Which of the following code is returned when a MongoDB application cannot open a file ?
a) 45
b) 20
c) 47
d) 100
View Answer

Answer: a
Explanation: 45 is returned when a MongoDB application cannot open a file or cannot obtain a lock on a file.

9. Identify the message returned by MongoDB applications for Windows due to failures installing ?
a) Message: ERROR: wsastartup failed
b) Message: NT Service Error
c) Message: wsastartup failed
d) None of the mentioned
View Answer

Answer: b
Explanation: 20 is returned by MongoDB applications for Windows due to failures installing, starting or removing the NT Service for the application

10. Which of the following document represents uncaught exception ?
a) 45
b) 49
c) 47
d) 100
View Answer

Answer: d
Explanation: 49 is returned by mongod.exe or mongos.exe on Windows when either receives a shutdown message from the Windows Service Control Manager.

Sanfoundry Global Education & Learning Series – MongoDB.

Here’s the list of Best Reference Books in MongoDB.

To practice all areas of MongoDB, Here is complete set of 1000+ Multiple Choice Questions and Answers.
« Prev Page - MongoDB Questions and Answers – Database Profiler
» Next Page - MongoDB Questions and Answers – Authentication
« MongoDB Questions and Answers – Database Profiler
MongoDB Questions and Answers – Authentication »

Deep Dive @ Sanfoundry:

  1. C# Programming Examples on Interfaces
  2. Oracle Database Questions and Answers
  3. Spring Questions and Answers
  4. SQL Server Questions and Answers
  5. 100+ Java Android Programming Examples
  6. MySQL Database Questions and Answers
  7. Cloud Computing Questions and Answers
  8. Recruitment Support Service – Employers
  9. MongoDB Questions and Answers
  10. MongoDB Questions and Answers – Kerberos Authentication
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He is Linux Kernel Developer and SAN Architect and is passionate about competency developments in these areas. He lives in Bangalore and delivers focused training sessions to IT professionals in Linux Kernel, Linux Debugging, Linux Device Drivers, Linux Networking, Linux Storage & Cluster Administration, Advanced C Programming, SAN Storage Technologies, SCSI Internals and Storage Protocols such as iSCSI & Fiber Channel. Stay connected with him below:
LinkedIn | Facebook | Twitter | Google+

Best Careers

Developer Tracks
SAN Developer
Linux Kernel Developer
Linux Driver Developer
Linux Network Developer

Live Training Photos
Mentoring
Software Productivity
GDB Assignment
Sanfoundry is No. 1 choice for Deep Hands-ON Trainings in SAN, Linux & C, Kernel Programming. Our Founder has trained employees of almost all Top Companies in India such as VMware, Citrix, Oracle, Motorola, Ericsson, Aricent, HP, Intuit, Microsoft, Cisco, SAP Labs, Siemens, Symantec, Redhat, Chelsio, Cavium, ST-Micro, Samsung, LG-Soft, Wipro, TCS, HCL, IBM, Accenture, HSBC, Mphasis, Tata-Elxsi, Tata VSNL, Mindtree, Cognizant and Startups.

Best Trainings

SAN I - Technology
SAN II - Admin
Linux Fundamentals
Advanced C Training
Linux-C Debugging
System Programming
Network Programming
Linux Threads
Kernel Programming
Kernel Debugging
Linux Device Drivers

Best Reference Books

Computer Science Books
Algorithm & Programming Books
Electronics Engineering Books
Electrical Engineering Books
Chemical Engineering Books
Civil Engineering Books
Mechanical Engineering Books
Industrial Engineering Books
Instrumentation Engg Books
Metallurgical Engineering Books
All Stream Best Books

Questions and Answers

1000 C Questions & Answers
1000 C++ Questions & Answers
1000 C# Questions & Answers
1000 Java Questions & Answers
1000 Linux Questions & Answers
1000 Python Questions
1000 PHP Questions & Answers
1000 Hadoop Questions
Cloud Computing Questions
Computer Science Questions
All Stream Questions & Answers

India Internships

Computer Science Internships
Instrumentation Internships
Electronics Internships
Electrical Internships
Mechanical Internships
Industrial Internships
Systems Internships
Chemical Internships
Civil Internships
IT Internships
All Stream Internships

About Sanfoundry

About Us
Copyright
TOS & Privacy
Jobs
Bangalore Training
Online Training
SAN Training
Developers Track
Mentoring Sessions
Contact Us
Sitemap
© 2011 Sanfoundry