Running your site on multiple load balanced servers

Frank CheungEvery site hosted here at Everleap can run on (at least) two servers simultaneously, and traffic to those servers is automatically load balanced for maximum performance.

A multiple server environment like ours is the best way to handle to handle a heavy load on your site, but there are a couple of important things to keep in mind when you gear up to use more than one worker.

1) ASP.NET Session

If your application uses sessions, you cannot use “In-proc” mode because in-process sessions cannot be shared between multiple web servers.  If you update your application to use SQL session, you won’t run in to that problem.

To use SQL session:

2) Machine Key

Typically you would need to setup your own machineKey for your application to work properly in a load balanced environment.  But at Everleap, we automatically generate an unique machine key for each site on the server level so you don’t have to worry about it.

As you can see, it can be pretty easy to prep your site to run on multiple servers. Of course every site is different, so you should always do your homework so you’ll be prepared when you make the move to multiple servers.


Rate this article

3 Responses
  • ewbi Reply

    Thanks for the info. Taking this a step further, can you please explain how site files are managed between two servers? For instance, when I attach via FTP, which server am I looking at? When I deploy my web site directly from Visual Studio to Everleap, which server gets updated, and how are they kept in synch? Should I avoid using local storage for site files, like in App_Data, for the same reason as avoiding in-proc session? Thanks.

  • ewbi Reply

    Duh. I just realized you’re probably pointing multiple web servers at the same shared storage, so one deployment, one FTP site, one App_Data folder, etc., just like on Azure. My initial thoughts turned to a client’s recent hosting of a site on two servers using separate local storage, which is admittedly difficult to manage.

  • Frank Cheung Reply

    Yeah. All your files are stored in a centralized storage which all the web workers are pointing to.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

oui décor