nagios圖像(nagiosgraph)(未成)
興寧網(wǎng)站制作公司哪家好,找創(chuàng)新互聯(lián)建站!從網(wǎng)頁設(shè)計、網(wǎng)站建設(shè)、微信開發(fā)、APP開發(fā)、響應(yīng)式網(wǎng)站開發(fā)等網(wǎng)站項目制作,到程序開發(fā),運營維護(hù)。創(chuàng)新互聯(lián)建站從2013年成立到現(xiàn)在10年的時間,我們擁有了豐富的建站經(jīng)驗和運維經(jīng)驗,來保證我們的工作的順利進(jìn)行。專注于網(wǎng)站建設(shè)就選創(chuàng)新互聯(lián)建站。
http://cdnetworks-kr-1.dl.sourceforge.net/project/nagiosgraph/nagiosgraph/1.4.4/nagiosgraph-1.4.4.tar.gz
http://apt.sw.be/redhat/el5/en/i386/rpmforge/RPMS/rrdtool-1.2.18-1.el5.rf.i386.rpm (32位)
http://apt.sw.be/redhat/el5/en/i386/rpmforge/RPMS/perl-rrdtool-1.2.18-1.el5.rf.i386.rpm
http://apt.sw.be/redhat/el5/en/x86_64/rpmforge/RPMS/rrdtool-1.2.18-1.el5.rf.x86_64.rpm (64位)
http://apt.sw.be/redhat/el5/en/x86_64/rpmforge/RPMS/perl-rrdtool-1.2.18-1.el5.rf.x86_64.rpm
# rpm -ivh rrdtool-1.2.18-1.el5.rf.i386.rpm
# rpm -ivh perl-rrdtool-1.2.18-1.el5.rf.i386.rpm
#tar zxf nagiosgraph-1.4.4.tar.gz
# cd nagiosgraph-1.4.4
# perl Makefile.PL
# vi install.pl
把所有的www-data改成nobody (web的用戶)
:wq
# make && make install
第一個路徑改為/usr/local/nagios/nagiosgraph其它直接回車
# cd /usr/local/nagios/nagiosgraph/etc
# cp nagiosgraph-apache.conf /usr/local/apache/conf
# vi /usr/local/apache/conf/httpd.conf
Include conf/nagiosgraph-apache.conf
:wq
# service httpd restart
# vi /usr/local/nagios/etc/nagios.cfg
service_perfdata_file=/usr/local/nagios/nagiosgraph/var/perfdata.log
service_perfdata_file_template=$LASTSERVICECHECK$||$HOSTNAME$||$SERVICEDESC$||$SERVICEOUTPUT$||$SERVICEPERFDATA$
service_perfdata_file_mode=a
service_perfdata_file_processing_interval=30
service_perfdata_file_processing_command=process-service-perfdata
process_performance_data=1 (原為0)
:wq
# cp cgi/*.cgi /usr/local/nagios/sbin
# cp bin/insert.pl /usr/local/nagios/libexec
# cp share/nagios/graph.css /usr/local/nagios/share
# cp share/nagiosgraph.js /usr/local/nagios/share
# vi /usr/local/nagios/etc/objects/commands.cfg
# 'process-host-perfdata' command definition
define command{
command_name process-host-perfdata
command_line /usr/local/nagios/libexec/insert.pl
}
# 'process-service-perfdata' command definition
define command{
command_name process-service-perfdata
command_line /usr/local/nagios/libexec/insert.pl
}
:wq
注:要注釋掉原有對process-service-perfdata和process-host-perfdata的定義
# vi /usr/local/nagios/etc/objects/yang.cfg
為主機添加小太陽圖標(biāo)
# vi /usr/local/nagios/etc/objects/yang.cfg
define host {
use linux-server
host_name yang
address 192.168.1.10
action_url /nagiosgraph/cgi-bin/show.cgi?host=$HOSTNAME$
}
:wq
為單個服務(wù)添加小太陽圖標(biāo)
# vi /usr/local/nagios/etc/objects/yang.cfg
define service {
use generic-service
host_name yang
service_description check_load
check_command check_nrpe!check_load
normal_check_interval 2
action_url /nagiosgraph/cgi-bin/show.cgi?host=$HOSTNAME$&srv=$SERVICEDESC$
}
:wq
重啟nagios
# service nagios restart
# ls /usr/local/nagios/nagiosgraph/var/rrd (看有沒有生成nagios中定義的主機名文件)
注:我做的沒有生成主機名文件,沒有生成圖表,原因還在研究中
標(biāo)題名稱:nagios圖像(nagiosgraph)(未成)
網(wǎng)站URL:http://jinyejixie.com/article34/ijchse.html
成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供營銷型網(wǎng)站建設(shè)、外貿(mào)建站、面包屑導(dǎo)航、微信公眾號、關(guān)鍵詞優(yōu)化、軟件開發(fā)
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)