Cacti installation
[Email protected]~]# rpm-ivh http://www.aminglinux.com/bbs/data/attachment/forum/month_1211/epel-release-6-7.noarch.rpm
// installation Epel Extension Source
[[email protected] ~]# yum install-y httpd php php-mysql mysql mysql-server mysql-devel php-gd libjpeg libjpeg-devel li Bpng Libpng-devel
// installation httpd , PHP , MySQL
[email protected] ~]# Yum install-y cacti net-snmp net-snmp-utils rrdtool
// installation cacti Net-snmp RRDtool
[[email protected] ~]#/etc/init.d/mysqld start
[[email protected] ~]#/etc/init.d/httpd start
[[email protected] ~]#/ETC/INIT.D/SNMPD start
[Email protected] ~]# vim/etc/httpd/conf.d/cacti.conf
<Directory/usr/share/cacti/>
<ifmodule mod_authz_core.c>
# httpd 2.4
Require host localhost
</IfModule>
<ifmodule!mod_authz_core.c>
# httpd 2.2
Order Deny,allow
allow from all
Allow from localhost
</IfModule>
</Directory>
[Email protected] ~]#/etc/init.d/httpd restart
[Email protected] ~]# mysql-uroot-e "CREATE Database Cacti"
[[email protected] ~]# MYSQL-UROOT-E "Grant all on cacti.* to ' cacti ' @ ' 127.0.0.1 ' identified by ' cacti ';"
[Email protected] ~]# Mysql-uroot cacti </usr/share/doc/cacti-0.8.8b/cacti.sql
[Email protected] ~]# vim/usr/share/cacti/include/config.php
$database _type = "MySQL";
$database _default = "cacti";
$database _hostname = "127.0.0.1";
$database _username = "cacti";
$database _password = "cacti";
$database _port = "3306";
$database _ssl = false;
Web Access 192.168.137.21/cacti Enter Cacti the installed graphics page
650) this.width=650, "style=" Border-bottom: #ddd 1px solid;border-left: #ddd 1px solid;background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border-top: #ddd 1px solid;border-right: #ddd 1px solid;" Src= "/e/u261/ Themes/default/images/spacer.gif "width=" 244 "height=" "alt=" Spacer.gif "/>"
Next-----Next------finish
User Name:admin
Password:admin
// Enter user name password login
Password:admin
Confirm:admin
// Change Password
Log in Success
650) this.width=650, "style=" Border-bottom: #ddd 1px solid;border-left: #ddd 1px solid;background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border-top: #ddd 1px solid;border-right: #ddd 1px solid;" Src= "/e/u261/ Themes/default/images/spacer.gif "width=" 186 "height=" 227 "alt=" Spacer.gif "/>
[Email protected] ~]#/usr/bin/php/usr/share/cacti/poller.php
[Email protected] ~]# Vim/etc/php.ini
Date.timezone =' asia/chongqing '
[Email protected] ~]# CRONTAB-E
*/5 * * * */usr/bin/php/usr/share/cacti/poller.php
wait 5 minutes or more, after the task is scheduled to execute, there are monitoring information parameters that are generated as picture information.
650) this.width=650, "style=" Border-bottom: #ddd 1px solid;border-left: #ddd 1px solid;background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border-top: #ddd 1px solid;border-right: #ddd 1px solid;" Src= "/e/u261/ Themes/default/images/spacer.gif "width=" 284 "height=" 205 "alt=" Spacer.gif "/>
The above monitoring for the native
now Cacti increase client Monitoring, install the client (add a Linux server)
Open a client computer
[email protected] ~]# Yum install-y net-snmp
[Email protected] ~]# vim/etc/snmp/snmpd.conf
Syslocation 137.21 // can write machine IP
syscontact Root [email protected] // Administrator's mailbox
[[Email protected] ~]# service SNMPD start
Increase the client's monitoring on the Web page
650) this.width=650, "style=" Border-bottom: #ddd 1px solid;border-left: #ddd 1px solid;background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border-top: #ddd 1px solid;border-right: #ddd 1px solid;" Src= "/e/u261/ Themes/default/images/spacer.gif "width=" "height=" "alt=" Spacer.gif "/>"
Console-------Device-------Add----
Description can write machine IP ( or Custom )
Hostname can write machine IP
Host Template selected ucd/net SNMP Host
SNMP Version selected Version 2
----Create------Create Graphs for this Host---------
Graph Types:snmp-interface Statistics
Select Network card -----Create
650) this.width=650, "style=" Border-bottom: #ddd 1px solid;border-left: #ddd 1px solid;background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border-top: #ddd 1px solid;border-right: #ddd 1px solid;" Src= "/e/u261/ Themes/default/images/spacer.gif "width=" 553 "height=" 134 "alt=" Spacer.gif "/>
Graph types:graph Template Based
Create:ucd/net-cpu Usage
Create:ucd/net-load Average
Create:ucd/net-memory Usage
Three Select all, monitor CPU , Load , Memory
Create
650) this.width=650, "style=" Border-bottom: #ddd 1px solid;border-left: #ddd 1px solid;background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border-top: #ddd 1px solid;border-right: #ddd 1px solid;" Src= "/e/u261/ Themes/default/images/spacer.gif "width=" 553 "height=" 131 "alt=" Spacer.gif "/>
The monitoring of this device is added Tree
Graph Trees-------Default Tree---------Add------
650) this.width=650, "style=" Border-bottom: #ddd 1px solid;border-left: #ddd 1px solid;background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border-top: #ddd 1px solid;border-right: #ddd 1px solid;" Src= "/e/u261/ Themes/default/images/spacer.gif "width=" 289 "height=" 255 "alt=" Spacer.gif "/>
Host----- Select the device you just added ---Create
650) this.width=650, "style=" Border-bottom: #ddd 1px solid;border-left: #ddd 1px solid;background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border-top: #ddd 1px solid;border-right: #ddd 1px solid;" Src= "/e/u261/ Themes/default/images/spacer.gif "width=" 554 "height=" 176 "alt=" Spacer.gif "/>
Graphs---------Default Tree----192.168.137.21
650) this.width=650, "style=" Border-bottom: #ddd 1px solid;border-left: #ddd 1px solid;background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border-top: #ddd 1px solid;border-right: #ddd 1px solid;" Src= "/e/u261/ Themes/default/images/spacer.gif "width=" 352 "height=" 201 "alt=" Spacer.gif "/>
View monitoring data generation
This article is from the Linux Learning Notes blog, so be sure to keep this source http://9656134.blog.51cto.com/9646134/1678497
Linux monitoring and Security OPS--CACTI installation deployment