The KILL command is used to "kill" the process that specifies the process PID. Terminate a foreground process you can use CTRL + C and terminate a background process with the KILL command. The KILL command ends the process by sending a specified signal to the process. By default, the KILL command sends a term signal to the process (all), and the term signal terminates all processes that cannot capture the signal. If you want to terminate the process that can capture the signal, send a Kill signal (9) and forcibly "kill" the process. Use kill-9 to be careful, in the database (Oracle, MySQL, etc.) server, try not to use kill-9 kill database related processes, this may bring you disastrous results.
The Killall command is used to "kill" a process that specifies a name. The biggest difference with the kill command is that using the KILL command must know the PID number of the "kill" process, then we have to use commands such as ps/pidof/pstree/top to get the PID of the process. Pkill and Killall Apply the same method, but also directly kill the running process.
The use of the above command is relatively simple, this article will not repeat.
Linux commands (005)-Comparison of Kill, Pkill, and Killall