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

[Xen-changelog] [xen-unstable] network-bridge: Make detection of gateway

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] network-bridge: Make detection of gateway device more robust.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 09 Nov 2007 04:21:00 -0800
Delivery-date: Fri, 09 Nov 2007 05:27:50 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir@xxxxxxxxxxxxx>
# Date 1194454513 0
# Node ID d4c5a1cdcf2e6e9c98c99d218f8b80f8baca10cd
# Parent  4f1363491a77b97f58b30b6652e357f93a8f100d
network-bridge: Make detection of gateway device more robust.
Signed-off-by: Guillaume Rousse <Guillaume.Rousse@xxxxxxxx>
---
 tools/examples/network-bridge |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff -r 4f1363491a77 -r d4c5a1cdcf2e tools/examples/network-bridge
--- a/tools/examples/network-bridge     Wed Nov 07 16:51:08 2007 +0000
+++ b/tools/examples/network-bridge     Wed Nov 07 16:55:13 2007 +0000
@@ -72,8 +72,8 @@ find_alt_device () {
     echo "$ifs"
 }
 
-netdev=${netdev:-$(ip route list | awk '/^default / { print $NF }' |
-                  sed 's/.* dev //')}
+netdev=${netdev:-$(ip route list 0.0.0.0/0  | \
+                   sed 's/.*dev \([a-z]\+[0-9]\+\).*$/\1/')}
 if is_network_root ; then
     altdevs=$(find_alt_device $netdev)
     for netdev in $altdevs; do break; done

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] network-bridge: Make detection of gateway device more robust., Xen patchbot-unstable <=