Upgrade testing of OpenStack projects built on top of DevStack.
Go to file
Joe Gordon 97fea9b267 Add upgrade-horizon
Upgrade horizon along with the rest of devstack before running new
devstack tests and tempest.

upgrade-horizon is based off of upgrade-keystone.

Change-Id: I6a6e4da06806cb840d7af673673e06f34eb297e0
Related-Bug: #1265057
(cherry picked from commit e9546e66e6)
2014-02-11 14:17:05 +11:00
from-grizzly Add upgrade-horizon 2014-02-11 14:17:05 +11:00
.gitignore Add a .gitignore file. 2013-03-26 13:07:05 -04:00
.gitreview open up stable/havana branch 2013-10-18 12:00:21 -04:00
HACKING.rst Update functions file from DevStack 2013-03-15 15:57:03 -05:00
LICENSE Initial repo setup 2012-08-03 17:07:12 -05:00
README.rst Cut over to grizzly -> havana 2013-05-02 14:43:41 -05:00
TODO.rst Change terms 2013-01-23 15:50:42 -06:00
check-sanity Cut over to grizzly -> havana 2013-05-02 14:43:41 -05:00
clean.sh cleanup: change to default ubuntu package service 2013-05-22 09:37:26 -03:00
devstack.localrc.base Cut over to grizzly -> havana 2013-05-02 14:43:41 -05:00
devstack.localrc.example add devstack.localrc.example 2013-03-26 10:42:39 -04:00
devstack.localrc.target Cut over to grizzly -> havana 2013-05-02 14:43:41 -05:00
functions Add upgrade-horizon 2014-02-11 14:17:05 +11:00
grenade.sh Add upgrade-horizon 2014-02-11 14:17:05 +11:00
grenaderc add oslo and infra from git to the upgrade 2013-08-05 14:14:23 -04:00
javelin.conf Create volume in javelin config 2012-08-31 10:04:05 -05:00
javelinrc Change terms 2013-01-23 15:50:42 -06:00
prep-base cliff 1.4.5 workaround 2013-09-24 08:14:01 -04:00
prep-target Combine localrc files 2013-04-05 10:45:28 -05:00
save-state Fix save state error, don't save swift Mysql db. 2013-05-17 12:43:32 +08:00
setup-grenade Fix setup-grenade to pass user and host as parameter 2013-05-03 15:32:19 -03:00
setup-javelin Cut over to grizzly -> havana 2013-05-02 14:43:41 -05:00
stop-base Guarantee swift process are ended after base run 2013-05-29 10:19:10 -04:00
upgrade-cinder Add Cinder API v2 to Keystone catalog 2013-08-29 10:29:32 -05:00
upgrade-devstack Preserve devstack/accrc files 2013-08-21 05:53:25 +02:00
upgrade-glance Install the new schema-image.json 2013-09-10 18:49:14 +02:00
upgrade-horizon Add upgrade-horizon 2014-02-11 14:17:05 +11:00
upgrade-infra add oslo and infra from git to the upgrade 2013-08-05 14:14:23 -04:00
upgrade-keystone Source lib/tls in upgrade-keystone 2013-10-04 11:58:21 +10:00
upgrade-nova add nova v3 api support in upgrade 2013-08-19 16:19:11 +08:00
upgrade-oslo add oslo and infra from git to the upgrade 2013-08-05 14:14:23 -04:00
upgrade-packages Change terms 2013-01-23 15:50:42 -06:00
upgrade-swift Cut over to grizzly -> havana 2013-05-02 14:43:41 -05:00
upgrade-tempest Change from quantum to neutron on upgrading 2013-07-08 13:57:05 -04:00

README.rst

Grenade

Grenade is an OpenStack test harness to exercise the upgrade process between releases. It uses DevStack to perform an initial OpenStack install and as a reference for the final configuration. Currently Grenade upgrades Keystone, Glance, Nova, Cinder and Swift in their default DevStack configurations.

