You can use CreateSchedule to schedule an automatic snapshot of a volume at a defined interval.
This method has the following input parameters:
Name | Description | Type | Default value | Required |
---|---|---|---|---|
attributes | Use the frequencystring to indicate the frequency of the snapshot. Possible values:
|
JSON object | None | No |
hours | Number of hours between recurring snapshots or hour in GMT time that the snapshot will occur in Days of Week or Days of Month mode. Valid values are 0 through 23. | integer | None | No |
name | The name of the snapshot. If no name is entered, the date and time the group snapshot was taken is used. The maximum name length allowed is 244 characters. | string | None | No |
minutes | Number of minutes between recurring snapshots or the minute in GMT time that the snapshot will occur in Days of Week or Days of Month mode. Valid values are 5 through 59. | integer | None | No |
paused | Indicates if the schedule should be paused or not. Valid values:
|
boolean | None | No |
recurring | Indicates if the schedule will be recurring or not. Valid values are:
|
boolean | None | No |
scheduleName | Unique name for the schedule. The maximum schedule name length allowed is 244 characters. | string | None | Yes |
scheduleType | Indicates the type of schedule to create. Valid value is snapshot. | string | None | Yes |
scheduleInfo | An object of schedule information about how the snapshot should be created at each scheduled interval.
|
JSON object | None | Yes |
snapMirrorLabel | The label used by SnapMirror software to specify the snapshot retention policy on a SnapMirror endpoint. | string | None | No |
startingDate | Time after which the schedule will be run. If not set, the schedule starts immediately. Formatted in UTC time. | ISO 8601 date string | None | No |
monthdays | The days of the month that a snapshot will be made. Valid values are 1 through 31. | integer array | None | Yes (if scheduling for days of the month) |
weekdays | Day of the week the snapshot is to be created. Required values (if used):
|
JSON object array | None | Yes (if scheduling for days of the week) |
This method has the following return values:
Name | Description | Type |
---|---|---|
scheduleID | ID of the schedule created. | integer |
schedule | An object containing information about the newly created schedule. | schedule |
{ "method":"CreateSchedule", "params":{ "hours":0, "minutes":0, "paused":false, "recurring":false, "scheduleName":"MCAsnapshot1", "scheduleType":"snapshot", "attributes":{ "frequency":"Days Of Week" }, "scheduleInfo":{ "volumeID":"1", "name":"MCA1" }, "monthdays":[], "weekdays":[ { "day":0, "offset":1 }, { "day":3, "offset":1 } ], "startingDate":"2015-06-01T19:17:54Z" }, "id":1 } } }
{ "id": 1, "result": { "schedule": { "attributes": { "frequency": "Days Of Week" }, "hasError": false, "hours": 0, "lastRunStatus": "Success", "lastRunTimeStarted": null, "minutes": 0, "monthdays": [], "paused": false, "recurring": false, "runNextInterval": false, "scheduleID": 4, "scheduleInfo": { "name": "MCA1", "volumeID": "1" }, "scheduleName": "MCAsnapshot1", "scheduleType": "Snapshot", "startingDate": "2015-06-01T19:17:54Z", "toBeDeleted": false, "weekdays": [ { "day": 0, "offset": 1 }, { "day": 3, "offset": 1 } ] }, "scheduleID": 4 } }
{ "method":"CreateSchedule", "params":{ "hours":12, "minutes":15, "paused":false, "recurring":true, "scheduleName":"MCASnapshot1", "scheduleType":"snapshot", "attributes":{ "frequency":"Days Of Month" }, "scheduleInfo":{ "volumeID":"1" }, "weekdays":[ ], "monthdays":[ 1, 10, 15, 30 ], "startingDate":"2015-04-02T18:03:15Z" }, "id":1 }
{ "id": 1, "result": { "schedule": { "attributes": { "frequency": "Days Of Month" }, "hasError": false, "hours": 12, "lastRunStatus": "Success", "lastRunTimeStarted": null, "minutes": 15, "monthdays": [ 1, 10, 15, 30 ], "paused": false, "recurring": true, "runNextInterval": false, "scheduleID": 5, "scheduleInfo": { "volumeID": "1" }, "scheduleName": "MCASnapshot1", "scheduleType": "Snapshot", "startingDate": "2015-04-02T18:03:15Z", "toBeDeleted": false, "weekdays": [] }, "scheduleID": 5 } }
{ "method":"CreateSchedule", "params":{ "hours":14, "minutes":45, "paused":false, "recurring":true, "scheduleName":"MCASnapUser1", "scheduleType":"snapshot", "attributes":{ "frequency":"Days Of Month" }, "scheduleInfo":{ "volumes":[1,2] }, "weekdays":[], "monthdays":[2,3,4], "startingDate":"2015-04-02T20:38:23Z" }, "id":1 }
{ "id": 1, "result": { "schedule": { "attributes": { "frequency": "Days Of Month" }, "hasError": false, "hours": 14, "lastRunStatus": "Success", "lastRunTimeStarted": null, "minutes": 45, "monthdays": [ 2, 3, 4 ], "paused": false, "recurring": true, "runNextInterval": false, "scheduleID": 6, "scheduleInfo": { "volumes": [ 1, 2 ] }, "scheduleName": "MCASnapUser1", "scheduleType": "Snapshot", "startingDate": "2015-04-02T20:38:23Z", "toBeDeleted": false, "weekdays": [] }, "scheduleID": 6 } }
9.6