ModifyRCDiskAttribute

Updated at:

Modifies the attributes of a block storage device, such as the name, description, release behavior with the instance, automatic snapshot deletion behavior with the disk, automatic snapshot policy, and performance burst feature.

Operation description

You can modify the attributes of a block storage device, such as its name, description, and release behavior with the instance, by specifying the DiskId parameter.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

rds:ModifyRCDiskAttribute

update

*All Resource

*

None None

Request syntax

POST  HTTP/1.1

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

Yes

The region ID. You can call the DescribeRegions operation to query available regions.

cn-hangzhou

DiskId

string

Yes

The ID of the block storage device whose attributes you want to modify.

rcd-wz9c8isqly8637zw****

DiskName

string

No

The name of the disk. It must be 2 to 128 characters in length and can contain characters from the Unicode Letter category, including English letters, Chinese characters, and digits. It can also contain colons (:), underscores (_), periods (.), and hyphens (-).

testDisk

Description

string

No

The description of the block storage device. The description must be 2 to 256 characters in length and cannot start with http:// or https://.

test

DeleteWithInstance

boolean

No

Specifies whether to release the block storage device when the instance is released. Default value: null. A value of null indicates that the current value remains unchanged.

This parameter is not supported for cloud disks that have the multi-attach feature enabled.

An error is returned if you set the DeleteWithInstance parameter to false in the following scenarios:

  • The disk category is local disk (ephemeral).

  • The disk category is basic cloud disk (cloud) and the disk is not removable (Portable=false).

Warning If you set this parameter to false and the ECS instance to which the disk is attached is locked for security reasons (the OperationLocks parameter indicates "LockReason" : "security"), the disk is released along with the instance regardless of the DeleteWithInstance attribute when the instance is released.

false

BurstingEnabled

boolean

No

Specifies whether to enable the performance burst feature for a disk that supports this feature. Valid values:

  • true: enables the feature.

  • false: disables the feature.

Note An error is returned if you specify any value for a disk that does not support the performance burst feature.

false

Response elements

Element

Type

Description

Example

object

Schema of Response

RequestId

string

Id of the request

1E43AAE0-BEE8-43DA-860D-EAF2AA0724DC

Examples

Success response

JSON format

{
  "RequestId": "1E43AAE0-BEE8-43DA-860D-EAF2AA0724DC"
}

Error codes

HTTP status code

Error code

Error message

Description

400 InvalidRegionId.MalFormed The specified parameter RegionId is not valid. The specified RegionId is illegal.
400 InvalidDiskName.Malformed The specified disk name is wrongly formed. The disk name format is incorrect. It can be 2 to 128 characters in length and start with an English letter or a Chinese letter. It can contain digits, periods (.), underscores (_), or hyphens (-). Cannot start with http:// and https.
400 NoAttributeToModify No attribute to be modified in this request. No properties were modified.
400 IncompleteParamter Some fields can not be null in this request. Missing parameter in request.
400 MissingParameter.DiskIdOrDiskIds Specified parameter DiskId or DiskIds is missing. The specified parameter DiskId or DiskIds is missing.
400 BurstingEnabledForDiskCategoryUnsupported The specified disk category does not support bursting enabled. The specified disk type does not support enabling the performance burst feature.
400 BurstingEnabledForMultiAttachDiskUnsupported The multi attach disk does not support bursting enabled. Multi-mount disks do not support the performance burst feature.
400 BurstingEnabledForModifyingDiskUnsupported The modifying disk does not support bursting enabled. Disks in the transition configuration are not allowed to modify the burst property.
400 InvalidBurstingEnabled.DiskSizeTooSmall The disk size must be greater than 3 GiB to enable burst. Performance burst can only be enabled when the disk size exceeds 3GiB.
403 QuotaExceed.Snapshot The snapshot quota exceeds. The snapshot quota exceeds the limit. If you want to store new snapshots, delete the existing old snapshots without affecting your business.
403 DiskNotPortable The specified disk is not a portable disk. The specified disk is not an unmountable disk. A disk with a Portable of false cannot be unmounted.
403 IncorrectDiskStatus The operation is not supported in this status. The current disk does not support this operation. Please check whether the disk is in normal use and is in arrears.
403 UserNotInTheWhiteList The user is not in disk white list. You are not in the disk whitelist. Please add it to the whitelist and try again.
403 DeleteWithInstance.Conflict Multi attach disk cannot be set to DeleteWithInstance attribute. Cloud disks with the multi-mount feature enabled do not support setting DeleteWithInstance.
404 InvalidDiskId.NotFound The specified disk does not exist. The specified disk does not exist. Please check whether the disk ID is correct.
404 InvalidDescription.Malformed The specified description is wrongly formed. The specified resource description format is invalid. The length is 2 to 256 characters and cannot start with http:// and https.
404 InvalidInstanceId.NotFound Specified attached instance does not exist. The specified instance does not exist. Check whether the instance ID is correct.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.