The master branch tests the upgrade path from the previous release (aka 'base') to the current trunk (aka 'target'). Stable branches of Grenade will be created soon after an OpenStack release and after a corresponding DevStack stable branch is available.

For example, following the release of Grizzly and the creation of DevStack's stable/grizzly branch a similar stable/grizzly branch of Grenade will be created. At that time master will be re-worked to base on Grizzly and the cycle will continue.

Goals

Continually test the upgrade process between OpenStack releases to find issues as they are introduced so they can be fixed immediately.

Status

Preparations are ongoing to add Grenade as a non-voting job in the OpenStack CI Jenkins.

  • Testing of the 'javelin' project artifacts is incomplete

Process

  • Install base OpenStack using current stable/<base-release> DevStack
  • Perform basic testing (exercise.sh)
  • Create some artifacts in a new project ('javelin') for comparison after the upgrade process.
  • Install current target DevStack to support the upgrades
  • Run upgrade scripts preserving (running?) instances and data

Terminology

Grenade has two DevStack installs present and distinguished between then as 'base' and 'target'.

  • Base: The initial install that will be upgraded.
  • Target: The reference install of target OpenStack (maybe just DevStack)

Directory Structure

Grenade creates a set of directories for both the base and target OpenStack installation sources and DevStack.

$STACK_ROOT

- <base> | - <target> | |- swift

Install Grenade

Get Grenade from GitHub in the usual way:

git clone https://github.com/openstack-dev/grenade.git

Grenade knows how to install the current master branch using the included setup-grenade script. The only argument is the hostname of the target system that will run the upgrade testing.

./setup-grenade testbox

The Grenade repo and branch used can be changed by adding something like this to localrc:

GRENADE_REPO=git@github.com:dtroyer/grenade.git
GRENADE_BRANCH=dt-test

Grenade includes devstack.localrc.base and devstack.localrc.target for DevStack that are used to customize its behaviour for use with Grenade. If $BASE_DEVSTACK_DIR/localrc does not exist the following is performed by prep-base:

  • devstack.localrc.base is copied to to $BASE_DEVSTACK_DIR/localrc
  • if devstack.localrc exists it is appended $BASE_DEVSTACK_DIR/localrc

Similar steps are performed by prep-target for $TARGET_DEVSTACK_DIR.

devstack.localrc will be appended to both DevStack localrc files if it exists. devstack.localrc is not included in Grenade and will not be overwritten it if it exists.

To handle differences between the DevStack releases GRENADE_PHASE will be set to base or target so appropriate decisions can be made:

if [[ "$GRENADE_PHASE" == "base" ]]; then
    # Handle base-specific local
    :
else
    # Handle target-specific local
    :
fi

Prepare For An Upgrade Test

./grenade.sh

grenade.sh installs DevStack for the Base release and runs its stack.sh. Then it creates a 'javelin' project containing some non-default configuration.

This is roughly the equivalent to:

grenade/prep-base
(cd /opt/stack/grizzly/devstack
 ./stack.sh)
grenade/setup-javelin
(cd /opt/stack/grizzly/devstack
 ./unstack.sh)
# dump databases to $STACK_ROOT/save
grenade/prep-target
grenade/upgrade-packages
grenade/upgrade-devstack
grenade/upgrade-keystone
grenade/upgrade-glance
grenade/upgrade-nova
grenade/upgrade-cinder
grenade/upgrade-swift

The Target release of DevStack is installed in a different directory from the Base release.

While the Base release is running an imaginary Javelin tenant is configured to populate the databases with some non-default content:

grenade/setup-javelin

Set up the javelin credentials with javelinrc.

Testing Upgrades

The upgrade-* scripts are the individual components of the DevStack/Grenade upgrade process. They typically stop any running processes, checkout updated sources, migrate the database, any other tasks that need to be done then start the processes in screen.

These scripts are written to be idmpotent.