ID=`ps -ef | grep java | grep apache-tomcat-6.0.35|awk '{print $2}'`
echo $ID
echo "------start---------"
for id in $ID
do
kill -9 $id
echo "killed$id"
done
echo "------end---------"
Note:
ID = `ps -ef | grep java | grep apache-tomcat-6.0.35 | awk '{print $ 2}'` is changed to the instruction of the own server to check the tomcat process
[Java interview questions and answers] sorting recommendations
- Basics and Grammar
- set
- network programming
- Concurrent programming
- Web
- Safety
- Design Patterns
- frame
- Algorithms and data structures
- abnormal
- File parsing and generation
- Linux
- MySQL
- Oracle
- Redis
- Dubbo