WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] "Network %s doesn't exist" in xenapi_create.py

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] "Network %s doesn't exist" in xenapi_create.py
From: Ramon Caceres <caceres@xxxxxxxxxx>
Date: Thu, 19 Jul 2007 14:43:34 -0400
Delivery-date: Thu, 19 Jul 2007 11:41:18 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <20070719163454.GA8493@xxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Hello.

How do I arrange for a new network bridge in dom0 to appear in the 
"networks" dictionary created by the following statement in line 417 of 
recent versions of xen-unstable.hg/tools/python/xen/xm/xenapi_create.py? 

                networks = dict([(record['name_label'], ref)
                                 for ref, record in
 server.xenapi.network.get_all_records().items()])
 
I am creating a bridge named br0.101 and adding to it a VLAN interface 
named peth0.101.  This bridge is in addition to the default eth0 bridge 
created by /xen/scripts/network-bridge.  I use the following sequence in a 
modified version of network-bridge:

        # Create VLAN interface
        vconfig add ${pdev} ${vlan}
        vlanif=${pdev}.${vlan}
        ip link set ${vlanif} up

        # Create bridge
        br="br${netnum}.${vlan}"
        create_bridge ${br}

        # Add VLAN interface to bridge
        setup_bridge_port ${vlanif}
        add_to_bridge2 ${br} ${vlanif}
        do_ifup ${br}

The new bridge and interface show up as expected in the output of brctl, 
ifconfig, and ip, as well as in the /sys/class/net directory.   However, 
when I try to connect a domU to the bridge by specifying "vif = [ 
'bridge=br0.101' ]", I get this:

        Error: Network br0.101 doesn't exist

If I change that to "vif = [ 'bridge=eth0' ]" or "vif = [ '' ]" then the 
domU comes up without error and connects to the eth0 bridge as normal.

The VLAN-related bridges were working for several months on xen-unstable 
changeset 14887 from April 21, but the above problem surfaced when I 
updated to 15521 from July 10.  I haven't been able to find what I'm 
missing to make my new bridge appear in that "networks" dictionary the way 
that the default bridge does.

Any help would be greatly appreciated.

--Ramón
_____________________________
Ramón Cáceres
Research Staff Member
IBM T.J. Watson Research Center


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel