Docs Menu

Connect to Your Federated Database Instance

On this page

  • Prerequisites
  • Connect Using the MongoDB Shell
  • Next Steps

Estimated completion time: 15 minutes

This part of the tutorial will walk you through connecting to your federated database instance using the MongoDB Shell, mongosh.

To complete this part of the tutorial, you will need to have completed the following:

Connecting to your federated database instance depends on whether you have the MongoDB shell, mongosh, installed:

Note

Only one user can authenticate on a connection to a federated database instance at any given time. If a user authenticates and then runs the db.auth() command, Data Federation replaces the previous user's permissions with the new user's permissions.

The connectionStatus command shows only the newly authenticated user in the authenticatedUsers output field.

Now that you're connected to your federated database instance, proceed to Verify Your Database and Collections.

Give Feedback
© 2022 MongoDB, Inc.

About

  • Careers
  • Investor Relations
  • Legal Notices
  • Privacy Notices
  • Security Information
  • Trust Center
© 2022 MongoDB, Inc.