5

I have had an EC2 instance working just fine for months (still developing, app not live yet), but I just realized I don't even know how to make my EC2 instance scale up / down depending on traffic.

The sheer number of services offered by Amazon is overwhelming, and I'm very confused.

Initially, I though I'd just have one instance, and Amazon would transparently allocate resources or create identical instances to handle traffic but it seems my impression was wrong.

My question is: can someone please tell me (in simple words, bullet list or point me to a tutorial) how to make my instance automatically grows to handle 100,000 simultaneous users then automatically goes back when the surge is done?

Assuming this is possible, can I do this via the AWS control panel? If so, how?

All I can see is micro, small, medium, etc.. instances. Each one has limited resources and it's not clear how to automatically setup the instance so that Amazon dynamically allocate additional resources to handle traffic spikes (or even gradually go up to keep with natural traffic growth for that matter).

Side question May I assume that Amazon auto-handle DDOS attacks when scaling up? (meaning rogue traffic would eventually stopped/slowed down by Amazon and scaling would only affect legitimate traffic spike). I realize this side question may be really stupid, keep in mind I didn't take my coffee yet :)

2 Answers 2

4

This article details how to auto scale using load balancers and EC2: http://kkpradeeban.blogspot.com/2011/01/auto-scaling-with-amazon-ec2.html

For scalability you may also want to look into this article on implementing a pub/sub system for distributed systems: http://www.infoq.com/articles/AmazonPubSub

Sign up to request clarification or add additional context in comments.

5 Comments

Thank you, it's more clear now. Same question thought: can't I create these "Auto Scaling Groups" visually via the control panel itself? It's not clear, how can I manage/change them? I mean I'd like to make sure I created the right conditions to scale up. It's a bit "dangerous" for a newbie to play with "live stuff" using commandline with no feedback.
There is no web console for autoscaling.
@FrederickCheung: That's what I afraid of. So how do I debug or check that I did configure the auto scaling group correctly?!!
@TheDude You can log the user-data script out put for debugging purposes - run the proposed auto-scaling infrastructure in a test environment first: alestic.com/2010/12/ec2-user-data-output
For each command in the command line tools has a "xx-describe-..." command. It will give you the feedback that you are looking for. for your case you can use "as-describe-autu-scaling-groups". See more in: awsdocs.s3.amazonaws.com/AutoScaling/latest/as-qrc.pdf
3

You can't automatically change the instance type (m1.small, m1.large, etc.) in response to changing load. You can, however, have AWS automatically create new instances as your load increases, and tear them down when load subsides.

I believe this article will help you: http://aws.amazon.com/autoscaling/.

1 Comment

Thanks, Can't I create these "Auto Scaling Groups" visually via the control panel itself? It's not clear, how can I manage/change them? I mean I'd like to make sure I created the right conditions to scale up. It's a bit "dangerous" for a newbie to play with "live stuff" using commandline with no feedback.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.