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

xen-devel

[Top] [All Lists]

[Xen-devel] bug in default interface number computation

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] bug in default interface number computation
From: Guillaume Rousse <Guillaume.Rousse@xxxxxxxx>
Date: 2006年12月14日 12:34:27 +0100
Delivery-date: 2006年12月14日 03:33:51 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
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
User-agent: Thunderbird 1.5.0.8 (X11/20061109)
Hello.
The network-bridge script tries to automatically find the default
network interface number with the following ligne:
vifnum=${vifnum:-$(ip route list | awk '/^default / { print $NF }' | sed
's/^[^0-9]*//')}
However, this fails on mandriva, because the parsed line is:
default via 193.55.250.126 dev eth0 metric 10
This causes many troubles, such as:
http://article.gmane.org/gmane.comp.emulators.xen.user/17846
A simple solution is to change the position-based parsing to something
more robust:
vifnum=${vifnum:-$(ip route list 0.0.0.0/0 | sed 's/.*dev
[^0-9]\+\([0-9]\+\).*$/1円/')}
This is also more robust against default interfaces that would be named
otherwise as dev[0-9].
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-devel] bug in default interface number computation, Guillaume Rousse <=
Previous by Date: Re: [PATCH] Re: [Xen-devel] Re: [PATCH 2/2] PV framebuffer , Keir Fraser
Next by Date: Re: [Xen-devel] [ANNOUNCE] Xen 3.0.4-rc1 , Keir Fraser
Previous by Thread: [Xen-devel] [Block issue] VMX status report 13008:360eb996fa38 , Yu, Ping Y
Next by Thread: [Xen-devel] [PATCH] Avoid netfront reaching BUG() condition , Glauber de Oliveira Costa
Indexes: [Date] [Thread] [Top] [All Lists]

Copyright ©, Citrix Systems Inc. All rights reserved. Legal and Privacy
Citrix This site is hosted by Citrix

AltStyle によって変換されたページ (->オリジナル) /