aboutsummaryrefslogtreecommitdiffstats
path: root/tools/xm-test/configure.ac
diff options
context:
space:
mode:
authorstekloff@dyn9047022152.beaverton.ibm.com <stekloff@dyn9047022152.beaverton.ibm.com>2006-05-04 14:22:29 +0100
committerstekloff@dyn9047022152.beaverton.ibm.com <stekloff@dyn9047022152.beaverton.ibm.com>2006-05-04 14:22:29 +0100
commit38a79ca247c4cc96b73830cfdc3ba4b276769fcf (patch)
tree9ba18fb726f2e2dbac472fe59cf2106496509d98 /tools/xm-test/configure.ac
parent57a3f4ca825815cc639277ab1837984f88db0de8 (diff)
downloadxen-38a79ca247c4cc96b73830cfdc3ba4b276769fcf.tar.gz
xen-38a79ca247c4cc96b73830cfdc3ba4b276769fcf.tar.bz2
xen-38a79ca247c4cc96b73830cfdc3ba4b276769fcf.zip
Add new networking infrastructure to Xm-Test. The goal is to make
creating domains with networking very easy. This patch: 1) Adds new XenDevice class, with the XenNetDevice subclass. These classes represent devices for xm-test and are tied to XenDomains. This can eventually be used for block devices as well. Currently, devices must be added to domains prior to starting the domain. The attach and detach needs to be handled. 2) Adds a new NetConfig class to handle configuring the network environment in which the tests run. This patch only handles ranges of IPs in a bridged environment. DHCP needs to be added as well as handling NAT and routed environments. 3) Modifies XenDomain class to handle XenDevices. 4) Adds new configuration options for defining a range of IPs, their network address, and their netmask. 5) Removes the old Network.py and Network class. 6) Modifies the existing tests to use the new infrastructure. 7) Adds some documentation to help creating domains. Signed-off-by: Daniel Stekloff <dsteklof@us.ibm.com>
Diffstat (limited to 'tools/xm-test/configure.ac')
-rw-r--r--tools/xm-test/configure.ac30
1 files changed, 30 insertions, 0 deletions
diff --git a/tools/xm-test/configure.ac b/tools/xm-test/configure.ac
index c2e380cfe1..44d81b224e 100644
--- a/tools/xm-test/configure.ac
+++ b/tools/xm-test/configure.ac
@@ -38,6 +38,36 @@ fi
AM_CONDITIONAL(HVM, test x$ENABLE_HVM = xTrue)
AC_SUBST(ENABLE_HVM)
+# Network needs to know ips to use: dhcp or a range of IPs in the form
+# of: 192.168.1.1-192.168.1.100
+# If not dhcp, a netmask and network address must be supplied. Defaults to
+# zeroconf range.
+NET_IP_RANGE="169.254.0.1-169.254.255.255"
+AC_ARG_WITH(net-ip-range,
+ [ --with-net-ip-range=ip-range Set a range of ip addresses to use for xm-test guest domain networks. Can specify dhcp or a range of IPs: 192.168.1.1-192.168.1.100 [[default="169.254.0.1-169.254.255.255"]]],
+ [ NET_IP_RANGE="$withval" ])
+
+iprange=`echo $NET_IP_RANGE | perl -e 'while(<>) { print if /\d+\.\d+\.\d+\.\d+-\d+\.\d+\.\d+\.\d+/ }'`
+
+NETWORK_ADDRESS="169.254.0.0"
+AC_ARG_WITH(network-address,
+ [ --with-network-address=ip Set network address to use with ip range [[default="169.254.0.0"]]],
+ [ NETWORK_ADDRESS="$withval" ])
+
+NETMASK="255.255.0.0"
+AC_ARG_WITH(netmask,
+ [ --with-netmask=mask Set netmask to use with ip range [[default="255.255.0.0"]]],
+ [ NETMASK="$withval" ])
+
+if test "x$NET_IP_RANGE" != "xdhcp" && test -z "$iprange"
+then
+ AC_MSG_ERROR(Invalid net-ip-range.)
+fi
+
+AC_SUBST(NET_IP_RANGE)
+AC_SUBST(NETWORK_ADDRESS)
+AC_SUBST(NETMASK)
+
AC_ARG_WITH(hvm-kernel,
[[ --with-hvm-kernel=kernel Use this kernel for hvm disk.img testing]],
HVMKERNEL=$withval,