施勇

只争朝夕

Linux中查看和杀死进程

首先查看进程:

[root@Appserver2 /]# ps -ef | grep tomcat
root      1726     1  0 Apr10 ?        00:07:20 /usr/java/jdk1.6.0_22//bin/java -Djava.util.logging.config.file=/opt/apache/apache-tomcat-6.0.39/conf/logging.properties -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Xms1024m -Xmx2048m -XX:PermSize=256M -XX:MaxNewSize=256m -XX:MaxPermSize=256m -Djava.endorsed.dirs=/opt/apache/apache-tomcat-6.0.39/endorsed -classpath /opt/apache/apache-tomcat-6.0.39/bin/bootstrap.jar -Dcatalina.base=/opt/apache/apache-tomcat-6.0.39 -Dcatalina.home=/opt/apache/apache-tomcat-6.0.39 -Djava.io.tmpdir=/opt/apache/apache-tomcat-6.0.39/temp org.apache.catalina.startup.Bootstrap start
root      4091     1  0 May05 ?        00:00:55 /usr/java/jdk1.6.0_22//bin/java -Djava.util.logging.config.file=/opt/apache/tomcat-fof/conf/logging.properties -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Xms1024m -Xmx2048m -XX:PermSize=256M -XX:MaxNewSize=256m -XX:MaxPermSize=256m -Djava.endorsed.dirs=/opt/apache/tomcat-fof/endorsed -classpath /opt/apache/tomcat-fof/bin/bootstrap.jar -Dcatalina.base=/opt/apache/tomcat-fof -Dcatalina.home=/opt/apache/tomcat-fof -Djava.io.tmpdir=/opt/apache/tomcat-fof/temp org.apache.catalina.startup.Bootstrap start
root     10370     1  0 Apr28 ?        00:00:53 /usr/java/jdk1.6.0_22//bin/java -Djava.util.logging.config.file=/opt/apache/apache-tomcat-test/conf/logging.properties -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Xms1024m -Xmx2048m -XX:PermSize=256M -XX:MaxNewSize=256m -XX:MaxPermSize=256m -Djava.endorsed.dirs=/opt/apache/apache-tomcat-test/endorsed -classpath /opt/apache/apache-tomcat-test/bin/bootstrap.jar -Dcatalina.base=/opt/apache/apache-tomcat-test -Dcatalina.home=/opt/apache/apache-tomcat-test -Djava.io.tmpdir=/opt/apache/apache-tomcat-test/temp org.apache.catalina.startup.Bootstrap start
root     24961     1  0 09:04 ?        00:01:54 /usr/java/jdk1.6.0_22//bin/java -Djava.util.logging.config.file=/opt/apache/tomcat-captainWeb/conf/logging.properties -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Xms1024m -Xmx2048m -XX:PermSize=256M -XX:MaxNewSize=256m -XX:MaxPermSize=256m -Djava.endorsed.dirs=/opt/apache/tomcat-captainWeb/endorsed -classpath /opt/apache/tomcat-captainWeb/bin/bootstrap.jar -Dcatalina.base=/opt/apache/tomcat-captainWeb -Dcatalina.home=/opt/apache/tomcat-captainWeb -Djava.io.tmpdir=/opt/apache/tomcat-captainWeb/temp org.apache.catalina.startup.Bootstrap start
root     25251     1  1 11:09 ?        00:01:32 /usr/java/jdk1.6.0_22//bin/java -Djava.util.logging.config.file=/opt/apache/tomcat-captainWeb/conf/logging.properties -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Xms1024m -Xmx2048m -XX:PermSize=256M -XX:MaxNewSize=256m -XX:MaxPermSize=256m -Djava.endorsed.dirs=/opt/apache/tomcat-captainWeb/endorsed -classpath /opt/apache/tomcat-captainWeb/bin/bootstrap.jar -Dcatalina.base=/opt/apache/tomcat-captainWeb -Dcatalina.home=/opt/apache/tomcat-captainWeb -Djava.io.tmpdir=/opt/apache/tomcat-captainWeb/temp org.apache.catalina.startup.Bootstrap start
root     25693 25399  0 13:16 pts/0    00:00:00 grep tomcat

然后删除进程:

[root@Appserver2 /]# kill -9 25251
阅读更多
版权声明:本文由施勇原创,转载请注明作者和出处! https://blog.csdn.net/shiyong1949/article/details/46830561
文章标签: linux 进程
个人分类: Linux
上一篇JSTL中<c:forEach>标签使用范例
下一篇SQL中Select语句的执行顺序
想对作者说点什么? 我来说一句

没有更多推荐了,返回首页

关闭
关闭