Every so often people ask me the question how should they estimate memory consumption by MySQL Server in given configuration. What is the formula they could use.
The reasons to worry about memory usage are quite understandable.
If you configure MySQL Server so it uses too small amount of
memory it will likey perform suboptimally. If you however
configure it so it consumes too much memory it may be crashing ,
failing to execute queries or make operation to swap seriously
slowing down. On now legacy 32bit platforms you could also run
out of address space so that had to be watched as well.
Having said so, I do not think looking for the secret fomula to
compute your possible memory usage is the right approach to this
problem. The reasons are - this formula is very complex nowadays
and what is even more important "theoretically possible" maximum
it provides have nothing to do with real memory consumptions. In
fact typical server with 8GB of …