Sunday, April 1, 2012

HP Cloud Services Beta

HP has opened up beta testing of their public cloud service - HP Cloud Services for a couple of months now, and I was lucky enough to be selected as an early private beta tester. HP Cloud Services is built on the open source cloud platform OpenStack and provides the Infrastructure as a Service (IaaS) model of cloud computing.
This post will just highlight my experiences with HP Cloud Services so far from the point of view of an Oracle DBA.

Setup

There are a couple of ways to access the HP Cloud resources. First there is the web-based management console that allows you to do basic administration. Here you can view, create and modify your compute instances and object storage. It also allows you to view your account keys, security IDs and other pertinent information needed to access and control your resources. Then there is the Unix command line interface (CLI) which is my preferred method of accessing and using HP Cloud. In addition, you can use RESTful APIs to access HP Cloud Compute and Object Storage services. Currently there are two availability zones but only one if available for beta testing.

Setting up HP Cloud requires using hp fog and ruby installations. I must admit that my initial attempts to set up the CLI tools took a lot of effort on Mac OS X 10.7.3. Luckily HP Cloud Services engineers and support staff do a great job of helping it's customers by providing a forum and knowledge base to quickly access information on commonly encountered issues. In one instance where I couldn't find answers online I was able to quickly contact them via twitter @hpcloud and got immediate responses to help resolve my issues. This was impressive - especially for a beta service.

Once you have setup the Unix CLI you can view a list of available commands using the hpcloud help command.

Compute Resources

HP Cloud compute instances consists of images and flavors. Images consitsts of operating systems and versions and the flavor is amount of resources allocated to the images i.e small, medium large. Each flavor is tied to CPU, memory and storage.

Images 

To get a list of images using the CLI type the hpcloud images command. 

iMac:HPCloud leighton$ hpcloud images
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | id  | name                                                   | minDisk | minRam | created_at           | updated_at           | status |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 417 | Debian Squeeze 6.0.3 Server 64-bit 20120123            |         |        | 2012-02-21T14:15:52Z | 2012-03-12T07:58:10Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 416 | Debian Squeeze 6.0.3 Server 64-bit 20120123 (Ramdisk)  |         |        | 2012-02-21T14:15:50Z | 2012-03-12T07:58:04Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 415 | Debian Squeeze 6.0.3 Server 64-bit 20120123 (Kernel)   |         |        | 2012-02-21T14:15:48Z | 2012-03-12T07:57:58Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 414 | CentOS 6.2 Server 64-bit 20120125                      |         |        | 2012-02-21T14:08:42Z | 2012-03-12T07:57:48Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 413 | CentOS 6.2 Server 64-bit 20120125 (Ramdisk)            |         |        | 2012-02-21T14:08:39Z | 2012-03-12T07:57:41Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 412 | CentOS 6.2 Server 64-bit 20120125 (Kernel)             |         |        | 2012-02-21T14:08:38Z | 2012-03-12T07:57:36Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 229 | Ubuntu Oneiric 11.10 Server 64-bit 20111212            |         |        | 2011-12-21T14:59:10Z | 2012-03-12T07:57:20Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 228 | Ubuntu Oneiric 11.10 Server 64-bit 20111212 (Kernel)   |         |        | 2011-12-21T14:59:09Z | 2012-03-12T07:57:13Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 227 | Ubuntu Natty 11.04 Server 64-bit 20111212              |         |        | 2011-12-21T14:56:38Z | 2012-03-12T07:56:54Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 226 | Ubuntu Natty 11.04 Server 64-bit 20111212 (Kernel)     |         |        | 2011-12-21T14:56:36Z | 2012-03-12T07:56:44Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 225 | Ubuntu Maverick 10.10 Server 64-bit 20111212           |         |        | 2011-12-21T14:54:36Z | 2012-03-12T07:56:37Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 224 | Ubuntu Maverick 10.10 Server 64-bit 20111212 (Kernel)  |         |        | 2011-12-21T14:54:28Z | 2012-03-12T07:56:31Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 223 | Ubuntu Lucid 10.04 LTS Server 64-bit 20111212          |         |        | 2011-12-21T14:52:13Z | 2012-03-12T07:56:22Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 222 | Ubuntu Lucid 10.04 LTS Server 64-bit 20111212 (Kernel) |         |        | 2011-12-21T14:52:11Z | 2012-03-12T07:56:16Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 221 | CentOS 5.6 Server 64-bit 20111207                      |         |        | 2011-12-21T14:50:22Z | 2012-03-12T07:56:05Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 220 | CentOS 5.6 Server 64-bit 20111207 (Ramdisk)            |         |        | 2011-12-21T14:50:20Z | 2012-03-12T07:55:59Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+
  | 219 | CentOS 5.6 Server 64-bit 20111207 (Kernel)             |         |        | 2011-12-21T14:50:19Z | 2012-03-12T07:55:52Z | ACTIVE |
  +-----+--------------------------------------------------------+---------+--------+----------------------+----------------------+--------+


