技術(shù)員聯(lián)盟提供win764位系統(tǒng)下載,win10,win7,xp,裝機純凈版,64位旗艦版,綠色軟件,免費軟件下載基地!

當前位置:主頁 > 教程 > 服務(wù)器類 >

阿里云如何使用刪除實例接口

來源:技術(shù)員聯(lián)盟┆發(fā)布時間:2017-12-10 06:32┆點擊:

  根據(jù)傳入實例的名稱來釋放實例資源。釋放后實例所使用的物理資源都被回收,包括磁盤及快照,相關(guān)數(shù)據(jù)全部丟失且永久不可恢復(fù)。

  實例狀態(tài)必須為 Stopped,才可以進行刪除操作。刪除后,實例的狀態(tài)為 Deleted,表示資源已釋放,刪除完成。

  實例被刪除時,掛載在實例上的 DeleteWithInstance的屬性為 True 的磁盤會相應(yīng)被刪除,這些磁盤的快照任舊保留,自動快照根據(jù)磁盤的 DeleteAutoSnapshot 屬性,如果為 false 的,保留自動快照,如果為 true 的,則刪除自動快照。

  實例被刪除后,相關(guān)數(shù)據(jù)全部丟失且永久不可恢復(fù)。

  如果刪除實例時,實例被安全控制在實例的 OperationLocks 中標記了 "LockReason" : "security" 的鎖定狀態(tài)時,即使獨立普通云盤的 DeleteWithInstnace 的屬性為 False,系統(tǒng)會忽略這個屬性而釋放掛載在實例上面的普通云盤。

  請求參數(shù)

名稱 類型 是否必須 描述
Action   String     系統(tǒng)規(guī)定參數(shù),取值:DeleteInstance  
InstanceId   String     實例 ID  

  返回參數(shù)

  全是公共返回參數(shù),詳見公共返回參數(shù)

  錯誤碼

錯誤代碼 描述 Http 狀態(tài)碼 語義
MissingParameter   The input parameter "InstanceId" that is mandatory for processing this request is not supplied.   400   缺少 InstanceId 值  
IncorrectInstanceStatus   The current status of the resource does not support this operation.   403   該資源目前的狀態(tài)不支持此操作  
ChargeTypeViolation   The operation is not permitted due to charge type of the instance.   403   不能刪除預(yù)付費的實例  
InternalError   The request processing has failed due to some unknown error.   500   內(nèi)部錯誤  
DependencyViolation.SLBConfiguring   Specified operation is denied as the instance is being used by another product.   400   實例被 SLB 引用,且 SLB 正在配置  

  示例

  請求示例

  https://ecs.aliyuncs.com/?Action=DeleteInstance

  &InstanceId=i-instance1

  &<公共請求參數(shù)>

  返回示例

  XML格式

  

  928E2273-5715-46B9-A730-238DC996A533

  

  JSON格式

  {

  "RequestId": "928E2273-5715-46B9-A730-238DC996A533"