1.1 Cacti Installation

Source: Internet
Author: User
Tags snmp

Configuring the service side

Description: Cacti requires Apache and PHP support, where we use the Yum installed lamp environment.

(1) Installation Epel

[email protected] ~]# Yum install-y epel-release

(2) Installing lamp

[[email protected] ~]# yum install-y httpd php php-mysql mysql mysql-server mysql-devel php-gd libjpeg libjpeg-devel LIBP Ng-devel

(3) Installation cacti

[email protected] ~]# Yum install-y cacti net-snmp net-snmp-utils rrdtool

(4) Start-up service

[[Email protected] ~]# /etc/init.d/mysqld startplease report any problems  with the /usr/bin/mysqlbug script!                                                              [OK] is starting  mysqld:                                             [OK][[email protected] ~]# /etc/init.d/httpd start is starting  httpd:httpd: could not reliably determine the server ' s fully  Qualified domain name, using ::1 for servername                                                              [OK][[email protected]  ~]# /etc/init.d/snmpd start is starting  snmpd:                                             [OK]


(5) Edit httpd.conf

[Email protected] ~]# vim/etc/httpd/conf.d/cacti.conf

Change "Deny from all" to "Allow from all"

Restart Service

[Email protected] ~]#/etc/init.d/httpd restart

(6) Import data create cacti Library

[Email protected] ~]# mysql-uroot-e "CREATE Database Cacti"

Create cacti User

[[email protected] ~]# MYSQL-UROOT-E "Grant all on cacti.* to ' cacti ' @ ' 127.0.0.1 ' identified by ' cacti ';"

Import SQL file

[Email protected] ~]# Mysql-uroot cacti </usr/share/doc/cacti-0.8.8h/cacti.sql

(7) Editing the cacti configuration file

[Email protected] ~]# vim/usr/share/cacti/include/config.php

Change:

$database _type = "MySQL"; $database _default = "cacti"; $database _hostname = "127.0.0.1"; $database _username = "cacti"; $ Database_password = "cacti"; $database _port = "3306"; $database _ssl = false;

(8) Web Access cacti and installation

http://ip/cacti/

If not accessible, check the iptables and SELinux configuration

650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M02/83/AF/wKioL1d6TS-Dig6iAACDdGO_T7U880.png "style=" float: none; "title=" 1.1-1.png "alt=" Wkiol1d6ts-dig6iaacddgo_t7u880.png "/>

Click "Next" and "Finish" at two:

650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M02/83/B0/wKiom1d6TTCi2wD5AAA8y44hdxo479.png "style=" float: none; "title=" 1.1-2.png "alt=" Wkiom1d6ttci2wd5aaa8y44hdxo479.png "/>


650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M00/83/AF/wKioL1d6TTDTdQECAADxFe7go_k745.png "style=" float: none; "title=" 1.1-3.png "alt=" Wkiol1d6ttdtdqecaadxfe7go_k745.png "/>


The following interface appears:

650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M01/83/AF/wKioL1d6TTGxSFUNAACG7c7-tIM199.png "style=" float: none; "title=" 1.1-4.png "alt=" Wkiol1d6ttgxsfunaacg7c7-tim199.png "/>

Enter Admin Admin login, reset new password

650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M00/83/B0/wKiom1d6TTLw8CX4AACKwX9dCdI766.png "style=" float: none; "title=" 1.1-5.png "alt=" Wkiom1d6ttlw8cx4aackwx9dcdi766.png "/>

Enter the following interface:

650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M01/83/B0/wKiom1d6TTPyHIRoAAEeuwEn6jk633.png "style=" float: none; "title=" 1.1-6.png "alt=" Wkiom1d6ttpyhiroaaeeuwen6jk633.png "/>

(9) Perform poller.php, generate graphs, join scheduled Tasks

[Email protected] ~]#/usr/bin/php/usr/share/cacti/poller.php

Add Cron Task

[Email protected] ~]# CRONTAB-E*/5 * * * */usr/bin/php/usr/share/cacti/poller.php

At this point, the browser interface click Graphs, Default Tree, Host:localhost, refresh, you can see the figure, and so on, the data came out

650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M02/83/AF/wKioL1d6TTSj4uvvAAELKHBsLso894.png "style=" float: none; "title=" 1.1-7.png "alt=" Wkiol1d6ttsj4uvvaaelkhbslso894.png "/>

So, just monitoring the local machine situation, we strongly need to monitor other client machines, so the following configuration Client

(10) Installing SNMP

[email protected] ~]# Yum install-y net-snmp

(11) Modify snmpd.conf

[Email protected] ~]# vim/etc/snmp/snmpd.conf

Syslocation and Syscontact to modify, wherein Syslocation can write a machine IP, syscontact writing the administrator mailbox.

Syslocation 56.128syscontact Root [email protected]

Remove the comment character

Access Notconfiggroup "" Any noauth exact roview Rwview Noneview all included. 1 80

(12) Start SNMP

[[email protected] ~]#/etc/init.d/snmpd start is starting snmpd: [OK]


This article is from the "Learn Notes for students" blog, please make sure to keep this source http://sanyisheng.blog.51cto.com/11154168/1795718

1.1 Cacti Installation

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.