Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 14 Jun 2007 14:03:46 -0400
From:      John Baldwin <jhb@freebsd.org>
To:        Jin Guojun <jin@george.lbl.gov>
Cc:        questions@freebsd.org, freebsd-hardware@freebsd.org
Subject:   Re: what causes error -- ELF interpreter /libexec/ld-elf.so.1 not found
Message-ID:  <200706141403.47035.jhb@freebsd.org>
In-Reply-To: <4670708A.5030805@george.lbl.gov>
References:  <466B2B9F.5010308@lbl.gov> <200706131001.25840.jhb@freebsd.org> <4670708A.5030805@george.lbl.gov>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wednesday 13 June 2007 06:32:42 pm Jin Guojun wrote:
> Umm, the amount of physical memory has no bearing on how the virtual
> address space for userland is laid out.  Do you know what virtual memory
> is and how it works?  Your first e-mail seems to contradict this paragraph
> as in your first e-mail you noted that the physical memory doesn't matter,
> the solution was to not raise MAXDSIZ higher than 1GB and that is consist=
ent
> with running out of virtual address space due to MAXDSIZ reserving too mu=
ch
> address space for malloc().
>  =20
>  No quite clear on this. Does this mean that the MAXDSIZ cannot exceeed 1=
GB=20
regardless
>  how many physical memory (say 16 GB) is installed? Then, this is=20
definitiely a software bug.
>  Then, somewhere the following checking is needed:
> =20
>  #if (MAXDSIZ > 1024 * 1024 * 1024)
>  #undef=A0=A0 MAXDSIZ
>  #define=A0=A0 MAXDSIZ=A0=A0 (1024 * 1024 * 1024)
>  #endif

It depends on the app.  Some apps you can crank the malloc space up a whole=
=20
lot.  Also, if you are running FreeBSD/amd64 and running a 32-bit binary=20
under freebsd32 emulation, then it has 4GB of VA space rather than 3GB, so=
=20
you can give it more MAXDSIZ.  It's really up to the user to only use a=20
maxdsiz that works.  You can also adjust the hard limit before exec'ing a=20
process that needs a smaller dsize and leave MAXDSIZ larger for other=20
processes.  Since it is dependent on things the compiler can't know about a=
t=20
the build time of the kernel, we just let the user set it to whatever and i=
f=20
they set it too high things break until they lower it.  You can even set th=
is=20
at boot time via 'kern.maxdsiz' tunable in the loader w/o needing to=20
recompile.

=2D-=20
John Baldwin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200706141403.47035.jhb>