Google
  Web www.spinics.net

Re: virtinst ... proper API way to add a floppy drive?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


On Wed, Apr 01, 2009 at 12:14:49PM -0400, Michael DeHaan wrote:
> 
> >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?

Just set

   device=VirtualDisk.DEVICE_FLOPPY

and  virtinst generated the device name

Daniel
-- 
|: Red Hat, Engineering, London   -o-   http://people.redhat.com/berrange/ :|
|: http://libvirt.org  -o-  http://virt-manager.org  -o-  http://ovirt.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505  -o-  F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|

_______________________________________________
et-mgmt-tools mailing list
et-mgmt-tools@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/et-mgmt-tools

[Home]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Red Hat 9 Bible]     [Fedora Bible]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]

Powered by Linux

Google
  Web www.spinics.net