Ick: Setting shared memory segment size

Greg Patterson (root@gomer.mlink.net)
Tue, 31 Dec 1996 20:47:15 -0500 (EST)


In a beta version of "The Gimp", it makes the following recommendation in
the INSTALL file:

Linux
-----

Linux is a free POSIX operating system for IBM PCs and
compatibles. By default, the kernel is configured with a maximum
shared memory segment size of 3.98 megs. This is probably large enough
for most users, but if you need to work with large images (larger than
1024x1024), then you will need to increase this value. It is easily
done by anyone who has recompiled their kernel before. In the
"include/linux/shm.h" header file in the kernel source tree, change
the value of `SHMMAX' to a larger value. The largest possible value is
`0x2000000'. (The current value is `0x3fa000'). This change will make
it possible for shared memory segments to be up to 32 megs in
size. (Which would be an RGB image of 2890x2890). I'm not sure what,
if any, side effects this may have. But I have made this change and
have experienced no negative effects...yet.

Assuming the author of the above note is reasonably correct, surely there
must be an easier way to modify this value through a /proc interface or
such. The author continues with Solaris settings suggesting that the
share memory maximum can be changed in an /etc/system configuration file.

Just something for you kernel gurus to think about. It might be nice for
other maximums to be adjustable without needing to do a kernel recompile
all of the time.

==============================================================
| Greg Patterson | EMAIL: root@gomer.mlink.net |
| | gomer@mlink.net |
| | IRC: Wizird (#Linux) |
| Linux is the Future! | WWW: http://gomer.mlink.net/~root |
==============================================================