<cdrom>
<file id="mycd.iso"/>
</cdrom>
public interface VmCdromService extends Service
Manages a CDROM device of a virtual machine.
If there is a disk inserted then the file
attribute will contain a reference to the ISO image:
<cdrom>
<file id="mycd.iso"/>
</cdrom>
If there is no disk inserted then the file
attribute won’t be reported:
<cdrom>
</cdrom>
Changing and ejecting the disk is done using always the update
method, to change the value of the file
attribute.
For example, to insert or change the disk send a request like this:
PUT /ovirt-engine/api/vms/123/00000000-0000-0000-0000-000000000000
The body should contain the new value for the file
attribute:
<cdrom>
<file id="mycd.iso"/>
</cdrom>
The value of the id
attribute, mycd.iso
in this example, should correspond to a file available in an attached
ISO storage domain.
To eject the disk use a file
with an empty id
:
<cdrom>
<file id=""/>
</cdrom>
By default the above operations change permanently the disk that will be visible to the virtual machine after the
next boot, but they don’t have any effect on the currently running virtual machine. If you want to change the disk
that is visible to the current running virtual machine, add the current=true
parameter. For example, to eject the
current disk send a request like this:
PUT /ovirt-engine/api/vms/123/00000000-0000-0000-0000-000000000000?current=true
With a request body like this:
<cdrom>
<file id=""/>
</cdrom>
Important
|
The changes made with the current=true parameter are never persisted, so they won’t have any effect
after the virtual machine is rebooted.
|
Modifier and Type | Interface and Description |
---|---|
static interface |
VmCdromService.GetRequest
Returns the information about this CDROM device.
|
static interface |
VmCdromService.GetResponse
Returns the information about this CDROM device.
|
static interface |
VmCdromService.UpdateRequest
Updates the information about this CDROM device.
|
static interface |
VmCdromService.UpdateResponse
Updates the information about this CDROM device.
|
Modifier and Type | Method and Description |
---|---|
VmCdromService.GetRequest |
get()
Returns the information about this CDROM device.
|
Service |
service(String path)
Service locator method, returns individual service on which the URI is dispatched.
|
VmCdromService.UpdateRequest |
update()
Updates the information about this CDROM device.
|
VmCdromService.GetRequest get()
Returns the information about this CDROM device.
VmCdromService.UpdateRequest update()
Updates the information about this CDROM device.
Copyright © 2016. All rights reserved.