Saturday, 14 July 2012

Software Illness


Every time when I watch the popular TV program 'Satyamev Jayate', I start thinking what might be the issue that could be raised in next episode. This time my mind thought rather differently. It came up what issue  should be raised- 'Illnesses of Indian Software Industry'. Yes there are many, I feel. I'll group them together and refer collectively as software illness.

First of all, we are very bad at following timings. We neither come on time nor leave the office on time. A wrong concept is flourishing in our software industry that those who leave office early or in time, are not sincere at work. This misconcept needs to be cured by the pill of looking at productivity instead of time spent in office. As long as deadlines are met and tasks are completed within time, sitting for longer hours in office should be discouraged. Another illness is one of the culprits behind the above issue- we are driven by managers and not by leaders.

Software is considered to be a job-open field by candidates and as an elite one by parents. This makes many folks opt for software related education and thereafter job. Choice and liking is nowhere taken into consideration. This has led to tremendous mediocrity in our software industry.

A rule of thumb to measure one's success in software career is to look at his onsite abroad assignments. If you don't have any onsite in your CV, janata considers you to be a failure! Another point in rule-book of people states that working with big software brand means you are good. Working with smaller companies is thought of as you are 'not able to fetch a good job'. So a combination of both these things means utter failure!!

I wish we get rid of software illness and make it healthy asap!

Sunday, 1 July 2012

Hypervisor: KVM


In my college days, I used to install VirtualBox on my Windows OS and run Linux inside it. Frankly speaking at that time I didn't know what is a hypervisor and what exactly a hypervisor does! :)

Hypervisor (VirtualBox was my college-days' hypervisor) is used to manage the guest operating systems (Linux was the guest operating system). Wikipedia defines it as:
In computing, a hypervisor, also called virtual machine manager (VMM), is one of many hardware virtualization techniques allowing multiple operating systems, termed guests, to run concurrently on a host computer.

There are two types of hypervisors:
1. Native or bare metal- It runs directly on the host's hardware. Examples: Hyper-V, KVM, XenServer.
2. Hosted- It runs within an OS. Examples: VirtualBox, VMware Workstation.

I recently used KVM(Kernel-based Virtual Machine) while working with OpenStack and it worked fine without any issues.

If you want to work with KVM, first thing you need to check is whether your processor supports hardware virtualization or not. Just run the following command : 
kvm-ok 

If you get the following output that means your processor supports it.
INFO: /dev/kvm exists
KVM acceleration can be used

From whatever I have read, it looks like even if your CPU does not support KVM extensions you can still run virtual machine but it will be very slow.

To install KVM run the following command:
apt-get install qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utils

You need to add your user to the libvirtd group. To do so run the following command:
adduser 'id -un' libvirtd

And then relogin to make your user an effective member of the libvirtd group.

Check if the installation was successful by running the following command:

virsh -c qemu:///system list

I get the following output:

 Id Name                         State
----------------------------------
 24 instance-0000001f     running
 31 win-server-1              running
 34 instance-00000020    running

Initially you will not have any instance running; so you should get the following output:

 Id Name                 State
----------------------------------

I will cover how OpenStack works with KVM in my next post.