TheDotProduct

Web-tech nerd stuff

Quick tutorial: installing Openstack as all-in-one using Stackops

I’ve recently been working on lots of trial-runs of software at work and got annoyed with having to rebuild servers all the time so i decided to join the rest of the world and go virtual. Our production VI at work runs VMWare (ESXi) but my trial stack was going to be a no-budget affair so I took the opportunity to try out Openstack which I’d been meaning to do for quite some time. If you’ve not come across Openstack previously, it’s a project which started at NASA and has moved over to be open source which provides pretty much all the base software you need to run a VI (cloud).

After having read a load of the install documentation on Openstack, I decided it looked pretty complex (and I still hold that view). Consequently, I looked for an installer script/application for Openstack and found the go-to installer of choice for many, devstack. After playing with devstack for a little while I actually liked it a lot, I have one major beef with it though, as default devstack configures the storage for keystone (the authentication mechanism for Openstack) to use non-persistent storage. This may be fine for very simple test purposes but I found out to my peril that user accounts e.g. admin logins don’t survive a host reboot. So after trying and failing to use a different storage backend devstack was sidelined for me (I fully recognise this is my weakness but I think since devstack is targetted at developers rather than experienced VI techies.

Enter stackops! So stackops has similar aims in that it intends to (and very much does) simplify the installation of Openstack. Stackops is essentially Ubuntu server as a basis (10.04 at the time of writing) with a “Smart installer” which is web-based to install Openstack. I found that with a little digging and a little judicious manual work, I could easily get my Openstack/stackops installation working (stackops defaults to using MySQL as the storage backend for keystone) so I thought I’d share what I found in case it helps someone out.

As a brief introduction, the stackops installer is very similar to the installer used by Debian and Ubuntu (but with no purple). So here goes with an overview of how to create an all-in-one (single node) installation of Openstack using stackops:

You’ll eventually arrive at a shell login prompt so you’re nearly done! Log in as root using the default password of “stackops” (without the quotes).

Now run the shell command “pvs” and note the device path (bolded below)

root@nova-controller:/# pvs
PV                VG           Fmt  Attr PSize   PFree
/dev/cciss/c0d0p6 nova-volumes lvm2 a-   102.42g 97.42g
root@nova-controller:/# pvs  PV                VG           Fmt  Attr PSize   PFree  /dev/cciss/c0d0p6 nova-volumes lvm2 a-   102.42g 97.42g

(You’ll need this in a moment)

So now go back to your desktop and go to the web-installer on the host on port 8888 – so if your hosts static IP is 192.168.16.10, go to 192.168.16.10:8888 and you will be forwarded on to the stackops web installer – don’t be scared it does work!

So head through the installer and when you come to the “volumes” page, make sure you select the device which holds your “nova-volumes” LVM group which we found above. Now complete the installer and sit back while it does it’s work.

Once the installer is complete, shell in again as root (pw: stackops) to the host – you now need to add some VM images. This step seems to be omitted in many guides but luckily, the nice folk at devstack and stackops have provided scripts to download and install some common images e.g. Debian, Ubuntu, Centos etc. You can find these scripts in /var/lib/stackops, just run them using e.g. ./pubdebian6.sh once you’ve cd’d to /var/lib/stackops.

Now you can log in to your admin console which is on port 80 at the static IP of your host.

Hope that’s useful.

Documents for reference:

Created: Mon, 11 Jun 2012 10:00:00 GMT
Last modified: Mon, 11 Jun 2012 10:00:00 GMT