Skip to content

Commit a3170fb

Browse files
Jenkinsopenstack-gerrit
authored andcommitted
Merge "Script for Ubuntu 11.10 on Xenserver"
2 parents 542067b + 4c88934 commit a3170fb

File tree

2 files changed

+47
-0
lines changed

2 files changed

+47
-0
lines changed

tools/xen/README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,3 +100,9 @@ Step 6: Do cloudy stuff!
100100
* Play with horizon
101101
* Play with the CLI
102102
* Log bugs to devstack and core projects, and submit fixes!
103+
104+
Ubuntu 11.10 VM on Xenserver
105+
----------------------------
106+
Run ./scripts/xenoneirictemplate.sh on your Xenserver host. This creates a
107+
template to be able to install a Ubuntu Oneiric (11.10) virtual machine.
108+
Once the template is created, follow the wizard to complete the network install.
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
#!/bin/bash
2+
## makeubuntu.sh, this creates Ubuntu server 11.10 32 and 64 bit templates
3+
## on Xenserver 6.0.2 Net install only
4+
## Original Author: David Markey <david.markey@citrix.com>
5+
## Author: Renuka Apte <renuka.apte@citrix.com>
6+
## This is not an officially supported guest OS on XenServer 6.02
7+
8+
LENNY=$(xe template-list name-label=Debian\ Lenny\ 5.0\ \(32-bit\) --minimal)
9+
10+
if [[ -z $LENNY ]] ; then
11+
echo "Cant find lenny 32bit template, is this on 6.0.2?"
12+
exit 1
13+
fi
14+
15+
distro="Ubuntu 11.10"
16+
arches=("32-bit" "64-bit")
17+
18+
19+
for arch in ${arches[@]} ; do
20+
echo "Attempting $distro ($arch)"
21+
if [[ -n $(xe template-list name-label="$distro ($arch)" params=uuid --minimal) ]] ; then
22+
echo "$distro ($arch)" already exists, Skipping
23+
else
24+
25+
NEWUUID=$(xe vm-clone uuid=$LENNY new-name-label="$distro ($arch)")
26+
xe template-param-set uuid=$NEWUUID other-config:install-methods=http,ftp \
27+
other-config:install-repository=http://archive.ubuntu.net/ubuntu \
28+
PV-args="-- quiet console=hvc0 partman/default_filesystem=ext3 locale=en_US console-setup/ask_detect=false keyboard-configuration/layoutcode=us netcfg/choose_interface=eth3 netcfg/get_hostname=unassigned-hostname netcfg/get_domain=unassigned-domain auto url=http://images.ansolabs.com/devstackubuntupreseed.cfg" \
29+
other-config:debian-release=oneiric \
30+
other-config:default_template=true
31+
32+
if [[ "$arch" == "32-bit" ]] ; then
33+
xe template-param-set uuid=$NEWUUID other-config:install-arch="i386"
34+
else
35+
xe template-param-set uuid=$NEWUUID other-config:install-arch="amd64"
36+
fi
37+
echo "Success"
38+
fi
39+
done
40+
41+
echo "Done"

0 commit comments

Comments
 (0)