ia64/xen-unstable

annotate tools/examples/xend-config.sxp @ 7557:4722eae11abb

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>
author emellor@leeni.uk.xensource.com
date Sun Oct 30 13:33:17 2005 +0100 (2005-10-30)
parents cefe36be8592
children a51ec6d425e7
rev   line source
emellor@7467 1 # -*- sh -*-
emellor@7467 2
emellor@7467 3 #
mjw@1723 4 # Xend configuration file.
emellor@7467 5 #
mjw@1723 6
emellor@7467 7 # This example configuration is appropriate for an installation that trusts
emellor@7467 8 # only localhost connections, and is otherwise fully functional, with a
emellor@7467 9 # bridged network configuration.
emellor@7467 10
emellor@7467 11 # Commented out entries show the default for that entry, unless otherwise
emellor@7467 12 # specified.
emellor@7467 13
emellor@7467 14 #(logfile /var/log/xend.log)
emellor@7467 15 #(loglevel DEBUG)
mjw@1723 16
emellor@7467 17 #(xend-http-server no)
emellor@7467 18 (xend-http-server yes)
emellor@7467 19 #(xend-unix-server yes)
emellor@7467 20 #(xend-relocation-server no)
emellor@7467 21 (xend-relocation-server yes)
emellor@7467 22
emellor@7467 23 #(xend-unix-path /var/lib/xend/xend-socket)
mjw@4095 24
emellor@7467 25 # Port xend should use for the HTTP interface, if xend-http-server is set.
emellor@7467 26 #(xend-port 8000)
emellor@7467 27
emellor@7467 28 # Port xend should use for the event interface. This interface is deprecated.
emellor@7467 29 #(xend-event-port 8001)
emellor@7467 30
emellor@7467 31 # Port xend should use for the relocation interface, if xend-relocation-server
emellor@7467 32 # is set.
emellor@7467 33 #(xend-relocation-port 8002)
emellor@7467 34
emellor@7467 35 # Address xend should listen on for HTTP connections, if xend-http-server is
emellor@7467 36 # set.
mjw@1723 37 # Specifying 'localhost' prevents remote connections.
emellor@7467 38 # Specifying the empty string '' (the default) allows all connections.
emellor@7467 39 #(xend-address '')
emellor@7467 40 (xend-address localhost)
mjw@1723 41
emellor@7467 42 # Address xend should listen on for relocation-socket connections, if
emellor@7467 43 # xend-relocation-server is set.
emellor@7467 44 # Meaning and default as for xend-address above.
emellor@7467 45 #(xend-relocation-address '')
emellor@7467 46 (xend-relocation-address localhost)
mjw@4095 47
emellor@7441 48 # The limit (in kilobytes) on the size of the console buffer
emellor@7467 49 #(console-limit 1024)
emellor@7441 50
emellor@7557 51 ##
emellor@7557 52 # To bridge network traffic, like this:
emellor@7557 53 #
emellor@7557 54 # dom0: fake eth0 -> vif0.0 -+
emellor@7557 55 # |
emellor@7557 56 # bridge -> real eth0 -> the network
emellor@7557 57 # |
emellor@7557 58 # domU: fake eth0 -> vifN.0 -+
emellor@7557 59 #
emellor@7557 60 # use
emellor@7557 61 #
emellor@7557 62 # (network-script network-bridge)
emellor@7557 63 #
emellor@7557 64 # Your eth0 is used as the outgoing interface, by default. To use a different
emellor@7557 65 # one (e.g. eth1) use
emellor@7557 66 #
emellor@7557 67 # (network-script 'network-bridge netdev=eth1')
emellor@7557 68 #
emellor@7557 69 # The bridge is named xenbr0, by default. To rename the bridge, use
emellor@7557 70 #
emellor@7557 71 # (network-script 'network-bridge bridge=<name>')
emellor@7557 72 #
emellor@7557 73 # It is possible to use the network-bridge script in more complicated
emellor@7557 74 # scenarios, such as having two outgoing interfaces, with two bridges, and
emellor@7557 75 # two fake interfaces per guest domain. To do things like this, write
emellor@7557 76 # yourself a wrapper script, and call network-bridge from it, as appropriate.
emellor@7557 77 #
emellor@7557 78 (network-script network-bridge)
kaf24@3431 79
emellor@7557 80 # The script used to control virtual interfaces. This can be overridden on a
emellor@7557 81 # per-vif basis when creating a domain or a configuring a new vif. The
emellor@7557 82 # vif-bridge script is designed for use with the network-bridge script, or
emellor@7557 83 # similar configurations.
emellor@7557 84 #
emellor@7557 85 # If you have overridden the bridge name using
emellor@7557 86 # (network-script 'network-bridge bridge=<name>') then you may wish to do the
emellor@7557 87 # same here. The bridge name can also be set when creating a domain or
emellor@7557 88 # configuring a new vif, but a value specified here would act as a default.
emellor@7557 89 #
emellor@7557 90 # If you are using only one bridge, the vif-bridge script will discover that,
emellor@7557 91 # so there is no need to specify it explicitly.
emellor@7557 92 #
emellor@7557 93 (vif-script vif-bridge)
emellor@7557 94
emellor@7557 95
emellor@7557 96 ## Use the following if network traffic is routed, as an alternative to the
emellor@7557 97 # settings for bridged networking given above.
emellor@7557 98 #(network-script network-route)
emellor@7557 99 #(vif-script vif-route)
emellor@7557 100
emellor@7557 101
emellor@7557 102 ## Use the following if network traffic is routed with NAT, as an alternative
emellor@7557 103 # to the settings for bridged networking given above.
emellor@7557 104 #(network-script network-nat)
emellor@7557 105 #(vif-script vif-nat)
emellor@7557 106
mjw@1723 107
kaf24@5932 108 # Dom0 will balloon out when needed to free memory for domU.
kaf24@5932 109 # dom0-min-mem is the lowest memory level (in MB) dom0 will get down to.
kaf24@5932 110 # If dom0-min-mem=0, dom0 will never balloon out.
kaf24@5932 111 (dom0-min-mem 0)
kaf24@5932 112
cl349@6916 113 # In SMP system, dom0 will use dom0-cpus # of CPUS
kaf24@5932 114 # If dom0-cpus = 0, dom0 will take all cpus available
kaf24@5932 115 (dom0-cpus 0)
emellor@7467 116
emellor@7467 117 # Whether to enable core-dumps when domains crash.
emellor@7467 118 #(enable-dump no)