[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] During my attempts to get the latest bridge networking model working on my



# HG changeset patch
# User kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID c9c49385c26efe83a4ff3b0d17b5fc773c61b03a
# Parent  481a4ce27c15f4ece0293d0e015890b4a20cb694
During my attempts to get the latest bridge networking model working on my 
system, I often invoked 'network-bridge stop' with total failure.  Attached 
is an updated version that works.

Signed-off-by: Andrew Theurer <habanero@xxxxxxxxxx>

diff -r 481a4ce27c15 -r c9c49385c26e tools/examples/network-bridge
--- a/tools/examples/network-bridge     Wed Sep 14 15:56:06 2005
+++ b/tools/examples/network-bridge     Wed Sep 14 16:49:23 2005
@@ -222,27 +222,31 @@
         return
     fi
 
-    brctl delif ${bridge} ${netdev}
-
-    if ifconfig veth0 2>/dev/null | grep -q veth0 ; then
-        brctl delif ${bridge} vif0.0
+    if ifconfig peth0 2>/dev/null | grep -q peth0 ; then
+
         ifconfig vif0.0 down
-        mac=`ifconfig veth0 | grep HWadd | sed -e 
's/.*\(..:..:..:..:..:..\).*/\1/'`
-        ifconfig ${netdev} down
-        ifconfig ${netdev} hw ether ${mac}
-        ifconfig ${netdev} arp up
-        transfer_addrs veth0 ${netdev}
-        transfer_routes veth0 ${netdev}
-        del_addrs veth0
-        ifconfig veth0 -arp down
-        ifconfig veth0 hw ether 00:00:00:00:00:00
+        mac=`ifconfig eth0 | grep HWadd | \
+            sed -e 's/.*\(..:..:..:..:..:..\).*/\1/'`
+        ifconfig ${netdev} 0.0.0.0 down
+        ifconfig ${netdev} hw ether fe:ff:ff:ff:ff:ff
+
+        ifconfig p${netdev} down
+        ifconfig p${netdev} hw ether ${mac} arp 
+        brctl delif ${bridge} p${netdev}
+
+        ip link set eth0 name veth0
+        ip link set peth0 name eth0
+        ifconfig ${bridge} down
+        brctl delbr ${bridge}
+        ifup eth0
+
     else
         transfer_routes ${bridge} ${netdev}
     fi
 }
 
 case ${OP} in
-  start)
+    start)
         op_start
         ;;
     

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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.