Question

MongoDB sharded incremental backup

  • 11 August 2023
  • 7 replies
  • 83 views

Userlevel 1
Badge +4

Hi Team,

I have configured MongoDB backup and successfully run Full backup. When I want to run incremental backup there is no option for incremental backup. Either through commandcenter or from commcell console.

Any idea why is that? Or I need to create another subclient for oplog backup?

Thanks and best regards,

Fauzi


7 replies

Userlevel 1
Badge +4

Hello @Fauzi Japri 

Thanks for your query.

To back up incremental changes, you must configure operation log backups, For more information, see Configuring a MongoDB Subclient to Back Up Operation Log Dumps.

https://documentation.commvault.com/2022e/expert/108343_configuring_mongodb_subclient_to_back_up_oplog_dumps.html

 

MongoDB Backup Operations
 
https://documentation.commvault.com/2022e/expert/99407_mongodb_backup_operations.html
 

Backup of Incremental Changes

The MongoDB operation logs are periodically dumped to local staging locations on secondary nodes. Based on threshold criteria such as the disk use percentage and the number of operation log dumps generated, the backup jobs are triggered on the staging locations to capture incremental changes. The default local staging location for operation logs is software_installation_path/iDataAgent/jobResults/subclient_id directory.

Userlevel 1
Badge +4

Hi Tanuj,

For steps 9b, how can I know the Job Interval pattern? Also for 9c? 

So I can only do schedule backup for incremental oplog? I cannot do as below on demand backup?

https://documentation.commvault.com/2022e/expert/161017_performing_incremental_backup_of_mongodb_cluster.html

regards,

Fauzi

Userlevel 1
Badge +4

Hello @Fauzi Japri 

For 9b -> 

The Back up on file activity every setting ensures that the software does not frequently run the job. The software does not check the database threshold settings during this interval. When this interval expires, the software checks to see whether the database qualifies for a backup, based on the log disk usage.

The Force a backup every setting ensures that the software backs up the logs even when the database threshold settings have not been met. For example, if the setting is set to 24 hours and the software has not run an automatic log backup in that time, the software starts a backup without checking the database options. When the interval expires, the software checks if the database or log files were backed up. The software checks the finish time and if it occurred during the Back up on file activity every interval.

===========

For 9c ->

Automatic backups of database log files use the data protection resources more efficiently because they only run backup jobs when there is enough data to back up. A non-automatic schedule runs the backup at the specified date and time, even if there is not enough data to back up.

===========
General Recommendations:

Take the following into consideration when plan your log backup schedule:

The number of transactions that the database generates

The disk size for the log file destination


The following best practices apply to all the agents:

Set a low Back up on file activity every interval. For example, set a minimum interval of 15 minutes.

Set a Force a backup every interval that is less then the time interval between running two backups.

Set the option to perform a back up when the log destination fills up to 50%-80%. The actual value depends on your storage size.

If you enable disk log caching for a schedule, an automatic schedule will not run.

==========

To run a job immediately follow below steps:

  1. From the CommCell Browser, go to Client Computers > client > Big Data Apps >instance.

  2. Right-click the subclient, and then click Backup.

    The Backup Options dialog box appears.

  3. In the Backup Type section, select Incremental.

  4. To include oplog dumps in the backup, select the Log check box.

  5. To include data dumps in the backup, select the Data check box.

  6. In the Job Initiation section, specify when to run the backup operation:

    • To run the job immediately, select Immediate.

 

 

 

Userlevel 1
Badge +4

Hi Tanuj,

Thanks for the explanation.

==========

To run a job immediately follow below steps:

  1. From the CommCell Browser, go to Client Computers > client > Big Data Apps >instance.

  2. Right-click the subclient, and then click Backup.

    The Backup Options dialog box appears.

  3. In the Backup Type section, select Incremental.

  4. To include oplog dumps in the backup, select the Log check box.

  5. To include data dumps in the backup, select the Data check box.

  6. In the Job Initiation section, specify when to run the backup operation:

    • To run the job immediately, select Immediate.

=================

Backup type Incremental doesn’t display in my backup option when I right-click the subclient (default). Refer below screenshot.

 

So does this mean I cannot do incremental backup since I don’t have that option? Even to schedule it?

regards,

Fauzi

Userlevel 1
Badge +4

Hello @Fauzi Japri 

Currently Incremental backup can be done through schedule policy only. Please verify if you have followed steps on following doc - Configuring a MongoDB Subclient to Back Up Oplog Dumps (commvault.com)

 

For Submitting on-demand incremental backups. We need to submit it through schedule policy by Right click on schedule policy and run immediately.

Performing an Incremental Backup for a MongoDB Cluster (commvault.com)

 

Please let me know if this helps.

Userlevel 1
Badge +4

Hi Tanuj,

I haven’t done the schedule steps since I’m currently doesn’t have access to the system. I’m actually implementing MongoDB backup for my customer, so need to wait once I have a visit to their office.

https://documentation.commvault.com/2022e/essential/161013_performing_incremental_backup_for_mongodb_cluster.html

Above steps is from Command Center, which I already try also doesn’t have the options for incremental backup.

Anyways, I will just let the customer knows that on-demand incremental backup can only be done from schedule policy.

Thanks and best regards,

Fauzi

 

Userlevel 1
Badge +4

Hi @Fauzi Japri 

Yes, on-demand incremental backup will only work via schedule policy. 

Once you perform steps to configure a MongoDB subclient to back up the Oplog dumps by using a schedule policy, it should then allow to run an immediate incremental backup.

 

Best Regards,

Tanuj Balani

Reply