outofMemory Exception in hot Deploy of jboss 3.2.5  
Author Message
elh.maayan





PostPosted: 2007-5-21 22:52:00 Top

java-programmer, outofMemory Exception in hot Deploy of jboss 3.2.5 hi...

why after a few hot deploys i get OutOfMemory Exception (i've allready
increased xmx and xms)

 
Tom Hawtin





PostPosted: 2007-5-22 1:08:00 Top

java-programmer >> outofMemory Exception in hot Deploy of jboss 3.2.5 email***@***.com wrote:
>
> why after a few hot deploys i get OutOfMemory Exception (i've allready
> increased xmx and xms)

Probably a memory leak then. A number of pieces of code in Sun's JRE can
leak class loaders (and hence all the classes and other data associated
with them). ThreadLocal is the common one. But java.beans and JDBC also
do it.

You can use a memory profiler to tell where the problem is. Googling can
give you more details.

It may be the permanent generation (code and interned strings) that is
running out. IIRC, -XX:MaxPermSize is the Sun option to increase that.

Tom Hawtin
 
elh.maayan





PostPosted: 2007-5-27 4:07:00 Top

java-programmer >> outofMemory Exception in hot Deploy of jboss 3.2.5 which java Profiler should i use?

and should i use the syntax java -XX:MaxPermSize=1024 ? (in jboss
command line run.bat)

On May 21, 8:07 pm, Tom Hawtin <email***@***.com> wrote:
> email***@***.com wrote:
>
> > why after a few hot deploys i get OutOfMemory Exception (i've allready
> > increased xmx and xms)
>
> Probably a memory leak then. A number of pieces of code in Sun's JRE can
> leak class loaders (and hence all the classes and other data associated
> with them). ThreadLocal is the common one. But java.beans and JDBC also
> do it.
>
> You can use a memory profiler to tell where the problem is. Googling can
> give you more details.
>
> It may be the permanent generation (code and interned strings) that is
> running out. IIRC, -XX:MaxPermSize is the Sun option to increase that.
>
> Tom Hawtin


 
 
Andrew Thompson





PostPosted: 2007-5-27 4:20:00 Top

java-programmer >> outofMemory Exception in hot Deploy of jboss 3.2.5 email***@***.com wrote:

Please refrain from top-posting.
<http://www.physci.org/codes/javafaq.html#toppost>

>...should i use the syntax java -XX:MaxPermSize=1024 ? (in jboss
>command line run.bat)

If the problem is a memory leak as Tom suggested, no.
At least, not unless you consider that doubling the
memory might allow the app. to run (roughly) twice
as long before failing, and that makes for 'a solution'.

--
Andrew Thompson
http://www.athompson.info/andrew/

Message posted via JavaKB.com
http://www.javakb.com/Uwe/Forums.aspx/java-general/200705/1

 
 
Lew





PostPosted: 2007-5-27 23:03:00 Top

java-programmer >> outofMemory Exception in hot Deploy of jboss 3.2.5 Andrew Thompson wrote:
> email***@***.com wrote:
>
> Please refrain from top-posting.
> <http://www.physci.org/codes/javafaq.html#toppost>
>
>> ...should i use the syntax java -XX:MaxPermSize=1024 ? (in jboss
>> command line run.bat)
>
> If the problem is a memory leak as Tom suggested, no.
> At least, not unless you consider that doubling the
> memory might allow the app. to run (roughly) twice
> as long before failing, and that makes for 'a solution'.

Other options that may help you avoid the real problem until it pops up in
production at the least opportune moment:

-XX:+CMSClassUnloadingEnabled
-XX:+CMSPermGenSweepingEnabled

--
Lew
 
 
Andrew Thompson





PostPosted: 2007-5-27 23:21:00 Top

java-programmer >> outofMemory Exception in hot Deploy of jboss 3.2.5 Lew wrote:
..
>> ...might allow the app. to run (roughly) twice
>> as long before failing, and that makes for 'a solution'.
>
>Other options that may help you avoid the real problem until it pops up in
>production at the least opportune moment:
>
>-XX:+CMSClassUnloadingEnabled
>-XX:+CMSPermGenSweepingEnabled

Huhh. Those options are new to me. I'll have to
look them up!

--
Andrew Thompson
http://www.athompson.info/andrew/

Message posted via JavaKB.com
http://www.javakb.com/Uwe/Forums.aspx/java-general/200705/1

 
 
Lew





PostPosted: 2007-5-27 23:34:00 Top

java-programmer >> outofMemory Exception in hot Deploy of jboss 3.2.5 Andrew Thompson wrote:
> Lew wrote:
> ..
>>> ...might allow the app. to run (roughly) twice
>>> as long before failing, and that makes for 'a solution'.
>> Other options that may help you avoid the real problem until it pops up in
>> production at the least opportune moment:
>>
>> -XX:+CMSClassUnloadingEnabled
>> -XX:+CMSPermGenSweepingEnabled
>
> Huhh. Those options are new to me. I'll have to
> look them up!

It's something I lifted from NetBeans's config file examples.

Options like this are nearly undocumented, perhaps for a reason.

I found
<http://blogs.sun.com/watt/resource/jvm-options-list.html>

--
Lew
 
 
Andrew Thompson





PostPosted: 2007-5-28 0:11:00 Top

java-programmer >> outofMemory Exception in hot Deploy of jboss 3.2.5 Lew wrote:
(a variey of -XX options to java)
>It's something I lifted from NetBeans's config file examples.
>
>Options like this are nearly undocumented, perhaps for a reason.

Yes. Them non-standard options are always to
be treated with a grain of salt (here one release,
possibly gone the next?).

>I found
><http://blogs.sun.com/watt/resource/jvm-options-list.html>

Thanks.

--
Andrew Thompson
http://www.athompson.info/andrew/

Message posted via JavaKB.com
http://www.javakb.com/Uwe/Forums.aspx/java-general/200705/1