Options & Arguments

top -hv|-bcEHiOSs1 -d secs -n max -u|U user -p pid -o fld -w [cols]

  1. top - 22:00:33 up 13:09, 2 users, load average: 0.08, 0.02, 0.01
  2. Tasks: 9 total, 1 running, 8 sleeping, 0 stopped, 0 zombie
  3. %Cpu(s): 0.0 us, 0.0 sy, 0.0 ni,100.0 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
  4. MiB Mem : 6293.7 total, 6081.6 free, 72.8 used, 139.3 buff/cache
  5. MiB Swap: 2048.0 total, 2048.0 free, 0.0 used. 6028.5 avail Mem
  6. PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
  7. 1 root 20 0 920 604 516 S 0.0 0.0 0:00.02 init
  8. 9 root 20 0 920 108 20 S 0.0 0.0 0:03.34 init
  9. 61 ronnie 20 0 7992 4436 3088 S 0.0 0.1 4:58.73 tmux: server
  10. 63 ronnie 20 0 10156 5244 3480 S 0.0 0.1 0:00.66 bash
  11. 4988 root 20 0 920 108 20 S 0.0 0.0 0:00.00 init
  12. 4989 root 20 0 920 108 20 S 0.0 0.0 0:00.00 init
  13. 4990 ronnie 20 0 10168 5176 3388 S 0.0 0.1 0:00.14 bash
  14. 5005 ronnie 20 0 7144 3648 3288 S 0.0 0.1 0:00.12 tmux: client
  15. 5153 ronnie 20 0 10884 3856 3328 R 0.0 0.1 0:00.01 top

Summary Fields

Row Field Meaning
1 top This is the name of the program.
22:00:33 This is the current time of day.
up 13:09 This is called uptime. It is the amount of time since the machine was last booted. In this example, the system has been up for six and a half hours.
2 users There are two users logged in.
load average: Load average refers to the number of processes that are waiting to run; that is, the number of processes that are in a runnable state and are sharing the CPU. Three values are shown, each for a different period of time. The first is the average for the last 60 seconds, the next the previous 5 minutes, and finally the previous 15 minutes. Values less than 1.0 indicate that the machine is not busy.
2 Tasks: This summarizes the number of processes and their various process states.
3 Cpu(s): This row describes the character of the activities that the CPU is performing.
0.7%us 0.7 percent of the CPU is being used for user processes. This means processes outside the kernel.
1.0%sy 1.0 percent of the CPU is being used for system (kernel) processes.

Sort

  1. x: 高亮当前排序的列
  2. b: 高亮背景
  3. SHIFT <``SHIFT >: 切换排序的列

    Kill processes

  4. K