Resource Center/Resource Pool/VM Instance Operations
PUTVM Instance OperationsSince 0.6SynchronousAuth Required
SetVmConsolePassword
SetVmConsolePassword
Execution Availability
Try It Out
Submit a mock request using the current auth context and example-driven inputs.
Path Parameters
Request Inputs
Path Parameters
uuidStringRequiredThe VM instance UUID.
Body Fields
setvmconsolepasswordObjectRequiredsetvmconsolepassword request body object.
consolePasswordStringRequiredThe console password, which is a plain text string.
systemTagsListOptional. The system tags.
userTagsListOptional. The user tags.
Responses
Endpoint
PUT/zstack/v1/vm-instances/{uuid}/actions
/zstack/v1/vm-instances/{uuid}/actions
Request Example
curl -X PUT 'http://{host}/zstack/v1/vm-instances/{uuid}/actions' -H 'Authorization: OAuth {sessionUuid}' -H 'Content-Type: application/json;charset=UTF-8' -d '{"setvmconsolepassword":{"consolePassword":"<consolePassword>"},"systemTags":["<systemTags>"],"userTags":["<userTags>"]}'
Response Example
200{ "inventory": { "uuid": "bce15aed2a083a258b0d4a4459bf4045", "name": "Test-VM", "description": "web server VM", "zoneUuid": "b53edec7e1a83f9da3cf8df77c571518", "clusterUuid": "4b9c77951519303a8da978ec7794d36e", "imageUuid": "55f62c5a6f27386bab19ad847d03d7ea", "hostUuid": "a93d581689a334fabc3cd9be944c9019", "lastHostUuid": "548d5d819eb83c6a96ab63c5d7123b82", "instanceOfferingUuid": "d2c8669d1caf3741a53f25d1e30c9c38", "rootVolumeUuid": "05b1fab950eb3c02abe7d4a4c7a9509c", "platform": "Linux", "defaultL3NetworkUuid": "a2e4d085db833457ac01b617a4fb3f65", "type": "UserVm", "hypervisorType": "KVM", "memorySize": 8.589934592E9, "cpuNum": 1.0, "allocatorStrategy": "LastHostPreferredAllocatorStrategy", "createDate": "Nov 14, 2017 10:20:57 PM", "lastOpDate": "Nov 14, 2017 10:20:57 PM", "state": "Running", "vmNics": [ { "uuid": "a653fd4b6b093d52924e88fe1b54d13d", "vmInstanceUuid": "bce15aed2a083a258b0d4a4459bf4045", "usedIpUuid": "f0d88327a73a34849d1c733348dceed7", "l3NetworkUuid": "a2e4d085db833457ac01b617a4fb3f65", "ip": "192.168.1.10", "mac": "00:0c:29:bd:99:fc", "hypervisorType": "KVM", "netmask": "255.255.255.0", "gateway": "192.168.1.1", "deviceId": 0.0, "createDate": "Nov 14, 2017 10:20:57 PM", "lastOpDate": "Nov 14, 2017 10:20:57 PM" } ], "allVolumes": [ { "uuid": "05b1fab950eb3c02abe7d4a4c7a9509c", "name": "Root-Volume-For-VM-bce15aed2a083a258b0d4a4459bf4045", "primaryStorageUuid": "3f22c507730d36e4b94bbc6ecbb285ed", "vmInstanceUuid": "bce15aed2a083a258b0d4a4459bf4045", "diskOfferingUuid": "bcba65f045db3538820db3e997fa507a", "rootImageUuid": "55f62c5a6f27386bab19ad847d03d7ea", "installPath": "/Cloud_ps/rootVolumes/acct-36c27e8ff05c4780bf6d2fa65700f22e/vol-05b1fab950eb3c02abe7d4a4c7a9509c/05b1fab950eb3c02abe7d4a4c7a9509c.qcow2", "type": "Root", "format": "qcow2", "size": 1.073741824E11, "actualSize": 2.147483648E10, "deviceId": 0.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.
