1. there are 5 states of processes on Centos: 1. running (running or waiting in the running queue) 2. interruption (sleep, blocked, waiting for the formation of a condition or receiving a signal) 3. do not interrupt (do not wake up when receiving the signal or do not run, the process must wait until an interruption occurs) 4. dead (the process has been terminated, but the process descriptor exists until the parent process calls wait4 () and is released after the system call)
1. there are 5 states of processes on Centos:
1. run (running or waiting in the running queue)
2. interruption (in sleep, blocked, waiting for the formation or receipt of a signal of a condition)
3. do not interrupt (do not wake up when receiving the signal or do not run, the process must wait until there is an interruption)
4. Stiff (the process has been terminated, but the process descriptor exists until the parent process calls wait4 () and is released after the system call)
5. stop (the process stops running after receiving signals from SIGSTOP, SIGSTP, SIGTIN, and SIGTOU)
2. Five status codes used by the PS tool to identify a process:
D. uninterruptible sleep (usually IO) cannot be interrupted)
R run runnable (on run queue)
S interrupt sleeping
T stop traced or stopped
Z dead a defunct ("zombie") process
3. ps command
Permission: all users
Usage: ps [options] [-- help]
Views: displays the dynamics of the instantaneous process.
Parameters:
1) ps a shows all programs under the current terminal, including those of other users.
2) ps-A shows all programs.
3) when listing programs in ps c, the real command name of each program is displayed without the path, parameter or resident service identifier.
4) the effect of this parameter is the same as that of the specified "A" parameter.
5) when listing programs, ps e displays the environment variables used by each program.
6) ps f uses ASCII characters to display the tree structure and express the relationship between programs.
7) the ps-H tree structure is displayed, indicating the relationship between programs.
8) ps-N shows all programs, except the programs under the ps command terminal.
9) ps displays the program status in the program signal format.
10) when listing programs in ps, it includes interrupted subroutines.
11) ps-t specifies the terminal number and lists the status of the program that belongs to the terminal.
12) ps u displays the program status in user-based format.
13) ps x shows all programs, which are not distinguished by terminals.
4. ps indicates the running processes in the current state, grep indicates searching in these processes, and ps aux shows all processes and their statuses.
$ Ps aux | grep svn
Check svn process
$ Kill-s 9 pid
Kill process