Title: RE: Memory Settings (was: java.lang.OutOfMemoryError)

The short answer is... it's complicated,  you can set the VM to a size large than you RAM size, though I would not do this if I were you.

In order to have a heap size of more that 2G you have to be using jdk1.3.1 and above

-Xmx2g would set the heap to 2Gig: be warned the VM will though an error if it can not initialize this much space.

-XX:+AggressiveHeap will take as much memory as needed, I believe it initializes at 350mg. BE WARNED this can cause serious problems on your machine. If I am not mistaken you only have 4G of memory space available to you, so if you start to infringe on this space with the VM, other programs (inside and outside the vm) could run into issues.

The reality is you should only set the VM to the amount of RAM available on you machine..

CAVEAT: I am not an expert on this subject, this is just my experience and what I have read in the past.

My 2 cents.

Rob



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Friday, June 06, 2003 1:59 PM
To: [EMAIL PROTECTED]
Subject: Memory Settings (was: java.lang.OutOfMemoryError)


The recent posts about FOP running out of memory has me thinking.

Suppose for a second that FOP is run on a Windows 2000 box.  Assume the box
has 512 MB of RAM.  Pretend that a certain XSL-FO causes the JVM to run out
of memory.

The question is:  Can the JVM heap size be set to a value larger than the
available RAM on the computer?  For instance, in this case could -Xmx1024M
be used to up the JVM heap to 1 GB?  Would this prevent the JVM from
crashing with an OutOfMemoryError?

Now, *if* it did work, I'll assume that anytime an XSL-FO pushed the heap
to a value higher than the amount of RAM, there would be a lot of memory
swapping, which of course would hinder performance.  But it might prevent a
system crash.  Would setting the JVM heap to a value higher than the
available RAM adversely affect the performance of all XSL-FO's, or just the
ones where the XSL-FO actually pushed the heap up that much in the first
place?

If anybody has tried this please share your experiences.  Or, share your
thoughts on what might happen.

Thanks!!

-Ryan







---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to