480 Commits

Author SHA1 Message Date
Jenkins
72854cc567 Merge "xenapi: enable block device access for stack user" 2013-09-05 11:52:55 +00:00
Jenkins
1800a8a1eb Merge "xenapi: README.md and embedded localrc updates" 2013-09-04 18:07:59 +00:00
Jenkins
9e597ec22d Merge "xenapi: Set VM memory before starting it" 2013-09-04 18:06:41 +00:00
Jenkins
9e2ba92d7a Merge "xenapi: add username to vncviewer command" 2013-09-04 18:06:27 +00:00
Jenkins
12f5009c29 Merge "xenapi: Increase default OS domU memory to 2G" 2013-09-04 16:17:01 +00:00
Jenkins
58afc72983 Merge "Move RHEL6 hacks to tools/fixup_stuff.sh" 2013-09-03 20:04:44 +00:00
Mate Lakat
bbf5623774 xenapi: README.md and embedded localrc updates
This change updates the readme, so that it is easier to get started, and
reflects the actual behavior of DevStack.

Changes in README.md:
 - Link to xenserver download page
 - Remove neutron interface - it is no longer installed by devstack
 - Add appendix with
   - How to use a different ubuntu mirror
   - How to use a proxy for ubuntu
   - How to re-use the created VM
 - Remove run from snapshot section and "do cloudy stuff"

Changes in the Readme-embedded sample localrc:
 - Upload a vhd image and a uec image by default - easier to get started

Change-Id: I13bb8e59ff5367ff7623fe9aa273886a957f81a7
2013-08-31 13:36:19 +01:00
Mate Lakat
4728001d01 xenapi: Increase default OS domU memory to 2G
In XenServer scenarios, an additional domU is created to run OpenStack
services. This change is increasing the memory for that VM to speed up
test runs.

Change-Id: I322f4e4703e506620fa7e7456c4264ee0d050edc
2013-08-31 12:12:46 +01:00
Dean Troyer
49ba22460b Move RHEL6 hacks to tools/fixup_stuff.sh
Change-Id: Ice983bc16379bc2bc25659c37cfc16b63fdfc34b
2013-08-30 15:20:59 -05:00
Mate Lakat
16ed068db5 xenapi: Set VM memory before starting it
If someone was re-using an existing template, for a memory change, he
needed to re-install the vm. This change sets the osdomu mem before
starting it, so it doesn't matter how much memory did the VM had
according to the template. It also removes the memory manipulation bits
from install-os-vpx.sh.

Change-Id: Iad85f573b90c23140012c20c552a17277d9c97a0
2013-08-30 14:21:10 +01:00
Mate Lakat
97621a1d1f xenapi: add username to vncviewer command
Devstack prints out an instruction, how to look at the virtual machine's
console. The command did not include the username, so if the user had a
config file to use a different username for that network, the command
failed.

Change-Id: I5dd49169c45e26e8d2bb3d5920a1b7fa584be50f
2013-08-30 13:12:17 +01:00
Mate Lakat
b1dc9bd5e4 xenapi: enable block device access for stack user
Although nova is setting the permissions on block devices, sometimes it
fails, and that results in an instance failing to launch. It is only an
issue for 3-part images, and images accessed through block devices. This
patch adds an udev rule, so that devices will be accessible.

fixes bug 1218251

Change-Id: I837ea515457fbfc50e9ce138ea9de9db12baa8be
2013-08-29 11:52:20 +01:00
Dean Troyer
2aa2a89cdb Add support for Docker as Nova hypervisor
* Add basic support for hypervisor plugins in lib/nova_plugins
* Add lib/nova_plugins/hypervisor-docker to use Docker as a Nova
  hypervisor.
* Add tools/install_docker.sh to install the Docker daemon and
  registry container, download base image and import
* Configure Nova to use docker plugin
* Add docker exercise and skip unsupported ones

Nova blueprint: new-hypervisor-docker

Change-Id: I9e7065b562dce2ce853def583ab1165886612227
2013-08-28 22:36:48 -05:00
Bob Ball
4669122dc8 Add XenServer to GetDistro's logic
This is primarily to satisfy the expectations of various scripts that os_*
variables are defined, and will result in a distro similar to "xs6.1.0-59235p"

Fixes bug 1211001

Change-Id: I951e1eb3a5e25f4d8773a11b15cf38157b6492fe
2013-08-13 21:51:41 +01:00
Jenkins
da2b6785fc Merge "xenapi: Use a jeos vm as a template" 2013-08-13 09:26:28 +00:00
Dean Troyer
9acc12a392 More Python package fixes
* Add tools/fixup_stuff.sh to fix prettytable and httplib2 install
  with pip 1.4+
* Cache downloads properly in tools/install_pip.sh

