View Full MongoDB C100DBA Exam Dumps and Practice Test Dumps
Question 201
Which MongoDB connection option controls the minimum connections kept in a pool?
- poolMinimum
- minimumPool
- connectionFloor
- minPoolSize
Correct Answer: 4
Explanation:
The minPoolSize connection option specifies the minimum number of connections that a MongoDB driver maintains in a connection pool. Keeping a baseline number of connections can help applications avoid repeatedly establishing connections during periods of renewed activity. The appropriate value depends on application concurrency, deployment architecture, and driver behavior. DBAs should avoid setting the minimum unnecessarily high because idle connections still consume resources on both client and server sides. Pool configuration should be evaluated together with maxPoolSize and actual workload patterns to maintain an appropriate balance between connection availability and resource consumption.
Question 202
Which connection option limits how long idle pooled connections may remain unused?
- maxIdleTimeMS
- idleConnectionLimit
- poolIdleTimeout
- connectionIdleMS
Correct Answer: 1
Explanation:
maxIdleTimeMS controls the maximum amount of time a connection can remain idle in a driver’s connection pool before it may be removed. This setting can help applications manage unused connections and reduce unnecessary resource consumption. It can be useful for workloads with changing traffic patterns, where maintaining a large number of permanently idle connections is undesirable. DBAs should select the value according to application behavior rather than simply minimizing it. Very aggressive idle connection cleanup can cause additional connection creation when traffic returns, so pool settings should be tested under realistic workloads.
Question 203
Which connection option specifies how long socket operations may wait before timing out?
- networkTimeoutMS
- socketTimeoutMS
- operationTimeoutMS
- ioTimeoutMS
Correct Answer: 2
Explanation:
socketTimeoutMS specifies the amount of time a MongoDB driver waits for socket activity before timing out an operation. It is different from connection establishment and server-selection timeout settings. A value that is too short may cause legitimate long-running operations to fail, while an excessively high value can delay detection of stalled network activity. DBAs should configure socket timeouts according to expected query duration, network characteristics, and application failure-handling requirements. Timeout settings should be reviewed as part of the complete driver configuration rather than adjusted independently without considering the workload.
Question 204
Which MongoDB connection option controls how long a connection attempt may take?
- connectionWaitMS
- connectTimeoutMS
- networkConnectLimit
- openTimeoutMS
Correct Answer: 2
Explanation:
connectTimeoutMS controls the amount of time a MongoDB driver waits while establishing a network connection to a server. It primarily concerns the connection-establishment phase rather than server selection or operations performed after the connection is established. Appropriate values depend on network latency, deployment topology, and availability requirements. If configured too aggressively, temporary network delays may produce unnecessary connection failures. If configured excessively high, applications may wait too long before detecting unreachable servers. DBAs should evaluate this option together with server-selection and socket timeout settings when tuning client connectivity.
Question 205
Which MongoDB option enables retryable reads in supported drivers?
- retryReads
- readRetryMode
- enableReadRetry
- automaticReads
Correct Answer: 1
Explanation:
The retryReads option enables retryable read behavior in supported MongoDB drivers. When enabled, eligible read operations may be retried after certain transient failures, improving resilience against temporary network or server conditions. Retryability does not mean every failed operation can safely be repeated, so drivers apply defined rules to supported operations and error conditions. DBAs should verify driver compatibility and understand the deployment topology before relying on automatic retries. Retry settings should also be considered alongside application-level error handling and server availability mechanisms.
Question 206
Which connection option identifies an application in MongoDB server monitoring?
- applicationName
- clientLabel
- appName
- programName
Correct Answer: 3
Explanation:
The appName connection option identifies the client application when connecting to MongoDB. The value can appear in server-side connection and monitoring information, helping administrators associate database activity with a particular application or service. This is especially useful in environments where many applications share the same MongoDB deployment. DBAs can use application identification to improve troubleshooting and operational visibility. A consistent naming convention is recommended so monitoring data remains understandable. The option does not itself control application behavior; it provides descriptive information about the connecting client.
Question 207
Which MongoDB connection setting controls how long a driver waits for a connection from its pool?
- poolWaitMS
- waitQueueTimeoutMS
- connectionQueueLimit
- poolAcquireTimeout
Correct Answer: 2
Explanation:
waitQueueTimeoutMS controls how long an operation can wait for an available connection from the driver’s connection pool. When the pool has reached its configured capacity, new operations may need to wait until a connection becomes available. An appropriate wait limit helps prevent requests from remaining blocked indefinitely during connection pressure. DBAs should examine this setting together with maxPoolSize, application concurrency, and server capacity. If many operations frequently reach the wait queue, simply increasing the timeout may conceal an underlying pool-sizing or workload problem rather than resolving it.
Question 208
Which MongoDB option enables automatic retry of supported write operations?
- writeRetry
- retryWrites
- automaticWrites
- writeRecovery
Correct Answer: 2
Explanation:
The retryWrites connection option enables retryable writes for supported MongoDB operations and deployment configurations. Retryable writes can help applications recover from certain transient network or server conditions without requiring application code to manually repeat the operation. MongoDB drivers apply retry rules to supported operations rather than indiscriminately repeating every write. DBAs should verify deployment compatibility and understand operation semantics before relying on this behavior. Retryable writes can improve resilience, but applications should still implement appropriate error handling for failures that cannot be retried automatically.
Question 209
Which MongoDB client option specifies a preferred compression algorithm?
- compressionMode
- compressors
- wireCompression
- compressionList
Correct Answer: 2
Explanation:
The compressors connection option specifies compression algorithms that a MongoDB client can use for network communication. Compression can reduce network bandwidth consumption, which may be useful when data transfer is a significant part of workload cost. However, compression also introduces CPU processing, so its effect depends on document sizes, network capacity, and server resources. DBAs should evaluate compression using representative workloads rather than assuming it always improves performance. Client and server support must also be compatible for the selected compression mechanism to be negotiated successfully.
Question 210
Which MongoDB driver option allows a client to connect directly to one specified server?
- directConnection
- singleServerMode
- targetServerOnly
- directServer
Correct Answer: 1
Explanation:
The directConnection option controls whether a MongoDB client connects directly to the specified host rather than discovering and selecting other members through normal topology discovery. This can be useful in particular administrative or specialized deployment scenarios. However, direct connections can change normal replica-set discovery and failover behavior. DBAs should therefore understand the topology before enabling the option in application configurations. It is especially important to distinguish direct connectivity from normal replica-set connection behavior, where drivers discover eligible servers and automatically react to topology changes.
Question 211
Which authentication mechanism is commonly used with Kerberos-integrated MongoDB deployments?
- SCRAM-SHA
- GSSAPI
- PLAIN-TLS
- DIGEST-MD5
Correct Answer: 2
Explanation:
GSSAPI is the MongoDB authentication mechanism commonly associated with Kerberos-based authentication. It allows MongoDB clients to authenticate using credentials managed through a Kerberos infrastructure rather than relying on locally stored username and password credentials in the same manner as SCRAM. Enterprise environments may use Kerberos to integrate database authentication with centralized identity services. DBAs configuring GSSAPI must ensure that MongoDB, client drivers, Kerberos services, principals, and system time are correctly configured. Troubleshooting often requires checking both MongoDB configuration and the surrounding authentication infrastructure.
Question 212
Which MongoDB authentication mechanism supports AWS IAM credentials?
- AWS-SCRAM
- GSSAPI-AWS
- MONGODB-AWS
- IAM-Mongo
Correct Answer: 3
Explanation:
MONGODB-AWS is the MongoDB authentication mechanism used for AWS IAM-based authentication in supported environments. It allows applications to authenticate using AWS identity credentials rather than traditional MongoDB username and password authentication. This can simplify identity management for workloads operating within AWS environments. DBAs should configure the required driver support, AWS credentials, and MongoDB deployment settings correctly. Credential handling should follow AWS security practices, with temporary credentials preferred where appropriate. Administrators should also verify driver and MongoDB version compatibility before deploying this authentication mechanism.
Question 213
Which MongoDB authentication mechanism is associated with LDAP or PLAIN authentication?
- LDAP-SCRAM
- PLAIN
- LDAP-MONGODB
- AUTH-PLAINER
Correct Answer: 2
Explanation:
The PLAIN authentication mechanism can be used with MongoDB deployments integrated with external identity systems such as LDAP, when configured and supported appropriately. In such configurations, authentication credentials are validated through the configured external authentication infrastructure. Because PLAIN transmits credentials in a form that relies on transport protection, TLS is important when this mechanism is used. DBAs should ensure that secure communication is enabled and that LDAP integration is correctly configured. External authentication also requires careful management of directory availability, user mappings, and authorization behavior.
Question 214
Which MongoDB command displays information about the authenticated client connection?
- connectionInfo
- db.connectionStatus()
- clientStatus()
- sessionDetails()
Correct Answer: 2
Explanation:
db.connectionStatus() returns information about the current connection’s authentication and authorization context. It can help administrators inspect the authenticated user, available roles, and related access information for the active session. This makes it useful when troubleshooting permission problems or verifying that a client authenticated against the expected database. DBAs should run the command using the same connection context whose privileges they want to inspect. The result reflects the current connection and should not be interpreted as a complete inventory of all users or roles configured across the deployment.
Question 215
Which MongoDB command creates a custom database role?
- db.createRole()
- db.addRole()
- db.defineRole()
- db.newRole()
Correct Answer: 1
Explanation:
db.createRole() creates a custom role with specified privileges and, optionally, inherited roles. Custom roles allow administrators to implement least-privilege access models tailored to application or operational requirements. A role can contain database actions that determine what authenticated users are allowed to perform. DBAs should avoid granting broader permissions than necessary and should review custom roles periodically as application requirements change. Role creation is part of MongoDB authorization management and should be performed with an administrative account that has sufficient privileges to define roles.
Question 216
Which MongoDB command grants additional roles to an existing user?
- db.addUserRole()
- db.grantRolesToUser()
- db.assignRole()
- db.attachRoles()
Correct Answer: 2
Explanation:
db.grantRolesToUser() adds one or more roles to an existing MongoDB user. Roles determine the actions and resources that the user can access, making role assignment a central part of authorization administration. DBAs should grant only the permissions required for the user’s operational responsibilities. Because roles can inherit other roles, administrators should examine inherited privileges before assigning additional access. Regular access reviews are useful for identifying unnecessary permissions and maintaining a least-privilege authorization model as applications and administrative responsibilities evolve.
Question 217
Which MongoDB command removes assigned roles from an existing user?
- db.revokeRolesFromUser()
- db.removeUserRoles()
- db.deleteRolesFromUser()
- db.detachUserRoles()
Correct Answer: 1
Explanation:
db.revokeRolesFromUser() removes specified roles from an existing MongoDB user. Revoking roles is useful when an administrator needs to reduce access after responsibilities change or when previously granted privileges are no longer required. DBAs should consider inherited permissions when evaluating the user’s effective access because removing one role may not eliminate permissions supplied through another role. Authorization changes should be documented and reviewed according to organizational procedures. Using narrowly defined roles and regularly auditing assignments can make access revocation more predictable and easier to manage.
Question 218
Which MongoDB command displays information about a specific user?
- db.userDetails()
- db.getUser()
- db.showUser()
- db.describeUser()
Correct Answer: 2
Explanation:
db.getUser() returns information about a specified MongoDB user, including relevant authentication and authorization details that the executing account is permitted to view. Administrators can use it to verify role assignments and review user configuration. This command is useful during authorization troubleshooting because it helps confirm whether expected roles are associated with an account. DBAs should remember that the command operates within a database security context, so the user lookup should specify the appropriate database when necessary. Access to user information itself is controlled by MongoDB authorization privileges.
Question 219
Which MongoDB command displays information about a defined role?
- db.showRole()
- db.getRole()
- db.roleInfo()
- db.describeRole()
Correct Answer: 2
Explanation:
db.getRole() retrieves information about a specified MongoDB role. The output can help administrators inspect role privileges and inherited roles when reviewing authorization configuration. This is particularly useful for custom roles because administrators need to understand both directly assigned actions and permissions inherited from other roles. DBAs should use role inspection when troubleshooting unexpected access or auditing privilege changes. Effective authorization can depend on role inheritance, so examining only the user’s directly assigned roles may not provide a complete picture of the permissions available to that user.
Question 220
Which MongoDB role grants broad administrative privileges across databases?
- readOnlyAnyDatabase
- dbAdmin
- clusterReader
- root
Correct Answer: 4
Explanation:
The built-in root role provides broad administrative privileges across a MongoDB deployment. Because it grants extensive capabilities, it should be assigned only to accounts that genuinely require comprehensive administrative access. For ordinary application or operational tasks, narrower built-in or custom roles are generally more appropriate. DBAs should follow least-privilege principles and avoid using root credentials for routine application workloads. Regular review of highly privileged accounts can help identify unnecessary access and reduce the potential impact of credential compromise or accidental administrative operations.