- HOME
- 提供API一覧
- detachVolume
detachVolume
処理概要
仮想サーバからボリュームをデタッチ
注意事項
・なし
リクエスト
・リクエストパラメータ
| Parameter Name | Description | Required |
| id | the ID of the disk volume | true |
・リクエストサンプル
$ ./kick_api.sh command=detachVolume id=eb4b2781-acd1-4e26-b964-bf62d4df7720
レスポンス
・レスポンスボディ
| Response Name | Description |
| id | ID of the disk volume |
| account | the account associated with the disk volume |
| attached | the date the volume was attached to a VM instance |
| chaininfo | the chain info of the volume |
| created | the date the disk volume was created |
| destroyed | the boolean state of whether the volume is destroyed or not |
| deviceid | the ID of the device on user vm the volume is attahed to. This tag is not returned when the volume is detached. |
| diskBytesReadRate | bytes read rate of the disk volume |
| diskBytesWriteRate | bytes write rate of the disk volume |
| diskIopsReadRate | io requests read rate of the disk volume |
| diskIopsWriteRate | io requests write rate of the disk volume |
| diskofferingdisplaytext | the display text of the disk offering |
| diskofferingid | ID of the disk offering |
| diskofferingname | name of the disk offering |
| displayvolume | an optional field whether to the display the volume to the end user or not. |
| domain | the domain associated with the disk volume |
| domainid | the ID of the domain associated with the disk volume |
| hypervisor | Hypervisor the volume belongs to |
| isextractable | true if the volume is extractable, false otherwise |
| isodisplaytext | an alternate display text of the ISO attached to the virtual machine |
| isoid | the ID of the ISO attached to the virtual machine |
| isoname | the name of the ISO attached to the virtual machine |
| maxiops | max iops of the disk volume |
| miniops | min iops of the disk volume |
| name | name of the disk volume |
| path | the path of the volume |
| project | the project name of the vpn |
| projectid | the project id of the vpn |
| provisioningtype | provisioning type used to create volumes. |
| quiescevm | need quiesce vm or not when taking snapshot |
| serviceofferingdisplaytext | the display text of the service offering for root disk |
| serviceofferingid | ID of the service offering for root disk |
| serviceofferingname | name of the service offering for root disk |
| size | size of the disk volume |
| snapshotid | ID of the snapshot from which this volume was created |
| state | the state of the disk volume |
| status | the status of the volume |
| storage | name of the primary storage hosting the disk volume |
| storageid | id of the primary storage hosting the disk volume; returned to admin user only |
| storagetype | shared or local storage |
| templatedisplaytext | an alternate display text of the template for the virtual machine |
| templateid | the ID of the template for the virtual machine. A -1 is returned if the virtual machine was created from an ISO file. |
| templatename | the name of the template for the virtual machine |
| type | type of the disk volume (ROOT or DATADISK) |
| virtualmachineid | id of the virtual machine |
| vmdisplayname | display name of the virtual machine |
| vmname | name of the virtual machine |
| vmstate | state of the virtual machine |
| zoneid | ID of the availability zone |
| zonename | name of the availability zone |
| tags(*) | the list of resource tags associated with volume |
| account | the account associated with the tag |
| customer | customer associated with the tag |
| domain | the domain associated with the tag |
| domainid | the ID of the domain associated with the tag |
| key | tag key name |
| project | the project name where tag belongs to |
| projectid | the project id the tag belongs to |
| resourceid | id of the resource |
| resourcetype | resource type |
| value | tag value |
| jobid | the ID of the latest async job acting on this object |
| jobstatus | the current status of the latest async job acting on this object |
・レスポンスサンプル
【API実行結果】
<?xml version=”1.0″ encoding=”UTF-8″?>
<detachvolumeresponse cloud-stack-version=”4.3.0.2″>
<jobid>21e7f2dd-a6c9-4a91-9273-216a41e41e44</jobid>
</detachvolumeresponse>
【queryAsyncJobResultでの確認結果】
<?xml version=”1.0″ encoding=”UTF-8″?>
<queryasyncjobresultresponse cloud-stack-version=”4.3.0.2″>
<accountid>d344caf5-24dc-4194-ac5f-2d78d5e38039</accountid>
<userid>0212ea46-0529-4250-9e3e-bcb03c114002</userid>
<cmd>org.apache.cloudstack.api.command.user.volume.DetachVolumeCmd</cmd>
<jobstatus>1</jobstatus>
<jobprocstatus>0</jobprocstatus>
<jobresultcode>0</jobresultcode>
<jobresulttype>object</jobresulttype>
<jobresult>
<volume>
<id>eb4b2781-acd1-4e26-b964-bf62d4df7720</id>
<name>test1</name>
<zoneid>7d4b9647-356d-49a8-8e1a-28862b9c9082</zoneid>
<zonename>jp2-east03</zonename>
<type>DATADISK</type>
<size>10737418240</size>
<created>2016-09-22T21:46:44+0900</created>
<state>Ready</state>
<account>xxxx</account>
<domainid>57edb9da-0279-45f0-842a-d768c4ed0d47</domainid>
<domain>MXXXXXXXX</domain>
<storagetype>shared</storagetype>
<diskofferingid>f9729993-01a7-4f5f-b195-d2d62cd8c50b</diskofferingid>
<diskofferingname>FAST_STORAGE</diskofferingname>
<diskofferingdisplaytext>FAST_STORAGE</diskofferingdisplaytext>
<destroyed>false</destroyed>
<isextractable>true</isextractable>
<pcidevicepath>pci-0000:00:10.0-scsi-0:0:1:0</pcidevicepath>
<displayvolume>true</displayvolume>
<quiescevm>false</quiescevm>
<jobid>21e7f2dd-a6c9-4a91-9273-216a41e41e44</jobid>
<jobstatus>0</jobstatus>
</volume>
</jobresult>
<created>2016-09-22T21:56:30+0900</created>
<jobid>21e7f2dd-a6c9-4a91-9273-216a41e41e44</jobid>
</queryasyncjobresultresponse>
