Date: Mon, 09 Dec 1996 19:56:17 -0600 From: "Eric L. Hernes" <erich@lodgenet.com> To: "Marc G. Fournier" <scrappy@hub.org> Cc: hackers@FreeBSD.ORG Subject: Re: Multiple Buffer allocation of Shared Memory Message-ID: <199612100156.TAA00658@jake.lodgenet.com> In-Reply-To: Your message of "Mon, 09 Dec 1996 19:56:16 EST." <Pine.NEB.3.95.961209194502.12999J-100000@hub.org>
next in thread | previous in thread | raw e-mail | index | archive | help
"Marc G. Fournier" writes: > >Hi... > > Just starting to play with shared memory, and have hit a wall >that I don't know if its too be expected, or if I've screwed something >up... Shared memory is cool, SysV symantics for shared memory *suck*, if at all possible use mmap(). BSDi uses libc wrappers around mmap() for it's SysV shm stuff, but there's caveats... I'd like the wrappers, but have the real ones available too. > > Basically, I'm setting up the shared memory as: > > > The problem seems to be when 'ii == 8', the shmget() is working, >but the shmat() is failing with 'strerror()' returning with: > >---- >hub> ./client >Too many open files >cannot initialize mesgptr #8 >---- yup, from /sys/conf/param.h: #ifndef SHMSEG #define SHMSEG 8 #endif you can only have 8 shm segments by default, you can override it with: `options "SHMSEG=32"' or something similar in your config file. I usually bump SHMSEG to 128 and SHMMAXPGS to 4096. > > which is the only one that I would think is appropriate to the >situation...unless its a kernel config problem... > You got it. > >Thanks in advance... > >Marc G. Fournier scrappy@hub.org >Systems Administrator @ hub.org scrappy@freebsd.org > > eric. -- erich@lodgenet.com http://rrnet.com/~erich erich@rrnet.com
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199612100156.TAA00658>