CreateVmFromVolumeBackup
CreateVmFromVolumeBackup
Execution Availability
Try It Out
Submit a mock request using the current auth context and example-driven inputs.
Path Parameters
Request Inputs
Path Parameters
backupUuidStringRequiredThe backup UUID.
Body Fields
paramsObjectRequiredRequest body parameter object.
nameStringRequiredThe VM instance name.
backupStorageUuidStringOptional. The backup storage UUID.
instanceOfferingUuidStringRequiredThe instance offering UUID.
defaultL3NetworkUuidStringOptional. The UUID of the default L3 network.
l3NetworkUuidsListRequiredThe L3 network UUID list.
typeStringOptional. The VM instance type.
zoneUuidStringOptional. The zone UUID.
clusterUuidStringOptional. The cluster UUID.
hostUuidStringOptional. The host UUID.
primaryStorageUuidForRootVolumeStringOptional. The UUID of the primary storage which the root volume resides on.
descriptionStringOptional. The description of the VM instance.
rootVolumeSystemTagsListOptional. The system tag of the root volume.
resourceUuidStringOptional.
systemTagsListOptional. The system tag.
tagUuidsListOptional. The tag UUID list.
strategyStringOptional. The VM creation strategy.
userTagsListOptional. The user tag.
Responses
Endpoint
POST/zstack/v1/vm-instances/from/vm-backup/{backupUuid}
/zstack/v1/vm-instances/from/vm-backup/{backupUuid}
Request Example
curl -X POST 'http://{host}/zstack/v1/vm-instances/from/vm-backup/{backupUuid}' -H 'Authorization: OAuth {sessionUuid}' -H 'Content-Type: application/json;charset=UTF-8' -d '{"params":{"name":"<name>","backupStorageUuid":"<backupStorageUuid>","instanceOfferingUuid":"<instanceOfferingUuid>","defaultL3NetworkUuid":"<defaultL3NetworkUuid>","l3NetworkUuids":["<l3NetworkUuids>"],"type":"<type>","zoneUuid":"<zoneUuid>","clusterUuid":"<clusterUuid>","hostUuid":"<hostUuid>","primaryStorageUuidForRootVolume":"<primaryStorageUuidForRootVolume>","description":"<description>","rootVolumeSystemTags":["<rootVolumeSystemTags>"],"resourceUuid":"<resourceUuid>","systemTags":["<systemTags>"],"tagUuids":["<tagUuids>"],"strategy":"<strategy>"},"userTags":["<userTags>"]}'
Response Example
200{ "inventory": { "uuid": "0a2cbf2edacc399cb9a7e6b2fa14602d", "name": "Test-VM", "description": "web server VM", "zoneUuid": "1086a7491b8c3fb9ab12192dc0fab906", "clusterUuid": "3e368e7f98913ec6bb20d6cc969cf50a", "imageUuid": "2ceb7086482d3b42ab56b9daa6fb4d44", "hostUuid": "d81f8599fd033183ab2d4bcafce233cc", "lastHostUuid": "2d9fd9b480be3fdd9df46548d9d178d5", "instanceOfferingUuid": "feba03817e0e326d827ebdb436786bad", "rootVolumeUuid": "2f368d0d8b4734b7b58e1c5cb2ec27c6", "platform": "Linux", "defaultL3NetworkUuid": "ecebe1b81b18351dbdf304622e9ada80", "type": "UserVm", "hypervisorType": "KVM", "memorySize": 8589934592, "cpuNum": 1, "allocatorStrategy": "LastHostPreferredAllocatorStrategy", "createDate": "Nov 14, 2017 10:20:57 PM", "lastOpDate": "Nov 14, 2017 10:20:57 PM", "state": "Running", "vmNics": [ { "uuid": "da1e1002fa2b387bbe389ce3bf10ba92", "vmInstanceUuid": "0a2cbf2edacc399cb9a7e6b2fa14602d", "usedIpUuid": "e8c56c6711e83896acb7413183726c1c", "l3NetworkUuid": "ecebe1b81b18351dbdf304622e9ada80", "ip": "192.168.1.10", "mac": "00:0c:29:bd:99:fc", "netmask": "255.255.255.0", "gateway": "192.168.1.1", "deviceId": 0, "state": "enable", "createDate": "Nov 14, 2017 10:20:57 PM", "lastOpDate": "Nov 14, 2017 10:20:57 PM" } ], "allVolumes": [ { "uuid": "2f368d0d8b4734b7b58e1c5cb2ec27c6", "name": "Root-Volume-For-VM-0a2cbf2edacc399cb9a7e6b2fa14602d", "primaryStorageUuid": "890196bf1b5a308da1c75eb61ff441a3", "vmInstanceUuid": "0a2cbf2edacc399cb9a7e6b2fa14602d", "rootImageUuid": "2ceb7086482d3b42ab56b9daa6fb4d44", "installPath": "/zstack_ps/rootVolumes/acct-36c27e8ff05c4780bf6d2fa65700f22e/vol-2f368d0d8b4734b7b58e1c5cb2ec27c6/2f368d0d8b4734b7b58e1c5cb2ec27c6.qcow2", "type": "Root", "format": "qcow2", "size": 107374182400, "actualSize": 21474836480, "deviceId": 0, "state": "Enabled", "status": "Ready", "createDate": "Nov 14, 2017 10:20:57 PM", "lastOpDate": "Nov 14, 2017 10:20:57 PM" } ] } }Change History
This API has no change history records yet.
