REST API - PUT Storage Policy Copy

This operation updates a storage policy copy. To create a storage policy copy, see REST API - POST Storage Policy Copy.

Request

Syntax

  • XML

    PUT webservice/V2/StoragePolicy/storagePolicyId/Copy/copyId Host: host name Accept: application/xml Authtoken: authentication token Content-type: application/xml <UpdateStoragePolicyCopy.xml>
  • JSON

    PUT webservice/V2/StoragePolicy/storagePolicyId/Copy/copyId Host: host name Accept: application/xml Authtoken: authentication token Content-type: application/xml <UpdateStoragePolicyCopy.json>

where <webservice> is the root path that routes the API requests to the Web Server.

For more information, see Available Web Services for REST API.

Request Body

Name

Description

Required

storagePolicyId

The system generated ID assigned to the parent storage policy in which the copy must be created. To retrieve the storage policy ID, you can use the POST Storage Policy Copy API.

Yes

storagepolicy

The name of the storage policy.

Yes

copyId

The system-generated ID of the copy.

Yes

mediaagent

The name of the MediaAgent that is associated with the storage policy.

Yes

library

The name of the library that is associated with the storage policy.

Yes

drivepool

The name of the drive pool that is associated with the storage policy.

No

scratchpool

The name of the scratch pool that is associated with the storage policy.

No

incstoragepolicy

The name of the incremental storage policy that is associated with the storage policy.

No

deduppath

The path of the deduplication database.

No

wormCopy

To enable the WORM lock for the storage policy copy, set the value to 1. However, once enabled, you cannot disable WORM lock. To disable, you must contact Customer Support.

No

weekStartsOn

The starting day of the week for the financial calendar.

Valid values are:

  • 0 - Sunday
  • 1 - Monday
  • 2 - Tuesday
  • 3 - Wednesday
  • 4 - Thursday
  • 5 - Friday
  • 6 - Saturday

No

monthStartsOn

The starting day of the month for the financial calendar.

Valid values are: 1 to 31.

No

Request Headers

Name

Description

Host

The host name of the Web Server or the Web Console that is used in the API request.

Accept

The format of the response.

Valid values are: application/xml or application/json.

Authtoken

The authentication token that you receive after successfully logging on. For information about receiving an authentication token, see Authentication.

Response

Response Parameters

Parameter

Description

Element

errorCode

The possible error codes.

Valid values are:

  • 0, a successful completion.

  • 1, a failure.

  • a specific error code.

error

Examples

Sample Request

XML

PUT webservice/V2/StoragePolicy/1716/Copy/236 HTTP/1.1
 Host: client.mydomain.com
 Accept: application/xml
 Authtoken: QSDK 38568012f4d1e8ee1841d283a47aa3ba78e124ea58354b5fc60f4dab8a63347d05cf5552484dafda3bfa4c5db84e580b1cb37bcf8e65b39f7f8549a443e6f78a2c7be3f31b3d845e24776c835e498e8e883bb40c46bd15af4f40ca94e823acedcdd4e9659e74b34a07a85c4586cd2ed914b6dce015874783ef768fda78183a4208930954a377f66eb56c8b92cexampl4s437a19317ca6ce7f3233d5a01aca35dbad93468b833f2cf71010809006a937670adce711ca8be46638e8
<App_UpdateStoragePolicyCopyReq>
    <storagePolicyCopyInfo>
        <throttleNetworkBandWidthMBHR/>
        <StoragePolicyCopy>
            <copyName>Copy1</copyName>/>
            <storagePolicyName>SP1</storagePolicyName>
        </StoragePolicyCopy>
        <copyFlags>
            <wormCopy>2</wormCopy>
            <archiveCheckAll>2</archiveCheckAll>
            <archiveCheckFull>2</archiveCheckFull>
            <preserveEncryptionModeAsInSource>2</preserveEncryptionModeAsInSource>
            <auxCopyReencryptData>1</auxCopyReencryptData>
            <storePlainText>2</storePlainText>
            <encryptOnNetworkUsingSelectedCipher>2</encryptOnNetworkUsingSelectedCipher>
            <storeKeyOnMedia>2</storeKeyOnMedia>
        </copyFlags>
        <dataEncryption>
            <encryptData>1</encryptData>
            <encryptionType>TWOFISH</encryptionType>/>
            <encryptionKeyLength>128</encryptionKeyLength>/>
        </dataEncryption>
        <retentionRules>
            <financialCalendarXML>
                <weekStartsOn>0</weekStartsOn> 
                <monthStartsOn>1<monthStartsOn>
            </financialCalendarXML>
        </retentionRules>
    </storagePolicyCopyInfo>
</App_UpdateStoragePolicyCopyReq>

JSON

PUT webservice/V2/StoragePolicy/1716/Copy/236 HTTP/1.1
 Host: client.mydomain.com
 Accept: application/xml
 Authtoken: QSDK 38568012f4d1e8ee1841d283a47aa3ba78e124ea58354b5fc60f4dab8a63347d05cf5552484dafda3bfa4c5db84e580b1cb37bcf8e65b39f7f8549a443e6f78a2c7be3f31b3d845e24776c835e498e8e883bb40c46bd15af4f40ca94e823acedcdd4e9659e74b34a07a85c4586cd2ed914b6dce015874783ef768fda78183a4208930954a377f66eb56c8b92cexampl4s437a19317ca6ce7f3233d5a01aca35dbad93468b833f2cf71010809006a937670adce711ca8be46638e8
{"storagePolicyCopyInfo":{"copyType":1,"active":1,"isDefault":0,"isSnapCopy":0,"isMirrorCopy":0,"throttleNetworkBandWidthMBHR":0,"copyPrecedence":3,"spareMediaGroup":{"spareMediaGroupId":0,"spareMediaGroupName":""},"sourceCopy":{"copyId":236,"copyName":"Copy1"},"dedupeFlags":{},"storagePool":{"storagePoolName":"","storagePoolId":0},"retentionRules":{"retainBackupDataForCycles":4,"jobs":0,"retainArchiverDataForDays":-1,"retainBackupDataForDays":30,"retentionFlags":{"dirtyExtendedRetention":1,"enableDataAging":1}},"StoragePolicyCopy":{"copyId":236,"copyName":"Copy1", "storagePolicyName":"SP1"},"extendedFlags":{},"drivePool":{"drivePoolName":"DrivePool(AUTOV11MA)13728","drivePoolId":13728},"copyFlags":{"wormCopy":2,"roundRobbinDataPath":1,"auxCopyReencryptData":1,"storeKeyOnMedia":1,"autoAddDataPaths":1},"dataEncryption":{"encryptionKeyLength":128,"encryptData":1,"encryptionType":"twofish"},"library":{"libraryName":"new_auto","libraryId":13320},"startTime":{"time":-1},"mediaAgent":{"mediaAgentId":3,"mediaAgentName":"MA1"}}}

Sample Response

XML

<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<App_GenericArchiveGroupResp responseType="0">
    <error errorCode="0"/>
</App_GenericArchiveGroupResp>

JSON

<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<App_GenericArchiveGroupResp responseType="0">
    <error errorCode="0"/>
</App_GenericArchiveGroupResp>
×

Loading...