Send signal to program, or list signal set synopsis kill [-S SIGNAL |-signal] PID ... kill-l [SIGNAL] ...
1. Brief description of signal operation1) kill-l. List the signal names and 2) Kill + Signal +%jobnumber. Signaled to a job 3) Kill + signal + PID. Indicates a signal to a PID
2. Important number of signals
Code |
Name |
Content |
1 |
SIGHUP |
On behalf of "let the PID reread its own profile", similar to restarting |
2 |
SIGINT |
Represents the [Ctrl]-c] entered by the keyboard to interrupt a program. |
9 |
SIGKILL |
The representative forces the interruption of a program, and if the program is halfway through, then the unfinished part may have a "half product", similar to what Vim would have. Filename.swp. |
15 |
SIGTERM |
Terminate the program with the normal end procedure. Because it is normal to terminate, the subsequent action will be done by him. However, if the program already has a problem, it is not possible to use the normal method of termination, the input of this signal is also useless. |
Example 1: After using PS to find the PID of this service, then use Kill to re-read the syslog configuration file data:
kill -sighup 'PS aux| grep ' syslog '| grep ' grep '| awk ' {print $} "'
Removal of the program kill