Change-Id: I482590cb91f7a10c1436bc9015afd572ac1cc73e
2013-08-10 16:44:17 -07:00
Dean Troyer
62d1d698a0 Add tools/install_pip.sh
Install a known working recent version of pip that handles installation
dependencies more correctly than before.  Extract to a separate script
so it can be used apart from stack.sh.

* Install distro setuptools if it not already present
* Install pip from source tarball as get-pip.py proved to be unreliable
* Remove python-distribute and python-pip from all prereq files,
  move python-setuptools to 'general'
* Remove the earlier unfubar_setuptppls() call that attenpted to fix this
* Only update requirements.txt when no changes in repo

Tested on Precise, F18 and CentOS6.
* Fedora and RHEL allow pip to install packages ON TOP OF RPM-installed
  packages.  THIS IS BROKEN.  And is one reason we have to be so picky
  about order and so forth.

Change-Id: Ibb4b42119dc2e51577c77bbbbffb110863e5324d
2013-08-07 20:28:56 -05:00
Jenkins
c31d192262 Merge "manage-vdi: Wait until devices have been created before mounting" 2013-07-31 14:48:21 +00:00
Mate Lakat
c02b2f87cc xenapi: Use a jeos vm as a template
DevStack was using templating to speed up the setup process with
XenServer. The template already included some devstack customisations,
not just a clean OS. This change modifies devstack behaviour, so that
the template is a simple clean operating system. This makes it easier to
use custom OS as a template, potentially speeding up the tests.

related to blueprint xenapi-devstack-cleanup

Change-Id: I6cb0a7ed7a90e749b78329a8e2b65fb8b7fcfa5f
2013-07-30 20:00:08 +01:00
Jenkins
e7559a479e Merge "xenapi: Uninstall instances" 2013-07-30 01:14:44 +00:00
Mate Lakat
0d97cbe2b5 xenapi: Uninstall instances
The devstack script sometimes failed to clean up the left over
instances. This patch will utilize the xe vm-uninstall force=true
command to get rid of the instances.

Change-Id: I3450e2d5c9a4b1fe8ede39c4cc5c337cd541ea35
2013-07-29 09:41:50 +01:00
Mate Lakat
abe56ee90f xenapi: Setup and Rotate text console logs
This patch installs the cronjob that rotates/sets up the text console
logs of the guests.

Related to blueprint xenapi-server-log

Change-Id: Ie4c778b54f69519fbb80aa0d9822383f55a1e2f9
2013-07-24 16:54:55 +01:00
Jenkins
1f0efadccf Merge "xenapi: preinstall python netaddr" 2013-07-15 16:19:23 +00:00
Jenkins
25d3ecf23e Merge "xenapi: xe network-attach for OVS bridge creation" 2013-07-15 15:03:22 +00:00
Jenkins
0ee1367a6d Merge "xenapi: Exit immediately if zipball download fails" 2013-07-15 14:03:27 +00:00
Mate Lakat
f34cb85135 xenapi: preinstall python netaddr
On our CI system, the devstack instance was reporting errors, that are
related to devstack's address_in_net function - that requires the python
netaddr library to be installed. This patch preinstalls this python
package.

Fixes bug 1097667

Change-Id: I8af199427f06cfdf0a68d96d87fe3e541199dca7
2013-07-12 17:11:07 +01:00
Euan Harris
a3ec804ad9 manage-vdi: Wait until devices have been created before mounting
kpartx creates partition devices asynchronously - it may exit before
the devices have been created.  This may cause a subsequent mount call
to fail, because the device it is trying to mount does not yet exist.
kpartx now has a -s option which makes it wait for the devices to be
created before returning, but the version XenServer's dom0 doesn't have
this option.   Work around this by retrying the mount.

When dom0's kpartx is updated, we will be able to use the -s option.

Change-Id: I823a8eac4f3a2ef313d06e21da0f38ed46d7386a
2013-07-11 15:50:32 +01:00
Euan Harris
6f0017161f xenapi: Exit immediately if zipball download fails
If install_os_domU.sh fails to download the Xapi plugins zipball
correctly it ignores the error and continues the installation.
This could damage the hypervisor's filesystem, as it may delete
files or overwrite them with garbage.

Change-Id: I9f6dc31b977592e2818e37b2d310c2a5dc477364
Fixes: bug #1195640
2013-07-11 12:05:44 +01:00
Jenkins
3c98af20fc Merge "devstack: Add paths specific to XenServer Core" 2013-07-10 20:30:39 +00:00
Mate Lakat
d8511034e6 xenapi: xe network-attach for OVS bridge creation
For Neutron we need an additional OVS bridge to be present. The xe
network-create command did not create the bridge immediately. A
workaround was applied to attach a network interface to that network,
forcing xapi to create the underlying OVS bridge. It turned out, that
the xe network-attach command could be used instead, so the workaround
is removed and replaced with the proper solution by this patch.

