Skip to main content
Platform O&M/Backup Management/Backup Service (Plus)/Backup Service Operations
POSTBackup Service OperationsSince 3.0.0SynchronousAuth Required

CreateVmFromVmBackup

CreateVmFromVmBackup

Execution Availability

Try It Out

Submit a mock request using the current auth context and example-driven inputs.

Path Parameters

Request Inputs

Path Parameters

  • groupUuidStringRequired

    The UUID of the VM backup group.

Body Fields

  • paramsObjectRequired

    Request body parameter object.

    • nameStringRequired

      The name of the VM.

    • backupStorageUuidString

      Optional. The UUID of the backup storage.

    • instanceOfferingUuidStringRequired

      The UUID of the instance offering.

    • l3NetworkUuidsList

      Optional. The UUIDs of L3 networks.

    • vmNicParamsString

      Optional.The information of the vmNic

    • typeString

      Optional. The type of the VM instance.

    • zoneUuidString

      Optional. The zone UUID.

    • clusterUuidString

      Optional. The cluster UUID.

    • hostUuidString

      Optional. The host UUID.

    • primaryStorageUuidForRootVolumeString

      Optional. The primary storage used to host the root volume.

    • primaryStorageUuidForDataVolumeString

      Optional. The primary storage used to host data volumes.

    • descriptionString

      Optional. The detailed description of the VM.

    • rootVolumeSystemTagsList

      Optional. The system tags of the root volume.

    • dataVolumeSystemTagsList

      Optional. The system tags of the data volume.

    • defaultL3NetworkUuidString

      The UUID of the L3 network.

    • resourceUuidString

      Optional.

    • tagUuidsList

      Optional. The tagUuids.

    • strategyString

      Optional. The srategy to create vms.

  • systemTagsList

    Optional. The system tags.

  • userTagsList

    Optional. The user tags.

Responses

200 OK

On success, this API returns the following response structure.

  • successbooleanRequired

    操作是否成功。

  • errorErrorCodeRequired

    The error code. If not null, the operation fails, or vice versa. For more information, see error

    • codeStringRequired

      The error code, which is a numbered or alphanumeric code that specifies an error. For example, SYS.1000, HOST.1001.

    • descriptionStringRequired

      The brief description of the error.

    • detailsStringRequired

      The details about the error.

    • elaborationStringRequired

      The reserved field. Default value: null.

    • opaqueLinkedHashMapRequired

      The reserved field. Default value: null.

    • causeErrorCodeRequired

      The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null.

  • inventoryVmInstanceInventoryRequired

    See inventory

    • uuidStringRequired

      The UUID of the VM instance.

    • nameStringRequired

      The name of the VM instance.

    • descriptionStringRequired

      The detailed description of the VM instance.

    • zoneUuidStringRequired

      The zone UUID.

    • clusterUuidStringRequired

      The cluster UUID.

    • imageUuidStringRequired

      The image UUID.

    • hostUuidStringRequired

      The host UUID.

    • lastHostUuidStringRequired

      最近一次主机UUID。

    • instanceOfferingUuidStringRequired

      The UUID of the instance offering.

    • rootVolumeUuidStringRequired

      The UUID of the root volume.

    • platformStringRequired

      平台。

    • architectureStringRequired

      No description provided.

    • defaultL3NetworkUuidStringRequired

      No description provided.

    • typeStringRequired

      类型。

    • hypervisorTypeStringRequired

      No description provided.

    • memorySizeLongRequired

      内存大小。

    • cpuNumIntegerRequired

      No description provided.

    • cpuSpeedLongRequired

      No description provided.

    • allocatorStrategyStringRequired

      No description provided.

    • createDateTimestampRequired

      The time when the VM instance was created.

    • lastOpDateTimestampRequired

      The time when the VM instance was last modified.

    • stateStringRequired

      当前状态。

    • guestOsTypeStringRequired

      No description provided.

    • vmNicsListRequired

      See vmNics

      • uuidStringRequired

        The UUID of the NIC of the VM instance.

      • vmInstanceUuidStringRequired

        The UUID of the VM instance.

      • l3NetworkUuidStringRequired

        The UUID of the L3 network.

      • ipStringRequired

        来源IP地址。

      • macStringRequired

        No description provided.

      • hypervisorTypeStringRequired

        No description provided.

      • netmaskStringRequired

        No description provided.

      • gatewayStringRequired

        No description provided.

      • metaDataStringRequired

        元数据。

      • ipVersionIntegerRequired

        IP版本。

      • driverTypeStringRequired

        No description provided.

      • internalNameStringRequired

        内部名称。

      • deviceIdIntegerRequired

        设备ID。

      • typeStringRequired

        类型。

      • stateStringRequired

        The state of the vmNics.

      • createDateTimestampRequired

        The time when the NIC was created.

      • lastOpDateTimestampRequired

        The time when the NIC was last modified.

      • usedIpsListRequired

        See usedIps

        • uuidStringRequired

          The UUID of the volume.

        • ipRangeUuidStringRequired

          The UUID of the ip range.

        • l3NetworkUuidStringRequired

          The UUID of the L3network.

        • ipVersionIntegerRequired

          IP版本。

        • ipStringRequired

          来源IP地址。

        • netmaskStringRequired

          No description provided.

        • gatewayStringRequired

          No description provided.

        • usedForStringRequired

          已使用用于。

        • ipInLonglongRequired

          No description provided.

        • vmNicUuidStringRequired

          The UUID of the vmNic.

        • createDateTimestampRequired

          The creation time.

        • lastOpDateTimestampRequired

          The last operation time.

    • allVolumesListRequired

      See allVolumes

      • uuidStringRequired

        The UUID of the volume.

      • nameStringRequired

        The name of the volume.

      • descriptionStringRequired

        The detailed description of the volume.

      • primaryStorageUuidStringRequired

        The UUID of the primary storage.

      • vmInstanceUuidStringRequired

        The UUID of the VM instance.

      • diskOfferingUuidStringRequired

        The UUID of the disk offering.

      • rootImageUuidStringRequired

        根镜像UUID。

      • installPathStringRequired

        安装路径。

      • typeStringRequired

        类型。

      • formatStringRequired

        数据格式或导出格式。

      • sizeLongRequired

        返回记录数。

      • actualSizeLongRequired

        实际大小。

      • deviceIdIntegerRequired

        设备ID。

      • stateStringRequired

        当前状态。

      • statusStringRequired

        状态信息。

      • createDateTimestampRequired

        The time when the volume was created.

      • lastOpDateTimestampRequired

        The time when the volume was last modified.

      • isShareableBooleanRequired

        是否可分享。

      • volumeQosStringRequired

        No description provided.

      • lastDetachDateTimestampRequired

        最近一次detach时间。

      • lastVmInstanceUuidStringRequired

        最近一次云主机实例UUID。

    • vmCdRomsListRequired

      SeevmCdRoms

