Yet Another Cloud

mercredi 18 septembre 2013
Are there more clouds in the IT domain or in the sky? I mean building is own cloud is getting easier and easier, I'm sure one day datacenter will looks like a weather forecast...

Today, I would like to share my experience on private cloud. In particular about an open source cloud software named: OpenStack

OpenStack is clearly the leader on cloud software domain. Too big to ignore it, the community (composed by more than 11 000 people) counts with Rackspace, RedHat & IBM as the biggest contributors. My aim was to try to set up a tiny private cloud on one machine to get familiar with it and explore the possibilities.

Getting started with OpenStack

Since Day 1, OpenStack has been designed to separate cloud management concerns. That's why OpenStack is compose by a set of module/service. The official Getting Started list you the ways to install the components. I decided to use a CentOS 6.4 linux distribution and use RDO to install OpenStack.
In terms of virtualization, I use the default kvm/qemu system provided by CentOS.

RDO is a Redhat related project aimed to ease OpenStack installation and indeed it eases it A LOT.

Go take a coffee, and 15mins later... Voilà everything is installed (I advise you to restart the services to check the cloud boot).

So what have you installed? Well everything needed to manage a cloud:

  • Image definition (glance)
  • Instance management aka. Compute (nova)
  • Network management ( The rdo doc advise to use nova-network)
  • + Storage, Dashboard, Identity
Every single service has is own command line API. That means everything can be automated ;)

Once everything is up you can start to play. I won't start to explain how to use it ie. RTFM and yes the manual is excellent.
The community also set up a Q&A applications:

Having it's own cloud is cool, but at this exact moment I was only able to use "public" images downloaded from the internet (cf. Fedora, CentOs, Ubuntu cloud projects). The next steps was to create my very own boxes, to my very own cloud to make it really private.

Building automatically private VM boxes

If you are looking for documentation on how set up a cloud you'll find plenty of articles but is much more harder to find stuff relates to VM building.

The OpenStack doc list a set of tools to create you own boxes. I tried 2 of them Oz and veewee  Oz is used by the CERN to create images. To be frank, I tried it, I failed, I moved on.

The second tool is veewee. I already tried this tool to build vagrant boxes so I reused my existing definition.


The traps to avoid during the VM creation:
  • Install the cloud-init package to bootstrap the communication between OpenStack and the VM.
  • Disable the firewall, to let OpenStack bootstrap the VM. OpenStack will inject automatically the security rules (aka. firewall rules).
  • The created images footprints can be huge, use qemu-img convert and virt-sparsify to shrink the image to a reasonable size (~500Mb). 
To automate the building I wrote a Rakefile. The process is automated with Jenkins which deploy automatically a new image into the cloud (thanks to OpenStack glance API).

Conclusion

OpenStack is an excellent tool. It is really a time saver!! The Cloud concerns have been perfectly identified and split. Nevertheless, it's hard to troubleshoot. Indeed, since every single one component has its own name and is responsible for one concern, you have to know by heart the OpenStack map of services... It' particularly true to find the appropriate log message. 

Regarding, image build, it's a mystery for me. Creating custom images should be as importing as instantiating them. Why not embed in OpenStack a service to build images in a standard way.

In a nutshell, building is own private cloud has been considerably eased but the common tools are not yet enterprise ready. I'm looking forward to test more advanced tools such as IBM Smart Cloud or vmware vCloud Suite.





Aucun commentaire :

Enregistrer un commentaire