Fixes bug 1197305

Change-Id: I10cc763531b71238f0bc12a12de985f8f35d7e27
2013-07-10 15:48:52 +01:00
Euan Harris
12229a77a5 devstack: Add paths specific to XenServer Core
* XenServer Core keeps its Xapi plugins in a different path to XenServer,
   in order to comply with the Filesystem Hierarchy Standard.

 * XenServer Core mounts devices under /dev/xen/blktap-2 in dom0,
   whereas XenServer mounts them under /dev/sm.

Change-Id: I0a66cd03f000f19c8ff63a8ae4231c00fda88380
2013-07-10 14:05:22 +01:00
Jenkins
4ef0c71914 Merge "xenapi: cleanup VM Installation" 2013-07-09 00:13:30 +00:00
Mark McClain
b05c876994 update for name change to Neutron
Note: Nova and Horizon are not updated until those projects have
migrated.

Change-Id: I256ef20e7caadd9c96e6dd908c5d8b69ca5c4aeb
2013-07-07 00:15:11 -04:00
Jenkins
16bfac4e76 Merge "Fix spelling mistakes" 2013-07-02 14:19:30 +00:00
Joe Gordon
4640026cc1 Fix spelling mistakes
git ls-files | misspellings -f -
Source: https://github.com/lyda/misspell-check

Change-Id: I7d63578734ca5cc1ec865a7d024c1a013d1ada87
2013-06-30 04:32:27 -07:00
Jenkins
cf225101fb Merge "Create the /images directory used by the resize functionality." 2013-06-27 20:45:46 +00:00
Jenkins
4a6529ae37 Merge "xenapi: Cleanup networking" 2013-06-27 18:56:50 +00:00
Bob Ball
39aeda23b2 Create the /images directory used by the resize functionality.
XenServer's resize uses /images as a known-path for each hypervisor.
This is a symlink to the storage repository so disks can be moved between
the /images path and the storage repository efficiently.

Change-Id: I13b39dbf5537ad45160c1af4cc10bd867b7f89c1
2013-06-24 10:51:42 +01:00
Mate Lakat
2f524bd905 xenapi: cleanup VM Installation
VM installation created a machine with multiple network interfaces. This
is a needless complexity at that point, we only need one interface. This
change removes the complex network interface setup from
install-os-vpx.sh script, so that only one network interface is created,
which is connected to the selected network (management by default). This
change also removes a lot of non-used code from install-os-vpx.sh
Specify the network to be used for ubuntu netinstall with:

    UBUNTU_INST_BRIDGE_OR_NET_NAME

defaults to $MGT_BRIDGE_OR_NET_NAME.

This change also includes:
 - use precise as default

Related to blueprint xenapi-devstack-cleanup

Change-Id: Ib0a0a316e849f2c2651305ea657c84820cd2bb3b
2013-06-20 15:22:58 +01:00
Mate Lakat
5a56cd6283 xenapi: Cleanup networking
OpenStack VM had 4 interfaces, from which eth0 was connected to HIMN (Host
Internal Management Network), and not used at all. The reason for not
using this interface according to johngarbutt is:
 - VNC console would not work
 - migrations would not work
 - many other things
This change removes the interface, thus devstack is providing the
same architecture as described in the official documentation, YAGNI
applied on the HIMN:

    http://goo.gl/dmrNF

The change also modifies some defaults, so it's easier to get started:
 - The Ubuntu VM is network-installed through the management network
 - OS VM is getting its address on the management network through DHCP
 - Default Public IP addresses aligned to stack.sh defaults
 - OS Services are listening on Management Interface

Related to blueprint xenapi-devstack-cleanup

Change-Id: I73c9751ade6f4786b8b682a1994cb87f0a624379
2013-06-20 14:43:14 +01:00
Mate Lakat
68ac03c7f2 xenapi: separate disk for cinder volumes
Some kernels have lockup issues while serving cinder volumes from
file-loopback-lvm kind of cinder setup. This patch provides a way to
create an additional drive to the OpenStack VM, and use that to store
cinder volumes, thus eliminating the lockup issue. It will help when
testing XenServer. Now, you can specify devices for stack-volumes
through:

    VOLUME_BACKING_DEVICE

In case you are using CINDER_MULTI_LVM_BACKEND, you can use

    VOLUME_BACKING_DEVICE2

as well.

Xenserver:
Should you whish to use a 10 gig disk backend for your cinder volumes,
specify:

    XEN_XVDB_SIZE_GB=10
    VOLUME_BACKING_DEVICE=/dev/xvdb

Citrix is using this approach on its internal CI system to run tests
against OpenStack. This is a workaround for this bug:

  https://bugs.launchpad.net/cinder/+bug/1023755

Related to blueprint xenapi-devstack-cleanup

