Description of problem: If we define the option SRCADDR in the default route interface and we use xen, the script network-bridge does not create the default xen bridge xenbrX. Version-Release number of selected component (if applicable): - xen-3.0.3-64.el5_2.3 How reproducible: Always Steps to Reproduce: 1. Define the option SRCADDR in the default route interface 2. Run /etc/xen/scripts/network-bridge start 3. We will get an error Actual results: network-bridge does not create the default xen bridge Expected results: network-bridge should create the default xen bridge xenbr0 Additional info: The problem is the way the network-bridge script tries to find the vifnum to use. It uses: vifnum=${vifnum:-$(ip route list | awk '/^default / { print $NF }' | sed 's/^[^0 -9]*//')} This works if we don't have the SRCADDR, because the normal output for 'ip route list | grep /^default/' is: default via 88.2.XX.XX dev eth1.11 So the dev is the last field, but if we use the SRCADDR option, the output is: default via 88.2.XX.XX dev eth1.11 src 88.2.XX.ZZ So it tries to use 88.2.XX.ZZ as the vifnum A very simple fix is to define the vifnum in the /etc/xen/xend-config.sxp file: (network-script 'network-bridge vifnum=0') But I guess it would be nice to have that fixed so people does not waste time trying to make it work
Created attachment 336442 [details] Network-bridge script patch This is a patch which solves issue of invalid vifnum device when SRCADDR option is defined in default routing interface. Basically it parses the options on the line using AWK expression to get correct vifnum. Tested using both SRCADDR defined and undefined in `ip route` and working fine for both cases. Michal
Fix built into xen-3.0.3-84.el5
Can you please help to give out steps on 'how to define the option SRCADDR in the default route interface'? Thanks a lot
ip route del default via $GATEWAY dev $IFACE ip route add default via $GATEWAY dev $IFACE src $IFACE_IP
Verified on xen-3.0.3-93.el5 and PASS
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2009-1328.html