[libvirt-users] network comanline to xml

basti black.fledermaus at aror.de
Fri Sep 14 22:54:05 UTC 2012


hello,

i start a kvm guest with the following comand line:

kvm -hda myimage.img -m 1024 -smp 2 \
     -net nic -net tap,ifname=tap0,script=no

now a plan to start this via libvirt.
I have try to set nat via the libvirt-manager but this doesn't connect.
So i try to use bridge network via the GUI and get a "non supported" 
error when i use tap0 as "bridge device".

How can i "convert" the "-net nic -net tap,ifname=tap0,script=no" to a 
valid libvirt-xml file?
The following example is also buggy:

  <interface type='network'>
       <mac address='52:54:00:46:3e:70'/>
       <source network='default'/>
       <target dev='tap0'/>
       <model type='virtio'/>
       <address type='pci' domain='0x0000' bus='0x00' slot='0x03' 
function='0x0'$
  </interface>


thanks




More information about the libvirt-users mailing list