htop命令:
選項:
-d # : 指定延遲時間間隔;
-u UserName :僅顯示指定用戶的進程;
-s : COLUME : 以指定字段進行排序;
子命令 :
l : 顯示選定的進程打開的文件列表;
s: 跟蹤選定的進程的系統調用;
t: 以cengj關系顯示個進程狀態;
a:將選定的進程綁定至某指定的cpu核心;
vmstat命令:
vmstat – Report virtual memory statistics
vmstat [options] [delay [count]]
procs:
r: 等待運行的進程的個數;cpu上等待運行的任務的隊列長度;
b:處于不可中斷睡眠狀態的進程個數;被阻塞的任務的長度;
memory :
swpd : 交換內存使用總量;
free: 空閑的物理內存總量;
buffer :用于buffer的內存總量:
cache :用于cache的內存總量;
swap
si: 數據進入swap中的數據速率(kb/s)
so: 數據離開swap的速率(kb/s)
io :
bi: 從塊設備讀入數據到系統的速度(kb/s)
bo:保存數據之塊設備的速率(kb/s)
system
in : interrupts, 中斷速率;
cs : context switch , 上下文切斷的速率;
cpu:
us: user space
sy: system
id: idle
wa:wait
st: stolen
選項:
-s:顯示內存統計數據;
pmap命令:
-report memory map of a process
pmap [options] pid […]
-x : 顯示詳細格式的信息;
另一種查看方式: cat /proc/PID/maps
glances命令:
-A aross-platform curses-based monitoring tool
內建命令:
常用選項:
-b: 以Byte為單位顯示網上數據速率;
-d: 關閉磁盤I/P模塊;
-m: 關閉mount模塊;
-n: 關閉network模塊;
-t # :刷新時間間隔;
-1 :每個cpu的相關信息數據單獨顯示;
-o {HTML | CSV}: 輸出格式;
-f /PATH/TO/SOMEDIR :設定輸出文件的位置;
C/S模式下運行glances 命令;
服務模式:
glances -s -B IPADDR
IPDDR :本機某地址,用于監聽
客戶端模式:
glances -c IPADDR 連接客戶端
dstat命令:
-c, –cpu
enable cpu stats (system, user, idle, wait, hardware interrupt, software interrupt)
-C 0,3,total
include cpu0, cpu3 and total (when using -c/–cpu)
-d, –disk
enable disk stats (read, write)
-D total,hda
include total and hda (when using -d/–disk)
-g, –page
enable page stats (page in, page out)
-i, –int
enable interrupt stats
-I 5,10
include interrupt 5 and 10 (when using -i/–int)
-l, –load
enable load average stats (1 min, 5 mins, 15mins)
-m, –mem
enable memory stats (used, buffers, cache, free)
-n, –net
enable network stats (receive, send)
-N eth1,total
include eth1 and total (when using -n/–net)
-p, –proc
enable process stats (runnable, uninterruptible, new)
原創文章,作者:shadow,如若轉載,請注明出處:http://www.www58058.com/65892
幾個工具挺強大的,但是希望能常用起來,熟練掌握工具的同時也要掌握對應的數據指標究竟帶來什么問題。