tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jan gestre <ipcopper...@gmail.com>
Subject Re: Optimize CPU Hogging Tomcat 6
Date Tue, 01 Feb 2011 21:54:28 GMT
On Tue, Feb 1, 2011 at 10:33 PM, Caldarale, Charles R
<Chuck.Caldarale@unisys.com> wrote:
>> From: jan gestre [mailto:ipcopper.ph@gmail.com]
>> Subject: Optimize CPU Hogging Tomcat 6
>
>> We have an Apache Tomcat 6 server (HA cluster using DRBD) that is
>> hogging the CPU, this happens when there are simultaneous users
>> accessing at the same time, which should be considered normal because
>> they're only 30. How will I optimize Tomcat?
>
> Highly unlikely that you need to optimize Tomcat.  Much more likely that you have a
bug in your webapp.  Take thread dumps and see who is spending time where.
>
> http://wiki.apache.org/tomcat/HowTo#How_do_I_obtain_a_thread_dump_of_my_running_webapp_.3F
>
>  - Chuck

Hi Chuck,

Here's a snippet of the thread dump using jstack:

Deadlock Detection:

No deadlocks found.

Thread 12288: (state = BLOCKED)
Error occurred during stack walking:

Locked ownable synchronizers:
    - None

Thread 12287: (state = BLOCKED)
Error occurred during stack walking:

Locked ownable synchronizers:
    - None

Thread 12285: (state = BLOCKED)
Error occurred during stack walking:

Locked ownable synchronizers:
    - None

Thread 12284: (state = BLOCKED)

Error occurred during stack walking:

Locked ownable synchronizers:
    - None

Thread 12283: (state = BLOCKED)
Error occurred during stack walking:

Locked ownable synchronizers:
    - None

Thread 12282: (state = BLOCKED)
Error occurred during stack walking:

Locked ownable synchronizers:
    - None

Thread 12281: (state = BLOCKED)
Error occurred during stack walking:

Locked ownable synchronizers:
    - None

----

Also, here's my catalina log:

 tail -f /web/tomcat/tomcat6/logs/catalina.2011-02-01.log
Feb 1, 2011 10:19:04 PM org.apache.tomcat.util.net.JIoEndpoint$Acceptor run
SEVERE: Socket accept failed
java.net.SocketException: Too many open files
        at java.net.PlainSocketImpl.socketAccept(Native Method)
        at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:390)
        at java.net.ServerSocket.implAccept(ServerSocket.java:453)
        at java.net.ServerSocket.accept(ServerSocket.java:421)
        at org.apache.tomcat.util.net.DefaultServerSocketFactory.acceptSocket(DefaultServerSocketFactory.java:61)
        at org.apache.tomcat.util.net.JIoEndpoint$Acceptor.run(JIoEndpoint.java:352)
        at java.lang.Thread.run(Thread.java:619)

---

Regards,


Jan

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message