Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Cacti monitoring system

2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Cacti is a performance and flow detection tool developed in PHP language. It is a management suite of Web interface. It uses Net-SNMP (protocol tool) to collect monitoring data and combine RRDtool data engine to record data and draw pictures. Server: 192.168.200.10 Software Environment: lnmp/lnmp Architecture net-snmp netsnmp-utils RRDtool-1.4.8.tar.gz cacti-0.8.8b.tar.gz client (controlled side-snmpd): 192.168.200.20 Software Environment: net-snmp lm_sensors1. Server configuration (master control side) requires installation of Apache,MySQL,php network platform in advance, and supporting software such as Net-SNMP,RRDtool 1.1 to build database and Web platform (lnmp or lamp) Next, use yum source package yum-y install httpd yum-y install mysql mysql-server mysql-devel yum-y install php php-mysql to start: service httpd start service mysqld start Note: writable php test page verification cat / var/www/html/test.php 1.2 install net-snmp-utils package yum-y install net-snmp net-snmp-utils service snmpd start 1.3 install rrdtool package tar zxf rrdtool -1.4.8.tar.gz cd rrdtool-1.4.8. / configure-- prefix=/usr/local/rrdtool-1.4.8 & & make & & make install 1.4 install cacti (1) extract cacti And move the extracted files to the root directory of the web page tar zxf cacti-0.8.8b.tar.gz mv cacti-0.8.8b / var/www/html/cacti (2) add users, and adjust the owner of the directory useradd cacti chown-R cacti.cacti / var/www/html/cacti (3) create a database to save the database mysql > create database cacti (4) Import sql statements in cacti into cd / var/www/html/cacti mysql cacti in the database

< cacti.sql (5)创建cacti访问数据的用户,并授权 mysql>

Grant all on cacti.* to 'cacti'@'localhost' identified by' cacti'; (6) login verifies whether the user can log in normally to mysql-u cacti-p-h localhost / / password: cacti (7) configure the cacti connection data file cd / var/www/html/cacti/include/ vim config.php $database_type = "mysql"; / / Database type $database_default = "cacti" / / the database name we just created for cacti $database_hostname = "localhost"; / / the database server address $database_username = "cacti"; / / the user accessing the cacti database $database_password = "cacti"; / / password $database_port = "3306"; / / server port $database_ssl = false Enable $url_path = "/ cacti/" (8) during the installation process, you will be asked to fill in the paths of several commands, of which the four commands snmpwalk snmpget snmpbulkwalk snmpgetnext need to install net-snmp-5.5-49.el6.x86_64 net-snmp-utils-5.5-49.el6.x86_64 net-snmp-libs-5.5-49.el6.x86_64 yum-y install net-snmp-* 1.5 to initialize cacti. Visit cacti vim / etc/httpd/conf/httpd.conf 402 DirectoryIndex index.html index.php service httpd reload to access the cacti installation interface http://192.168.200.10/cacti

Press "Next > >" next, and select the correct path for the package.

The default user, the password is admin, and then the password will be changed to 2. Vim / etc/php.ini find [Date] field add date.timezone = Asia/Shanghai 2.2 configuration and start snmp vim / etc/snmp/snmpd.conf 41 com2sec notConfigUser 192.168.200.10 public / / change line 41 defaults to IP address 85 view all included. 180 of the monitor / enable line 85 62 access notConfigGroup "" any noauth exact all none none change systemview to all 2.3 to start snmp service snmpd start netstat-antp | grep snmpdtcp 0 0127.0.0.1 systemview 199 0.0.0.0 * LISTEN 50473/snmpd3. Use Web Control 3.1 of cacti to add controlled terminal (1) add controlled device or host Click "Devices" under Management to manage controlled host or device, click "Add" in the upper right corner to add IP, and click "create"

(2) set detection items to add system process detection (the last one, Add)

Add disk Partition Detection

Generate detection image (1) create image (Create-- > New Graphs-- > select the image entry-- > click "create" below)

(2) add images to the monitoring tree

Add the newly created image objects to "Graph Trees" to make it easy for users to classify and view them.

Click "Management"-- > "Graph Trees"-- > click "Default Tree"-- > click "Add"-- > Host (host) / Graph (image) / Header (header)-- > "Create"-- > "Save"

3.4 regular collection of testing data (collected through the poller.php page)

3.5 View monitoring results

Graphs-- > Default Tree to view

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report