How to setup 2 server or 4 server load balancer/cluster? LAMP/MysqlReplication/Rsync

Our company is currently running a single webserver for the company site with a RAID5 server. While this setup prevents downtime from hard drive failure, we are in need of an upgrade and are looking into possibly running 2 servers where one is the master and the other is in sync and available if the master dies or breaks. We want 100% uptime since we have alot of things hitting this box constantly.

What are your ideas on how to set something up like this?

Ideally we would want to use LAMP on UBUNTU 8 or 9. If we were to power down Server1, Server2 would take over the requests until Server1's hardware or software is fixed and appears back online. Is something like this possible with just 2 servers?

From what I could find... The popular setup would be 2 load balancers (checking availability of each other)  and 2 web servers (running rsync and mysql replication) with 5 IP addresses. Is it possible to do a setup like this without the need for the 2 load balancers?  

Im looking for the protection if webserver1 goes down that webserver2 will take over so we can then fix
webserver1 without downtime. Whats the cheapest and best way to do this with 2 servers? If it isnt possible with 2 servers what is the best way to do it with 4?
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

I was looking for a similar solution and came across this page:

I'm not sure how old this article is but it shows some merit for the application you are a looking for.  

Good luck!

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
i would recommend 'dns load balancing' for cheapest disaster solution and splitting the load, you just need a dns server, and two synced machine. You can use whatever software using before.

you can find information about dns load balancing at
I successfully built a load balanced apache server cluster last week in the lab using the following tools:

-Two servers running vmware esxi
-Two virtual pen machines (pen  is a load balancing software that runs on linux).  If you use esxi you can download a 4mb linux OS template called "hercules load balancer" which incorporates a number of tools (pen, vrrp) for load balancing and HA between two load balancers using a virtual IP.  Vrrp (virtual router redundancy protocol) is used to load balance the load balancers (uber redundancy!) and is a snap to setup.  It also allows you to "bond" the two load balancers under one virtual IP address so you can avoid any kind of round robin dns disasters (trust me, round robin dns is a NIGHTMARE... I speak from 150000 email customers experience)
-Two virtual apache machines, one the master node where changes are made, a second node which has the data rsynced to it.

You configure the Hercules load balancers to share a virtual IP, then you define cluster nodes behind the load balancers... load balancing done!
Then the hardest part is configuring your apache server with rsync and migrating the appropriate directories and setting up cron jobs to keep your httpd daemon up-to-date on the slave node.

Good luck!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.