Linux Kill is a command to terminate a process. By sending a different signal to the corresponding process.
Kill command parameter:
-L signal, if no signal number parameter, then use the "-L" parameter will list all the signal names
-a The corresponding relationship between the command name and the process number is not restricted when processing the current process
-p Specifies that the KILL command prints only the process number of the associated process without sending any signals
-s specifies to send a signal
-u Specifies user
What process signals are there:
How do I find the PID of a process?
You can find the PID by Ps/pgrep/pidof/top and other commands.
Ps-ef | grep Chrome
Pgrep Chrome
PIDOF Chrome
How to kill PID?
#强制终止进程
Kill-s 9 pid
#xargs表示用前面命令输出结果作为kill-S 9 parameter
Pgrep Chrome | Xargs Kill-s 9
#命令执行结果作为参数
Kill-s 9 ' pgrep Chrome '
#pkill =pgrep+kill here without parameter S
Pkill-9 Chrome
#杀死同一进程组内所有进程, you can specify the process name
Killall httpd