My website is growing too large for the one webserver that powers it to handle the traffic. Anticipating this, the code is perfectly capable of running in parallel, sharing a database, but I've never actually tried to split one IP address among several webservers. What kind of hardware or software do I need to divide up incoming TCP connections between multiple boxes? Bonus points if the system can detect that one or more boxes has gone offline.
You need a load balancer. There are two kinds : software and hardware.
hardware : You buy a box that usually has a web interface and will split the traffic evenly between web servers. They usually have many features that allow you to do many things such as 802.1Q support, SFP, Global load balancing, SSL Termination, so on and so forth. These are quite expensive and you can get them from Cisco, F5, Radware, Barracuda (cheaper).
software : You get a standard server and you install load balancing software. This is quite easy to do with Linux. You can use either HAProxy or ldirectord or Keepalived. There are quite a few to chose from. This is a cheaper method but without all the pretty web interfaces and fun features.
Any half decent load balancing system will detect an offline server. All the above do.
You could use Varnish for this, or Pound two good and robust systems and varnish will even cache your site like a king and speed things up.
To add to what Antoine said, I would recommend a hardware load balancer if your site really is getting large. Software Load Balancers have a tendency to add a lot of overhead traffic on your network. Hardware Load Balancers are also usually designed with failover in mind since if not it becomes a single point of failure. As Atnoine mentioned they usually are very expensive. If you are a smaller shop I would recommend looking into a Load Balancer by Kemp Technologies, they are well made and perform well for a price that is literally a 10th of the big boys listed above. We are currently using a pair to Load Balance our website, student portal, and online learning portal at the online university where I run where we quite a bit of traffic everyday.
You can also kind of split up "services". Have one server handling requests for MySQL and the other handling web requests. You can also arrange it so that one is processing only images/static pages and the other handling dynamic requests. This should work regardless of operating systems and may provide some additional flexibility, but tightens the coupling of the servers.
The cheap way to do this is to get another IP address and add it to the A record for the website. Requests will then randomly be directed to one machine or the other. This doesn't automatically handle failover for you though, nor does it guarantee session consistency.