OpenStack is a free, open source platform developed specifically for cloud computing. Through this cloud-centric platform, virtual machines and other resources can be made available to clients as Infrastructure-as-a-Service. There are a number of ways to get OpenStack installed–some are much more challenging than others.
One such means of installing OpenStack is through DevStack. DevStack is a series of scripts that are used to bring up a complete OpenStack environment based on the latest version. Although installing with DevStack might be one of the easiest methods of installing OpenStack, it does take some time (30-60 minutes). I’m going to walk you through the process of installing OpenStack, via DevStack. I’ll do so on the Ubuntu Server 16.04 platform, although the process should work on nearly any Linux server distribution.
Let’s get right to it.
Installation
The first thing you must do is create a new non-root user that can be used for the installation. Open up a terminal window and issue the command:
sudo useradd -s /bin/bash -d /opt/stack -m stack
Give that user sudo privileges with the command:
echo "stack ALL=(ALL) NOPASSWD: ALL" | sudo tee /etc/sudoers.d/stack
Change to that user with the command:
sudo su - stack
Next we’ll checkout Devstack from Github. First install git with the command:
sudo apt install git
Now you can checkout DevStack (we’ll use the most recent stable version, queens) with the command:
git clone https://github.com/openstack-dev/devstack.git -b stable/queens devstack/
This will create a new directory, devstack. Change into that directory with the command cd devstack.
Before you issue the installation command, you need to configure the local.conf file. Open this file with the command nano local.conf. Make sure that contains the following:
HOST_IP=SERVER_IP
SERVICE_PASSWORD=PASSWORD
ADMIN_PASSWORD=PASSWORD
SERVICE_TOKEN=PASSWORD
DATABASE_PASSWORD=PASSWORD
RABBIT_PASSWORD=PASSWORD
ENABLE_HTTPD_MOD_WSGI_SERVICES=True
KEYSTONE_USE_MOD_WSGI=True
# Logging
LOGFILE=$DEST/logs/stack.sh.log
VERBOSE=True
ENABLE_DEBUG_LOG_LEVEL=True
ENABLE_VERBOSE_LOG_LEVEL=True
GIT_BASE=${GIT_BASE:-git://git.openstack.org}
TACKER_MODE=standalone
USE_BARBICAN=True
TACKER_BRANCH=enable_plugin networking-sfc ${GIT_BASE}/openstack/networking-sfc $TACKER_BRANCH
enable_plugin barbican ${GIT_BASE}/openstack/barbican $TACKER_BRANCH
enable_plugin mistral ${GIT_BASE}/openstack/mistral $TACKER_BRANCH
enable_plugin tacker ${GIT_BASE}/openstack/tacker $TACKER_BRANCH
You need to replace each instance of PASSWORD with a unique and challenging password, and SERVER_IP with the IP address of your OpenStack server. Once you’ve done that, save and close the file.
Now we run the command for the installation. That command is ./stack.sh. This is where the installation takes a significant amount of time. You can expect this command to take between 30-60 minutes to complete, so take care of some other tasks while it works its magic.
Logging in
Once the installation completes, open up a web browser that’s on the same network as your OpenStack server and point it to http://SERVER_IP/dashboard (where SERVER_IP is the IP address of your OpenStack server). You should be greeted by the login window (Figure A). Log in with the username admin and the password you used in the local.conf configuration file.
Figure A
At this point, you can being working with OpenStack (Figure B). Manage the installation, create new projects, and manage users and groups.
Figure B
Get your cloud on
You can now get your cloud on, thanks to DevStack and OpenStack. Although this method might take a bit of time, it’s significantly easier than installing OpenStack manually. Give this a try and see if it finally makes OpenStack a possibility for you.