日本免费全黄少妇一区二区三区-高清无码一区二区三区四区-欧美中文字幕日韩在线观看-国产福利诱惑在线网站-国产中文字幕一区在线-亚洲欧美精品日韩一区-久久国产精品国产精品国产-国产精久久久久久一区二区三区-欧美亚洲国产精品久久久久

I/O、內(nèi)存、網(wǎng)絡(luò)性能優(yōu)化命令 iostat , vmstat,netstat

是在sun網(wǎng)站上看到的,原文是e文,連接如下:
http://www.adminschoice.com/docs/iostat_vmstat_netstat.htm

大概翻譯了一下,總覺(jué)得好像以前哪位大大貼過(guò)類(lèi)似的
不管了,覺(jué)得有點(diǎn)用,大家一起看看
翻譯得不好,見(jiàn)笑了……如果有錯(cuò),請(qǐng)指正哦,先謝了

Input Output statistics ( iostat )

iostat反映了終端、磁盤(pán)I/O情況和CPU活動(dòng) 。輸出結(jié)果的第一行是從系統(tǒng)啟動(dòng)到現(xiàn)在為止的這段時(shí)間的結(jié)果,接下去的每一行是interval時(shí)

間段內(nèi)的結(jié)果 。Kernel里有一組計(jì)數(shù)器用來(lái)跟蹤這些值 。
iostat的默認(rèn)參數(shù)是tdc(terminal, disk, and CPU) 。如果任何其他的選項(xiàng)被指定,這個(gè)默認(rèn)參數(shù)將被完全替代,例如,iostat -d將只反

映磁盤(pán)的統(tǒng)計(jì)結(jié)果 。

語(yǔ)法:

基本語(yǔ)法: iostat interval count

option - 讓你指定所需信息的設(shè)備,像磁盤(pán)、cpu或者終端(-d , -c , -t or -tdc )。x 選項(xiàng)給出了完整的統(tǒng)計(jì)結(jié)果(gives the extended

statistic) 。

interval - 在兩個(gè)samples之間的時(shí)間(秒) 。

count - 就是需要統(tǒng)計(jì)幾次

例子:

$ iostat -xtc 5 2
extended disk statistics tty cpu
disk r/s w/s Kr/s Kw/s wait actv svc_t %w %b tin tout us sy wt id
sd0 2.6 3.0 20.7 22.7 0.1 0.2 59.2 6 19 0 84 3 85 11 0
sd1 4.2 1.0 33.5 8.0 0.0 0.2 47.2 2 23
sd2 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0 0
sd3 10.2 1.6 51.4 12.8 0.1 0.3 31.2 3 31


The fIElds have the following meanings:

disk name of the disk
r/s reads per second
w/s writes per second
Kr/s kilobytes read per second
Kw/s kilobytes written per second
wait average number of transactions waiting for service (Q length)
actv average number of transactions actively
being serviced (removed from the
queue but not yet
completed)
%w percent of time there are transactions waiting
for service (queue non-empty)
%b percent of time the disk is busy (transactions
in progress)




Results and Solutions:

從iostat輸出結(jié)果中需要注意的值:

Reads/writes per second (r/s , w/s)
Percentage busy (%b)
Service time (svc_t)

如果磁盤(pán)顯示長(zhǎng)時(shí)間的高reads/writes,并且磁盤(pán)的percentage busy (%b)也遠(yuǎn)大于5%,同時(shí)average service time (svc_t)也遠(yuǎn)大于30

milliseconds,這以下的措施需要被執(zhí)行:
1.)調(diào)整應(yīng)用,令其使用磁盤(pán)i/o更加有效率,可以通過(guò)修改磁盤(pán)隊(duì)列、使用應(yīng)用服務(wù)器的cache

2.)將文件系統(tǒng)分布到2個(gè)或多個(gè)磁盤(pán)上,并使用volume manager/disksuite的條帶化特點(diǎn)

3.) 增加系統(tǒng)參數(shù)值,如inode cache , ufs_ninode 。Increase the system parameter values for inode cache , ufs_ninode , which

is Number of inodes to be held in memory. Inodes are cached globally (for UFS), not on a per-file system basis

4.) 將文件系統(tǒng)移到更快的磁盤(pán)/控制器,或者用更好的設(shè)備來(lái)代替

還有兩段等會(huì)翻好了再貼……

Virtual Memory Statistics ( vmstat )

vmstat - vmstat反映了進(jìn)程的虛擬內(nèi)存、虛擬內(nèi)存、磁盤(pán)、trap(是不是翻譯成中斷??)和cpu的活動(dòng)情況

在多cpu系統(tǒng)中,vmstat在輸出結(jié)果中平均了cpu數(shù)量 。For per-process statistics .如果沒(méi)有選項(xiàng),vmstat顯示一行虛擬內(nèi)存活動(dòng)的概要

結(jié)果,是從系統(tǒng)啟動(dòng)時(shí)開(kāi)始的 。

語(yǔ)法:

vmstat interval count

option - 讓你指定所需的信息類(lèi)型,例如 paging -p , cache -c ,.interrupt -i etc.

如果沒(méi)有指定選項(xiàng),將會(huì)顯示進(jìn)程、內(nèi)存、頁(yè)、磁盤(pán)、中斷和cpu信息

interval - 同iostat

count - 同iostat

例子
The following command displays a summary of what the system
is doing every five seconds.

example% vmstat 5
procs memory page disk faults cpu
r b w swap free re mf pi p fr de sr s0 s1 s2 s3 in sy cs us sy id

推薦閱讀