Change-Id: Iee633d2704185bfbf9234882654c47b850fa168a
2013-06-19 13:56:33 +01:00
Mate Lakat
8ff33ce75f xenapi: kernel_cmdline moved out from template
The kernel's cmdline was set during the initial devstack machine
installation. Thus, during second runs, the kernel's cmdline was not
updated. This patch extracts append_kernel_cmdline, and configures
domU's kernel cmdline every time. As some networking parameters are
passed through the kernel cmdline, this patch makes it possible to
change the network configuration, even if a cached devstack exists.

Related to blueprint xenapi-devstack-cleanup

Change-Id: I3b7175f4e83326c3e28825ac50625f6bd2a9a029
2013-05-31 10:45:46 +01:00
Mate Lakat
f652e0fb6d xenapi - quantum: L2 agents for dom0 and domU
This patch makes it easier to support the all-in-one installation of
XenServer with Quantum:
- separate agents for domU and dom0 openvswitches. The domU agent's name
  is "q-domua", and the dom0 agent is called "q-agt"
- create a physnet1 physical network to connect those openvswitches

Note: This patch depends on the quantum patch:

    https://review.openstack.org/15022

For a diagram, see:
    http://goo.gl/BuAdg

Change-Id: Iff851438553528b9051edd380ecbb2c0415cbf78
2013-05-24 18:23:53 +01:00
Mate Lakat
9e32677927 xenapi - cleanup network configuration
The Xenserver/XCP part of devstack was configuring the hypervisor's
connectivity to the outer world, by adding VLANs, and physical
interfaces to the virtual networks. It added a lot of complexity, and
made it hard to get started with XenServer. This patch removes that
extra complexity, so it is left as an exercise for the user.

Related to blueprint blueprint xenapi-devstack-cleanup

Change-Id: If3367335c3da8621d0afe1f6cae77511fbdbb3e2
2013-05-24 12:07:56 +01:00
Jenkins
b4057a4c50 Merge "xenapi - use management network to reach OS VM" 2013-05-24 11:04:04 +00:00
Mate Lakat
d3740f70b5 xenapi: Ubuntu installation repository/proxy fix
Get rid of UBUNTU_INST_REPOSITORY, use UBUNTU_INST_HTTP_HOSTNAME and
UBUNTU_INST_HTTP_DIRECTORY instead. User can also specify
UBUNTU_INST_HTTP_PROXY to utilize a proxy for the OpenStack VM
installation. The answer file will be edited to contain the specified
values. Also get rid of the magic, undocumented MIRROR variable.

This is related to blueprint xenapi-devstack-cleanup

Change-Id: Ic9fc564c4ad0f43e2e536854335ebe14791d0255
2013-05-14 11:37:07 +01:00
Mate Lakat
8644676846 xenapi - use management network to reach OS VM
Devstack used the HOST_IP_IFACE to reach the OpenStack VM through ssh.
This patch changes this behavior, so that the IP address of the
interface connected to the management network will be used.

Related to blueprint xenapi-devstack-cleanup

Change-Id: I7f34d973870792d60a33ea512901d9b0d422150b
2013-05-12 18:41:40 +01:00
Mate Lakat
0b3804bff7 xenapi - cleanup
Add error on unitialised variable to the scripts. This way some issues
were identified. Also modify README with fresh variables. The patch
includes:
 - Add SWIFT_HASH to the README
 - Add XENAPI_CONNECTION_URL to the README
 - Add VNCSERVER_PROXYCLIENT_ADDRESS to the README
 - Introduce UBUNTU_INST_IFACE which is the OpenStack VM interface used
   for the netinstall. It defaults to eth3. Previously this parameter
   was set by the combination of HOST_IP_IFACE and the undocumented
   NETINSTALL_IP
 - get rid of NETINSTALL_IP
 - xenrc includes CLEAN_TEMPLATES
 - xenrc no longer tries to change directory
 - remove chrooting from prepare_guest.sh (STAGING_DIR was always / )
 - remove DO_TGZ variable from prepare_guest.sh
 - use arguments to call prepare_guest.sh, instead of env vars
 - Fix backslash escaping in prepare_guest_template.sh

NOTE: networking is about to be addressed in a separate change.

Related to blueprint xenapi-devstack-cleanup

Change-Id: Ie9a75321c7f41cc9a0cc051398d1e6ec2c88adfa
2013-05-12 17:27:13 +01:00
Jenkins
d2930a5286 Merge "Correcting comment for HOST_IP_IFACE" 2013-05-01 07:41:14 +00:00
Bob Ball
2634be00b8 Correcting comment for HOST_IP_IFACE
Change-Id: I4c3438dc1168401c193841976cf8ba8534b33679
Fixes: bug #1174455
2013-04-29 23:35:57 +01:00