Netscape Enterprise server child stack limit

Netscape Enterprise server child stack limit

Post by elliot » Sat, 25 Oct 1997 04:00:00



I notice that Netscape Enterprise Server 3.0 limits its children's stack
size to 512 KBytes. I want to run a program from the server that has
much larger requirements than that. Does anyone know how I can increase
this limit?

--
Elliott Hughes - GeneData AG, Postfach 254, CH-4016 Basel, Switzerland

 
 
 

Netscape Enterprise server child stack limit

Post by Jay Goldber » Wed, 29 Oct 1997 04:00:00


Threads and the stack

The default size for the process stack on all platforms is 64 KB. Each
thread consumes space on the
stack. Unfortunately, if the stack overflows, most platforms just give you a
segmentation fault or a
general protection fault (GPF) without specifically noticing the stack
overflow. So you need to be
aware that the stack size is small.

A new StackSize parameter, specifying the number of bytes to be set aside
for the stack, has been
added to the magnus.conf file.

One way to determine whether an abnormal termination was caused by a stack
overflow is to scan the
stack trace near the top and the bottom. Look at the addresses of the local
variables in the top frame
and the addresses of the local variables in the bottom frame. If these
addresses are more than 65536
apart, you had a stack overflow.


> I notice that Netscape Enterprise Server 3.0 limits its children's stack
> size to 512 KBytes. I want to run a program from the server that has
> much larger requirements than that. Does anyone know how I can increase
> this limit?

> --
> Elliott Hughes - GeneData AG, Postfach 254, CH-4016 Basel, Switzerland



 
 
 

Netscape Enterprise server child stack limit

Post by elliot » Fri, 31 Oct 1997 04:00:00



> I think Jay misses the point. The question was how to get around the
> 512K limit for the thread stack, not how to change the default setting
> (which is 64K)

Actually, the question was how to get around the 512 KByte hard & soft
limits set with setrlimit(2) for the fork(2)'ed process which then
exec(3)'s a CGI child. The thread stack size (set with StackSize in
magnus.conf) is for Netscape server extensions, not CGI programs.

The child stack limit is (on IRIX 6.2 at least) 512 KBytes, not 64
KBytes. That's a different stack, internal to the server.

I get the feeling that Netscape would rather we used WAI or server
extensions --- in short, anything Netscape-specific. As far as I can
see, there's no way to alter the CGI I/O timeout either.

--
Elliott Hughes - GeneData AG, Postfach 254, CH-4016 Basel, Switzerland

 
 
 

Netscape Enterprise server child stack limit

Post by Ulf Leonhard » Fri, 31 Oct 1997 04:00:00


I think Jay misses the point. The question was how to get around the
512K limit for the thread stack, not how to change the default setting (which is
64K)

Apparently, Elliot has already used the StackSize parameter in  magnus.conf.

So does anybody have the answer? I have the same problem.

Thanks
Ulf

 
 
 

Netscape Enterprise server child stack limit

Post by Ulf Leonhard » Sat, 01 Nov 1997 04:00:00


Well, at least NSAPI allows you to write your own CGI handler,
which of course is a bit of a hassle.
Does the limit your refer to also prevent you from creating threads
with a stack bigger than 512KB in the CGI process?

Ulf



> > I think Jay misses the point. The question was how to get around the
> > 512K limit for the thread stack, not how to change the default setting
> > (which is 64K)

> Actually, the question was how to get around the 512 KByte hard & soft
> limits set with setrlimit(2) for the fork(2)'ed process which then
> exec(3)'s a CGI child. The thread stack size (set with StackSize in
> magnus.conf) is for Netscape server extensions, not CGI programs.

> The child stack limit is (on IRIX 6.2 at least) 512 KBytes, not 64
> KBytes. That's a different stack, internal to the server.

> I get the feeling that Netscape would rather we used WAI or server
> extensions --- in short, anything Netscape-specific. As far as I can
> see, there's no way to alter the CGI I/O timeout either.

> --
> Elliott Hughes - GeneData AG, Postfach 254, CH-4016 Basel, Switzerland


--
-------------------------------------------------------

 Imperial College    | Phone:         +44 171 594 8249
 Dept. of Computing  | Fax:           +44 171 581 8024
 180 Queens Gate     |
 London SW7 2BZ, UK  | http://www-dse.doc.ic.ac.uk/~ul
-------------------------------------------------------