
jesus at omniti
Sep 12, 2002, 6:51 AM
Post #2 of 6
(992 views)
Permalink
|
Gary Sewell wrote: >Hi List > >This is my first post, so thanks for listening > >Im currently running our datbase (mysql) on box1 and all the perl for the >site is running on box2 and speaking to box1 via TCP. These are connected >over a 10Mb link which will soon be upgraded to 100Mb. > >Box2 gets bogged down with perl requests and we are going to add another box >to share the load. > >So this is what Im looking for... >A single database server (box1) and then the other 2 (box2 and box3) sharing >requests to www.mysite.com so they can share the load of the perl requests >which is our biggest problem at the moment. > >I've been reading into backhand and am still not too sure how it works... Im >not sure if it needs to be installed on all three servers or only the inital >box that receives all the requests. > All machines that run Apache that are participating in cluster activity (whether receiving originating requests to proxied requests) must have mod_backhand installed. >Im thinking of using box1 to host tha apache that receives all requests to >www.mysite.com and then spitting them out to box2.mysite.com or >box3.mysite.com. Is it a good idea to have the main apache on the same box >as the mysql? > If by "main" you mean the one doing the least amount of work, then it make good sense. :-D If you plan on having the single frontend machine running a thin Apache that just backhands requests to box2 and box3, then I don't see any problem with it. Other than you have a pretty severe single point of failure. If you have some IPs to use, I might suggest this: box1 run mysql and Apache. box2 and box3 have a standby copy of mysql and run apache. All three are publicly accessible. All are running mod_backhand. Use DNS RR to cycle through the boxes. Use wackamole to make sure that all 3 IP addresses are always up in the event of a box failure. This is must more complicated, but provides you with a bit more horsepower and infinitely more redundancy (as you had zero before). >Another problem is that I want to get a firewall up and running, but box1 >has FreeBSD on it and apprently needs recompiling to be able to do this. > If this is a standard FreeBSD install, this is unlikely. You just need to load the ipfw module. man ipfw :-) Be careful, it defaults to deny all, you will lock yourself out of your machine if you are not _very_ careful... This is best to do for the first few times from the console. >Howere the new box has linux and I will be able to run IPTABLES on this, so >I am thinking of running the new box as box1 and swapping the vurrent box1 >to be box3... Only problem is box3 has an ide drive while the other 2 have >scsi drives... > >Your ideas will be greatfully received. > > If you perl requests are bogging down your server, perhaps some application rearchitecting might alleviate the problem. Most applications have plenty of slow code that could be optimized (even if they are 2nd or 3rd generation). The key is figuring out _what_ to try to optimize. -- Theo Schlossnagle 1024D/82844984/95FD 30F1 489E 4613 F22E 491A 7E88 364C 8284 4984 2047R/33131B65/71 F7 95 64 49 76 5D BA 3D 90 B9 9F BE 27 24 E7
|