Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 10 Jul 2006 14:06:06 -0400
From:      Chuck Swiger <cswiger@mac.com>
To:        Mike Jakubik <mikej@rogers.com>
Cc:        stable@freebsd.org
Subject:   Re: MySQL and default memory limits (mysqld: Out of memory)
Message-ID:  <44B2970E.7000501@mac.com>
In-Reply-To: <44B28B7F.1000507@rogers.com>
References:  <44B16BE9.60508@rogers.com> <E56FEA0F58A776685B3AB5DF@[192.168.1.5]> <44B176D2.3080501@rogers.com> <44B276F7.4070507@mac.com> <44B28B7F.1000507@rogers.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Mike Jakubik wrote:
> Chuck Swiger wrote:
>> 512MB is more than enough for almost all processes to run just fine, 
>> and is only really inappropriate for the case where you've got 1-plus 
>> GB of physical RAM and want to dedicate the system to a single large 
>> task, or perhaps a single-digit number of processes if you've got 
>> several GB of physical RAM.
> 
> Such as a database server.

Yes, exactly.  :-)

Database servers are a rather specialized role which differs in tuning 
requirements from normal "general purpose"/"interactive use" workloads 
substantially, and it is common for databases to work much better after the 
system has been tuned appropriately.

This is partially because many databases want to do their own filesystem 
management and control their own VM/paging behavior, which are uncommon 
requirements.

> I just think it would be nicer if this limit 
> was dynamically set, based on your configuration. Just like MAXUSERS was 
> a kernel variable, it is now dynamically set based on your resources.

Yes, well, autotuning is nice but sometimes there isn't an "obviously correct 
value" for this limit which is appropriate for all circumstances.

Anyone doing virtual hosting needs to keep this kind of thing under tighter 
control, for example.  Setting the value lower is beneficial for some cases 
because it prevents memory leaks in C code or the system libraries, or bloated 
Java VM's, etc, from stealing too many resources from other processes.

-- 
-Chuck



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?44B2970E.7000501>