You may notice that Red Hat Enterprise Linux/Oracle Linux or any other Linux flavor supported by Oracle is not listed. However, I was able to use the CentOS 5.6 image for my Oracle evaluation.

Flavors

There are currently six flavors to choose from. To see a list of flavors using the CLI use the hpcloud flavors command.


iMac:HPCloud leighton$ hpcloud flavors
  +-----+------------------+-------+------+
  | id  | name             | ram   | disk |
  +-----+------------------+-------+------+
  | 100 | standard.xsmall  | 1024  | 30   |
  +-----+------------------+-------+------+
  | 101 | standard.small   | 2048  | 60   |
  +-----+------------------+-------+------+
  | 105 | standard.2xlarge | 32768 | 960  |
  +-----+------------------+-------+------+
  | 103 | standard.large   | 8192  | 240  |
  +-----+------------------+-------+------+
  | 102 | standard.medium  | 4096  | 120  |
  +-----+------------------+-------+------+
  | 104 | standard.xlarge  | 16384 | 480  |
  +-----+------------------+-------+------+

Remote Access and Security

HP Cloud uses the concept of Security Groups to limit remote access to a specific resource by explicitly specifying which ports, protocols and IP addresses are opened to the remote machine. The default security group allows SSH access only. Once you create your Security Group you can then assign it to your machine or compute instance. If you make changes to your compute instance you will have to reboot it for the changes to take effect.
To see a list of security groups using the CLI use the hpcloud securitygroup command.

iMac:HPCloud leighton$ hpcloud securitygroups 
  +---------+-----------------------+----------+
  | name    | description           | owner_id |
  +---------+-----------------------+----------+
  | default | default               |          |
  +---------+-----------------------+----------+
  | oracle  | Oracle Security Group |          |

After selecting an image, flavor, security group and key pair you create your instance. Instance creation takes only a couple of minutes. 

Once you have created your compute instance you can then access it remotely via SSH. Before you can login remotely however, you will need to attach a public IP address to your compute instance. This can be done using the following CLI commands:
hpcloud addresses:add
hpcloud addresses:associate


For more examples and usages of the CLI for compute instance see here.

Object Storage

The HP Cloud Services Object Storage service provides access to cloud based storage. It can be managed using the web-based management console as well as the Unix CLI. With Object Storage you can copy files (objects) to and from the cloud using containers. A container is a logical representation for storing objects. Objects can be copied and moved between a local filesystem and containers as well as between containers. To see a list of containers using the CLI using the hpcloud list command. Files stored in object storage are stored as private by default. The Access Control List (ACL) property of the container determines whether they are public and private.
Here is an example of how to copy files between a container and local filesystem as well as change the ACL properties of a file.

List contents of a container called oracle-db

iMac:HPCloud leighton$ hpcloud list :oracle-db
Oracle11gXE-Install-EL5.6
docs/
docs/MeasuringMemory_LinuxUnix[1].pdf
scripts/
stage/
virtualbox/
virtualbox/VirtualBox.png

Copy the VirtualBox.png file from the oracle-db container to the local filesystem

iMac:HPCloud leighton$ hpcloud copy :oracle-db/virtualbox/VirtualBox.png .
Copied :oracle-db/virtualbox/VirtualBox.png => ./VirtualBox.png

Change the ACL for the oracle-db container to so that is readable by the public

iMac:HPCloud leighton$ hpcloud acl:set :oracle-db public-read
ACL for :oracle-db updated to public-read.

There is a video demo with more examples and features of the Object Storage services.

Oracle on HP Cloud Services

After setting up your compute instance, creating your Oracle environments is fairly straightforward. So far I have been able to successfully install and configure the following Oracle products for evaluating HP Cloud Services
  • Oracle Database 11.2.0.1
  • Oracle Enterprise Manager 12c Cloud Control
  • Oracle VM VirtualBox 4.1 (Running inside an Ubuntu 11.10 compute instance)
I'll try to do another post on the above listed use cases.

Conclusion

There are a couple of features that seem to be missing from the HPCS but this is totally understandable since it's still in the beta phase. The most notable of which in my opinion is the ability to create/import custom images. This is not completely true - you can create an image based on a current one, however only the root partitions can be saved. I haven't tried this yet but some articles in the knowledgebase seem to support this. You cannot boot into a custom kernel on existing instances.  For example, when I installed the Oracle Unbreakable Kernel (UEK) in CentOS, it would always boot the default kernel provided by the instance. In addition, there is no easy way to do vertical scaling with Compute Instances. You will have to create a snapshot of an existing instance and then create a new one with a different flavor using the snapshot.

This by no means covers the entire list of features available with HP Cloud Service. I suggest that you sign up for yourself to experience all that it has to offer and provide feedback to help improve it. Overall I find HP Cloud Service stable and promising especially for developers. Being open-source is also a big plus because the community can contribute to the OpenStack project to further enhance the cloud services.


No comments:

Post a Comment

IOUG Collaborate 14

IOUG Collaborate 14
IOUG Collaborate 14 Las Vegas