Date: Wed, 24 May 2006 12:51:03 +1200 From: Mark Kirkwood <markir@paradise.net.nz> To: Kirk Strauser <kirk@strauser.com> Cc: freebsd-stable@freebsd.org Subject: Re: PostgreSQL uses more memory on 6.1? Message-ID: <4473ADF7.4080101@paradise.net.nz> In-Reply-To: <200605231636.27463.kirk@strauser.com> References: <200605231531.18092.kirk@strauser.com> <200605231713.22363.jkim@FreeBSD.org> <200605231719.56164.jkim@FreeBSD.org> <200605231636.27463.kirk@strauser.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Kirk Strauser wrote: > On Tuesday 23 May 2006 16:19, Jung-uk Kim wrote: > >> I meant 'kern.ipc.shmall', which used to be 'kern.ipc.shmmaxpgs'. :-( > > That did it! Bumping kern.ipc.shmall to 65536 got me back up and running > with enough shared_memory to get my jobs done. Having not so long ago been caught by this myself, I think the relationship between shmmax and shmall is worth clarifying: $ sysctl -d kern.ipc.shmall kern.ipc.shmall: Maximum number of pages available for shared memory $ sysctl -d kern.ipc.shmmax kern.ipc.shmmax: Maximum shared memory segment size So to run 1 Postgres installation with 128Mb of shared memory: kern.ipc.shmall=32768 kern.ipc.shmmax=134217728 However suppose you want to run 2 Postgres installations, each using 128Mb of shared memory: kern.ipc.shmall=65536 kern.ipc.shmmax=134217728 i.e. maximum system wide shared memory is 65536*4096 = 256Mb, but the maximum size any single segment can be is 128Mb. Cheers Mark
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4473ADF7.4080101>