Re: free reporting wrong values?
- From: Christian Schröder <chschroe@xxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 11 Jun 2008 08:03:03 +0200
Robert M. Riches Jr. wrote:
The JVM imposes limits of its own. Try
java -X
to see some of them. The initial and maximum heap sizes are
probably what you're looking for.
The problem with java was that I gave the JVM 2048M initial heap size (-Xmx2048m) which should have been possible according to "free", but the JVM did not even start and instead gave me error messages:
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.
So I asked myself (and also the newsgroup) why java was unable to reserve the requested memory although "free" reported that enough was available.
To answer this question I wrote that little C program and found out that it also could not reserve as much memory as "free" reported. Thus, the question is NOT java specific, but more general: Why does "free" report 2.5G of free memory, but only 1.5G are available to an application? (That's exactly what I asked in my original post. Maybe the java stuff was misleading. I just tried to give some context.)
Regards,
Christian
.
- Follow-Ups:
- Re: free reporting wrong values?
- From: Robert Heller
- Re: free reporting wrong values?
- References:
- free reporting wrong values?
- From: Christian Schröder
- Re: free reporting wrong values?
- From: Robert M. Riches Jr.
- free reporting wrong values?
- Prev by Date: Re: Software RAID on Linux Server
- Next by Date: Re: cmp 2 or more files and print out common rows
- Previous by thread: Re: free reporting wrong values?
- Next by thread: Re: free reporting wrong values?
- Index(es):
Relevant Pages
|