Subject: Re: "Allowed memory size of 8388608 bytes exhausted" installing
To: None <joel@carnat.net>
From: Steven M. Bellovin <smb@cs.columbia.edu>
List: pkgsrc-users
Date: 03/04/2006 15:02:43
On Sat, 4 Mar 2006 20:57:18 +0100
J
> > 
> well... in fact I saw that but couldn't change it ; so I thought I was
> looking at the wrong one.
> 
> # sysctl -w proc.curproc.rlimit.stacksize.hard=16777216
> proc.curproc.rlimit.stacksize.hard: 8388608 -> 16777216
> # sysctl proc.curproc.rlimit.stacksize
> proc.curproc.rlimit.stacksize.soft = 8388608
> proc.curproc.rlimit.stacksize.hard = 8388608
> 
> # ulimit -s 16384
> # ulimit -a
> time(cpu-seconds)    unlimited
> file(blocks)         unlimited
> coredump(blocks)     unlimited
> data(kbytes)         1048576
> stack(kbytes)        8192
> lockedmem(kbytes)    unlimited
> memory(kbytes)       unlimited
> nofiles(descriptors) 3404
> processes            1044
> sbsize(bytes)        unlimited

Odd -- it works for me, on both -current and 3.0.

# ulimit -a
time(cpu-seconds)    unlimited
file(blocks)         unlimited
coredump(blocks)     unlimited
data(kbytes)         262144
stack(kbytes)        8192
lockedmem(kbytes)    339682
memory(kbytes)       1019048
nofiles(descriptors) 256
processes            160
sbsize(bytes)        unlimited
# ulimit -s 32768
# ulimit -a
time(cpu-seconds)    unlimited
file(blocks)         unlimited
coredump(blocks)     unlimited
data(kbytes)         262144
stack(kbytes)        32768
lockedmem(kbytes)    339682
memory(kbytes)       1019048
nofiles(descriptors) 256
processes            160
sbsize(bytes)        unlimited

I don't know why you can't change it, but it's pretty clear that that's
the immediate problem.  (Whether compiling php4 should take such a
large stack is a separate issue.)