Home > Article > Operation and Maintenance > How to solve the problem that tomcat cannot be shut down in linux
Method: 1. Use the ps command to find the current tomcat process id, the syntax is "ps -ef|grep tomcat"; 2. Use the kill command to end the tomcat process based on the id, the syntax is "kill -HUP id" ;3. Use the "./shutdown.sh" command to restart.
#The operating environment of this tutorial: linux7.3 system, Dell G3 computer.
How to solve tomcat cannot be shut down in Linux
Execute ./shutdown in tomcat’s bin directory to close tomcat and the following problem occurs
Solution:
Execute the following command to find the current tomcat process id
ps -ef|grep tomcat
The red circled position is the process id
According to the found process id of tomcat, end the tomcat process through the following command
kill -3 2196
Enter the following command to close tomcat
./shutdown.sh
The following result indicates that tomcat has been closed
After shutting down, enter the following command to restart tomcat
./startup.sh
Started successfully
Related recommendations:《Linux video tutorial》
The above is the detailed content of How to solve the problem that tomcat cannot be shut down in linux. For more information, please follow other related articles on the PHP Chinese website!