OpenStack and quick PoC deployment using PackStack on CentOS7 and DevStack on Ubuntu


OpenStack and quick PoC deployment using PackStack on CentOS7 and DevStack on Ubuntu

At TEKYHOST we provide OpenStack consulting for Private and Public deployments

Introduction to OpenStack

OpenStack is a set of software tools for building and managing cloud computing platforms for public and private clouds. Backed by some of the biggest companies in software development and hosting, as well as thousands of individual community members, many think that OpenStack is the future of cloud computing. OpenStack is managed by the OpenStack Foundation, a non-profit that oversees both development and community-building around the project.

And most importantly, OpenStack is open source software, which means that anyone who chooses to can access the source code, make any changes or modifications they need, and freely share these changes back out to the community at large.

OpenStack components

Nova is the primary computing engine behind OpenStack. It is used for deploying and managing large numbers of virtual machines and other instances to handle computing tasks
Swift is a storage system for objects and files. Rather than the traditional idea of a referring to files by their location on a disk drive, developers can instead refer to a unique identifier referring to the file or piece of information and let OpenStack decide where to store this information. This makes scaling easy, as developers don’t have the worry about the capacity on a single system behind the software. It also allows the system, rather than the developer, to worry about how best to make sure that data is backed up in case of the failure of a machine or network connection.
Cinder is a block storage component, which is more analogous to the traditional notion of a computer being able to access specific locations on a disk drive. This more traditional way of accessing files might be important in scenarios in which data access speed is the most important consideration.
Neutron provides the networking capability for OpenStack. It helps to ensure that each of the components of an OpenStack deployment can communicate with one another quickly and efficiently.
Horizon is the dashboard behind OpenStack. It is the only graphical interface to OpenStack, so for users wanting to give OpenStack a try, this may be the first component they actually “see.” Developers can access all of the components of OpenStack individually through an application programming interface (API), but the dashboard provides system administrators a look at what is going on in the cloud, and to manage it as needed.
Keystone provides identity services for OpenStack. It is essentially a central list of all of the users of the OpenStack cloud, mapped against all of the services provided by the cloud, which they have permission to use. It provides multiple means of access, meaning developers can easily map their existing user access methods against Keystone.
Glance provides image services to OpenStack. In this case, “images” refers to images (or virtual copies) of hard disks. Glance allows these images to be used as templates when deploying new virtual machine instances.
Ceilometer provides telemetry services, which allow the cloud to provide billing services to individual users of the cloud. It also keeps a verifiable count of each user’s system usage of each of the various components of an OpenStack cloud. Think metering and usage reporting.

OpenStack competitors within open-source community


Deploying OpenStack with RDO and PackStack

In this article we will show you quick and easy way to deploy OpenStack as PoC(Proof of Concept). We will be using RDO and CentsOS 7 for this tutorial. RDO is a community of people using and deploying OpenStack on CentOS and Red Hat Linux. We will be using packstack installation utility which is Puppet based installation utility
We will be deploying pike current pike release

1. We installed minimum CentOS 7 ON hardware system with 16GB RAM, processors with hardware virtualization extensions, and 2 network adapters
2. Disable network manager and assight static IP to one of network interfaces

systemctl disable NetworkManager
systemctl stop NetworkManager
systemctl enable network
systemctl start network

3. Disable firewalld

Systemctl disable firewalld

4 disable selinux

Vi /etc/selinux

5 set hostname for our openstacl poc server

hostnamectl set-hostname openstackpoc.local

9. Reboot your system after all above steps are done.


Lets download and install all necessary RDP repository

yum install -y
yum install -y centos-release-openstack-pike

Enable repositories

Yum install yum-utils
yum-config-manager --enable openstack-pike

Run update on current packages

Yum update -y

Install packstack installer

yum install -y openstack-packstack


packstack --allinone

Running an instance

. demo-openrc
openstack flavor list
openstack image list
openstack network list
openstack security group list

Create an instance

openstack server create --flavor m1.nano --image cirros \
  --nic net-id=PROVIDER_NET_ID --security-group default \
  --key-name mykey provider-instance

OpenStack with Ubuntu DevStack

OpenStack has a very complex architectural design to understand. It consist of many different components and modules. All this makes it hard for beginner to understand. We already looked at quick deployment with PackStack on CentOS. Now lets look at deploying OpenStack with DevStack which is Ubuntu based implementation of all in one OpenStack for testing purposes.

We have Ubuntu 16.04 LTS server VM runnign on Virtual box.

  • 6GB RAM
  • 30G hard disk
  • 2 NIC in bridged mode
  • 2CPU
  • As this is just a demo , NIC’s configured to be on the same network in our case

    # The primary network interface
    auto enp0s3
    iface enp0s3 inet dhcp
    # second network interface 
    auto enp0s8
    iface enp0s8 inet dhcp

    Update system before we start

    sudo apt-get update

    Setup user that will run installation and give this use sudo rights without password

    sudo useradd -s /bin/bash -d /opt/stack -m stack
    echo "stack ALL=(ALL) NOPASSWD: ALL" | sudo tee /etc/sudoers.d/stack

    Login as a stack user

    sudo su - stack

    Lets get DevStack octa

    sudo apt-get install -y git-core
    git clone -b stable/ocata

    No we will do some configuration before we start install.

    cd devstack
    git checkout stable/ocata
    cp samples/local.conf .
    echo "HOST_IP=${HOST_IP}" >> local.conf

    If you go through your local.conf environment file you could change the hard-coded admin and database passwords in the local.conf file.
    Now run install


    After installation complete you can connect to your new OpenStack

    DevStack useful commands

    Rerunning installation after reboot


    Stop OpenStack servces


    Remove DevStack


    About the author