Sunday, August 30, 2009

How to install kernel headers to build modules against the Xen kernel - Amazon EC2

If you are using a Ubuntu/Debian AMI, and need to install kernel headers to build modules: apt-get would not work almost all of the time. You would probably end up with doing something like following,
root@domU-XX-XX-XX-XX-XX-E1:~$ apt-get install linux-headers-`uname -r`
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Couldn't find package linux-headers-
I used the following method to get Kernel headers and compile a VMWare 2 instance. This method will always work,
alien -k --scripts kernel-xen-devel-
dpkg -i kernel-xen-devel_2.6.21.7-2.fc8_i386.deb
ln -s /usr/src/kernels/ /lib/modules/
ln -s /usr/src/kernels/ /usr/src/linux
Make sure to include symbolic links to .configure to work properly.

Thursday, August 27, 2009

Virtual cloud? or something like that

Everyone on the plant is really interested in cloud computing these days. There are many organizations specialized in providing HaaS services. Is it possible for someone to build their own cloud, if one could find a hardware rich machine. Yes!, it is. Lets call this is a virtual cloud. How can a virtual cloud is built?. Simple, use VMWare 2. Let see what I did,

1. I have two machines. A hardware rich machine A ( and some other machine B (

2. I downloaded and installed VMWare 2 in machine A. This version is free and you will get an access key free too. Follow the simple instructions to install VMWare 2. VMWare 2 has a very powerful web console. Default http port is 8222 and https port is 8333. To install VMWare 2 in Ubuntu, follow these instructions.

3. Now I am going to create an VMWare image to install Ubuntu 9.04. Ubuntu is my all time favourite Linux distribution.

4. From machine A, open up a Mozilla browser and type Login using "root" and the password. Create the VMImage for Ubuntu 9.04. If you are using the "console" tab for the very first time, browse will ask to download VMWare Remote Console Puglin. Download and restart the browser.

5. Create many number of VMImages. Use different distributions. If you want you can use Windows too. Logout after this.

This is the place where we can introduce the notion of a virtual cloud. Each VMImage can be treated as a node in a cloud. There is one limitation though. This cloud can grow up until it runs out of VMImages.

6. I have created my virtual cloud in the previous step. How can I access it from out side. Lets go to machine B. In my example machine B is in the same network. Access the VMWare 2 using Login as "root" and password. I need to find out administration permissions documents to create users to access VMImages but "root".

7. In this example, there is only one VMImage. Select it and power it up. You can turn on many VMImages.

This way you can create your own private virtual cloud.

Amazon EC2 allows users to create custom AMIs. Unless one does not have an agreement with them, one can not build AKIs and ARIs. If I do the prior in an Amazon EC2 node, I would definitely be able to run a distribution with my kernel, without worrying about underlying necessaties. This process might be possible to try in any cloud service providers.

One would ask, why would you want to do this after all. Well I am a grad student and this is fun!.

Thursday, August 13, 2009

I have registered * domain for myself at last. Domain registration 101, is for my blogs. Enjoy!

Monday, August 3, 2009