[libvirt] Xen network interface behavior with 0.6.2

Daniel P. Berrange berrange at redhat.com
Mon Apr 20 09:19:16 UTC 2009


On Fri, Apr 17, 2009 at 01:29:12PM -0700, Kaitlin Rupert wrote:
> Hi,
> 
> I'm using libvirt 0.6.2 to create a Xen guest with a network type 
> interface (see XML below).  When the guest is defined, the interface is 
> converted to an ethernet type interface.  If the guest is started, the 
> interface is then converted to a bridge type interface.

This sounds bad :-)  Can you provide the output of 'xm list --long hd_domain'
immediately after defining it, and then again immediately after starting
the guest.

> 
> # virsh list --all
>  Id Name                 State
> ----------------------------------
>   0 Domain-0             running
>   - rstest_domain        shut off
> 
> # cat tmp
> <domain type="xen">
>   <name>hd_domain</name>
>   <on_poweroff>destroy</on_poweroff>
>   <on_crash>destroy</on_crash>
>   <uuid>f99fd6b6-1434-4bc2-88e0-1ed9c8c6f8e9</uuid>
>   <os>
>     <type>linux</type>
>     <kernel>/tmp/default-xen-kernel</kernel>
>     <initrd>/tmp/default-xen-initrd</initrd>
>     <cmdline/>
>   </os>
>   <currentMemory>131072</currentMemory>
>   <memory>131072</memory>
>   <vcpu>1</vcpu>
>   <devices>
>     <disk type="file" device="disk">
>       <source file="/tmp/default-xen-dimage"/>
>       <target dev="xvda"/>
>     </disk>
>     <interface type="network">
>       <mac address="00:11:22:33:44:aa"/>
>       <source network="default"/>
>     </interface>
>     <input type="mouse" bus="xen"/>
>     <graphics type="vnc" port="-1" listen="127.0.0.1" keymap="en-us"/>
>   </devices>
> </domain>
> 
> # virsh define tmp
> Domain hd_domain defined from tmp
> 
> # virsh list --all
>  Id Name                 State
> ----------------------------------
>   0 Domain-0             running
>   - hd_domain            shut off
>   - rstest_domain        shut off
> 
> [root at elm3b25 cimtest]# virsh dumpxml hd_domain
> <domain type='xen'>
>   <name>hd_domain</name>
>   <uuid>f99fd6b6-1434-4bc2-88e0-1ed9c8c6f8e9</uuid>
>   <memory>131072</memory>
>   <currentMemory>131072</currentMemory>
>   <vcpu>1</vcpu>
>   <os>
>     <type arch='x86_64' machine='xenpv'>linux</type>
>     <kernel>/tmp/default-xen-kernel</kernel>
>     <initrd>/tmp/default-xen-initrd</initrd>
>   </os>
>   <clock offset='utc'/>
>   <on_poweroff>destroy</on_poweroff>
>   <on_reboot>restart</on_reboot>
>   <on_crash>destroy</on_crash>
>   <devices>
>     <disk type='file' device='disk'>
>       <driver name='file'/>
>       <source file='/tmp/default-xen-dimage'/>
>       <target dev='xvda' bus='xen'/>
>     </disk>
>     <interface type='ethernet'>
>       <mac address='00:11:22:33:44:aa'/>
>     </interface>
>     <console type='pty'>
>       <target port='0'/>
>     </console>
>     <input type='mouse' bus='xen'/>
>     <graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1' 
> keymap='en-us'/>
>   </devices>
> </domain>
> 
> # virsh start hd_domain
> Domain hd_domain started
> 
> [root at elm3b25 cimtest]# virsh dumpxml hd_domain
> <domain type='xen' id='61'>
>   <name>hd_domain</name>
>   <uuid>f99fd6b6-1434-4bc2-88e0-1ed9c8c6f8e9</uuid>
>   <memory>131072</memory>
>   <currentMemory>131072</currentMemory>
>   <vcpu>1</vcpu>
>   <os>
>     <type>linux</type>
>     <kernel>/tmp/default-xen-kernel</kernel>
>     <initrd>/tmp/default-xen-initrd</initrd>
>   </os>
>   <clock offset='utc'/>
>   <on_poweroff>destroy</on_poweroff>
>   <on_reboot>restart</on_reboot>
>   <on_crash>destroy</on_crash>
>   <devices>
>     <disk type='file' device='disk'>
>       <driver name='file'/>
>       <source file='/tmp/default-xen-dimage'/>
>       <target dev='xvda' bus='xen'/>
>     </disk>
>     <interface type='bridge'>
>       <mac address='00:11:22:33:44:aa'/>
>       <script path='vif-bridge'/>
>       <target dev='vif61.0'/>
>     </interface>
>     <console type='pty' tty='/dev/pts/4'>
>       <source path='/dev/pts/4'/>
>       <target port='0'/>
>     </console>
>     <input type='mouse' bus='xen'/>
>     <graphics type='vnc' port='5900' autoport='yes' listen='127.0.0.1' 
> keymap='en-us'/>
>   </devices>
> </domain>
> 
> 


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




More information about the libvir-list mailing list