Best practices with EC2 and RightScale

| | Comments ()

I've been doing some client work lately on the RightScale platform and wanted to share my thoughts.

First, things that you should do:

  • Accept the way that RightScale does things. So yeah, maybe you might prefer nginx or lighttpd or whatever the kids are using these days for a load balancer. Too bad. Don't waste your time reproducing the work that RightScale has already done.
  • Use dnsmadeeasy.com for dns. The first thing you'll need moving to the cloud is a dns provider with a simple api and flexibility to set low ttl values. The integration between RightScale and dnsmadeeasy works beautifully. Use it.
  • Use svn or git rather than attachments. The most important RightScript we have is one of the simplest... it installs the subversion package and does an svn checkout into /usr/local/<abc>. Later scripts and tools, etc. can rely on the presence of your code, tools and configuration in that directory.
  • Setup arrays for auto-scaling of your app servers. Arrays seem to fit best at the app tier - you probably don't want to automate new database instances, and you probably don't need to automate new load balancers.
  • Use ganglia or similar for usage metrics. You'll need good data to make good decisions. Add some custom metrics to your monitoring system and you'll have more data than you know what to do with.

Things you should not do:

  • Do everything the RightScale way. Nobody in their right mind is going to use the RightScale tomcat image with the Centos default install of tomcat 5. It sucks and it will be totally different from the tomcat install that you used for development. If you can do something better than RightScale without spending too much time on it, go ahead.
  • Count on auto scaling to save your butt. You should know that ec2 instances can take as long as 15 minutes to start up. Add in time for RightScale initialization, your code initialization, etc... and by the time you have a few more servers up and running the internets will probably be on to a competing lolcat site.
  • Rely on a 100% success rate with S3. S3 fails. That's life. And when s3 fails, RightScale can fail, causing your images to come up "stranded in booting." Yet another reason not to count on auto scaling.
  • Heavily use RightScale attachments. Your custom RightScripts can have arbitrary files associated with them. For example, you might have a script that would install ganglia and configure /etc/gmond.conf, and you might be tempted to use an attachment for /etc/gmond.conf. Attachments might be appropriate once in a while but in general they suck for version control, patching and code reuse. Our advice: use S3 for large files, svn/git for text and RightScale attachments only rarely.

Bottom line, is it worth the cost? It depends. Don't expect RightScale to displace the need for a good sys admin, but it just might save you some time every month. At $500/mo. the relevant question is whose time will it displace and how valuable is their time.

Comments

Recent Activity

  • Sam tweeted, "At Ballard Seafood Fest looking for yummie crab melts and lemonade."
  • Sam tweeted, "Stoopid ruby, rails and vlad! How can anybody solve problems with all this damn meta-programming?"
  • Sam tweeted, "Drunkflixing: editing your netflix queue after too many drinks (inspired by The Other Bolyn Girl)."