Today we are kicking off a series of posts that explain how you can use some simple mathematical tools to maximize server throughput in your data center. We will write one article per week to slowly build up our idea and introduce you to the concept.
The throughput of any device (server, database, network switch) is subject to certain limitations. For example, you cannot add too many JVMs to a virtualized application server (or a dedicated one) without slowing the performance of other JVMs. This is because both exist in the same virtual machine – their CPU time and memory is shared between the resources.
You can increase swap space on a server and decrease actual memory available to one application to give it to another, but that can cause the computer to page out memory to disk, creating a bottleneck, thus slowing down the entire computer.
In an ideal world, CPU, memory, network bandwidth, switch speed, all would be limitless, but they are not (even if they seem limitless as servers have become commodities). Instead, to optimize performance in an application there are a series of trade-offs such as those that were just explained. Regarding tradeoffs, where is the optimal point? What is the optimal number of JVMs? With the proper tools, there is no need to guess or use trial and error. Instead we can calculate that optimal point exactly.
Measuring how one can maximize throughput in a server subject to the constraints of memory and CPU, among others, is a classic example of a branch of mathematics called “linear programming.” Do not worry – there is no need actually learn how to solve these kinds of problems with paper and pencil or whiteboard. Instead, Microsoft Excel can do that for you with its plug-in called the “Solver.”
Linear programming can be used to look at various aspects of your operation. All you need is a number that you wish to maximize (server throughput), subject to certain limitations (memory, CPU, network latency). The difficulty lies in formulating the problem and using some common means of measurement.
In the next post, we will begin by explaining the classic example of linear programming known as the “transportation problem.” This is what professors normally use to start teaching their students about maximization-minimization problems. Once you understand that, you will be able to follow the subsequent discussion and understand more clearly how to apply such analysis in your own organization. I think you’ll find it useful in measuring performance.