Smoothwall Firewall project

Showing posts with label amazon ec3. Show all posts
Showing posts with label amazon ec3. Show all posts

Monday, 5 December 2011

How to add another hard disk to your Xen virtual machine




If like me you have many Xen virtual machines that have been running for a while, you will likely come across the problem of having to increase the disk space, as the services or jobs the virtual machine offers over time changes.

Now you could increase the size of the existing disk, but I always feel that offers a level of risk, which with adding a new disk and using LVM or a new mount goes away.

Ok, so firstly we need to create a new virtual disk on the physical harddisk with the following command:

dd if=/dev/zero of=vm01-disk2.img bs=1G count=50

This will give us 50GB of new space. You can of course change the size to what ever you require, if your physical disk space will allow it.

Then we need to edit the Xen virtual machine configuration file and add in the new disk.

On my virtual machine host this is in /etc/xen/vm01

The line that needs to be altered is obviously the disk line, like so

disk = [ "tap:aio:/opt/xendisks/vm01.img,xvda,w",\
"tap:aio:/opt/xendisks/vm01-disk2.img,xvdb,w" ]


NB Notice the slash which allows the configuration line to expand over two lines in the configuration file.

Once you have done this, you can use the virsh and xm commands to restart the virtual machine , so that the new disk is available inside the virtual machine.

Once your VM has re-booted, you will notice another disk, which you can then either add to your LVM configuration, or just format and mount in a new directory. Here is my new mount as an example.

/dev/xvdb 50G 19G 29G 39% /opt/tomcat

Thursday, 27 August 2009

Virtual Private clouds are the next logical step for everyone




I have been working with virtualization since I could first get my hands on the code and it has proved to be a great success in many , but not all, environments. The introduction a couple of years ago of Amazons EC3 cloud was a great first step, and you could see the logic for it's uses among many companies, but again not all.

With the announcement of Amazons new Virtual Private Cloud, I think a very large step is now being taken into the next stage of cloud based systems development.

I think this is nothing more than the realisation by Amazon, and I suspect other cloud service providers that many large companies were never, and I mean never , going to put their corporate systems into a global cloud, no matter how long you could talk on the security of separation.

Using this method, corporate IT managers can migrate certain systems into the cloud and see how they go, like all things with corporates, slowly ,slowly. Once they are happy that the world hasn't ended with moving the Intranet into this new cloud extension to their network, they could well be persuaded to start to move other services into this new area.Then five years from now, they will all be sitting at the bar at a conference telling people they were one of the first to see the light and they always new it would be the future ;-)

Have a look at the announcement here Amazons Virtual Private Cloud