The power of Amazon EC2

So, one thing that is nice about Amazon EC2 is the price. The cost of a server is $0.10/hour, or about $75/month.

Another nice thing is that you can have an instance up and running in a few minutes once you have an AMI ready that you are happy with. No need to order and install hardware, or even wait 24-48 hours for a new server from somewhere like Rackspace.

Yet another really cool thing about EC2 is that you can use it to give you bursts of computing power. Let’s suppose that I have a cron job that does some sort of regular processing (off on a processing server or other non-web server). Eventually, as I get more and more traffic to my site, the processing ends up taking all day. So, eventually, I add a second server. However, suppose that from an end user perspective, it would be beneficial if I could have all that processing done in 1 hour rather than 24-48 hours.

In a traditional environment, that would be really expensive. I would have to purchase 24-48 “processing” servers in order to get all the processing done in an hour. Then, all those servers would sit idle for 23 hous/day.

With EC2, on the other hand, I could instantiate 24-48 servers for one hour, knock out all the processing, and then shut them back down. The end cost is about the same since EC2 charges by the hour. So, I can appear to have 24-48 servers for the price of 1-2 servers (and I would in fact have 24-48 servers, but for only 1 hour/day).

One of today’s Amazon Web Services Blog entries has an entry about a Perl interface to Amazon EC2 written by Jeff Kim that allows you to script the starting and stopping of EC2 instances. This would allow you to programatically determine the number of servers you need, automate the process of starting up new instances, and automate the shutting down of instances that are no longer needed.

Another simple use of this would be to automatically monitor the load on your web servers and instantiate new instances or deactive unneeded instances depending on the amount of traffic coming to your website.

Bottom line: EC2 is amazing.

Advertisements

No comments yet

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: