• Post Reply Bookmark Topic Watch Topic
  • New Topic

Question on JVM Garbage Collection

 
Jim Jacob
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ranchers,

I am experiencing frequent OutOfmemory issues in WebSphere Application Server, and I'm treying to tune the JVM Heap Size.

Given below a few lines from my native_stederr.log

<AF[9132]: Allocation Failure. need 391344 bytes, 7135 ms since last AF>
<AF[9132]: managing allocation failure, action=2 70525752/618068480)>
<GC(9132): GC cycle started Wed Jul 30 10:30:41 2008
<GC(9132): freed 374573296 bytes, 72% free (445099048/618068480), in 276 ms>
<GC(9132): mark: 244 ms, sweep: 32 ms, compact: 0 ms>
<GC(9132): refs: soft 0 (age >= 32), weak 3779, final 256, phantom 0>
<AF[9132]: completed in 288 ms>

My question is:

If 70525752/618068480 bytes is the free heap size at the time of GC, why does the JVM reports an allocation failure of 391344 bytes?

Regards,
Jim Jacob
 
Jim Jacob
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Found the answer to my question.
Heap fragmentation is the cause for this.

Here is an article on Developerworks, worth reading.

http://www.ibm.com/developerworks/ibm/library/i-gctroub/
 
BV Boose
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can I piggy back your post?
How do you tell what jvm you are running? Can you change jvms? How do you tell if you have multiple jvms?
 
Jim Jacob
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1. java -version gives you the details of your JVM

2. On a unix enviornment, use ps -ef | grep java to find all the running Java processes.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!