All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] network-script: use default network device
@ 2006-01-31 17:32 Bill Nottingham
  2006-02-10  1:12 ` Ewan Mellor
  0 siblings, 1 reply; 2+ messages in thread
From: Bill Nottingham @ 2006-01-31 17:32 UTC (permalink / raw)
  To: xen-devel

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

(Warning: I'm not subscribed, please CC me on replies...)

Rather than require config changes if you aren't using eth0, use the
default network device available no matter the name. It can still
be configured if you want a specific network device.

Bill

[-- Attachment #2: xen-default-network.patch --]
[-- Type: text/plain, Size: 1703 bytes --]

diff -ru xen-3.0.0/tools/examples/network-bridge xen-3.0.0-new/tools/examples/network-bridge
--- xen-3.0.0/tools/examples/network-bridge	2006-01-25 15:30:13.000000000 -0500
+++ xen-3.0.0-new/tools/examples/network-bridge	2006-01-31 12:20:25.000000000 -0500
@@ -61,6 +61,7 @@
 
 vifnum=${vifnum:-0}
 bridge=${bridge:-xenbr${vifnum}}
+netdev=${netdev:-$(ip route list default scope global| awk '{ print $NF }')}
 netdev=${netdev:-eth${vifnum}}
 antispoof=${antispoof:-no}
 
diff -ru xen-3.0.0/tools/examples/xend-config.sxp xen-3.0.0-new/tools/examples/xend-config.sxp
--- xen-3.0.0/tools/examples/xend-config.sxp	2006-01-31 12:23:38.000000000 -0500
+++ xen-3.0.0-new/tools/examples/xend-config.sxp	2006-01-31 12:24:44.000000000 -0500
@@ -70,8 +70,8 @@
 #
 # (network-script network-bridge)
 #
-# Your eth0 is used as the outgoing interface, by default.  To use a different
-# one (e.g. eth1) use
+# Your default ethernet device is used as the outgoing interface, by default. 
+# To use a different one (e.g. eth1) use
 #
 # (network-script 'network-bridge netdev=eth1')
 #
diff -ru xen-3.0.0/tools/examples/xend-config.sxp.mem-min xen-3.0.0-new/tools/examples/xend-config.sxp.mem-min
--- xen-3.0.0/tools/examples/xend-config.sxp.mem-min	2006-01-06 17:42:59.000000000 -0500
+++ xen-3.0.0-new/tools/examples/xend-config.sxp.mem-min	2006-01-31 12:25:13.000000000 -0500
@@ -70,8 +70,8 @@
 #
 # (network-script network-bridge)
 #
-# Your eth0 is used as the outgoing interface, by default.  To use a different
-# one (e.g. eth1) use
+# Your default ethernet device is used as the outgoing interface, by default.
+# To use a different one (e.g. eth1) use
 #
 # (network-script 'network-bridge netdev=eth1')
 #

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

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

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

end of thread, other threads:[~2006-02-10  1:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-01-31 17:32 [PATCH] network-script: use default network device Bill Nottingham
2006-02-10  1:12 ` Ewan Mellor

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.