Connecting to MongoDB

A MongoDB cluster may contain multiple databases — an input must be created for each database you’d like to replicate.

  1. How do you want to connect to Alooma? If it's via an SSH server, check out how to connect via SSH. Otherwise, you'll need to whitelist access to Alooma's IP addresses.

  2. In the Plumbing screen, click Add new input and select the MongoDB option.

  3. Define your MongoDB input source:

    • Name to be used in Alooma.

    • Hostname or IP address of the MongoDB server.

    • Port (default port is 27017).

    • [Optional] User name and password.

    • Name of the database to replicate.


      this is not the authentication database - to set a different authentication DB please set authSource in the connection string parameters under "Advanced Options".

    • [Optional] Connection parameters to be added as a suffix to the connection string, such as authSource=admin.

    • A list of collections to replicate (separated by spaces or commas). Leave this blank to replicate all collections.

    • Choose whether you'd like to dump and load an initial snapshot of your collections into your data destination. This option works best for small collections (under 100M documents). If you have larger collections, please contact

    • [Optional] You can connect to your MongoDB server via SSH.

    As you fill in the fields above, Alooma automatically builds the connection string for accessing your MongoDB database and displays it in the Your MongoDB connection string field.

  4. Click Finish and data starts streaming into Alooma. Alooma continuously queries the OpLog to replicate the latest database changes – inserts, updates, and deletes.

    Alooma creates an event type in the Mapper screen for each collection you chose to replicate.


    Incoming events are stored in Alooma’s Restream queue until you map their event types and restream.

In parallel to the above, contact Alooma support for guidance on how to load the initial state of your existing MongoDB data into your data destination.

If you'd like to connect to your MongoDB via SSL with server validation, just add ssl=true in the connection string parameters as described in the MongoDB connection string documentation.

Alooma maintains three tables in your data destination per each collection in MongoDB.

That's it, you're ready to replicate your MongoDB collections in Alooma!

Search results

    No results found