Install Cacti RHEL/CentOS/Oracle/Alma/Rocky

Install Cacti RHEL/CentOS/Oracle/Alma/Rocky

Install Cacti CentOS 6

Root shell prompt on host cactidev, a CentOS minimal install

Cacti is an Open Source Monitoring/Graphing Solution for Small to Enterprise Class networks.  Cacti Allows you to Monitor Ping Response, Internet Usage, Internal Bandwidth, CPU, memory usage, etc. Very handy tool. Here’s the process to get it installed.

login to your Hosted Zwiegnet VM, and su to root

In our Case we have a CentOS Minimal install, we went ahead and installed updates with yum -y update, as well as install wget.

Root prompt on cactidev after yum -y update and installing wget

from here we need to install our dependencies:

yum -y install httpd httpd-devel mysql mysql-server

and a few more dependencies for php

yum install php-mysql php-pear php-common php-gd php-devel php php-mbstring php-cli

and now our SNMP dependencies:

yum -y install net-snmp-utils net-snmp-libs php-pear-Net-SMTP php-snmp rrdtool

done, now we have to set our services to start at startup, as well as start them now

chkconfig httpd on, chkconfig mysqld on, then service httpd start and service mysqld start

now we need to enable the EPEL Repo

wget of epel-release-6-8.noarch.rpm from download.fedoraproject.org for EPEL 6 x86_64

from here install the repo

rpm -ivh epel-release-6-8.noarch.rpm installing the EPEL repo

now we need to actually install cacti

yum -y install cacti

now set your MySQL password

mysqladmin -u root password to set the MySQL root password

login to MySQL

mysql -u root -p prompting for the root password

now Setup your Database

create database Cacti_2014, GRANT ALL to cacti@localhost, FLUSH privileges, quit

import cacti template database

rpm -ql cacti | grep cacti.sql, then mysql import of /usr/share/doc/cacti-0.8.8b/cacti.sql into Cacti_2014

configure cacti mysql settings

vi /etc/cacti/db.php to edit the Cacti database settings

set up database Username/Password, etc

db.php settings: database_type mysql, database_default Cacti_2014, hostname localhost, username cacti, port 3306

edit apache to allow outside connections

vi /etc/httpd/conf.d/cacti.conf to open up web access

add your network (cusomize for your environment)

cacti.conf Directory /usr/share/cacti block with Allow from 172.30.10.0/24 added

restart apache

service httpd restart: Stopping and Starting httpd OK

setup cron

Cacti poller cron line: */5 * * * * cacti /usr/bin/php /usr/share/cacti/poller.php

un-comment the first line

Same cron line in /etc/cron.d/cacti after removing the # comment

now enter the IP of your server, or hostname/cacti, you should have a nice greeting

Cacti Installation Guide welcome page at 192.168.1.138/cacti/install/

click next

Cacti Installation Guide: New Install, database user cacti on localhost, database Cacti_2014

next

Cacti installer wizard on RHEL/CentOS, clicking Next to continue

and finish!

Cacti User Login page with User Name and Password fields

login with the default cacti username=admin, pw=admin

Forced Password Change page asking for a new cacti password

you will be forced to change your password

Cacti console after login with Create devices, Create graphs and View links

That’s it!

Hosted Linux Servers at www.zwiegnet.com/go

Related guides: Configure Cacti OpenLDAP authentication | Migrate Cacti to New Server CentOS 6

Leave a Reply

Your email address will not be published. Required fields are marked *