Cacti installation and configuration 2 in linux

Source: Internet
Author: User
Tags rrdtool
This experiment is the second step of installing and configuring Nagios and Cacti. The Cacti installation and configuration adopts the previously established lamp environment, which requires many auxiliary kits to be installed, cacti collects data through net-snmp, stores templates, host information, and rra information through Mysql, and stores data through RRdtool.

This experiment is the second step of installing and configuring Nagios and Cacti. The Cacti installation and configuration adopts the previously established lamp environment, which requires many auxiliary kits to be installed, cacti collects data through net-snmp, stores templates, host information, and rra information through Mysql, and stores and draws data through RRdtool, cacti is a platform that interacts directly with administrators.

The kits to be installed are rrdtool, net-snmp, cacti-spine, and cacti.

First, the installation and setup steps

[Root @ localhost ~] # Ll rrdtool-1.4.5.tar.gz
-Rw-r -- 1 root 1348713 Oct 15 2011 rrdtool-1.4.5.tar.gz
[Root @ localhost ~] # Tar zxvf rrdtool-1.4.5.tar.gz

[Root @ localhost rrdtool-1.4.5] #./configure -- prefix =/usr/local/rrdtool
[Root @ localhost rrdtool-1.4.5] # make & make install

[Root @ localhost ~] # Ll net-snmp-5.6.1.1.tar.gz
-Rw-r -- 1 root 5937279 Oct 15 2011 net-snmp-5.6.1.1.tar.gz
[Root @ localhost ~] # Tar zxvf net-snmp-5.6.1.1.tar.gz

[Root @ localhost net-snmp-5.6.1.1] #./configure // write the following two items, the other uses the default system can be

System Contact InfoRmAtion (): cactiuser

System LoCatIon (Unknown): office_7f
[Root @ localhost net-snmp-5.6.1.1] # make & make install

[Root @ localhost ~] # Ll cacti-spine-0.8.7h.tar.gz // an accelerator for cacti
-Rw-r -- 1 root 623334 Oct 15 2011 cacti-spine-0.8.7h.tar.gz
[Root @ localhost ~] # Tar zxvf cacti-spine-0.8.7h.tar.gz

[Root @ localhost cacti-spine-0.8.7h] #./configure -- prefix =/usr/local/spine

[Root @ localhost cacti-spine-0.8.7h] # make & make install
[Root @ localhost cacti-spine-0.8.7h] #Cd/Usr/local/spine/etc/
[Root @ localhost etc] #CpSpine. conf. dist spine. conf
[Root @ localhost etc] # vi spine. conf
DB_Host localhost
DB_Database cacti
DB_User cactiuser
DB_Pass 721 wyzj // Change Password
DB_Port 3306
DB_PreG 0
[Root @ localhost ~] # Ll cacti-0.8.7h.tar.gz
-Rw-r -- 1 root 2249323 Oct 15 2011 cacti-0.8.7h.tar.gz

[Root @ localhost ~] # Tar zxvf cacti-0.8.7h.tar.gz

[Root @ localhost ~] #MvCacti-0.8.7h/var/www/cacti
Next, set the database and user.

[Root @ localhost ~] # UseraDdCactiuser
[Root @ localhost ~] # Vi/etc/Crontab// Add the following scheduled task

*/5 * cactiuser/usr/local/Php/Bin/php/var/www/cacti/poller. php>/dev/null 2> & 1
[Root @ localhost ~] # Mysql // Add the required cacti Database
Mysql> create database cacti;
Mysql> grant all privileges on cacti. *IdEntifiEdBy "721 wyzj ";
Mysql> flush privileges;
Mysql> \ q
Bye
[Root @ localhost cacti] # mysql-p cacti

[Root @ localhost cacti] # mysql-p cacti // The following data indicates that the import is successful.
Mysql> show tables;
+ --------------------------- +
| Tables_in_cacti |
+ --------------------------- +
| Cdef |
..................................

......................................

........................................ |
| User_log |
| Version |
+ --------------------------- +
48 rows inSet(0.01 sec)

[Root @ localhost cacti] # cd ..
[Root @ localhost www] #Chown-R root. root cacti/
[Root @ localhost cacti] # chown-R cactiuser log/rra // This is the place for cacti data interaction. cactiuer must have the write permission.
[Root @ localhost cacti] # cd INcLude/
[Root @ localhost include] # cp config. php config. php. bak
[Root @ localhost include] # vi config. php
$ Database_type = "mysql ";
$ Database_default = "cacti ";
$ Database_hostname = "localhost ";
$ Database_username = "cactiuser ";
$ Database_password = "721 wyzj"; // modified part
$ Database_port = "3306 ";
$ Database_ssl = faLsE;

Finally, in windows, enter the following content in the IE address bar to install cacti.

Http: // 192.168.1.192/cacti/install/indEx. Php

After the installation is successful, use the account, password admin: admin to log on and set the password.

 

To sum up, this is the second step for installing and configuring Nagios and Cacti. It mainly performs Cacti installation and configuration. However, you still need to add relevant plug-ins to manage the devices. Next, we will explore more!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.