aboutsummaryrefslogtreecommitdiffstats
path: root/tools/examples/xend-config.sxp
diff options
context:
space:
mode:
authoremellor@leeni.uk.xensource.com <emellor@leeni.uk.xensource.com>2005-10-30 13:33:17 +0100
committeremellor@leeni.uk.xensource.com <emellor@leeni.uk.xensource.com>2005-10-30 13:33:17 +0100
commitaf374bc7d282588b703e12bf2c8cd1b312d2cf70 (patch)
tree1e706e6b188cf89bf7f34b1132ea8981e4408115 /tools/examples/xend-config.sxp
parent925293bc791850fd2b292c0c2d69c02022ac9551 (diff)
downloadxen-af374bc7d282588b703e12bf2c8cd1b312d2cf70.tar.gz
xen-af374bc7d282588b703e12bf2c8cd1b312d2cf70.tar.bz2
xen-af374bc7d282588b703e12bf2c8cd1b312d2cf70.zip
Added xen-script-common.sh, for functions common to all scripts, not just the
hotplug ones. Added evalVariables and findCommand functions to that, which we use to clarify the handling of variables being passed in as command line variables. Make vif-bridge able to find the bridge for itself if only one bridge is in use. This means that it is not necessary to specify a bridge in many configurations. Allow the bridge to be specified on the command line, meaning that a default may be provided in the xend-config.sxp if desired. Added xenstore_read_default to xen-hotplug-common.sh, which reads from the store but uses a given default if the path in the store is not present. This is used by vif-bridge to allow the store details (i.e. those given to xm create) to override the default value given in the xend-config.sxp. Remove vif-bridge setting -- the value can be specified on the vif-script command line if necessary. Added examples for network-nat/vif-nat. Added lots of big comments. Signed-off-by: Ewan Mellor <ewan@xensource.com>
Diffstat (limited to 'tools/examples/xend-config.sxp')
-rw-r--r--tools/examples/xend-config.sxp69
1 files changed, 56 insertions, 13 deletions
diff --git a/tools/examples/xend-config.sxp b/tools/examples/xend-config.sxp
index ba433cd745..13c38de24e 100644
--- a/tools/examples/xend-config.sxp
+++ b/tools/examples/xend-config.sxp
@@ -48,19 +48,62 @@
# The limit (in kilobytes) on the size of the console buffer
#(console-limit 1024)
-## Use the following if VIF traffic is routed.
-# The script used to start/stop networking for xend.
-#(network-script network-route)
-# The default script used to control virtual interfaces.
-#(vif-script vif-route)
-
-## Use the following if VIF traffic is bridged.
-# The script used to start/stop networking for xend.
-(network-script network-bridge)
-# The default bridge that virtual interfaces should be connected to.
-(vif-bridge xenbr0)
-# The default script used to control virtual interfaces.
-(vif-script vif-bridge)
+##
+# To bridge network traffic, like this:
+#
+# dom0: fake eth0 -> vif0.0 -+
+# |
+# bridge -> real eth0 -> the network
+# |
+# domU: fake eth0 -> vifN.0 -+
+#
+# use
+#
+# (network-script network-bridge)
+#
+# Your eth0 is used as the outgoing interface, by default. To use a different
+# one (e.g. eth1) use
+#
+# (network-script 'network-bridge netdev=eth1')
+#
+# The bridge is named xenbr0, by default. To rename the bridge, use
+#
+# (network-script 'network-bridge bridge=<name>')
+#
+# It is possible to use the network-bridge script in more complicated
+# scenarios, such as having two outgoing interfaces, with two bridges, and
+# two fake interfaces per guest domain. To do things like this, write
+# yourself a wrapper script, and call network-bridge from it, as appropriate.
+#
+(network-script network-bridge)
+
+# The script used to control virtual interfaces. This can be overridden on a
+# per-vif basis when creating a domain or a configuring a new vif. The
+# vif-bridge script is designed for use with the network-bridge script, or
+# similar configurations.
+#
+# If you have overridden the bridge name using
+# (network-script 'network-bridge bridge=<name>') then you may wish to do the
+# same here. The bridge name can also be set when creating a domain or
+# configuring a new vif, but a value specified here would act as a default.
+#
+# If you are using only one bridge, the vif-bridge script will discover that,
+# so there is no need to specify it explicitly.
+#
+(vif-script vif-bridge)
+
+
+## Use the following if network traffic is routed, as an alternative to the
+# settings for bridged networking given above.
+#(network-script network-route)
+#(vif-script vif-route)
+
+
+## Use the following if network traffic is routed with NAT, as an alternative
+# to the settings for bridged networking given above.
+#(network-script network-nat)
+#(vif-script vif-nat)
+
# Dom0 will balloon out when needed to free memory for domU.
# dom0-min-mem is the lowest memory level (in MB) dom0 will get down to.