SunOS 4.0 Dynamic Linking

Steve Souza @eldest souza at telesoft.UUCP
Thu Oct 6 07:39:30 AEST 1988


The problem is solved!  Many thanks to all who responded.

    Turns out to have been a problem with the max allocable
process stack segment.  There is a call to setrlimit in our
daemon just prior to the system(3) of the sub-process.  This
call removed the limit on RLIMIT_STACK, and set it to
RLIM_INFINITY. 

    This seems to make the dynamic linker (DL) unhappy.  One
person (Greg Onufer) who had this problem reported that
increasing the swap partition size on his system fixed the
problem.  Seems the DL uses less physical memory, but more
virtual memory.  These pieces all fit together somehow, but I
don't know how without source.  I wonder if the DL doesn't
pre-allocate stack to the limit before invoking the command...

    Anyways, You can duplicate these messages on your 4.0
system by playing with the C-shell "limit" command:

	unlimit stack
	ls
	limit stack 2048
	
Here are some of the command error messages I got after creeping up
towards the system limit:

	ld.so: swap space exhausted for mmap of /usr/lib/libc.so.0.10
	ld.so: map heap error (22) for /dev/zero
	crt0: /usr/lib/ld.so mapping failure
----------------------------------------------------------------------------
Steve Souza			ucsd!telesoft!souza, telesoft!souza at ucsd.edu
TELESOFT Inc., San Diego, CA	(619)457-2700 x277



More information about the Comp.unix.wizards mailing list