Wednesday, August 18, 2010

Every Wondered How to launch a linux Instance automatically ?

I don't know about you, But whenever we need to launch an Instance the only option I could see is to login to the AWS console and select the AMI and then follow the usually process .Now the following command can come to your rescue .

ec2-run-instances AMI [-n INSTANCE_COUNT] [-g GROUP [-g GROUP ...]] [-k KEY] [-d USER_DATA | -f FILE_NAME]

Now if you observe the only important option that is not present is the Launch zone
viz. US-EAST..etc .Hence this is what you can do use "-Z" option as follows

$ec2-run-instances ami-xxxxxxxx -z us-east-1a

The above command will allow you to specify the launch zone so that you can safely attach the storage once its up.Amazon are you Listening why haven't you mentioned this on your website ."http://docs.amazonwebservices.com/AmazonEC2/dg/2006-10-01/CLTRG-run-instances.html"

Tuesday, August 17, 2010

So What Is Cloud Computing Exactly ?

The Wikipedia says "Cloud computing is a Internet-based computing, whereby shared resources, software, and information are provided to computers and other devices on demand, like the electricity grid" .But this is all about the technical jargon in a lay mans word what I would say is that cloud computing is what a Taxi is to an Automobile its basically A Pay As You go kind of a model in which an Individual,SME,Corporates hire or lend Computing services .So lets assume you have a website which has a regular number of hits but on certain occasions you see that the Hits are almost double of what you had expected, In that case the only option left traditionally is to Purchase a new Machine and configure the same Web server or have virtualisation implemented.But these technologies come at a cost which you may have to invest for a short period of time(In this case for the days in which you see above average Hits ).So here is where cloud computing comes to your rescue.So in case your server was on the cloud all you have to do is add a couple of servers which are a replication of the original one and use them untill you require them and once done you can Bundle the server or simply terminate .Even the scaling can be automated .In coming days I shall update the various types of Clouds that are picking up in the Tech World

Friday, August 13, 2010

Bundling errors in Linux Instances On AWS?

I have come across the following error while bundling since quiet some time now so though of posting the problem with the solution

1048576 bytes (1.0 MB) copied, 0.001952 seconds, 537 MB/s
mke2fs 1.39 (29-May-2006)
mount: could not find any free loop device
ERROR: execution failed: "mount -o loop /mnt/latin-bpo-dev-database-image2010-08-13 /mnt/img-mnt"
Copying / into the image file /mnt/latin-bpo-dev-database-image2010-08-13...

The reason this happens is cause the loopback device that is used while bundling has a maximum limit of 8 and in case the previous
onces havent been cleaninly unmounted and hence the kernel simply refuses to allow a new mount which is done during the bundling process

The Solution to the problem is as follows

[root@:~] losetup -a
[root@:~] losetup -d /dev/loop7
[root@:~] losetup -d /dev/loop6


Once done with this try Bundling the instances

Thursday, August 12, 2010

Well Times Change and so did I :-)

Hello Geeks,
Well its been long since I am back with Blogging and I guess will keep up to this habit.In the coming days I shall Blog More of Cloud Computing and Mobile Computing .I shall try to keep you guys abreast of the latest Tech surrounding these topics .Off-course that goes without saying Linux is still gonna be around so Happy Reading and do let me know your comments ..
Thanks
Jiten