One way to check if you have stuck threads is through Weblogic Admin console.
- Login to weblogic admin console with admin credentials.
- Expand Environment and click on Servers in the left menu
- Click on the Admin server or any managed server you want to check the stuck threads
- Click on the Monitoring tab in the server properties
- click on Threads tab.
- Check the Health column in Self-Tuning Thread Pool table. If it says OK there are no stuck threads.
- If Health column value shows "Warning" there are stuck threads in JVM.
- Next thing is that you will have to find the root cause of the stuck threads. For that JVM thread dump needs to be taken.
- There is a tool called jstack starting from JDK 1.6 version.
- Find out the process ID of the weblogic service and execute "jstack <<PID>> > threaddump.log"command.
- Above command generates threaddump.log file with JVM thread dump.
- Check the STUCK threads and fix the issue. It might be in application code or connection to external services.
Happy debugging.
Thanks
Siva Pokuri.
No comments:
Post a Comment