close
建置MRTG流量統計主機
2.設定/etc/sysconfig/network-scripts/ifcfg-etho固定IP
3.yum安裝mrtg及相關軟體,包括gcc、perl、zlib、gd、libpng、net-snmp、mrtg
指令:yum install gcc perl zlib gd libpng net-snmp mrtg
4.產生mrtg設定檔
指令:cfgmaker public@xxx.xxx.xxx.xxx > mrtg.cfg
5.調整mrtg設定檔/etc/mrtg/mrtg.cfg
WorkDir:/var/www/html/mrtg
Options[_]:growright,bits
6.產生HTML檔
指令:indexmaker --title 'XXXXXX' --output /var/www/html/mrtg/XXX.html /etc/mrtg/mrtg.cfg
7.執行mrtg
指令:env LANG=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg
8.設定定期執行,crontab -e
指令:*/5 * * * * env LANG=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg
9.調整mrtg網頁預設值
指令:vi /etc/httpd/conf.d/mrtg.conf
全站熱搜
留言列表