Linux下使用NMON監控 分析系統效能

2022-08-24 07:15:14 字數 1334 閱讀 3110

linux下使用nmon監控、分析系統效能 

關於nmon的介紹見官網:

從而確定:系統是64位,centos6.4的版本

wget

二.初始化nmon工具

命令1 #tar -zxvf nmon16d_x86.tar.gz

命令2 ./nmon_x86_64_centos6 -s 10 -c 60 -f -m /root/nmon

找到 nmon_x86_64_centos6 檔案

根據不同的平台,初始化對應平台的nmon工具:

chmod +x nmon_x86_64_centos6 (給於可執行許可權)

mv nmon_x86_64_centos6 /usr/local/bin/nmon (移動到指定目錄/usr/local/bin,並改名成  nmon )

三.執行nmon

cd  /usr/local/bin/

./nmon

mon可以實時監控系統資源的使用情況,執行下面的步驟可以展現一段時間系統資源消耗的報告。

下面是直接執行nmon命令實時監控系統資源消耗情況的截圖:

cpu、記憶體、磁碟和網路的消耗情況都被很直觀的展現出來。

四.生成nmon報告

1).採集資料:

#nmon -s10 -c60 -f -m /home/

引數解釋:

-s10 每 10 秒採集一次資料。

-c60 採集 60 次,即為採集十分鐘的資料。

-f 生成的資料檔名中包含檔案建立的時間。

-m 生成的資料檔案的存放目錄。

這樣就會生成乙個 nmon 檔案,並每十秒更新一次,直到十分鐘後。

生成的檔名如: _090824_1306.nmon ,"" 是這台主機的主機名。

2).生成報表:

下面是在測試環境中生成的nmon報告截圖:

紅色區域為不同指標的分析報告。

3).自動按天採集資料:

在 crontab 中增加一條記錄:

0 0 * * * root nmon -s300 -c288 -f -m /home/ > /dev/null 2>&1

300*288=86400 秒,正好是一天的資料。

參考文章:

nmon 效能:分析 aix 和 linux 效能的免費工具:

nmon analyser —— 生成 aix 效能報告的免費工具:

Linux監控工具nmon使用

一丶安裝nmon 1.2 解壓 tar gxvf nmon linux 14i.tar.gz 1.3 安裝 mv nmon x86 64 sentos6 nmon nmon解壓後有很多可執行檔案,根據linux的版本去安裝 cp nmon usr bin 二丶用法 2.1 命令輸出資料 nmon f...

linux下安裝nmon監控工具

wget2.解壓並修改許可權 3.啟動可能會報如下錯誤,安裝相應包即可 如果沒報,就表示安裝成功,可直接使用 錯誤1 error while loading shared libraries libncurses.so.5 cannot open shared object file no such...

Linux資源監控(Nmon)

2.解壓nmon linux 14g.tar.gz tar zxvf nmon linux 14g.tar.gz 3.為nmon x86 64 rhel54附加許可權 chmod a rxw nmon x86 64 rhel54 4.啟動該工具,在nmon目錄下輸入 nmon x86 64 rhel...