Are You Ready to Scale?

The growth of a typical web site might look a little like something this:

  1. Ready To Scale - Phase 1You build the first version of your site and deploy it into a shared hosting environment (Dreamhost, etc). All is well.
  2. Ready To Scale - Phase 2You need to build more features for your growing customer base. Performance and uptime are also concerns, so you move your site to a dedicated server. Freedom in a box!
  3. Ready To Scale - Phase 3More customers. They want more features and they want them right now! How do you cope with the load? You put your database onto it’s own dedicated server. We can breath again.

So here we are with the traditional 2 server 2 tier backend. One server is responsible for generating and serving web pages, the other server is responsible for storing data. Here are some of the problems you may be fortunate enough to encounter when running on a setup like this:

  1. Availability: You now have 2 points of failure. If either your web server or database server dies you are in trouble. What’s your plan when this happens?
  2. Performance: How are you measuring this? How many more concurrent users can your site handle before you’re no longer serving requests in a timely manner? More importantly, what do you do when you reach that point?
  3. Backup: How do we accurately and quickly backup all our customer data without taking our entire web site offline?
  4. State & Tangle: Where are you storing user and session data, on the file system? How easily can you partition off different areas of your site/application onto separate servers?

If you’ve reached this point in your web site’s growth but don’t have answers to these questions it’s about time you started thinking about tackling these problems.

Next week is guaranteed to be nothing but crazy at SitePoint HQ as we are moving to a bigger and better office. But I promise to post early in the week with some suggestions/ideas and other things to consider as you ready for the next phase of your site’s growth.

Free book: Jump Start HTML5 Basics

Grab a free copy of one our latest ebooks! Packed with hints and tips on HTML5's most powerful new features.

  • http://www.sitepoint.com/ mattymcg

    Looking forward to the follow up on this Lucas. Btw your lil graphics are purdy.

  • nwmcsween

    1. You deploy a reverse cache such as varnish cache varnish cache
    2. Optimize use apachen for php and lighttpd or nginx as a static server.

  • http://www.realityedge.com.au mrsmiley

    4. Unmanaged infrastructure = freedom in a rack

    I don’t know that having multiple failure points is always a good thing. With more points to look at, your maintenance overhead increases with each point. And naturally, some points lend themselves to failure more than others.

  • nwmcsween

    If you want availibilty go with something like ha-proxy

  • http://www.devisedmedia.com devised

    Looking forward to the follow up as well as we could use some tips on increasing our server performance.

  • jobr700

    You also need to take licensing into consideration. If you’re not using free software licenses tend to go up quickly when fail-over and other similar features are needed. We start to see this problem for clients hosting systems on their own machines.

  • Wolf_22

    The typical growth of a web site might look a little like something this…

    Lucas, I think you have some great information in this article. May I suggest changing that first sentence, though, to reflect the following?:

    “The growth of a typical web site might look like this…”

    I am sure it was probably a typo of some sort. I just thought that a fix to that sentence above might help readibility. Regardless, keep up the great work!

  • http://www.blogpatrol.com BlogPatrol

    Hi Lucas, Our site growth and development exactly mirror your examples. Looking forward to hearing your suggestions in the next post!

  • http://www.someventure.com zackjenks

    1. Availability: You now have 2 points of failure. If either your web server or database server dies you are in trouble. What’s your plan when this happens?

    Redundancy, Redundancy, Redundancy?

  • http://www.dangrossman.info Dan Grossman

    Looking forward to the followup… you’ve told us about a problem but no solution!

  • http://www.Moorec.com.com shalliday

    Hi Lucas,

    We are exactly where your article leaves off. One applications server and one database server. Now experiencing site performance issues and being told I need to add two additional servers to handle existing and anticipated server load. I have been holding off making a decision and looking forward to your next post to see what other server configuration options to consider.

    Thank you for posting on what is such a relevant and important issue for many of us.

  • http://www.calcResult.co.uk omnicity

    Are you just fishing for ideas, or do you plan to provide some suggestions of your own?