Ubuntu,11.04,11.10。 tomcat 7.0.25-7.0.28,jdk sun 1.6_30 - 1.6_33。新鮮和空Tomcat 7.0安裝吃了很多CPU
解壓縮,刪除的webapp文件夾。 catalina啓動後頂部顯示 CPU在1cpu x64 4核心上吃tomcat 170%。在2cpu x64 4core它 顯示高達400%。
在tomcat中沒有安裝應用程序。試圖找出 線程消耗的CPU - 下面是5的頂部螺線:
"VM Periodic Task Thread" prio=10 tid=0x0000000040a7f000 nid=0x166c waiting on condition
"ajp-bio-8009-AsyncTimeout" daemon prio=10 tid=0x00007feaf0666800 nid=0x16ad sleeping[0x00007feafe011000]
java.lang.Thread.State: TIMED_WAITING (sleeping)
at java.lang.Thread.sleep(Native Method)
at org.apache.tomcat.util.net.JIoEndpoint$AsyncTimeout.run(JIoEndpoint.java:148)
at java.lang.Thread.run(Thread.java:662)
"http-bio-8080-AsyncTimeout" daemon prio=10 tid=0x000000004204f800 nid=0x16ab waiting on condition [0x00007feafead1000]
java.lang.Thread.State: TIMED_WAITING (sleeping)
at java.lang.Thread.sleep(Native Method)
at org.apache.tomcat.util.net.JIoEndpoint$AsyncTimeout.run(JIoEndpoint.java:148)
at java.lang.Thread.run(Thread.java:662)
"ContainerBackgroundProcessor[StandardEngine[Catalina]]" daemon prio=10 tid=0x0000000041d1b800 nid=0x16a9 sleeping[0x00007feafe405000]
java.lang.Thread.State: TIMED_WAITING (sleeping)
at java.lang.Thread.sleep(Native Method)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1517)
at java.lang.Thread.run(Thread.java:662)
"VM Thread" prio=10 tid=0x0000000040a39000 nid=0x1665 runnable
看起來沒什麼interresting。所以,我被困住了。任何人 知道哪裏可以走得更遠?還有一件事:有幾個虛擬的 框與幾乎相同的設置 - 並且從來沒有看到如此巨大的CPU消耗。
確保你沒有被閏秒錯誤所擊中。 (你可能需要重啓,如果你自6月30日以來沒有這樣做) – nos 2012-07-06 12:09:35
小測試哪個只運行Thread.sleep主要消耗高達〜80%cpu。有沒有辦法解決它,而無需重新啓動?我只是無法重新啓動主機。 – user1171379 2012-07-07 07:02:38
你說得對。固定。 /etc/init.d/ntp stop;日期; date'date +「%m%d%H%M%C%y。%S」';日期;在這裏找到https://groups.google.com/forum/?fromgroups#!topic/railo/-hz3ckuaCT0。無需重啓。 – user1171379 2012-07-07 07:13:49