Endpoint

POST/zstack/v1/vm-instances/from/vm-backups/{groupUuid}

/zstack/v1/vm-instances/from/vm-backups/{groupUuid}

Operation ID

CreateVmFromVmBackup

Permalink

Request Example

curl -X POST 'http://{host}/zstack/v1/vm-instances/from/vm-backups/{groupUuid}' -H 'Authorization: OAuth {sessionUuid}' -H 'Content-Type: application/json;charset=UTF-8' -d '{"params":{"name":"<name>","backupStorageUuid":"<backupStorageUuid>","instanceOfferingUuid":"<instanceOfferingUuid>","l3NetworkUuids":["<l3NetworkUuids>"],"vmNicParams":"<vmNicParams>","type":"<type>","zoneUuid":"<zoneUuid>","clusterUuid":"<clusterUuid>","hostUuid":"<hostUuid>","primaryStorageUuidForRootVolume":"<primaryStorageUuidForRootVolume>","primaryStorageUuidForDataVolume":"<primaryStorageUuidForDataVolume>","description":"<description>","rootVolumeSystemTags":["<rootVolumeSystemTags>"],"dataVolumeSystemTags":["<dataVolumeSystemTags>"],"defaultL3NetworkUuid":"<defaultL3NetworkUuid>","resourceUuid":"<resourceUuid>","tagUuids":["<tagUuids>"],"strategy":"<strategy>"},"systemTags":["<systemTags>"],"userTags":["<userTags>"]}'

Response Example

200
{ "inventory": { "uuid": "a1c07d683f693f6e9f2d7f9a499c7840", "name": "Test-VM", "description": "web server VM", "zoneUuid": "1e48b41ec4b63660b38a72d271c0164b", "clusterUuid": "f29498f04b1e3c319bdaeb6b3f8259f3", "imageUuid": "5c07704333c532e8b402b6b3ddb89315", "hostUuid": "e18cf66eedb3306686a1d4685bbb63af", "lastHostUuid": "4834161c409a34b6a84e40d71d85f714", "instanceOfferingUuid": "f53ad9f147203b499dfbd93ce41b7a8e", "rootVolumeUuid": "24b9fcb69f123ad6b3ddfffed96d2882", "platform": "Linux", "defaultL3NetworkUuid": "d50554f493153be78f6740e18e598046", "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": "9856d36e40783d669b9e4f1de41d1a17", "vmInstanceUuid": "a1c07d683f693f6e9f2d7f9a499c7840", "usedIpUuid": "be02105c2a223492a91fb09ba664ecb1", "l3NetworkUuid": "d50554f493153be78f6740e18e598046", "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": "24b9fcb69f123ad6b3ddfffed96d2882", "name": "Root-Volume-For-VM-a1c07d683f693f6e9f2d7f9a499c7840", "primaryStorageUuid": "ae47a25fd7cf3a349035d01060a8a224", "vmInstanceUuid": "a1c07d683f693f6e9f2d7f9a499c7840", "rootImageUuid": "5c07704333c532e8b402b6b3ddb89315", "installPath": "/zstack_ps/rootVolumes/acct-36c27e8ff05c4780bf6d2fa65700f22e/vol-24b9fcb69f123ad6b3ddfffed96d2882/24b9fcb69f123ad6b3ddfffed96d2882.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.

View all change history