[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Shared Memory & Semaphore
Tim Wu <tim@vbisd.org>wrote:
>>>>Subject: Shared Memory & Semaphore
>>>>Hi,
>>>> Does anyone know how to config shared memory & semaphore parameters.
>>>>
>>>>Like SHMMAX, SHMIN, SHMMNI, SHMSEG, SEMMNS, SEMMNI AND SEMMSL. Or if
>>>>you know there is a reference/how-tos I can find on the internet.
"Adam Williams" <awilliam@whitemice.org>wrote:
>These variable are found in the header files in the kernel source code.
>/usr/src/linux/include. But it does not seem clear what each means or what
>it's default value is. If your worried about minimums you might try asking a
>question on the kernel mailling list. I know that I have PostgreSQL running
>with 24Mb of shared memory, if I try to set it to 32Mb it won't start due to
>an inability to allocate shared memory. I think that might reflect some kernel
>limit, as my machine has 256Mb of RAM and 160Mb of swap. I'd like to know how
>to turn it up.
I'm a bit surprised the Oracle people don't provide more information on this.
While you're looking at kernel source, swoop by /usr/src/linux/ipc and look at
shm.c and sem.c, which contains a number of functions that appear to be VERY
SIMILAR (in declared syntax, anyway) to the shared memory and semaphore soft-
ware that SUN provided with both SunOS and Solaris. I wrote applications that
used those, but it's been a while (Bush was President at the time). It would
not surprise me that this is reverse engineered to work like the old Sun
software, and it may be worthwhile to snoop around the Sun website to see if
you can pick up something from there as well. Be careful about this, the Linux
calls may well be different, even slight differences will mean a great deal.
Adam, I'd like to know with WHAT that PostgreSQL is sharing 24 MEG of memory?
We used to measure shared memory in KB [!!]
Tim, please share what you find, and good luck on your search! I agree with the
idea of asking theis question on the kernel mailing list, as well.
---> RGB <---