linux系统查看系统性能命令详解(5)
2. top //直接敲TOP即可。
//系统当前时间、启动时间、当前登录数、平均负载 1、5、15分钟负载值
top - 19:43:46 up 4 days, 10:46, 7 users, load average: 0.25, 0.37, 0.38
//进程总数、运行进程数、休眠进程数、终止进程数、僵死进程数
Tasks: 222 total, 1 running, 221 sleeping, 0 stopped, 0 zombie
//用户占用、系统占用、优先线程占用、闲置线程占用、
Cpu(s): 0.3%us, 0.1%sy, 0.0%ni, 98.5%id, 1.0%wa, 0.0%hi, 0.1%si, 0.0%st
//内存状态(总内存、已用内存、闲置内存、缓存使用内容)
Mem: 8183648k total, 8124052k used, 59596k free, 115072k buffers
//交换内存(总交换内存、已用内存、闲置内存、高速缓存容量)
Swap: 2104472k total, 1369376k used, 735096k free, 1462236k cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
1 root 16 0 784 72 40 S 0 0.0 0:06.28 init
2 root RT 0 0 0 0 S 0 0.0 0:00.08 migration/0
3 root 34 19 0 0 0 S 0 0.0 0:00.01 ksoftirqd/0
4 root RT 0 0 0 0 S 0 0.0 0:00.29 migration/1
5 root 34 19 0 0 0 S 0 0.0 0:00.00 ksoftirqd/1
6 root RT 0 0 0 0 S 0 0.0 0:00.21 migration/2
7 root 34 19 0 0 0 S 0 0.0 0:00.05 ksoftirqd/2
8 root RT 0 0 0 0 S 0 0.0 0:00.08 migration/3
9 root 34 19 0 0 0 S 0 0.0 0:00.01 ksoftirqd/3
10 root 10 -5 0 0 0 S 0 0.0 0:00.02 events/0
11 root 10 -5 0 0 0 S 0 0.0 0:00.00 events/1