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

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

 



On Tue, Mar 31, 2009 at 04:15:44PM -0400, Michael DeHaan wrote:
> I'm working on adding scripted Windows install support (ISO + answer 
> file on floppy) support to koan.
> 
> I'm getting the following when trying to attach a floppy image.  
> 
> 
> =======================
> 
> Here's the error:
> 
> libvir: QEMU error : Domain not found
> libvir: QEMU error : Domain not found
> libvir: Domain Config error : internal error Invalid floppy device name: hda
> <class 'libvirt.libvirtError'>

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

> internal error Invalid floppy device name: hda
>    <disk type='file' device='floppy'>
>      <source file='/tmp/tmpkmVdz3.floppy'/>
>      <target dev='hda' bus='ide'/>
>    </disk>

This should be 
    <disk type='file' device='floppy'>
      <source file='/tmp/tmpkmVdz3.floppy'/>
      <target dev='fda' bus='fdc'/>
    </disk>

> 
>  
> 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

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

[Index of Archives]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux