1、添加用戶(hù)
10年的阿巴嘎網(wǎng)站建設(shè)經(jīng)驗(yàn),針對(duì)設(shè)計(jì)、前端、開(kāi)發(fā)、售后、文案、推廣等六對(duì)一服務(wù),響應(yīng)快,48小時(shí)及時(shí)工作處理。成都全網(wǎng)營(yíng)銷(xiāo)的優(yōu)勢(shì)是能夠根據(jù)用戶(hù)設(shè)備顯示端的尺寸不同,自動(dòng)調(diào)整阿巴嘎建站的顯示方式,使網(wǎng)站能夠適用不同顯示終端,在瀏覽器中調(diào)整網(wǎng)站的寬度,無(wú)論在任何一種瀏覽器上瀏覽網(wǎng)站,都能展現(xiàn)優(yōu)雅布局與設(shè)計(jì),從而大程度地提升瀏覽體驗(yàn)。創(chuàng)新互聯(lián)公司從事“阿巴嘎網(wǎng)站設(shè)計(jì)”,“阿巴嘎網(wǎng)站推廣”以來(lái),每個(gè)客戶(hù)項(xiàng)目都認(rèn)真落實(shí)執(zhí)行。[root@nagios ~]# groupadd nagcmd [root@nagios ~]# useradd -G nagcmd nagios [root@nagios ~]# usermod -a -G nagcmd apache
2、安裝nagios
官方下載地址:http://www.nagios.org/download/
[root@nagios ~]# cd /home/nagios [root@nagios nagios]# wget http://jaist.dl.sourceforge.net/project/nagios/nagios-4.x/nagios-4.0.7/nagios-4.0.7.tar.gz [root@nagios nagios]# tar xzvf nagios-4.0.7.tar.gz [root@nagios nagios]# cd nagios-4.0.7 [root@nagios nagios-4.0.7]# ./configure --with-command-group=nagcmd --enable-event-broker [root@nagios nagios-4.0.7]#make all [root@nagios nagios-4.0.7]#make install [root@nagios nagios-4.0.7]#make install-init [root@nagios nagios-4.0.7]#make install-config [root@nagios nagios-4.0.7]#make install-commandmode [root@nagios nagios-4.0.7]#make install-webconf
設(shè)置登陸web界面時(shí)HTTP驗(yàn)證的賬號(hào)密碼
[root@nagios nagios-4.0.7]#htpasswd -c /usr/local/nagios/etc/htpasswd.users nagiosadmin [root@nagios nagios-4.0.7]#service httpd restart
3、安裝nagios-plugins
[root@nagios nagios-4.0.7]#cd /home/nagios [root@nagios nagios]# wget http://nagios-plugins.org/download/nagios-plugins-2.0.2.tar.gz [root@nagios nagios]# tar xzvf nagios-plugins-2.0.2.tar.gz [root@nagios nagios]# cd nagios-plugins-2.0.2 [root@nagios nagios-plugins-2.0.2]# ./configure --with-nagios-user=nagios --with-nagios-group=nagios --with-mysql [root@nagios nagios-plugins-2.0.2]# make [root@nagios nagios-plugins-2.0.2]# make install
所有插件命令將被安裝到/usr/local/nagios/libexec 目錄下
4、其他設(shè)置
檢查nagios的配置:
[root@nagios ~]# /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
添加自動(dòng)動(dòng)項(xiàng):
[root@nagios ~]# chkconfig --add nagios [root@nagios ~]# chkconfig nagios on [root@nagios ~]# service nagios start
登陸頁(yè)面:
http://localhost/nagios
賬號(hào)nagiosadmin密碼123456
5、遇到的問(wèn)題
點(diǎn)擊頁(yè)面左側(cè)的MAP和History報(bào)錯(cuò):
The requested URL /nagios/sbin/statusmap.cgi was not found on this server. The requested URL /nagios/sbin/histogram.cgi was not found on this server.
原因一:因?yàn)間d-devel php-gd沒(méi)有安裝的問(wèn)題,造成NAGIOS在編譯時(shí)不生成這statusmap.cgi
原因二:nagios編譯在前, gd-devel安裝在后,造成不生成這statusmap.cgi
解決方法:yum安裝gd-devel php-gd,再重新編譯安裝nagios
另外有需要云服務(wù)器可以了解下創(chuàng)新互聯(lián)scvps.cn,海內(nèi)外云服務(wù)器15元起步,三天無(wú)理由+7*72小時(shí)售后在線(xiàn),公司持有idc許可證,提供“云服務(wù)器、裸金屬服務(wù)器、高防服務(wù)器、香港服務(wù)器、美國(guó)服務(wù)器、虛擬主機(jī)、免備案服務(wù)器”等云主機(jī)租用服務(wù)以及企業(yè)上云的綜合解決方案,具有“安全穩(wěn)定、簡(jiǎn)單易用、服務(wù)可用性高、性?xún)r(jià)比高”等特點(diǎn)與優(yōu)勢(shì),專(zhuān)為企業(yè)上云打造定制,能夠滿(mǎn)足用戶(hù)豐富、多元化的應(yīng)用場(chǎng)景需求。