添加URL
分享
如下,都是以
catalina-exec-开头的,大概有200个线程,都处于这种状态,
"catalina-exec-484" daemon prio=10 tid=0x0000002c0b3e5400 nid=0x2bda waiting on condition [0x0000000060f35000..0x0000000060f35db0]
java.lang.Thread.State: TIMED_WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for  <0x0000002ac2471888> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
at java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:198)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:1963)
at java.util.concurrent.LinkedBlockingQueue.poll(LinkedBlockingQueue.java:395)
at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:944)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:906)
at java.lang.Thread.run(Thread.java:619)
网上查到的信息如下:但不清楚如何解决?
如果发现有大量的线程都在处在 Wait on condition,从线程 stack看, 正等待网络读写,这可能是一个网络瓶颈的征兆。因为网络阻塞导致线程无法执行。一种情况是网络非常忙,几 乎消耗了所有的带宽,仍然有大量数据等待网络读 写;另一种情况也可能是网络空闲,但由于路由等问题,导致包无法正常的到达。所以要结合系统的一些性能观察工具来综合分析,比如 netstat统计单位时间的发送包的数目,如果很明显超过了所在网络带宽的限制 ; 观察 cpu的利用率,如果系统态的 CPU时间,相对于用户态的 CPU时间比例较高;如果程序运行在 Solaris 10平台上,可以用 dtrace工具看系统调用的情况,如果观察到 read/write的系统调用的次数或者运行时间遥遥领先;这些都指向由于网络带宽所限导致的网络瓶颈。
jstack 声明:本人一直认为【看是一回事,做是一回事】,此篇博客是本人参考下述博客(见文末链接),进行的操作整理记录。 部分内容直接摘录自下述博客,若涉及到侵权问题,请及时联系本人。 jstack介绍 jstack指令 jstack实战之高cpu占用率排查 jstack实战之死锁线程的定位 jstack介... jvm工具-jstack使用 jstack是java虚拟机自带的一种堆栈跟踪工具。jstack用于打印出给定的java进程ID或core&amp;nbsp;file或远程调试服务的Java堆栈信息,如果是在64位机器上,需要指定选项”-J-d64”,Windows的jstack使用方式只支持以下的这种方式: jstack [-l] pid &amp;nbsp; 主要分为两个功能:&amp;nbsp; a.&amp;nbsp; 针对活着的进程做本地的... tomcat jvm 大量线程waiting on condition,如何解决? 大佬们好,做性能压测遇到及其奇怪的问题,机器load极高,甚至飙到100+,逻辑核数只有16核 ![图片说明](https://img-ask.csdn.net/upload/201904/19/1555639361_818159.png) jstack dump的线程有一半的线程都在waiting on condition,而且都是一些tomcat的线程池之类的问题线程栈如下: ![图片说明](https://img-ask.csdn.net/upload/201904/19/1555638646_167074.png) 53%的线程都是如下堆栈 "catalina-exec-7" daemon prio=10 tid=0x00007f52fc016800 nid=0x1430 waiting on condition [0x00007f537abe7000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for <0x000000073168d480> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:186) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2043) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:104) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:32) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1068) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:745) Locked ownable synchronizers: - None 附上已确定的可以过滤的影响因素,其中cpu利用率81%,fullgc只有俩次,也不是fullgc问题引起的,parNew gc每次耗时20-40ms之间,也是合理的。内存也足够用 ![图片说明](https://img-ask.csdn.net/upload/201904/19/1555638758_853326.png) 又一次Java线程卡死的调试经历 我的java代码,每天凌晨1点都会执行一个定时任务,定时任务中有循环执行的任务,每次循环都有开始和结束日志,某一天,我忽然发现,日志中前一天的循环只执行了几次就停止了,根据日志来看,执行到第4次循环的时候,只有开始的日志,没有结束的日志,那肯定是在里面卡死了 我首先执行 # ps -ef | grep tomcat 获取到了线程的pid 然后执行jstack # jstack -l 1... 补充下:经过测试这是很正常的现象,你可能启用了Tomcat的线程池,并且有20个左右的并发访问,的话就会产生您这种情况。
<!-- Modified by 陈炳灿2011-10-11 注视掉这段 -->
<Executor name="tomcatThreadPool" namePrefix="catalina-exec-"
maxThreads="150" minSpareThreads="4"/>
"catalina-exec-18" daemon prio=6 tid=0x0c84f800 nid=0xee8 waiting on condition [0x0ef9f000..0x0ef9f9e8]
java.lang.Thread.State: TIMED_WAITING (parking)
at sun.misc.Unsafe.park(Native Method)
- parking to wait for  <0x053567b0> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
at java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:198)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:1963)
at java.util.concurrent.LinkedBlockingQueue.poll(LinkedBlockingQueue.java:395)
at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:945)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
at java.lang.Thread.run(Thread.java:619)
Locked ownable synchronizers:
- None java.util.concurrent.locks.AbstractQueuedSynchronizer队列同步器源码解析 1.什么是队列同步器 用来构建锁或者其他同步组件的基础框架,使用int型的成员变量来表示同步的状态,线程以及等待状态等信息被封装成了Node节点,而这些Node节点采用先进先出的队列来进行排队管理。 三、使用示例 <em>jstack</em> -l 5524 &amp;amp;amp;gt; c:\users\Administrator\Desktop\<em>jstack</em>.txt 2018-09-14 12:59:46 Full th... java.lang.Thread.State:WAITING(parking)
闲话少说, <em>Tomcat</em>日志报错及堆栈信息: 因为这个问题,挂了几个节点。 跟踪报错的代码<em>发现</em>代码中用到future.get()方法: Callable&lt;Object&gt; myCallable = createThreadCallable(interfaceName, httpbody, authSeedVo); Future&...
内存监控工具——> jstack
文章目录一、说明二、语法三、实战四、<em>线程</em>与Monitor五、<em>线程</em><em>状态</em> Jstack是Jdk自带的<em>线程</em>跟踪工具,用于打印指定Java进程的<em>线程</em>堆栈信息。 <em>jstack</em> [option] option:命令选项,常用选项如下: 当’<em>jstack</em> [-l] pid’没有相应的时候强制打印栈信息,如果直接<em>jstack</em>无响应时,用于强制<em>jstack</em>),一般情况不需要使用...
使用 TDA 工具,看到大量 Java Thread State 的第一反应是: 1,<em>线程</em><em>状态</em>为“waiting for monitor entry”: 意味着它在等待进入一个临界区,所以它在”Entry Set“队列中等待。 此时<em>线程</em><em>状态</em>一般都是 Blocked: java.lang.Thread.State:BLOCKED(on object moni... Tomcat 服务器Time_Wait问题解决
Nginx与<em>Tomcat</em>用了短连接造成Time_Wait连线数太多, 网上一大堆文章,方法大都不可靠, 其实只需改两步就搞定! 1、upstream中增加keepalive 128; 2、每个location增加: proxy_http_version 1.1; proxy_set_header Connection ""; 3、nginx -s reload
jstack 命令(Java Stack Trace)
JDK内置工具使用 一、javah命令(C Header and Stub File Generator) 二、jps命令(Java Virtual Machine Process Status Tool) 三、<em>jstack</em>命令(Java Stack Trace) 四、jstat命令(Java Virtual Machine Statistics Monitoring Tool) Jstack 线程 状态 BLOCKED/TIMED_WAITING/WAITING解释
一、<em>线程</em>5种<em>状态</em> 新建<em>状态</em>(New) 新创建了一个<em>线程</em>对象。 就绪<em>状态</em>(Runnable) <em>线程</em>对象创建后,其他<em>线程</em>调用了该对象的start()方法。该<em>状态</em>的<em>线程</em>位于可运行<em>线程</em>池中,变得可运行,等待获取CPU的使用权。 运行<em>状态</em>(Running) 就绪<em>状态</em>的<em>线程</em>获取了CPU,执行程序代码。 阻塞<em>状态</em>(Blocked) 阻塞<em>状态</em>是<em>线程</em>因为某种原因放弃CPU使用权,暂时停止运行。直到<em>线程</em>进入就绪<em>状态</em>,才
请问没有 jstack 怎么办?
linux环境,有java命令但是没有<em>jstack</em>命令,是不是需要安装<em>jstack</em>呢?可是我在网上没有找到<em>jstack</em>
1、<em>jstack</em>命令的语法格式:<em>jstack</em> &amp;lt;pid&amp;gt;,可用于查看java进程id。 2、Dump文件:Dump文件是进程的内存镜像。可以把程序的执行<em>状态</em>通过调试器保存到dump文件中。Dump文件是用来给驱动程序编写人员调试驱动程序用的,这种文件必须用专门的工具软件打开,比如使用Windbg。 在Windbg中可以通过.dump命令保存进程的du... jstack Could not find symbol "gHotSpotVMTypes"
# <em>jstack</em> -F 20940 Attaching to process ID 20940, please wait... sun.jvm.hotspot.debugger.NoSuchSymbo
AbstractQueuedSynchronizer ConditionObject解析 // condition队列第一个节点 private transient Node firstWaiter; // condition队列最后一个节点 private transient Node lastWaiter; // 重新中断退出等待 private static final int REINTERRUPT = 1; // 抛出中断异常退出等待 private stati... jstack 用法 java.util.concurrent.locks.AbstractQueuedSynchronizer构造同步类
AbstractQueuedSynchronizer是一个同步架构, Java中有很多同步类是由这个架构实现,比如FutureTask、ReentrantLock等。为了使用这个类实现一个同步架构,需要将其定义为一个帮助子类,需要适当地重新定义以下方法,这是通过使用getState 、 setState、或compareAndSetState 方法来检查和/或修改同步<em>状态</em>来实现的: java.util.concurrent.locks.LockSupport
2019独角兽企业重金招聘Python工程师标准&gt;&gt;&gt; Thread Dump 分析综述 最近在做性能测试,需要对<em>线程</em>堆栈进行分析,在网上收集了一些资料,学习完后,将相关知识整理在一起,输出文章如下。 一、Thread Dump介绍 1.1什么是Thread Dump? Thread Dump是非常有用的诊断Java应用问题的工具。每一个Java虚拟机都有及时生成所有<em>线程</em>在某一点<em>状态</em>的thread-dump的能力,虽然各个 Java虚拟机打印的thread dump略有...
Java性能调优工具
1、JDK命令行工具 1.1、jps命令 jps用于列出Java的进程,jps可以增加参数,-m用于输出传递给Java进程的参数,-l用于输出主函数的完整路径,-v可以用于显示传递给jvm的参数。 jps -l -m -v 31427...
AbstractQueuedSynchronizer中条件(Condition)等待(await)、通知唤醒(signal)实现的源码分析
1. 概述 在AbstractQueuedSynchronizer中,有两个FIFO队列,一个是同步队列,用来排队申请同步<em>状态</em>,还有一个是条件等待队列,当调用了await()系列的方法后,就会在等待队列尾部插入一个节点,通知唤醒的时候会把这个节点从等待队列转移到同步队列。 本文主要描述条件等待队列以及等待、通知机制的实现,关于同步队列的相关操作和实现分析,可以在这篇博客了解。 2. 分析 Java 线程 中断(interrupt)与阻塞 (park)的区别
很多Java开发人员(包括我),尤其是刚进入软件行业的新手,认为Java设置<em>线程</em>中断就是表示<em>线程</em>停止了,不往前执行了, Thread.currentThread().interrupt() 其实不是这样的,<em>线程</em>中断只是一个<em>状态</em>而已,true表示已中断,false表示未中断 //获取<em>线程</em>中断<em>状态</em>,如果中断了返回true,否则返...
java— Tomcat 高性能调优方案详解
java飞虎队 2017-10-06 10:04 <em>Tomcat</em>大致分为两个部分,Connector组件及Container组件。Connector组件负责控制入口连接,并关联着一个Executor。Container负责Servlet容器的实现,Executor负责具体的业务逻辑,如Servlet的执行。一个请求到达服务器后,经过以下关键几步,参见图1: 【jvm】java查看内存使用jmap,jstat和 jstack 使用 ,docker启动服务下查看jvm使用情况...
【声明,如果是docker启动的服务,可以在进入容器内后,再使用如下命令操作】 【dockerexec -it容器ID /bin/bash 即可进入容器内】 【如果不是docker启动的服务,可以直接在宿主机使用下面操作】 简易操作步骤: 1.使用top命令获取所有Linux服务器上的进程PID以及相关信息
最近<em>发现</em>个问题,不知道是使用不当还是何种原因造成的。 具体内容:      用Quartz调度任务,周期10分钟。但具体业务执行的时间要大于10分钟。Quartz<em>线程</em>池的<em>配置</em>是缺省,查了一下10个大小。 现象,运行一段时间后,Quartz的<em>线程</em>池中9个<em>线程</em>的<em>状态</em>是Waiting on Condition,一个是runnable。整进程的<em>状态</em>貌似停住了,调度时间到了,没有执行高度<em>线程</em>中的代码。...
SynchronousQueue(同步队列) SynchronousQueue:同步Queue,属于<em>线程</em>安全的BlockingQueue的一种,此队列设计的理念类似于&quot;单工模式&quot;,对于每个put/offer操作,必须等待一个take/poll操作,类似于我们的现实生活中的&quot;火把传递&quot;:一个火把传递地他人,需要2个人&quot;触手可及&quot;才行. 因为这种策略,最终导致队列中并没有一个真正的元素;这是一种pipleline思路的基于queue的&quot;操作传递...
背景:采用mina和外部进行通信,在发送数据的方法上出现。 tracestack: "" prio=10 tid=0x00007f1c7c1e0000 nid=0x3e31 in Object.wait() [0x00007f1cb48bf000]    java.lang.Thread.State: TIMED_WAITING (on object monitor)     at jav
公司项目运行一会,访问页面一直在加载中,ps -ef|grep java 查看进程还在,       去查看日志文件,还没见什么异常,日志文件也停住了。       郁闷了好久,运行一会,项目就熄火了,本宝宝,解决办法就是SB一样的重启一下,       管一会,又重启下。真是坑啊。        通过对启动日志的分析,<em>发现</em>启动了两次,很奇怪。 Tomcat 假死原因分析
<em>Tomcat</em> 假死原因分析报告 BLOCKED,WAITING,TIMED_WAITING有什么区别?-用生活的例子解释
BLOCKED,WAITING和TIMED_WAITING是很重要的<em>线程</em><em>状态</em>,但是经常对我们造成困扰。如果需要分析<em>线程</em>dump必须要对其有一定的理解。使用生活的例子,本文将每个<em>状态</em>变成了简单的例子。 与正式的Java文档定义相比,任何让人费解的概念都可以用简单的例子来理解。如果用真实生活中的例子,就更好理解了。我想分享一些真实生活的例子来帮助理解这些<em>线程</em><em>状态</em>。 BLOCKED java文档官方定义...
一次排查线上 线程 池数量过高的报警经历
线上<em>jstack</em>查看<em>正常</em>机器和问题机器对比堆栈信息,<em>发现</em>大量的http-nio-1601-exec-<em>线程</em>在等待,查看线上监控<em>发现</em>优惠券接口调用量飙升,中午商家做活动抢券,根据<em>线程</em>名字可以看出是tomcat的<em>线程</em>池被打满了,线上监控显示<em>线程</em>数超过1000,比<em>正常</em>机器<em>线程</em>数超出500左右,对比上图基本确定原因。 进一步需要做tomcat<em>线程</em>池调优,应对每周一的高流量请求,甚至需要机器扩容,...
Springboot刚启动就报内存溢出?
1.问题描述: 本地系统是Ubuntu,jdk1.8,工具是eclipse,新创建的最简单的springboot项目,其中只导入了web、config的包。 只写了一个controller,启动就会报错。 Full thread dump Java HotSpot(TM) 64-Bit Server VM (25.201-b09 mixed mode): "DestroyJavaVM" #39 prio=5 os_prio=0 tid=0x00007f0ae800f000 nid=0x697c waiting on condition [0x0000000000000000] java.lang.Thread.State: RUNNABLE "http-nio-8080-Acceptor-0" #37 daemon prio=5 os_prio=0 tid=0x00007f0ae8224800 nid=0x69ae runnable [0x00007f0ac26ed000] java.lang.Thread.State: RUNNABLE at sun.nio.ch.ServerSocketChannelImpl.accept0(Native Method) at sun.nio.ch.ServerSocketChannelImpl.accept(ServerSocketChannelImpl.java:422) at sun.nio.ch.ServerSocketChannelImpl.accept(ServerSocketChannelImpl.java:250) - locked (a java.lang.Object) at org.apache.tomcat.util.net.NioEndpoint.serverSocketAccept(NioEndpoint.java:448) at org.apache.tomcat.util.net.NioEndpoint.serverSocketAccept(NioEndpoint.java:70) at org.apache.tomcat.util.net.Acceptor.run(Acceptor.java:95) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-ClientPoller-1" #36 daemon prio=5 os_prio=0 tid=0x00007f0ae821f000 nid=0x69ad runnable [0x00007f0ac27ee000] java.lang.Thread.State: RUNNABLE at sun.nio.ch.EPollArrayWrapper.epollWait(Native Method) at sun.nio.ch.EPollArrayWrapper.poll(EPollArrayWrapper.java:269) at sun.nio.ch.EPollSelectorImpl.doSelect(EPollSelectorImpl.java:93) at sun.nio.ch.SelectorImpl.lockAndDoSelect(SelectorImpl.java:86) - locked (a sun.nio.ch.Util$3) - locked (a java.util.Collections$UnmodifiableSet) - locked (a sun.nio.ch.EPollSelectorImpl) at sun.nio.ch.SelectorImpl.select(SelectorImpl.java:97) at org.apache.tomcat.util.net.NioEndpoint$Poller.run(NioEndpoint.java:743) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-ClientPoller-0" #35 daemon prio=5 os_prio=0 tid=0x00007f0ae821d000 nid=0x69ac runnable [0x00007f0ac28ef000] java.lang.Thread.State: RUNNABLE at sun.nio.ch.EPollArrayWrapper.epollWait(Native Method) at sun.nio.ch.EPollArrayWrapper.poll(EPollArrayWrapper.java:269) at sun.nio.ch.EPollSelectorImpl.doSelect(EPollSelectorImpl.java:93) at sun.nio.ch.SelectorImpl.lockAndDoSelect(SelectorImpl.java:86) - locked (a sun.nio.ch.Util$3) - locked (a java.util.Collections$UnmodifiableSet) - locked (a sun.nio.ch.EPollSelectorImpl) at sun.nio.ch.SelectorImpl.select(SelectorImpl.java:97) at org.apache.tomcat.util.net.NioEndpoint$Poller.run(NioEndpoint.java:743) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-10" #34 daemon prio=5 os_prio=0 tid=0x00007f0ae82b5800 nid=0x69ab waiting on condition [0x00007f0ac29f0000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-9" #33 daemon prio=5 os_prio=0 tid=0x00007f0ae82b4000 nid=0x69aa waiting on condition [0x00007f0ac2af1000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-8" #32 daemon prio=5 os_prio=0 tid=0x00007f0ae82b2000 nid=0x69a9 waiting on condition [0x00007f0ac2bf2000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-7" #31 daemon prio=5 os_prio=0 tid=0x00007f0ae82b0000 nid=0x69a8 waiting on condition [0x00007f0ac2cf3000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-6" #30 daemon prio=5 os_prio=0 tid=0x00007f0ae82ae000 nid=0x69a7 waiting on condition [0x00007f0ac2df4000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-5" #29 daemon prio=5 os_prio=0 tid=0x00007f0ae8256800 nid=0x69a6 waiting on condition [0x00007f0ac2ef5000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-4" #28 daemon prio=5 os_prio=0 tid=0x00007f0ae8254800 nid=0x69a5 waiting on condition [0x00007f0ac2ff6000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-3" #27 daemon prio=5 os_prio=0 tid=0x00007f0ae8252800 nid=0x69a4 waiting on condition [0x00007f0ac30f7000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-2" #26 daemon prio=5 os_prio=0 tid=0x00007f0ae8251000 nid=0x69a3 waiting on condition [0x00007f0ac31f8000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "http-nio-8080-exec-1" #25 daemon prio=5 os_prio=0 tid=0x00007f0ae824f800 nid=0x69a2 waiting on condition [0x00007f0ac32f9000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:107) at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "NioBlockingSelector.BlockPoller-1" #24 daemon prio=5 os_prio=0 tid=0x00007f0ae82e3800 nid=0x69a1 runnable [0x00007f0ac33fa000] java.lang.Thread.State: RUNNABLE at sun.nio.ch.EPollArrayWrapper.epollWait(Native Method) at sun.nio.ch.EPollArrayWrapper.poll(EPollArrayWrapper.java:269) at sun.nio.ch.EPollSelectorImpl.doSelect(EPollSelectorImpl.java:93) at sun.nio.ch.SelectorImpl.lockAndDoSelect(SelectorImpl.java:86) - locked (a sun.nio.ch.Util$3) - locked (a java.util.Collections$UnmodifiableSet) - locked (a sun.nio.ch.EPollSelectorImpl) at sun.nio.ch.SelectorImpl.select(SelectorImpl.java:97) at org.apache.tomcat.util.net.NioBlockingSelector$BlockPoller.run(NioBlockingSelector.java:304) "spring.cloud.inetutils" #23 daemon prio=5 os_prio=0 tid=0x00007f0ae82fb800 nid=0x69a0 waiting on condition [0x00007f0ac34fb000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) "SimplePauseDetectorThread_0" #22 daemon prio=9 os_prio=0 tid=0x00007f0a84015000 nid=0x699f waiting on condition [0x00007f0ac37fc000] java.lang.Thread.State: TIMED_WAITING (sleeping) at java.lang.Thread.sleep(Native Method) at java.lang.Thread.sleep(Thread.java:340) at java.util.concurrent.TimeUnit.sleep(TimeUnit.java:386) at org.LatencyUtils.TimeServices.sleepNanos(TimeServices.java:62) at org.LatencyUtils.SimplePauseDetector$SimplePauseDetectorThread.run(SimplePauseDetector.java:116) "Thread-4" #21 daemon prio=9 os_prio=0 tid=0x00007f0a84011800 nid=0x699e waiting on condition [0x00007f0ac38fd000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442) at org.LatencyUtils.PauseDetector$PauseDetectorThread.run(PauseDetector.java:85) "container-0" #20 prio=5 os_prio=0 tid=0x00007f0ae8c72800 nid=0x699d waiting on condition [0x00007f0ac39fe000] java.lang.Thread.State: TIMED_WAITING (sleeping) at java.lang.Thread.sleep(Native Method) at org.apache.catalina.core.StandardServer.await(StandardServer.java:568) at org.springframework.boot.web.embedded.tomcat.<em>Tomcat</em>WebServer$1.run(<em>Tomcat</em>WebServer.java:181) "Catalina-utility-2" #19 prio=1 os_prio=0 tid=0x00007f0a68314800 nid=0x699c waiting on condition [0x00007f0ac8dfd000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039) at java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take(ScheduledThreadPoolExecutor.java:1088) at java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take(ScheduledThreadPoolExecutor.java:809) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "Catalina-utility-1" #18 prio=1 os_prio=0 tid=0x00007f0ae8c6a800 nid=0x699b waiting on condition [0x00007f0ad0143000] java.lang.Thread.State: TIMED_WAITING (parking) at sun.misc.Unsafe.park(Native Method) - parking to wait for (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject) at java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:215) at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:2078) at java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take(ScheduledThreadPoolExecutor.java:1093) at java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take(ScheduledThreadPoolExecutor.java:809) at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) at java.lang.Thread.run(Thread.java:748) "RMI TCP Accept-0" #13 daemon prio=5 os_prio=0 tid=0x00007f0ae850a000 nid=0x6995 runnable [0x00007f0ad056d000] java.lang.Thread.State: RUNNABLE at java.net.PlainSocketImpl.socketAccept(Native Method) at java.net.AbstractPlainSocketImpl.accept(AbstractPlainSocketImpl.java:409) at java.net.ServerSocket.implAccept(ServerSocket.java:545) at java.net.ServerSocket.accept(ServerSocket.java:513) at sun.management.jmxremote.LocalRMIServerSocketFactory$1.accept(LocalRMIServerSocketFactory.java:52) at sun.rmi.transport.tcp.TCPTransport$AcceptLoop.executeAcceptLoop(TCPTransport.java:405) at sun.rmi.transport.tcp.TCPTransport$AcceptLoop.run(TCPTransport.java:377) at java.lang.Thread.run(Thread.java:748) "RMI TCP Accept-43459" #12 daemon prio=5 os_prio=0 tid=0x00007f0ae84ca000 nid=0x6994 runnable [0x00007f0ad0694000] java.lang.Thread.State: RUNNABLE at java.net.PlainSocketImpl.socketAccept(Native Method) at java.net.AbstractPlainSocketImpl.accept(AbstractPlainSocketImpl.java:409) at java.net.ServerSocket.implAccept(ServerSocket.java:545) at java.net.ServerSocket.accept(ServerSocket.java:513) at sun.rmi.transport.tcp.TCPTransport$AcceptLoop.executeAcceptLoop(TCPTransport.java:405) at sun.rmi.transport.tcp.TCPTransport$AcceptLoop.run(TCPTransport.java:377) at java.lang.Thread.run(Thread.java:748) "RMI TCP Accept-0" #11 daemon prio=5 os_prio=0 tid=0x00007f0ae84b5000 nid=0x6993 runnable [0x00007f0ad0795000] java.lang.Thread.State: RUNNABLE at java.net.PlainSocketImpl.socketAccept(Native Method) at java.net.AbstractPlainSocketImpl.accept(AbstractPlainSocketImpl.java:409) at java.net.ServerSocket.implAccept(ServerSocket.java:545) at java.net.ServerSocket.accept(ServerSocket.java:513) at sun.rmi.transport.tcp.TCPTransport$AcceptLoop.executeAcceptLoop(TCPTransport.java:405) at sun.rmi.transport.tcp.TCPTransport$AcceptLoop.run(TCPTransport.java:377) at java.lang.Thread.run(Thread.java:748) "Service Thread" #9 daemon prio=9 os_prio=0 tid=0x00007f0ae80d8000 nid=0x6992 runnable [0x0000000000000000] java.lang.Thread.State: RUNNABLE "C1 CompilerThread3" #8 daemon prio=9 os_prio=0 tid=0x00007f0ae80cc800 nid=0x6991 waiting on condition [0x0000000000000000] java.lang.Thread.State: RUNNABLE "C2 CompilerThread2" #7 daemon prio=9 os_prio=0 tid=0x00007f0ae80ca800 nid=0x6990 waiting on condition [0x0000000000000000] java.lang.Thread.State: RUNNABLE "C2 CompilerThread1" #6 daemon prio=9 os_prio=0 tid=0x00007f0ae80c9000 nid=0x698f waiting on condition [0x0000000000000000] java.lang.Thread.State: RUNNABLE "C2 CompilerThread0" #5 daemon prio=9 os_prio=0 tid=0x00007f0ae80c6000 nid=0x698e waiting on condition [0x0000000000000000] java.lang.Thread.State: RUNNABLE "Signal Dispatcher" #4 daemon prio=9 os_prio=0 tid=0x00007f0ae80c4800 nid=0x698d waiting on condition [0x0000000000000000] java.lang.Thread.State: RUNNABLE "Finalizer" #3 daemon prio=8 os_prio=0 tid=0x00007f0ae8091800 nid=0x698c in Object.wait() [0x00007f0ad26de000] java.lang.Thread.State: WAITING (on object monitor) at java.lang.Object.wait(Native Method) - waiting on (a java.lang.ref.ReferenceQueue$Lock) at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:144) - locked (a java.lang.ref.ReferenceQueue$Lock) at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:165) at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:216) "Reference Handler" #2 daemon prio=10 os_prio=0 tid=0x00007f0ae808f000 nid=0x698b in Object.wait() [0x00007f0ad27df000] java.lang.Thread.State: WAITING (on object monitor) at java.lang.Object.wait(Native Method) - waiting on (a java.lang.ref.Reference$Lock) at java.lang.Object.wait(Object.java:502) at java.lang.ref.Reference.tryHandlePending(Reference.java:191) - locked (a java.lang.ref.Reference$Lock) at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:153) "VM Thread" os_prio=0 tid=0x00007f0ae8085800 nid=0x698a runnable "GC task thread#0 (ParallelGC)" os_prio=0 tid=0x00007f0ae8025000 nid=0x6980 runnable "GC task thread#1 (ParallelGC)" os_prio=0 tid=0x00007f0ae8026800 nid=0x6981 runnable "GC task thread#2 (ParallelGC)" os_prio=0 tid=0x00007f0ae8028800 nid=0x6982 runnable "GC task thread#3 (ParallelGC)" os_prio=0 tid=0x00007f0ae802a000 nid=0x6983 runnable "GC task thread#4 (ParallelGC)" os_prio=0 tid=0x00007f0ae802c000 nid=0x6984 runnable "GC task thread#5 (ParallelGC)" os_prio=0 tid=0x00007f0ae802d800 nid=0x6987 runnable "GC task thread#6 (ParallelGC)" os_prio=0 tid=0x00007f0ae802f800 nid=0x6988 runnable "GC task thread#7 (ParallelGC)" os_prio=0 tid=0x00007f0ae8031000 nid=0x6989 runnable "VM Periodic Task Thread" os_prio=0 tid=0x00007f0ae850c000 nid=0x6996 waiting on condition JNI global references: 1235 PSYoungGen total 144384K, used 45005K [0x000000076d000000, 0x0000000777b00000, 0x00000007c0000000) eden space 126976K, 35% used [0x000000076d000000,0x000000076fbf3608,0x0000000774c00000) from space 17408K, 0% used [0x0000000775d00000,0x0000000775d00000,0x0000000776e00000) to space 17408K, 0% used [0x0000000774c00000,0x0000000774c00000,0x0000000775d00000) ParOldGen total 175616K, used 22110K [0x00000006c7000000, 0x00000006d1b80000, 0x000000076d000000) object space 175616K, 12% used [0x00000006c7000000,0x00000006c85978a8,0x00000006d1b80000) Metaspace used 35192K, capacity 37248K, committed 37504K, reserved 1081344K class space used 4819K, capacity 5214K, committed 5248K, reserved 1048576K 2019-04-01 14:22:57.992 INFO 27001 --- [on(2)-127.0.0.1] inMXBeanRegistrar$SpringApplicationAdmin : Application shutdown requested. 2019-04-01 14:22:57.994 INFO 27001 --- [on(2)-127.0.0.1] o.s.s.concurrent.ThreadPoolTaskExecutor : Shutting down ExecutorService 'applicationTaskExecutor' 2019-04-01 14:22:58.004 INFO 27001 --- [on(2)-127.0.0.1] o.apache.catalina.core.StandardService : Stopping service [<em>Tomcat</em>]
linux 版本 Linux version 2.6.32-358.6.2.el6.x86_64 (mockbuild@c6b8.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-3) (GCC) ) #1 SMP Thu May 16 20:59:36 UTC 2013 JAVA版本 java version "1.7.0_55" OpenJDK Runtime Environment (rhel-2.4.7.1.el6_5-x86_64 u55-b13) OpenJDK 64-Bit Server VM (build 24.51-b03, mixed mode) 我想使用<em>jstack</em>来查看堆栈信息,确<em>发现</em>系统不支持这个命令,后来我搜索了整个磁盘也没<em>发现</em>有<em>jstack</em>这个东西,是不是因为我这个jdk的版本原因,需要重新安装其它版本的jdk吗,不是很懂,求指教
JVM调优之 jstack 找出最耗cpu的 线程 并定位代码
<em>jstack</em>可以定位到<em>线程</em>堆栈,根据堆栈信息我们可以定位到具体代码,所以它在JVM性能调优中使用得非常多。下面我们来一个实例找出某个Java进程中最耗费CPU的Java<em>线程</em>并定位堆栈信息,用到的命令有ps、top、printf、<em>jstack</em>、grep。 第一步先找出Java进程ID,服务器上的Java应用名称为mrf-center: root@ubuntu:/# ps -ef | grep m...
运行 jstack 提示Exception in thread "main" java.lang.UnsatisfiedLinkError: no attach i
运行:<em>jstack</em> 6 提示报错信息: Exception in thread "main" java.lang.UnsatisfiedLinkError: no attach in java.lib
JDK8的 jmap和 jstat 命令结果不准
java version : "1.8.0_60" linux系统版本:CentOS release 6.5 (Final) java命令启动时的部分参数:-XX:MaxMetaspaceSize=1
jstack - F 12255
Thread 6957: (state = IN_NATIVE) - java.net.SocketInputStream.socketRead0(java.io.FileDescriptor, by
请教一下 JStack中的wait on condition是什么意思? 我<em>发现</em>,某个<em>线程</em>在<em>jstack</em>中被标识为“wait on condition”时, 下面的<em>线程</em><em>状态</em>,有时候是:“RUNNABLE”,也有的时候是:“TIMED_WAITING” 至于其他<em>状态</em>,应该也有,只是我只简单看到这两个而已。 [img]http://dl2.iteye.com/upload/attachment/0091/6719/20447b04-a38c-3f75-95e3-92e001d29fb6.png[/img] 那个这个“wait on condition”在<em>jstack</em>中究竟是什么含义呢? JStack对应的信息在JConsole中一样可以查看。 但是在JConsole中并没有给出“wait on condition”的概念。 [img]http://dl2.iteye.com/upload/attachment/0091/6723/51d8a35c-c558-35da-85a0-34e929416648.png[/img] 另外,jconsole的查看到的<em>线程</em>信息,来源是MBean中的java.lang.management.ThreadMXBean的<em>线程</em>描述信息: java.lang.management.ThreadInfo 这一点确信无异。(这一点我猜测是JMX通过不同的连接器发布出来的) [img]http://dl2.iteye.com/upload/attachment/0091/6733/91213646-e913-3d3d-9427-1edbffee119f.png[/img] jstack -查看Java进程的 线程 堆栈信息,锁定高消耗资源代码。
<em>jstack</em>主要用来查看某个Java进程内的<em>线程</em>堆栈信息。语法格式如下: <em>jstack</em>[option]pid <em>jstack</em>[option]executablecore <em>jstack</em>[option][server-id@]remote-hostname-or-ip 命令行参数选项说明如下: -llonglistings,会打印出额外的锁信息,在发生死锁时可以用j...
AbstractQueuedSynchronizer的ConditionObject类
在CyclicBarrier里面就用到这个类这个this$0还带上了外部类的引用private final ReentrantLock lock = new ReentrantLock(); /** Condition to wait on until tripped */ private final Condition trip = lock.newCondition();在CyclicBarr...
使用 jstack 排查系统问题
<em>jstack</em>介绍 <em>jstack</em>是java虚拟机自带的一种堆栈跟踪工具,用于生成java虚拟机当前时刻的<em>线程</em>快照。 生成<em>线程</em>快照的主要目的是定位<em>线程</em>出现长时间停顿的原因,如<em>线程</em>间死锁、死循环、请求外部资源导致的长时间等待等。 <em>线程</em>出现停顿的时候通过<em>jstack</em>来查看各个<em>线程</em>的调用堆栈,就可以知道没有响应的<em>线程</em>到底在后台做什么事情,或者等待什么资源。 如果java程序崩溃生成core文件,<em>jstack</em>...
Attaching to process ID 11827, please wait... Debugger attached successfully. Server compiler detected. JVM version is 25.40-b25 Deadlock Detection: No deadlocks found. Thread 16483: (state = BLOCKE
执行 jstack 命令提示"No suitable match for type of address",求解。
各位好! 最近我的一个线上tomcat应用服务器总是发生页面访问速度非常慢,通过top观察<em>发现</em>tomcat进程cpu占用率达到了3200%。 想通过<em>jstack</em>命令看看<em>线程</em>执行情况,分析一下是哪个<em>线程</em>
jstack -l pid 内容解析
其实这些内容有个名词叫做    JVM内部<em>线程</em> 下面我们对这些功能挨个解说  JDK 版本:Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)   下面的输出是一个典型的HotSpot JVM的thread dump,以此为例,来说明一下JVM的内部<em>线程</em>功能。   2014-04-29 17:59:54...
记一次 Tomcat 线程 数占满而导致的运维事故
记一次<em>Tomcat</em><em>线程</em>数占满而导致的运维事故 <em>Tomcat</em>访问报500错误,无法对外提供服务。多个<em>Tomcat</em>服务异常。 查看系统资源,内存有小量上涨,CPU、带宽等负载显著下降,TCP连接数<em>处于</em>ESTABLISHED<em>状态</em>的数据没有显明变化,但非ESTABLISHED<em>状态</em>的数量大量减少。 第一时间先上重启服务大法。重启后能短暂提供服务,但是马上又回到卡死<em>状态</em>。 使用<em>jstack</em>...
jstack 简单使用,定位死循环、 线程 阻塞、死锁等问题
两篇文章:(一)如何用<em>jstack</em>找出tomcat没有被成功关闭的原因?https://segmentfault.com/q/1010000012857185使用shutdown.sh之后tomcat没有被成功关闭,网上有教程说<em>jstack</em>可以用来定位错误位置,但是并没有看明白怎么定位,。百度这个问题的时候,还认识了一次词“守护<em>线程</em>”,只知道它是不会阻挡JVM关闭的,但具体的还没有去了解。不说废话...
死循环的例子:https://blog.csdn.net/goldenfish1919/article/details/8755378 步骤:查找进程-》查找<em>线程</em>-》分析threadDump日志-》找出问题代码 a、查看cpu高的java进程 b、生成进程下所有<em>线程</em>的栈日志 通过 jstack 日志分析和问题排查
转自:http://www.ccblog.cn/84.htm 前段事件公司出现了一个严重故障(调用dubbo服务一直<em>处于</em>超时,整个服务系统发生雪崩,系统彻底访问不了),一开始怎么都找不到问题的根源,日志的表现形式是dubbo<em>线程</em>池用完了,那么具体是什么导致的没有找到,后然通过<em>jstack</em>日志分析才找到问题的根源,根源就是系统日志代码写有问题。通过这个故障我们来了解下如何通过<em>jstack</em>日志分
关于 jstack 输出的信息
这里waiting on 和 locked 指向同一个地址 请问这是<em>正常</em>现象吗? 它代表了什么意思?
jstack 分析 线程 等待、死锁问题 我的java代码,每天凌晨1点都会执行一个定时任务,定时任务中有循环执行的任务,每次循环都有开始和结束日志,某一天,我忽然<em>发现</em>,日志中前一天的循环只执行了几次就停止了,根据日志来看,执行到第4次循环的时候,只有开始的日志,没有结束的日志,那肯定是在里面卡死了 我首先执行 # ps -ef | grep tomcat 获取到了<em>线程</em>的pid 然后执行<em>jstack</em> # <em>jstack</em> -l  ... jstack 命令详解
<em>jstack</em>用于打印出给定的java进程ID或corefile或远程调试服务的Java堆栈信息,如果是在64位机器上,需要指定选项&quot;-J-d64&quot;,Windows的<em>jstack</em>使用方式只支持以下的这种方式:<em>jstack</em>[-l]pid 如果java程序崩溃生成core文件,<em>jstack</em>工具可以用来获得core文件的javastack和nativestack的信息,从而可以轻松地知道java程序...
tomcat每天启动后,晚上无人操作,但第二天铁定假死, 线程 dump已抓,请各位帮忙分析一下问题所在
2014-07-01 10:42:45 Full thread dump Java HotSpot(TM) 64-Bit Server VM (20.0-b11 mixed mode): "RMI T
AbstractQueuedSynchronizer同步队列与Condition等待队列协同机制
之前对AbstractQueuedSynchronizer(AQS)同步队列与Condition等待队列的功能一直不是很清晰,没太清楚地区分开二者的区别和联系,最近研究了一下分享出来。1.同步队列和等待队列简述AQS维护的队列是当前等待资源的队列。当前<em>线程</em>获取同步<em>状态</em>失败时,同步器会将当前<em>线程</em>以及等待<em>状态</em>等信息构造成为一个节点并将其加入同步队列,同时会阻塞当前<em>线程</em>,当同步<em>状态</em>释放时,会把首节点中的线
WAITING on java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject@13c3b403;
“DubboServerHandler-XXXXXXX-thread-192” Id=146345 RUNNABLE (in native) waiting on java.util.concurrent.locks.AbstractQueuedSynchronizerConditionObject@13c3b403atjava.util.concurrent.locks.LockSuppor...
tomcat运行一段时间就挂掉...
我的tomcat每运行2-3天后,就会出现不再处理http请求的情况。打印出<em>线程</em><em>状态</em>如下: http-90-exec-40:TIMED_WAITING http-90-exec-43:TIMED_WA
tomcat应用无端挂掉,大佬们帮看看是什么原因?
WebappClassLoader.(2090) - The web application registered the JDBC driver but failed to unregister i
linux下使用 jstack 报错,牛人速来支援
# <em>jstack</em> -F 20940 Attaching to process ID 20940, please wait... sun.jvm.hotspot.debugger.NoSuchSymbolException: Could not find symbol "gHotSpotVMTypes" in any of the known library names (libjvm.so, libjvm_g.so, gamma_g) at sun.jvm.hotspot.HotSpotTypeDataBase.lookupInProcess(HotSpotTypeDataBase.java:585) at sun.jvm.hotspot.HotSpotTypeDataBase.readVMTypes(HotSpotTypeDataBase.java:150) at sun.jvm.hotspot.HotSpotTypeDataBase.(HotSpotTypeDataBase.java:85) at sun.jvm.hotspot.bugspot.BugSpotAgent.setupVM(BugSpotAgent.java:569) at sun.jvm.hotspot.bugspot.BugSpotAgent.go(BugSpotAgent.java:493) at sun.jvm.hotspot.bugspot.BugSpotAgent.attach(BugSpotAgent.java:331) at sun.jvm.hotspot.tools.Tool.start(Tool.java:163) at sun.jvm.hotspot.tools.JStack.main(JStack.java:86) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at sun.tools.<em>jstack</em>.JStack.runJStackTool(JStack.java:136) at sun.tools.<em>jstack</em>.JStack.main(JStack.java:102) Debugger attached successfully. <em>jstack</em> requires a java VM process/core!
jstack 分析java应用 线程 阻塞实战
问题描述: 生产环境,有个查询交易提交后,一直转圈未响应。 问题分析: 1、其他操作都比较流畅,初步怀疑是有同步锁导致的<em>线程</em>阻塞 2、使用<em>jstack</em>命令收集堆栈信息。 进程号为7689,命令如下: <em>jstack</em> -l 7689 &amp;gt; aa.tdump 参考http://www.cnblogs.com/nexiyi/p/java_thread_<em>jstack</em>.html中的操作,查找...
jstack 无法连接myclipse的进程,报错不能连接64位进程
C:\><em>jstack</em> -l 4008 4008: Unable to attach to 64-bit process The -F option can be used when the targe
如何用Jstack把java进程中的堆栈信息输出到文件
Jstack -l PID &amp;gt;&amp;gt; 123.txt进程ID通过jps命令可查看注意,如果没有成功添加环境变量,那么这里只能在Jstack的路径下执行,否则操作系统无法识别。如图,这里一般有两个运行参数,用来拍取内存快照,他们的含义如下:-l long listings,会打印出额(防盗连接:本文首发自http://www.cnblogs.com/jilodream/ )外的锁信息,在发...
jps命令(Java Virtual Machine Process Status Tool)
JDK内置工具使用 一、javah命令(C Header and Stub File Generator) 二、jps命令(Java Virtual Machine Process Status Tool) 三、<em>jstack</em>命令(Java Stack Trace) 四、jstat命令(Java Virtual Machine Statistics Monitoring Tool) JedisPool的getResource()方法 配置 不当导致服务假死
JedisPool的getResource()方法<em>配置</em>不当导致服务假死 dubbo服务中使用jedis,在从JedisPool获取jedis时超时导致dubbo服务假死 &quot;DubboServerHandler-10.0.101.208:20880-thread-22&quot; daemon prio=10 tid=0x00007f52f00b7800 nid=0x3d85 waiting on cond...
使用jmap -histo:live pid 抱错
linux下执行 /usr/java/jdk1.6.0_07/bin/jmap -histo:live 11553 | grep packagermanager 总是报错: sun.jvm.hotsp
分析JAVA应用CPU占用过高的问题
使用<em>jstack</em>分析java程序cpu占用率过高的有关问题 使用<em>jstack</em>分析java程序cpu占用率过高的问题 1,使用jps查找出java进程的pid,如3707 2,使用top -p 14292 -H观察该进程中所有<em>线程</em>的CPU占用。 [root@cp01-game-dudai-0100.cp01.baidu.com ~]# top -p 14292 -H top - 22:14:
如何查看JAVA某个进程下的 线程
jps -lvm jps -lvm 用于查看当前机器上运行的java进程。 可以看到所有运行的java进程都列出来了 top -Hp pid可以查看某个进程的<em>线程</em>信息 -H 显示<em>线程</em>信息,-p指定pid 如果想查看某个进程下的<em>线程</em>的堆栈信息的话可以使用下面命令 <em>jstack</em> -l pid <em>jstack</em> -l 32318  查看此进程下<em>线程</em>的堆栈信息:
2014-12-15 14:19:47 Full thread dump Java HotSpot(TM) 64-Bit Server VM (20.45-b01 mixed mode): "resin-1954" daemon prio=10 tid=0x00007fe870024800 nid=0x15ca waiting on condition [0x00007fe8ad969000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1953" daemon prio=10 tid=0x00007fe87001b000 nid=0x1578 waiting on condition [0x00007fe88da66000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1952" daemon prio=10 tid=0x00007fe870004000 nid=0x1470 waiting on condition [0x00007fe796f26000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1949" daemon prio=10 tid=0x00007fe870021000 nid=0x131a waiting on condition [0x00007fe7968f3000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1948" daemon prio=10 tid=0x00007fe87000d000 nid=0x114d waiting on condition [0x00007fe796ac9000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1947" daemon prio=10 tid=0x00007fe870033800 nid=0x108e waiting on condition [0x00007fe88dc68000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1945" daemon prio=10 tid=0x00007fe870032000 nid=0x105f waiting on condition [0x00007fe8ac946000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1944" daemon prio=10 tid=0x00007fe87003a000 nid=0xfc0 waiting on condition [0x00007fe88e16d000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1943" daemon prio=10 tid=0x00007fe870051800 nid=0xf54 waiting on condition [0x00007fe8acc49000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1941" daemon prio=10 tid=0x00007fe87000a000 nid=0xecb waiting on condition [0x00007fe8adb6b000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1940" daemon prio=10 tid=0x00007fe870026000 nid=0xe3f waiting on condition [0x00007fe8ac643000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1939" daemon prio=10 tid=0x00007fe870038000 nid=0xe3e waiting on condition [0x00007fe795ee9000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-port-127.0.0.1:6800-launcher" daemon prio=10 tid=0x00007fe87002b000 nid=0xba7 waiting on condition [0x00007fe79742b000] java.lang.Thread.State: TIMED_WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.parkUntil(LockSupport.java:351) at com.caucho.env.thread2.AbstractTaskWorker2.run(AbstractTaskWorker2.java:256) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:173) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1936" daemon prio=10 tid=0x00007fe870001000 nid=0xba6 waiting on condition [0x00007fe8ac744000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1935" daemon prio=10 tid=0x00007fe87002d000 nid=0xb5e waiting on condition [0x00007fe797027000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1934" daemon prio=10 tid=0x00007fe870006000 nid=0xb2a waiting on condition [0x00007fe795fea000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) "resin-1933" daemon prio=10 tid=0x00007fe87000b800 nid=0xa4e waiting on condition [0x00007fe797229000] java.lang.Thread.State: WAITING (parking) at sun.misc.Unsafe.park(Native Method) at java.util.concurrent.locks.LockSupport.park(LockSupport.java:283) at com.caucho.env.thread2.ResinThread2.park(ResinThread2.java:196) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:147) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118) 死循环的例子:https://blog.csdn.net/goldenfish1919/article/details/8755378 步骤:查找进程-》查找<em>线程</em>-》分析threadDump日志-》找出问题代码 a、查看cpu高的java进程 b、生成进程下所有<em>线程</em>的栈日志 多 线程 , 线程 池的一点问题
最近维护别人的代码遇到一点<em>线程</em>池的问题,具体如下 ExecutorService pool = Executors.newFixedThreadPool(30); 接着循环3000多次,提交任务并返回Future,然后将其加入List f = pool.submit(new Task()); list.add(f);//list有个初始大小2000 然后调用shutdown()关闭<em>线程</em>池 接着for循环list 取出任务执行结果 rank = task.get(2, TimeUnit.MINUTES); 问题如下:任务总是无法全部执行,并且抛出java.lang.InterruptedException异常 该异常出现在AbstractQueuedSynchronizer的await()方法中,跪求各问大神解决!
<em>jstack</em> 属性 &amp;quot;http-nio-9090-exec-9&amp;quot; <em>线程</em>名称 prio 优先级 os_prio 系统优先级 tid 虚拟机中的Java<em>线程</em>id nid <em>线程</em>在操作系统中的id [0x00007f...
现网问题排查实战:Jstat,Jstack,Jmap jstack 文件
Broken pipe产生的原因通常是当管道读端没有在读,而管道的写端继续有<em>线程</em>在写,就会造成管道中断。(由于管道是单向通信的) SIGSEGV(Segment fault)意味着指针所对应的地址是无
jmap 的一次使用经历
一个负责的项目(tomcat容器内),重构部分代码后,<em>发现</em>cpu使用居高不下,而且http接口无法访问, 但是提供的dubbo接口能<em>正常</em>访问,感觉很奇怪。 首先想到先dump出heap分析下 jmap -dump:file=auto.dump 11598 提示:-bash: jmap: command not found 找到jdk的环境变量目录: echo $JAVA_HOME JAVA cpu 100%,怀疑是GC的时候出的问题,求教高手。
描述: 1.在Linux中运行jboss中的web项目,里面有一个socket服务。 2.在程序运行一段时间后,大概20个小时左右,会把CPU资源占用到100%。 3.我用top -Hp 的
jstack 调试程序
<em>jstack</em>:Java堆栈跟踪工具功能:用于生成虚拟机当前时刻的<em>线程</em>快照(一般称为threaddump或javacore文件)。javacore主要目的是定位<em>线程</em>出现长时间停顿的原因,比如死锁、死循环、请求外部资源响应长等;另外JDK 1.5后Thread类新增了getAllStackTraces()方法,可以基于此自己增加管理页面来分析;...
java进程莫名的假死,调用jmap/ jstack 后恢复工作
使用java做一个项目,jdk版本为1.7.0_79,现<em>发现</em>程序在运行一段时间后,会莫名的<em>处于</em>假死<em>状态</em>(根据日志判断,<em>正常</em>情况下该程序会刷日志);而当该进程<em>处于</em>假死<em>状态</em>后,调用jmap -heap p
Tomcat 运行一段时间后就会挂掉,时间不确定,一会几天,一会几分钟,请大神看看
因为是服务器的原因,断了之后再链接只能看到以下日志, at com.sun.jmx.mbeanserver.JmxMBeanServer.unregisterMBean(JmxMBeanServer.java:546) at org.apache.catalina.util.LifecycleMBeanBase.unregister(LifecycleMBeanBase.java:194) at org.apache.catalina.util.LifecycleMBeanBase.destroyInternal(LifecycleMBeanBase.java:73) at org.apache.catalina.core.StandardService.destroyInternal(StandardService.java:597) at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292) at org.apache.catalina.core.StandardServer.destroyInternal(StandardServer.java:848) at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292) at org.apache.catalina.startup.Catalina.stop(Catalina.java:768) at org.apache.catalina.startup.Catalina$CatalinaShutdownHook.run(Catalina.java:913) public class TestThread { public static void main(String[] args) { Thread thread = new Thread(new Worker()); thread.start(); static class Worker implements Runnabl
用 jstack 看到的WAITING和BLOCK的区别的是什么
用<em>jstack</em>看到的WAITING和BLOCK的区别的是什么
终于明白阿里百度这样的大公司,为什么面试经常拿ThreadLocal考验求职者了
Visual C++开发实战1200例 (配光盘代码 第5章) 《visual c++开发实战1200例》包括第i卷、第ii卷共计1200个例子,本书是第i卷,共计602个例子。 本书以开发人员在项目开发中经常遇到的问题和必须掌握的技术为中心,介绍了应用visual c++进行程序开发各个方面的知识和技巧,主要包括编程基础、界面设计、应用程序控制和图形图像。全书分4篇15章,共计602个实例和602个经验技巧。每个实例都是经过笔者精心筛选的,具有很强的实用性,其中一些实例是开发人员难于寻觅的解决方案。 本书两卷共计1200个例子,包括了开发中各个方面最常用的实例,是目前市场上实例最全面的开发类 相关下载链接:[url=//download.csdn.net/download/lhsxsh/3146009?utm_source=bbsseo]//download.csdn.net/download/lhsxsh/3146009?utm_source=bbsseo[/url]
c# implicit c#怎么保留3个小数点 c# 串口通信、 网络调试助手c# c# 泛型比较大小 c#解压分卷问题 c#启动居中 c# 逻辑或运算符 c# 全局检测鼠标位置 c# js popup
我们是很有底线的