How to fix Bido

Unfortunately, Bido has been experiencing some down time lately.

After I wrote about Bido’s launch, I suspected that there were going to be issues with handing load and scaling. It looks like these are the issues the team is facing now.

I don’t know the specifics of how the Bido platform is configured, but from the notes and emails I have seen from the Bido team, it looks like the whole shot is running on one server.

It could be separated into one web server and one database server, but trust me, that’s the same thing as running it all on one server. ;-)

The problem

There are two fundamental problems with the one server solution.

Server resources - sooner or later you will run out of RAM or cpu cycles which means your site will either slow down, or die on you completely.

Hardware failure - some piece of hardware will fail on your server and the RAID hard drives and N+1 power supplies you bought with your server will not save you when your network port fails, your cpu overheats or a ram stick goes bad.

The solution

Typical cluster

A cluster is the best platform to deploy an application like Bido. Google, Yahoo and Ebay are all clustered. This blog is even served from a cluster !!

Clusters are easy to set up and maintain. From a system administration standpoint, there is a little more work to do because you have more hardware to keep track of, but you will get a lot more sleep and pull out less hair when a server fails.

A cluster allows you to have multiple server failures and still be online. In the standard cluster that we install for clients, we can have three hardware failures and one time (load balancer, web server, database server), and the client will still be online.

Clusters can be installed in many different configurations, depending on your budget, but at the very minimum, you should have a pair of load balancers, web servers and database servers as shown in the diagram above.

If your application needs to scale, you simply add more web servers to the cluster, as needed. In my experience, the majority of the load comes onto the web servers. A pair of database servers is normally fine for even the busiest sites. Normally you want to put 4Gb RAM in your web servers and use a quad or eight core system with 8Gb RAM and RAID-10 for your database servers. For load balancers, I like the Foundry load balancing switches. They are a load balancer and switch in one appliance, which eliminates another possible failure point - your network switches.

And if you want to take the google route, you can set up clusters in multiple locations and geographically serve your traffic between locations so that you can lose and entire data center and still be online !! ;-)

If you have any questions about clusters, let me know. I’d be happy to answer them.

Share

5 Responses to “How to fix Bido”

  1. JeffB says:

    Hi,

    Nice writeup on clusting. Assista is running on a cluster. Bido.com on the other hand is not N+1 setup(Many internal reasons for that). It’s a delicate balance to be running in concert to a stable dnzoom architecture. Every decision is based off not changing the ‘current setup’ which has created bottle necks in the system design of bido. Once you reach a limit where business is affected you just have to take a step back and decide, and we have decided we need to move to a different architecture that is going to benefit Bido users. So don’t be counting us off ;) You have to take a step back in order to leap!

    JeffB

  2. Richard says:

    Jeff,

    Thank you for the follow up. Yes, I noticed that Bido is making calls to dnzoom which made me think that you could have load problems all over the place with a setup like that.

    And if you are running your front end in one location and backend in another, that will also be causing you speed and load problems.

    I hope you end up setting up a nice stable cluster just for Bido, and don’t forget a backup site in a second location !

    - Richard

  3. Eliot says:

    Hi Richard,

    For someone dipping their toes in the cluster waters for the first time, can you advise on a good economical initial step for a site moving from a dedicated server or VPS to a cluster?

  4. Richard says:

    Elliot,

    There are some companies that offer shared hosting from a cluster. I believe that Media Temple is one of them. Although I have not used their service, I see that it is very popular.

    If you want to stick with your own dedicated solution, then your hosting company will need to supply you with 2 web servers and 2 database servers and connect them to separate load balancing switches. It most cases, your hosting company can do the setup and config of the cluster for you and all you need to do is add your content.

  5. Eliot says:

    Thanks for the advice Richard - much appreciated!