April 14, 2018

Install Openstack Labs

Openstack Training Labs is a python project that installs a new OpenStack cluster in two virtual machines. It is an easy way to provision a working deployment for testing/development purposes.

It works like docker-machine or boot2docker:

  • spawn two VM’s using a guest Hyper-visor (supports VirtualBox and KVM)
  • copy bash scripts in the machine and run it (this will install the OpenStack Components)
  • port-forward some services from the NAT provided by the Hyper-visor to the guest machine

All the documentation can be found here, it goes in greater details about the setup.

Step by Step Guide

Following the provided documentation on a

Install dependency

To use this project we need to have a few dependencies satisfied:


This will install the VirtualBox utility and a graphical Interface that we can use

~ $ sudo apt-get install virtualbox virtualbox-qt


~ $ sudo apt-get git

Python This is usually already installed in most distributions.

~ $ sudo apt-get install python2.7
Clone the project

The project is hosted on Gerrit but all the OpenStack project have mirrors on GitHub.

~ $ git clone https://github.com/openstack/training-labs.git
~ $ cd training-labs/labs

We need to use the latest release of OpenStack.(You can check the OpenStack releases here)

~ $ git checkout stable/queens
Start the cluster

We should have a tree structure like this

~ $ ls
autostart  config  lib  log  osbash  scripts  stacktrain  st.py  tests  tools  wbatch

We can run the provisioning with the following command

~ $ ./st.py --verbose --gui gui --provider virtualbox --build cluster

This process may take some time depending on your hardware and network speed.