[DOCS-11539] Update Backup Restore through the API Tutorial for OM versions 3.2 and 2.0 Created: 03/Apr/18  Updated: 29/Oct/23  Resolved: 11/Apr/18

Status: Closed
Project: Documentation
Component/s: Ops Manager
Affects Version/s: 3.2.13, 2.0-beta4
Fix Version/s: None

Type: Task Priority: Major - P3
Reporter: Robert Justice (Inactive) Assignee: Robert Justice (Inactive)
Resolution: Fixed Votes: 0
Labels: triage
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
Participants:
Days since reply: 5 years, 43 weeks, 2 days ago

 Description   

Fell out of DOCSP-1845. That ticket updated this tutorial to recommend using the automated restore method for versions 3.6 of OM and master of CM (no versioning of CM). This ticket will contain the fix described below, but only for OM 3.4 and 2.0.

This issue is present in the documentation for Ops Manager 3.6, 3.4 and 2.0 affecting all these versions.

*Issue*
The following documentation on Automate Backup Restoration through the API does not consider in step 2: Create a restore job for the snapshot that the maximum number of downloads for the snapshot will be limited to 1.
As a consequence of this, when the automationConfig gets updated in step 5 to be then pushed in step 6 the restore *won't work* as the maximum number of downloads will be reached.

Below you will find the example output obtained when executing the API call documented in step 2:

curl -i -u "username:apiKey" -H "Content-Type: application/json" --digest -X POST "http://<url>/api/public/v1.0/groups/<group_id>/clusters/<cluster_id>/restoreJobs" --data '
{
  "snapshotId": "<snapshot_id>"
}'

Results in:

...
results": [
        {
            "clusterId": "5a8585ec9f0df71e682ef3c5",
            "created": "2018-02-15T13:37:48Z",
            "delivery": {
                "expirationHours": 1,
                "maxDownloads": 1,
                "methodName": "HTTP",
                "statusName": "NOT_STARTED"
            },
            "encryptionEnabled": false,
            "groupId": "5a8582f09f0df71e682ef23c",
            "id": "5a858d2c9f0df71e682f084f",
            "links": [
                {
                    "href": "http://192.168.1.100:8080/api/public/v1.0/groups/5a8582f09f0df71e682ef23c/clusters/5a8585ec9f0df71e682ef3c5/restoreJobs/5a858d2c9f0df71e682f084f",
                    "rel": "self"
                }
            ],
            "pointInTime": false,
            "snapshotId": "5a8588279f0df71f993c6288",
            "statusName": "IN_PROGRESS",
            "timestamp": {
                "date": "2018-02-15T13:15:15Z",
                "increment": 1
            }
        }
    ]
...

*Proposed solution*
Change the current call in step 2 to the following:

curl -i -u "username:apiKey" -H "Content-Type: application/json" --digest -X POST "http://<url>/api/public/v1.0/groups/<group_id>/clusters/<cluster_id>/restoreJobs" --data '
{
  "delivery":{"maxDownloads":<number_of_replica_set_members>}
  "snapshotId": "<snapshot_id>"
}'

Where the value for delivery.maxDownloads should match the number of data bearing members of the destination Replica Set.



 Comments   
Comment by Githook User [ 16/Apr/18 ]

Author:

{'name': 'Robert Justice', 'email': 'robertjustice@Roberts-MacBook-Air-3.local'}

Message: Update tutorial for Backup Restoration + entity description. (DOCS-11539-B)
Branch: v3.4
https://github.com/10gen/mms-docs/commit/b06dccdadc44a7f14e48311f40dcd137d6f6f309

Generated at Thu Feb 08 08:03:03 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.