In recent years, MongoDB has emerged as a dominant force among NoSQL database technologies, revolutionizing data management with next-generation scalability, flexibility, and performance. Boasting rapid growth and increasing market share, MongoDB is positioned as a frontrunner for cloud-minded enterprises relying on massive data volumes. 

However as data becomes increasingly critical to business operations, the importance of robust data protection strategies (such as backup and recovery) cannot be understated. Rubrik's data protection architecture helps organizations leverage the power of MongoDB while applying effective backup and recovery mechanisms for MongoDB data—safeguarding critical information and ensuring uninterrupted business operations. 

Here’s how you use Rubrik to defend your MongoDB data.

Quick Look at Rubrik’s Data Protection for MongoDB

Rubrik Security Cloud (RSC) is a software-as-a-service (SaaS) platform that secures, monitors, and recovers your data wherever it lives: in the datacenter , the cloud, or SaaS applications. Rubrik offers many data protection and security solutions, such as enterprise data protection for your databases, VMs, physical machines, etc., with air-gapped, immutable, access-controlled backups. 

Rubrik’s native MongoDB protection is similar to the backup and recovery protection offered for VMware, Oracle, MS SQL, SAP HANA, IBM Db2, and other workloads, delivering the following benefits:

  • Automated Discovery: Rubrik automatically discovers MongoDB databases and collections during initial setup and continues to protect new objects post-SLA assignment.

  • Declarative SLA Policy Engine: Simplifies MongoDB protection by allowing users to configure backup frequency, retention, archiving, and replication through a single policy engine.

  • Native Protection Benefits: Semantic deduplication reduces storage costs, ensures faster recovery with consistent snapshots, and allows flexibility to recover data across different cluster topologies.

  • Point-in-Time Granularity: Enables granular collection-level point-in-time recovery by leveraging both data and log backups.

  • Unified Management and Reporting: Provides centralized management for MongoDB and other database protection across on-premises and cloud environments, with active monitoring and comprehensive SLA compliance reporting.

How to Activate Rubrik’s MongoDB Protection Architecture

Rubrik's protection architecture for MongoDB (sharded and replica set config) is comprised of three key components:

 

Protection Architecture


First, the Rubrik Backup Service (RBS) needs to be downloaded and installed on the Linux MongoDB source hosts using rpm or deb installation methods. This ensures a secure connection between the Rubrik Secure Vault and the Linux host. Rubrik will automatically flag any nodes that lack an RBS connection unless they are intentionally exempt from protection.

Next, administrators add the MongoDB sources to RSC. RSC automatically discovers underlying databases and collections using a two-step process: the control plane flow gathers metadata and uses this data to add the MongoDB source and explore the databases. 

After discovery, administrators can use the Rubrik Global SLA policy engine to create and assign SLA Policies from RSC. This automates protection frequency and retention for database or Oplog backups, managing the entire data life cycle. Rubrik utilizes the data path to store MongoDB data in its immutable file system and retrieve backups for recovery purposes. The data path uses the NFSv3 protocol to write directly to an immutable file system to store MongoDB backups and logs.

All internal and external communications between protected objects, Rubrik Secure Vault, your cloud accounts, and RSC are encrypted. Communication between the Rubrik Secure Vault Cluster and RSC via the control path is always encrypted using the TLS 1.2 protocol. Through the Thrift protocol, communication from the Rubrik Cluster to MongoDB nodes occurs over RBS.

Incremental Forever Backups for Maximum Efficiency

MongoDB provides a native backup solution for granular recovery and point-in-time recovery, but these APIs are not accessible to third parties. To overcome this challenge, Rubrik has developed an innovative approach to backing up MongoDB using the native client library interface to gather documents and Oplogs.

To ensure the creation of a consistent backup image, it is essential to start the Oplog backup before initiating the full backup in MongoDB. This process captures any changes made during the full backup, maintaining data integrity and consistency.

Rubrik adopts a "First Full, Forever Incremental" strategy for backing up MongoDB databases. This methodology involves executing an initial full backup followed by perpetual incremental backups, resulting in faster, more network-efficient, and storage-efficient snapshots of the databases.

 

Incremental Backup


Rubrik: Strong Defense for Your MongoDB Data

So, what happens if you experience a catastrophic outage to one or more of your MongoDB instances? Rubrik supports multiple recovery options. You can recover single or multiple databases, restoring all collections inside the database(s). Or, you can recover single or multiple collections inside a single database.

Rubrik also supports in-place recovery to return a production source database or collection to the original host and isolated recovery to clone your database or collection to auxiliary sources, offering a comprehensive range of options to meet different restoration needs.

If you are ready to protect your MongoDB data, getting started is easy! Check out our hands-on lab for MongoDB and learn how to take the first step.