Posted by: Anonymous Coward
on April 25, 2006 05:38 PM
This article is brief and the setup in my opinion does not advocate the best way of allocating resources. (Mistakes such as cookie locations doesn't help).
Firstly you should always look at your system and analysis where the bottle neck is. Sometimes just replicating the sytems n times, although may work is actually very cost ineffective. Instead of having the same setup 5 times, may be better to split the tasks on sperate machines.
Further having worked on many mysql systems, one of the fastest way to use mysql is to have 1 read database and many read database slaves. All it takes is coders to write code to use 2 different DB's. Remember for most LAMP sites reads (selects) significantly used more than writes. I dread when I sometimes look at the mysql queries constructed. Of course I understand that this is not always an option for some people as they use off-the-web applications (which many are pretty good) with little leeway for modification.
If you have the traffic that you need to scale to more than a few machines. In my experience if you need 3 or more machines, a load balancer will save you more time and aggro in the long term if you employ a good one of course (the old WSD were really bad when state tables filled up). Cookie issues become irrelevant as LB's have sticky cookies ensuring the user will always go back to the same machine. Also a good one (I won't advertise one) allows you many many load balancing options such as observed load balacing. Remember even if you get even traffic across your machines not everyone will use the same amount of resources and hence some machines will be more loaded and customer experience worsen.
I have worked on systems with hits exceeding 8 million a day and day one of the job is always convincing the owner that buying another machine is not always the best answer. Often anaylsis of the existing system results in me, moving resources around, setting up mysql more efficiently (not much can be done about poor DB schemas people employ even when better indexes are added) and many times no need hardware is needed, service runs faster and smoother.
There is so many resources on the web with help to system anaylsis you don't have to be a pro to work out where bottlenecks are. This is how I started but when you done it load of times it becomes easier and quicker to spot even with the changes in the software and hardware.
Be flexible and open minded. I am always suprised when I revisit old systems I have setup and find both things I could have done better and things that I did that I forgotten was a good idea!
Horses for courses..
Posted by: Anonymous Coward on April 25, 2006 05:38 PMFirstly you should always look at your system and analysis where the bottle neck is. Sometimes just replicating the sytems n times, although may work is actually very cost ineffective. Instead of having the same setup 5 times, may be better to split the tasks on sperate machines.
Further having worked on many mysql systems, one of the fastest way to use mysql is to have 1 read database and many read database slaves. All it takes is coders to write code to use 2 different DB's. Remember for most LAMP sites reads (selects) significantly used more than writes. I dread when I sometimes look at the mysql queries constructed. Of course I understand that this is not always an option for some people as they use off-the-web applications (which many are pretty good) with little leeway for modification.
If you have the traffic that you need to scale to more than a few machines. In my experience if you need 3 or more machines, a load balancer will save you more time and aggro in the long term if you employ a good one of course (the old WSD were really bad when state tables filled up). Cookie issues become irrelevant as LB's have sticky cookies ensuring the user will always go back to the same machine. Also a good one (I won't advertise one) allows you many many load balancing options such as observed load balacing. Remember even if you get even traffic across your machines not everyone will use the same amount of resources and hence some machines will be more loaded and customer experience worsen.
I have worked on systems with hits exceeding 8 million a day and day one of the job is always convincing the owner that buying another machine is not always the best answer. Often anaylsis of the existing system results in me, moving resources around, setting up mysql more efficiently (not much can be done about poor DB schemas people employ even when better indexes are added) and many times no need hardware is needed, service runs faster and smoother.
There is so many resources on the web with help to system anaylsis you don't have to be a pro to work out where bottlenecks are. This is how I started but when you done it load of times it becomes easier and quicker to spot even with the changes in the software and hardware.
Be flexible and open minded. I am always suprised when I revisit old systems I have setup and find both things I could have done better and things that I did that I forgotten was a good idea!
#