From owner-freebsd-questions Thu Dec 26 17:01:25 1996 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.4/8.8.4) id RAA21999 for questions-outgoing; Thu, 26 Dec 1996 17:01:25 -0800 (PST) Received: from hod.tera.com ([206.215.142.67]) by freefall.freebsd.org (8.8.4/8.8.4) with ESMTP id RAA21993 for ; Thu, 26 Dec 1996 17:01:23 -0800 (PST) Received: from athena.tera.com (athena.tera.com [206.215.142.62]) by hod.tera.com (8.7.5/8.7.3) with ESMTP id RAA03939; Thu, 26 Dec 1996 17:00:30 -0800 (PST) From: Gary Kline Received: (from kline@localhost) by athena.tera.com (8.7.5/8.7.3) id RAA10931; Thu, 26 Dec 1996 17:00:29 -0800 (PST) Message-Id: <199612270100.RAA10931@athena.tera.com> Subject: Re: multi-media app runs out of forking capabilities In-Reply-To: from Doug White at "Dec 26, 96 03:23:57 pm" To: dwhite@resnet.uoregon.edu Date: Thu, 26 Dec 1996 17:00:28 -0800 (PST) Cc: kline@tera.com, questions@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL23 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-questions@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk According to Doug White: > On Thu, 26 Dec 1996, Gary Kline wrote: > > > I didn't think that this would stall my devlopment, but > > it has. Before I upgraded to 32MB of memory I sometimes > > would get a ``Can't fork'' error from the kernel. I > > thought that having 32 megs would automagically resolve > > this problems, but no such luck. > > It depends on what causes the error. I highly doubt it's out of memory. > No, the proc table may be full, though.... > > > > Now I'm writing a multi-media app that does many forks > > to spawn and kill ancillary processes, and I am getting > > the same `can'tt fork' messages. > > > > My zsh used to allow ulimit -p where N could be > > large. The number of processes currently defaults to > > just 40. No longer. > > > > Q1: What's the quick fix, if there is one for the 2.1.5 > > kernel? > > Try 'ulimit' with no options. Under sh and csh, it unlocks all the > resource restrictions. Will do, thanks.. I've also thought of another way that would obviate all these scores of forks:: Using whatever IPC that FBSD has might work. Is there a way that one program can send a flag to another program? Assuming yes, where is some sample code?? > > > Q2: What and where can I set the default and rebuild > > my kernel so that I have an unlimited or large (say 200) > > procs? > > I don't think this is a kernel issue. > Well, I found that ``limit maxprocs 300'' sets that limit. But even with that I ran out of the ability to spawn new procs at around 60 forks. Setting maxprocs higher didn't help. gary