← Back to team overview

openstack team mailing list archive

Re: Audio card for libvirt/kvm in folsom

 

On Fri, Jan 11, 2013 at 10:53:25PM +0800, 孙玉新 wrote:
> Davide,
> 
> If you use KVM, it's possible to enable audio.
> Please refer  http://libvirt.org/formatdomain.html#elementsSound
> 
> Here is some infomation about how to enable it in nova:
>  http://www.gossamer-threads.com/lists/openstack/operators/21302
> 
> Haven't test it, I think the steps should be:
> 1. cp /usr/lib/python2.7/dist-packages/*nova*/virt/libvirt.xml.template
> /etc/*nova/*
> 2. add next line to *nova*.conf
> --*libvirt_xml_template*=/etc/*nova*/libvirt.xml.template
> 3. Edit /etc/*nova*/libvirt.xml.template, add the following lines:
> 
>  <devices>
>     <sound model='ich6'>
>       <codec type='micro'/>
>     <sound/>
>   </devices>
> 
> Hope this is helpful.


That won't work on Folsom since the libvirt.xml.template no longer
exists.  See my reply elsewhere in this thread for how todo it in
the Nova code.  If you want to just hack it in without modifying
Nova though, it is possible to use a libvirt hook script:

  http://libvirt.org/hooks.html

this is invoked by libvirt immediately prior to launching a guest,
allowing you to modify the XML that is used.

Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|


Follow ups

References