在linux中查看线程数的三种方法



在linux中查看线程数的三种方法
 
在linux中查看线程数的三种方法
  www.2cto.com  
1、top -H
手册中说:-H : Threads toggle
加上这个选项启动top,top一行显示一个线程。否则,它一行显示一个进程。
 
2、ps xH
手册中说:H Show threads as if they were processes
这样可以查看所有存在的线程。
 
3、ps -mp <PID>
手册中说:m Show threads after processes
 
这样可以查看一个进程起的线程数。

相关内容

    暂无相关文章