Restoring a MongoDB Cluster to Its Current Location (In Place)

Updated

You can restore an entire MongoDB cluster to its current location (in place).

After the data is restored to all the servers in the source cluster, replica sets are initiated, and then all the secondary nodes are added to the corresponding replica set automatically.

Note: If authentication is disabled on the destination MongoDB server, the loopback IP (127.0.0.1/localhost) must be a part of the bind_ip list to automatically shut down the server. Otherwise, you will need to manually shut down the server.

Before You Begin

If you scheduled oplog dump backups, disable them.

Procedure

  1. From the navigation pane, go to Protect > Big data.

    The Apps page appears.

  2. In the row for the cluster, click the action button , and then click Restore.

    The Backup content page appears.

  3. Select the content that you want to restore, and then click Restore.

    The Restore dialog box appears.

    By default, the Automatic Restore check box is selected, to automatically shut down the MongoDB servers and clean up the data directories as part of the restore.

    If you are using OpsManager to manage a MongoDB cluster, the OpsManager services shut down automatically. After the restore is complete, the services automatically start again. On Unix clusters, by default, the systemctl commands are used to start and stop OpsManager. However, you can set the sOpsManagerServiceScript additional setting to override the systemctl commands.

    Note: If the Automatic Restore check box is cleared, then before you submit the restore, you must manually shut down the servers and clean up the dbPath. In addition, on Linux, if there are any symbolic links to dbPath or under dbPath, they must not be removed.

  4. On the In place tab, click Submit.

What to Do Next

  • For sharded clusters, start the mongo routing service (mongos) on the required nodes:

    mongos --config <path-to-config>
  • After the restore operation is complete, MongoDB server is started as a process using the config file that the Commvault software has created during the restore process. To start the MongoDB server using another config file or as a service, stop the MongoDB server after completing the restore operation, and restart the MongoDB server.