This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes BEA/Weblogic and the fly likes How to troubleshoot a memory leak or an out-of-memory exception in the Weblogic  Server Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » BEA/Weblogic
Bookmark "How to troubleshoot a memory leak or an out-of-memory exception in the Weblogic  Server " Watch "How to troubleshoot a memory leak or an out-of-memory exception in the Weblogic  Server " New topic
Author

How to troubleshoot a memory leak or an out-of-memory exception in the Weblogic Server

Ravi Kiran Va
Ranch Hand

Joined: Apr 18, 2009
Posts: 2234

Hi Ranchers , Please tell me how to ?

How to troubleshoot a memory leak or an out-of-memory exception in the Weblogic Server



I know my question is vague .
A General idea on this is sufficient . Please help

Save India From Corruption - Anna Hazare.
Marco Ehrentreich
best scout
Bartender

Joined: Mar 07, 2007
Posts: 1280

Hi Ravi,

a log message containing the corresponding OutOfMemoryException would be a good starting point ;-)

Additionally you could use a profiler to analyze the memory usage of your application to spot a memory leak in the results. Perhaps you can track down the problem even with simple tools like jconsole or jvisualvm together with the server logs to narrow the part of your application causing the memory leak by watching which actions in the application are consuming so much memory.

Marco
Ravi Kiran Va
Ranch Hand

Joined: Apr 18, 2009
Posts: 2234

Thanks Macro ,

The approach you mentioned(Using Proflers ) would be fine before check in into Repository . Now situation is out of my hand .

While Googling i found that

"You can also troubleshoot the outofmemory(OOM) or server
hanging issues by taking a thread dump of the server. "


Can you please tell me what is Thread Stuck mean ?
Marco Ehrentreich
best scout
Bartender

Joined: Mar 07, 2007
Posts: 1280

Most popular JVMs support startup parameters which enable some kind of heap dump even when the JVM shuts down with an OutOfMemoryException. Then you can try analyze this dump with a profiler later.

Moreover at least Sun's JDK comes with additional tools (jmap, jstack, etc.) which allow you to create stack traces and memory dumps from a running JVM.

Possibly Websphere gives some support here, too, but I unfortunately don't know very much about it.

But to be honest, if you don't know what all these things are it's very unlikely that you will find the necessary information in such a dump. Anyway good luck ;-)

Marco
Chengwei Lee
Ranch Hand

Joined: Apr 02, 2004
Posts: 884
Ravi Pavan wrote:The approach you mentioned(Using Proflers ) would be fine before check in into Repository . Now situation is out of my hand .


The OOM is typically caused by a piece of code in your application. So you cannot have a situation whereby it is out of your hand. Even if that piece of code is deployed to production and you found that it is causing the memory leak, you have got to fix it and release it.

Ravi Pavan wrote:Can you please tell me what is Thread Stuck mean ?

A thread will execute a request and by default, WLS will set a pre-determined duration, 600 seconds, as the threshold for the thread to finish the work. If for whatever reasons, the thread doesn't complete its work within 600 seconds, it is deemed to be "stucked" by WLS. This is however, just, an information/warning. There is a possibility that the thread cannot finish its work or it could be that the thread needs more time to finish its work. Looking through the logs, you may find that the thread becomes unstucked later on. Or if you don't, something is wrong. Look into the code that the thread is running, you may have to fix some bad coding or a bad design.


SCJP 1.4 * SCWCD 1.4 * SCBCD 1.3 * SCJA 1.0 * TOGAF 8
Ravi Kiran Va
Ranch Hand

Joined: Apr 18, 2009
Posts: 2234

You are right . Thanks .
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to troubleshoot a memory leak or an out-of-memory exception in the Weblogic Server
 
Similar Threads
use of ReplicatedSessionData
Find out the heap memory leak in java web application
Reason for such a werid error??
How to change the VM to run WebLogic
Using JProbe for Memory Analyzing