Cacti uses snmpget to obtain data and uses rrdtool to draw images. In addition, you do not need to understand the complex parameters of rrdtool. It provides powerful data and user management functions, allowing each user to view the tree structure, host, and any graph, and perform user verification with LDAP, you can also add templates by yourself, which are very powerful and complete.
I. Installation
1. Install the lamp Environment
# Yum install-y httpd PHP-mysql PHP-snmp php-xml php-Gd MySQL mysql-server mysql-sevel
# Service httpd start
# Chkconfig httpd on
# Service mysqld start
# Chkconfig mysqld on
# Mysqladmin-u Root Password 'Password'
Ii. install and configure net-snmp
1. Install the net-snmp component
# Yum install-y net-snmp-utils net-snmp-libs net-snmp-devel
2. Configuration File
# Vim/etc/snmp/snmpd. conf
Access not configgroup "" any noauth exact systemview none (changed)
Access notconfiggroup "" any noauth exact all none
View All supported ded. 1 80
3. Install rrdtool
# Yum install-y rrdtool
4. Download and install cacti
# Wget http://www.cacti.net/downloads/cacti-0.8.8b.tar.gz
# Tar-zxvf cacti-0.8.8b.tar.gz
# Music cacti-0.8.8b/var/www/html/cacti
# Cd/var/www/html/cacti/
5. Configure the database
1. Create a database
Mysql> Create Database cacti;
2. Create user authorization
Mysql> grant all on cacti. * to [email protected] identified by 'cacti ';
Mysql> flush privileges;
3. Import Database
# Mysqldump-ucacti-P cacti <cacti. SQL
6. modify the configuration file
# Vim/var/www/html/cacti/include/config. php
$ Database_type = "MySQL ";
$ Database_default = "cacti ";
$ Database_hostname = "localhost ";
$ Database_username = "cacti ";
$ Database_password = "cacti ";
$ Database_port = "3306 ";
$ Database_ssl = false;
$ Url_path = "/cacti/"; (uncomment)
# Chown-r Apache/var/www/html/cacti
VII. Configure scheduled tasks
# Echo "*/5 ***** root PHP/var/www/html/cacti/poller. php>/dev/null 2> & 1">/etc/crontab
# Service crond restart
8. Complete cacti Installation
Http: // ip/cacti
The client only needs to configure the community of net-snmp and the server side. For details, see Step 2.
This article is from the blog of the "Bremen band" and will not be reposted!