3 ms·
I use EC2 and I do swear by it. I see the initial extra effort you need to put in to get it to work right (designing for failover etc) as: 'the more you sweat i
by kirubakaran 19y ago
I use EC2 and I do swear by it. I see the initial extra effort you need to put in to get it to work right (designing for failover etc) as: 'the more you sweat in practice, the less you bleed in battle'.
I first ported a toy app that I wrote (http://www.instantwordsearch.com http://www.instantwordsearch.com) to EC2 - as an exercise. I personally learnt a lot in the process. Now I use EC2 for everything I do. It is a LOT of fun (imho).
Interesting links:
http://jimmyg.org/2007/09/01/amazon-ec2-for-people-who-prefer-debian-and-python-over-fedora-and-java/ http://jimmyg.org/2007/09/01/amazon-ec2-for-people-who-prefe...
http://jimmyg.org/2007/09/01/custom-debian-ec2-amis-from-xen-images/ http://jimmyg.org/2007/09/01/custom-debian-ec2-amis-from-xen...
- davidw 19y agoSo how'd you deal with its ephemeral nature?
- kirubakaran 19y agoI have my own AMI - so, I can bring the instance up as soon as it craps out. (This has never happened so far - which means I am either lucky or the fear is overblown). I have another server outside of AWS babysitting EC2. I am designing a little bit on the paranoid side and making automatic incremental backups in S3. Recovery script will automatically restore using this too. I've simulated failures and I know it is safe. (this is something you need to do anyway - there are no guarantees in life!) I still haven't automated the DNS change that needs to be done when you get a new instance. I will be handling this soon. There are some cool hacks already out there if you google for ec2 dns
- davidw 19y agoHaving a central server to run everything seems pretty key to the entire operation. Is that where you store your data, or do you just hope to be able to fix things from backups to S3 if you lose a server?
- kirubakaran 19y agoIMO EC2 lends itself very well to higher availability by redundancy - if that is what you want. My current approach is more exploratory coz I am learning as I go. But, to answer your question, if the instance were to fail right this moment, I'll get a notification and I'll run a recovery script that I've set up. I won't have this manual-intervention method for long though.
- wmf 19y agoI haven't used EC2, but the complexity would worry me if I was on a schedule. If you only have a few months of runway and you spend most of them sharpening your EC2 tools rather than coding features you could be doomed.
- kirubakaran 19y agoI would say you can grok the whole thing in a weekend.
- tx 19y agoHm... the toy app you ported took about 5 seconds to respond. Slo-o-o-o-ow. Is that EC2 overhead? This is the kind of thing we were trying to avoid and ultimately (again) decided on our own servers in a data center.
- DocSavage 19y agoI bet most of that response delay is from the autosuggest lookup against the dictionary. It seems to be querying every time you enter a letter, so if you quickly type a word, you'll be initiating multiple GET requests, each of which hits the DB.
- kirubakaran 19y agoIt is near instantaneous for me and I am in Seattle,WA,USA. I've heard from many sources that AWS is slow if you are outside the US. Someone even brought this up in the AWS dev conference and the Amazon guys just dodged it and gave a generic 'things are being improved' response. If http://www.instantwordsearch.com/ http://www.instantwordsearch.com/ look up is painfully slow but http://www.instantwordsearch.com/backstage.html http://www.instantwordsearch.com/backstage.html (statically served 103KB text) is very fast, then you can conclude that the problem is with my app. Otherwise it might be safe to blame EC2.
- tx 19y agoI am in Austin, TX and the front page took 5 seconds. I did not type anything or clicked anywhere. The problem with EC2 and other super-managed hosting solutions (Joyent comes to mind) is inconsistency: I am sure they're moving VMs around, and occasionally they end up on overloaded servers.
- wmf 19y agoBut I am equally sure that EC2 does not oversell CPU/RAM resources and does not move VMs around. I don't think Xen even supports memory overcommit.