public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] update qemu-ifup for modern ip route output
@ 2009-09-17 20:38 Dustin Kirkland
  2009-09-18 16:12 ` Marcelo Tosatti
  0 siblings, 1 reply; 2+ messages in thread
From: Dustin Kirkland @ 2009-09-17 20:38 UTC (permalink / raw)
  To: kvm

[-- Attachment #1: Type: text/plain, Size: 876 bytes --]

update qemu-ifup for modern ip route output

The output from the /sbin/ip utility has changed, adding two
more columns, which breaks the qemu-ifup script, as it was
depending on the last column being the interface name.

Change this from $NF to $5.

https://bugs.edge.launchpad.net/ubuntu/+source/qemu-kvm/+bug/430652

Signed-off-by: Dustin Kirkland <kirkland@canonical.com>
---
 kvm/scripts/qemu-ifup |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/kvm/scripts/qemu-ifup b/kvm/scripts/qemu-ifup
index 3bf8801..284b176 100755
--- a/kvm/scripts/qemu-ifup
+++ b/kvm/scripts/qemu-ifup
@@ -1,5 +1,5 @@
 #!/bin/sh
 
-switch=$(/sbin/ip route list | awk '/^default / { print $NF }')
+switch=$(/sbin/ip route list | awk '/^default / { print $5 }')
 /sbin/ifconfig $1 0.0.0.0 up
 /usr/sbin/brctl addif ${switch} $1
-- 
1.6.3.3



[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] update qemu-ifup for modern ip route output
  2009-09-17 20:38 [PATCH] update qemu-ifup for modern ip route output Dustin Kirkland
@ 2009-09-18 16:12 ` Marcelo Tosatti
  0 siblings, 0 replies; 2+ messages in thread
From: Marcelo Tosatti @ 2009-09-18 16:12 UTC (permalink / raw)
  To: Dustin Kirkland; +Cc: kvm

Applied, thanks.

On Thu, Sep 17, 2009 at 03:38:38PM -0500, Dustin Kirkland wrote:
> update qemu-ifup for modern ip route output
> 
> The output from the /sbin/ip utility has changed, adding two
> more columns, which breaks the qemu-ifup script, as it was
> depending on the last column being the interface name.
> 
> Change this from $NF to $5.
> 
> https://bugs.edge.launchpad.net/ubuntu/+source/qemu-kvm/+bug/430652
> 
> Signed-off-by: Dustin Kirkland <kirkland@canonical.com>
> ---
>  kvm/scripts/qemu-ifup |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/kvm/scripts/qemu-ifup b/kvm/scripts/qemu-ifup
> index 3bf8801..284b176 100755
> --- a/kvm/scripts/qemu-ifup
> +++ b/kvm/scripts/qemu-ifup
> @@ -1,5 +1,5 @@
>  #!/bin/sh
>  
> -switch=$(/sbin/ip route list | awk '/^default / { print $NF }')
> +switch=$(/sbin/ip route list | awk '/^default / { print $5 }')
>  /sbin/ifconfig $1 0.0.0.0 up
>  /usr/sbin/brctl addif ${switch} $1
> -- 
> 1.6.3.3
> 
> 



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-09-18 16:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-09-17 20:38 [PATCH] update qemu-ifup for modern ip route output Dustin Kirkland
2009-09-18 16:12 ` Marcelo Tosatti

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox