- 1、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。。
- 2、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 3、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
- 4、该文档为VIP文档,如果想要下载,成为VIP会员后,下载免费。
- 5、成为VIP后,下载本文档将扣除1次下载权益。下载后,不支持退款、换文档。如有疑问请联系我们。
- 6、成为VIP后,您将拥有八大权益,权益包括:VIP文档下载权益、阅读免打扰、文档格式转换、高级专利检索、专属身份标志、高级客服、多端互通、版权登记。
- 7、VIP文档为合作方或网友上传,每下载1次, 网站将根据用户上传文档的质量评分、类型等,对文档贡献者给予高额补贴、流量扶持。如果你也想贡献VIP文档。上传文档
查看更多
Cacti 0.8.8在CentOS6.2上的安装
1.系统的安装这次我用的是CentOS6.2-i386,在选择安装包时一个包都不需要装,就以最小系统或者为了方便只选Base Server。配置好IP等。A.关闭SElinux
1
2
3
4
5
6 vi /etc/sysconfig/selinux
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#?????? enforcing - SELinux security policy is enforced.
#?????? permissive - SELinux prints warnings instead of enforcing.
#?????? disabled - SELinux is fully disabled. 1
2
3
4
5 SELINUX=enforcing
# SELINUXTYPE= type of policy in use. Possible values are:
#?????? targeted - Only targeted network daemons are protected.
#?????? strict - Full SELinux protection.
SELINUXTYPE=targeted 把SELINUX=enforcing改为SELINUX=disabled并保存!在这个时候SElinux还在运行我们用
1 setenforce 0 来关闭SElinuxB.防火墙一般我都是把防火墙直接关掉
1
2
3
4 /etc/init.d/iptables stop
/etc/init.d/ip6tables stop
chkconfig iptables off
chkconfig ip6tables off 2.配置cacti需要的软件环境A.安装cacti需要的环境包
1
2
3 yum install -y httpd mysql mysql-server php php-mysql net-snmp net-snmp-utils
yum install -y zlib libpng freetype libjpeg fontconfig gd libxml2?
yum install -y rrdtool B.为cacti创建数据库和用户(是密码可自行修改)
1
2
3 service mysqld start
/usr/bin/mysqladmin --user=root create cacti
mysql -e GRANT ALL ON cacti.* TO cactiuser@localhost IDENTIFIED BY 3.下载cacti-0.8.8.tar.gz并解压、MV
1
2
3
4
5
6
7
8
9
10 cd /var/www/html/
yum install wget -y
wget /downloads/cacti-0.8.8.tar.gz
tar xf cacti-0.8.8.tar.gz
rm -rf cacti-0.8.8.tar.gz
cd cacti-0.8.8/
mv * ../
cd ..
rm -rf cacti-0.8.8/
mysql -ucactiuser - cacti /var/www/html/cacti.sql 修改cacti的配置文件并保存
1
2
3
4
5
6
7
8 vi /var/www/html/include/config.php
/* make sure these values refect your actual database/host/user/password */
$database_type = mysql;
$database_default = cacti;
$database_hostname = localhost;
$database_username = cactiuser;
$database_password = ;
$database_port = 3306; 设置crontab定时任务如果我们是最小系统安装将没有安装定时任务,此时我们首先安装
1 yum install vixie-cron 然后我们添加定时任务
1 echo */5 * * * * root /usr/bin/php /var/www/html/poller.php /etc/crontab 设置服务开机自启动,重启服务
1
2
3
文档评论(0)