Welcome to OpenStack - An Introduction
The OpenStack project was originally launched by RackSpace in collaboration with NASA in July 2010 where it gained a lot of attention in a short period of time. NASA contributed their code from the Nebula cloud project to OpenStack compute, and RackSpace contributed most of code behind their cloud platform, specifically Cloud File products. Technology giants like Intel and Dell embraced OpenStack immediately after it started and now there are over 140 companies that support the OpenStack initiative. Giants like IBM, AT&T, and HP all recently announced they’ve joined OpenStack and Sony has moved a portion of its PlayStation services from AWS to OpenStack in Rackspace after suffering from a cyber-attack last year which caused a major outage to their services.
OpenStack consists of a set of inter-related projects which make up the various components of a cloud computing platform. Its services are interoperable with existing cloud services like AWS, which heightens its appeal. Three key components of OpenStack are:
1. OpenStack Compute (Nova)
2. OpenStack Object Storage (Swift)
3. OpenStack Image Service (Glance)
OpenStack compute aka Nova, is a python-based software used to orchestrate cloud and manage virtual machines and networks. Nova allows us to create and manage virtual servers using machine images. These images are handled by a separate OpenStack service called Glance. Nova includes the underlying software, APIs, and a control panel. It is hypervisor agnostic which means it can run on variety of hypervisors and doesn’t include any virtualization software, whereas it defines drivers to interact with well-known virtualization software like Xen, VMWare, Hyper-V.
Nova has server logical components which fall under two main categories:
1. WSGI daemons to accept and manage API calls
2. Worker daemons to carry out orchestration tasks
Apart from these two, there are two other components, a database and message queue which perform critical roles in orchestration tasks through data sharing and message passing.
The most important part of OpenStack Compute is nova-api WSGI daemon which provides an end-point for API requests to the OpenStack API or EC2 API. This end-point can be used start and manage instances similar to managing EC2 instances using API requests. Nova basically interfaces with OpenStack Image Service through the glance-api.
Next we have nova-compute worker daemon which handles the instance life cycles by executing a series of system commands while updating the state in a database. nova-network daemon deals with the network-related tasks like allocation of IP, network manipulations, etc. It accepts networking tasks from a queue and performs a series of commands to manipulate networks. nova-scheduler processes takes a virtual machine instance request and determines where it should run.
An SQL database will store the configuration and run-time status of the cloud infrastructure. Sqlite3, MySQL, and PostgreSQL are the currently supported databases; though sqlite3 is the most widely used.
OpenStack Object Storage (Swift)
OpenStack Object Storage is roughly similar to Amazon S3. Swift allows us to store objects in massively scalable infrastructure with in-built redundancy and fail-over. It can be used to store static data (like Images and Videos), make back-ups, archive data, and so on. Swift will write copies of data to multiple redundant servers which are logically grouped into Zones. Zones are isolated from each other to safeguard from failures. We can configure Swift and decide the number of Zones and replicas we need to have in the system.
Object is the basic storage entity in Swift. An object can be anything like a document, audio, or video data. A container, which is similar to buckets in S3, allows you to organize objects by grouping them. Swift simply provides API endpoints to store and manipulate objects. We cannot use Swift as a file system and they are not accessible via any file sharing protocols. To access the Object Storage you must authenticate against an authentication service to receive a token. This token must be passed in subsequent API calls. Every Swift user will have their own storage account with full access to it. An authenticated user can create and delete containers and objects in their account.
There are many components for Swift, like Object server, Container server, Ring, Proxy server, and so on. Object server is a simple blob storage for storing and retrieving objects. Container servers primarily list the objects by grouping them. Ring contains the information about the physical location of objects. It is something similar to an index in traditional database. The Proxy server acts as an entry point to the OpenStack Object Storage infrastructure. Users access Swift by making API requests to this Proxy server. It is responsible for handling failovers by switching requests to any handover server.
OpenStack Image Service (Glance)
Glance is responsible for storage, discovery, and retrieval of virtual machine images. Glance can be configured to store VM images in Object Storage, Amazon S3, or simple file-system. Glance-registry and Glance-api are the two important components of Image Service. Glance-registry stores and retrieves metadata about images. Like I mentioned previously, Nova interacts with Glance using Glance-api for querying and retrieving actual VM images.
Clients can register VM images by making API requests to Image Service. Glance supports a variety of image formats like RAW, ISO (Archive disk format used in optical disks), AMI (Amazon Machine Image), etc.
In addition to the three core projects there are two projects, OpenStack Identity (keystone) and OpenStack Dashboard (Horizon), incubated in the Diablo release which will be added to the core in next release. OpenStack identity provides a unified authentication across all OpenStack projects. Though this is not quite production ready right now, it’s going to be a key component in coming releases.
OpenStack Dashboard enables users to manage their infrastructure using a simple web interface. Administrators can launch and manage instances and resources from here. Dashboard will list all available images, and users can select one to launch from this list. It also allows users to create volumes and attach them to any instance.
OpenStack has the support of a code base that powers Rackspace cloud and big companies in the industry are actively contributing to the project. OpenStack is committed to creating an enterprise cloud platform that is truly and completely open-sourced. Open-source software prevents any kind of proprietary vendor lock-ins. Even more interesting is its interoperability with existing IaaS providers like AWS.
In October 2011 Rackspace announced transitioning of its management to an independent foundation called OpenStack foundation, to protect the OpenStack brand for the benefit of community participants. Making OpenStack a ubiquitous cloud platform and ensuring its interoperability are the most important goals of the OpenStack foundation. There are two interesting initiatives that are intended to make using OpenStack easier: StackOps provides tools for making deployment and operation of OpenStack by packaging them to Distros and DevStack provides a set of well-documented shell scripts to build a complete OpenStack environment.
(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)