調用DeleteDisk釋放一塊按量付費數據盤。磁盤類型包括普通云盤、高效云盤、SSD云盤和ESSD云盤。
接口說明
調用該接口時,您需要注意:
- 您的磁盤手動快照會被保留。
- 您可以通過 ModifyDiskAttribute 設置是否保留或者同時釋放自動快照。建議您及時刪除不必要的快照,以保持足夠的快照額度完成周期性的自動快照策略。
- 釋放磁盤時,云盤的狀態必須為待掛載(Available)。
- 如果指定 ID 的磁盤不存在,請求將被忽略。
調試
您可以在OpenAPI Explorer中直接運行該接口,免去您計算簽名的困擾。運行成功后,OpenAPI Explorer可以自動生成SDK代碼示例。
授權信息
當前API暫無授權信息透出。
請求參數
名稱 | 類型 | 必填 | 描述 | 示例值 |
---|---|---|---|---|
DiskId | string | 是 | 需要釋放的云盤設備 ID。 | d-bp14k9cxvr5uzy5**** |
返回參數
示例
正常返回示例
JSON
格式
{
"RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E"
}
錯誤碼
HTTP status code | 錯誤碼 | 錯誤信息 | 描述 |
---|---|---|---|
400 | InvalidRegionId.MalFormed | The specified parameter RegionId is not valid. | 指定的 RegionId 不合法。 |
403 | IncorrectDiskStatus | The current disk status does not support this operation. | 當前的磁盤不支持此操作,請您確認磁盤處于正常使用狀態,是否欠費。 |
403 | DiskNotPortable | The specified disk is not a portable disk. | 指定的磁盤不是可卸載的磁盤,Portable 為 false 的磁盤無法卸載。 |
403 | DiskTypeViolation | The specified disk is a system disk and cannot support the operation. | 指定的云盤是系統盤,不能卸載。 |
403 | DiskCreatingSnapshot | The operation is denied due to a snapshot of the specified disk is not completed yet. | 指定的磁盤正在創建快照。 |
403 | IncorrectDiskStatus.Initializing | The current disk status does not support this operation. | 當前的磁盤不支持此操作,請您確認磁盤處于正常使用狀態,是否欠費。 |
403 | DiskStillAttached | The disk is still attached to the disk. | 磁盤仍然掛載在實例上。 |
403 | UserNotInTheWhiteList | The user is not in disk white list. | 您不在磁盤白名單中,請加入白名單后重試。 |
403 | InvalidDiskStatus.DeleteProtection | The specified disk is under delete protection, can not be deleted. | 指定的云盤處于刪除保護狀態。可能原因:該云盤作為系統盤從源實例上卸載,被卸載的系統盤會作為數據盤保留下來。源實例未釋放前,被卸載的系統盤無法被主動釋放。 |
404 | InvalidDiskId.NotFound | The specified disk does not exist. | 指定的磁盤不存在。請您檢查磁盤 ID 是否正確。 |
500 | InternalError | The request processing has failed due to some unknown error. | 內部錯誤,請重試。 |
訪問錯誤中心查看更多錯誤碼。
變更歷史
變更時間 | 變更內容概要 | 操作 |
---|
暫無變更歷史