ModifyRCDiskAttribute

Updated at:

Modifies disk attributes, such as the name, description, and whether to release the disk with its instance, delete its automatic snapshots upon deletion, enable an automatic snapshot policy, or enable performance bursting.

Operation description

This operation modifies disk attributes, such as the name, description, and whether the disk is released with its instance.

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 ID of the region. You can call the DescribeRegions operation to get the latest list of regions.

cn-hangzhou

DiskId

string

Yes

The ID of the disk to modify.

rcd-wz9c8isqly8637zw****

DiskName

string

No

The new name of the disk. The name must be 2 to 128 characters long. The name can contain letters (including English and Chinese), digits, colons (:), underscores (_), periods (.), and hyphens (-).

testDisk

Description

string

No

The new description of the disk. The description must be 2 to 256 characters long and cannot start with http:// or https://.

test

DeleteWithInstance

boolean

No

Specifies whether to release the disk when the instance is released. If you do not specify this parameter, the current setting remains.

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

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

The disk is an ephemeral disk (category: ephemeral).
The disk is a basic cloud disk (category: cloud) that cannot be detached (Portable=false).
Warning If you set DeleteWithInstance to false, the disk is still released with the instance if the ECS instance is security-locked. An instance is security-locked if its OperationLocks response contains "LockReason": "security". In this case, the DeleteWithInstance setting is ignored.

false

BurstingEnabled

boolean

No

Specifies whether to enable performance bursting. Valid values:

true: Enables performance bursting.
false: Disables performance bursting.
Note: An error is returned if you specify this parameter for a disk that does not support performance bursting.

false

Response elements

Element

Type

Description

Example

object

The response body.

RequestId

string

The request ID.

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.