服务器监控--cacti中英文版安装全解
作者 佚名技术
来源 Linux系统
浏览
发布时间 2012-05-15
eetype2
#安装rrdtool-1.2.23 cd /opt tar zxvf rrdtool-1.2.23.tar.gz cd rrdtool-1.2.23 ./configure --prefix=/usr/local/rrdtool make make install #========================安装net-snmp======================== cd /opt tar -zxvf net-snmp-5.3.2.tar.gz cd net-snmp-5.3.2 ./configure –prefix=/usr/snmp –enable-mfd-rewrites --enable-developer make;make install cp EXAMPLE.conf /usr/local/net-snmp/share/snmp/snmpd.conf #vi /usr/local/net-snmp/share/snmp/snmpd.conf #com2sec local localhost public #com2sec mynetwork 192.168.8.0/24 public /usr/local/net-snmp/sbin/snmpd -c /usr/local/net-snmp/share/snmp/snmpd.conf echo "/usr/local/net-snmp/sbin/snmpd -c /usr/local/net-snmp/share/snmp/snmpd.conf" >> /etc/rc.local PATH=/usr/local/net-snmp/bin/:/usr/local/net-snmp/sbin/:$PATH cd ../ #=======================安装 英文版cacti============================ #下载[url]http://www.cacti.net[/url] cd /opt useradd cactiuser -g users passwd cactiuser (pwd:cactipw) tar -zxvf cacti-0.8.7b.tar.gz mkdir -p /var/www/ mv cacti-0.8.7b /var/www/cacti #创建cactidb数据库 /usr/local/mysql5/bin/mysqladmin -u root password nginx /usr/local/mysql5/bin/mysql -u root -pnginx create database cactidb; grant all on cactidb.* to ''cactiuser''@''localhost'' identified by ''cactipw''; exit; cd /var/www/cacti /usr/local/mysql5/bin/mysql -u root -pnginx cactidb <cacti.sql chown -R cactiuser rra/ log/ cd scripts chown cactiuser:users * #vi /var/htdoc/cacti/include #$database_type = “mysql”; #$database_default = “cactidb”; #$database_hostname = “localhost”; #$database_username = “cactiuser”; #$database_password = “cactipw”; crontab -u cactiuser -e 加入 */5 * * * * /usr/local/php5/bin/php /var/www/cacti/poller.php > /dev/null 2>&1 #[url]http://192.168.8.152 [/url] admin admin cactipw su cactiuser /usr/local/php5/bin/php /var/www/cacti/poller.php # 把cacti目录里的cmd.php和poller.php文件加下运行的权限 #测试SNMP是不是工作正常 snmpwalk -c community -v 2c hostIP if正常的话会出现一些数据.不正常会出现一些错误,也会有对应的错误提示. #7、我原来使用的是rrdtool-1.0.x 升级到 1.2.x 后部分图像无法显示(Zoom) #修改Configuration -> Settings -> RRDTool Utility Version -> 1.2.x #==========================安装 中文版cacti=================================== cd /opt tar -zxvf cacti-0.8.7b-cn-utf8.tar.gz useradd cactiuser -g users passwd cactiuser (pwd:cactipw) mkdir -p /var/www/ mv cacti-0.8.7b /var/www/cacti #创建cactidb数据库 /usr/local/mysql5/bin/mysqladmin -u root password nginx /usr/local/mysql5/bin/mysql -u root -pnginx create database cactidb; grant all on cactidb.* to ''cactiuser''@''localhost'' identified by ''cactipw''; exit; cd /var/www/cacti /usr/local/mysql5/bin/mysql -u root -pnginx cactidb <cacti.sql chown -R cactiuser rra/ log/ cd scripts chown cactiuser:users * #vi /var/htdoc/cacti/include/config.php global.php #$database_type = “mysql”; #$database_default = “cactidb”; #$database_hostname = “localhost”; #$database_username = “cactiuser”; #$database_password = “cactipw”; crontab -u cactiuse |
凌众科技专业提供服务器租用、服务器托管、企业邮局、虚拟主机等服务,公司网站:http://www.lingzhong.cn 为了给广大客户了解更多的技术信息,本技术文章收集来源于网络,凌众科技尊重文章作者的版权,如果有涉及你的版权有必要删除你的文章,请和我们联系。以上信息与文章正文是不可分割的一部分,如果您要转载本文章,请保留以上信息,谢谢! |
你可能对下面的文章感兴趣
上一篇: [伊达原创]如果fstab这个文件消失了怎么办?下一篇: linux服务---DNS
关于服务器监控--cacti中英文版安装全解的所有评论