Re: Memory settings.
Timo Hoepfner <[email protected]> Thu, 27 Jan 2005 15:57:20 +0100
| Newsgroups | gmane.comp.web.webobjects.admin |
|---|---|
| Message-ID | <[email protected]> |
> > 2. I tried setting to: Xmx2048m Xms128m (also tried Xmx3g Xms1g) but > this seems not possible. I app wouldn't start up and I get this error > message in webobjects.err: > > "Could not reserve enough space for object heap > Error occurred during initialization of VM" > From Apple's java-dev mailing list (http://lists.apple.com/archives/java-dev/2003/Dec/msg00000.html): > Subject: Re: Allocating more than 2G heap for JVM > From: email@hidden > Date: Mon, 01 Dec 2003 08:38:32 -0800 > > email@hidden wrote: > | If I perform the command: > | java -Xmx3G -version > | > | the result is: > | Error occurred during initialization of VM > | Could not reserve enough space for object heap > | Trace/BPT trap > | > | Does anybody know how to make it work? > > Wait until there's a version of Java that uses 64-bit addresses. (It > probably won't exist until at least 10.4. Right now, everything but > the OS itself is limited to 32-bit addresses.) The addresses Java > currently uses aren't large enough to handle more than 2GB. (And a > sizable chunk of that 2GB is already reserved for various uses.) > > Glen Fisher > I just tried it. The actual limit seems to be 1932m: [pbg4:/] th% uname -a Darwin pbg4.local 7.7.0 Darwin Kernel Version 7.7.0: Sun Nov 7 16:06:51 PST 2004; root:xnu/xnu-517.9.5.obj~1/RELEASE_PPC Power Macintosh powerpc [pbg4:/] th% java -Xmx1932m -version java version "1.4.2_05" Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_05-141.3) Java HotSpot(TM) Client VM (build 1.4.2-38, mixed mode) [pbg4:/] th% java -Xmx1933m -version Error occurred during initialization of VM Could not reserve enough space for object heap Trace/BPT trap [pbg4:/] th% Just tried it on a Sun Fire V440 with 8GB RAM. The limits are higher there. Intrestingly enough the messages of the JVM change there when approaching the limit... Here's the result: bash-2.05$ uname -a SunOS dudp 5.9 Generic_117171-09 sun4u sparc SUNW,Sun-Fire-V440 bash-2.05$ java -Xmx3924m -version java version "1.4.1_06" Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1_06-b01) Java HotSpot(TM) Client VM (build 1.4.1_06-b01, mixed mode) bash-2.05$ java -Xmx3925m -version Fatal: Unable to create signal thread (may be due to resource limit) Abort (core dumped) ... bash-2.05$ java -Xmx3929m -version Error occurred during initialization of VM Could not reserve enough space for heap offset array ... bash-2.05$ java -Xmx3933m -version Error occurred during initialization of VM Could not reserve enough space for card marking array ... bash-2.05$ java -Xmx3945m -version Error occurred during initialization of VM Could not reserve enough space for object heap Timo