[et-mgmt-tools] virtinst ... proper API way to add a floppy drive?

Michael DeHaan mdehaan at redhat.com
Wed Apr 1 16:14:49 UTC 2009


> This is the core issue - you're giving the floppy a harddisk name
>   

Yeah, I caught that :)

>>  
>> guest.disks.append(virtinst.VirtualDisk(device=virtinst.VirtualDisk.DEVICE_FLOPPY, 
>> path=floppy_path))
>>     
>
> I think you'll need to at least give a device name.
>
> libvirt fills in the bus, based on device name if you leave it out
>   

The constructor signature for VirtualDisk is...

__init__(self, path=None, size=None, transient=False, type=None, device='dis
k', driverName=None, driverType=None, readOnly=False, sparse=True, 
conn=None, vo
lObject=None, volInstall=None, volName=None, bus=None)

Which field would I use for specifying the device name?

Thanks!

--Michael






More information about the et-mgmt-tools mailing list