1、CPU使用率排序
[root@localhost ~]# ps auxk-pcpu
[root@localhost ~]# top -b
[root@localhost ~]# top -b |head -n 30
root@yiquan-ThinkPad-X200:~# ps auxk-pcpu
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
yiquan 2619 16.0 8.5 885388 166880 ? Sl May28 2:50 /usr/lib/firefox-4.0.1/firefox-bin
yiquan 2904 8.9 1.9 91612 38060 ? Sl 00:05 0:36 /usr/lib/nspluginwrapper/i386/linux/npviewer.bin –plugin /us
root 1567 6.7 1.5 154896 29896 tty7 Ss+ May28 1:25 /usr/bin/X :0 -nr -verbose -auth /var/run/gdm/auth-for-gdm-eR
yiquan 2891 3.4 1.0 238640 20400 ? Sl 00:05 0:13 /usr/lib/firefox-4.0.1/plugin-container /var/lib/flashplugin-
yiquan 2234 2.5 3.4 636260 67444 ? Sl May28 0:32 compiz
yiquan 2948 1.2 0.9 345808 19400 ? Sl 00:11 0:00 gnome-terminal
yiquan 2239 1.0 2.3 675936 45516 ? Sl May28 0:13 nautilus
yiquan 2954 0.5 0.2 25648 5380 pts/0 Ss 00:11 0:00 bash
yiquan 2343 0.4 1.0 451792 20868 ? Sl May28 0:06 /usr/lib/unity/unity-panel-service
yiquan 2550 0.2 2.4 366144 47680 ? Sl May28 0:03 /usr/bin/python /usr/lib/ubuntuone-client/ubuntuone-syncdaemo
root 3009 0.1 0.1 84316 2536 pts/0 S 00:11 0:00 su
yiquan 2192 0.1 0.1 26284 2688 ? Ss May28 0:01 //bin/dbus-daemon –fork –print-pid 5 –print-address 7 –se
yiquan 2182 0.1 1.5 392324 29968 ? Sl May28 0:01 /usr/bin/python /usr/share/ibus/ui/gtk/main.py
root 2596 0.0 0.0 15812 1704 ? Ss May28 0:00 /sbin/mount.ntfs /dev/sda1 /media/System -o rw,nosuid,nodev,u
root 1289 0.0 0.0 0 0 ? S May28 0:00 [kworker/0:2]
root 1 0.0 0.1 24140 2312 ? Ss May28 0:00 /sbin/init
mysql 1037 0.0 1.2 171104 24804 ? Ssl May28 0:00 /usr/sbin/mysqld
yiquan 2245 0.0 0.9 408948 18336 ? SLl May28 0:00 nm-applet –sm-disable
yiquan 2200 0.0 0.3 59572 6348 ? S May28 0:00 /usr/lib/libgconf2-4/gconfd-2
root 25 0.0 0.0 0 0 ? S May28 0:00 [kworker/1:1]
yiquan 2216 0.0 0.7 327644 14608 ? Ssl May28 0:00 /usr/lib/gnome-settings-daemon/gnome-settings-daemon
root 8 0.0 0.0 0 0 ? S May28 0:00 [kworker/1:0]
root 3017 0.0 0.1 22732 2488 pts/0 S 00:11 0:00 bash
root 2037 0.0 0.2 77660 4352 ? Sl May28 0:00 /usr/lib/upower/upowerd
102 622 0.0 0.1 24740 2208 ? Ss May28 0:00 dbus-daemon –system –fork –activation=upstart
root 14 0.0 0.0 0 0 ? S May28 0:00 [kworker/u:1]
yiquan 2263 0.0 0.6 337276 12224 ? Sl May28 0:00 gnome-power-manager
2、按内存使用情况排序
命令:ps
参数:auxk-vsz 以所使用的虚拟内存大小排序
auxk-rss 以进程使用的实际物理内存大小排序
只显示系统正在运行的进程。
[root@localhost ~]# ps aur
Leave a Reply