Install Cacti on openSUSE 13.2

Cacti is an open source web-based network monitoring tool designed as the front end application for the RRDtool (Round-Robin database tool), it allows a user to poll the services at an interval of time and resulting in the graph format. Cacti is generally used to get a graph data for the cpu and network bandwidth utilization, it monitors the network traffic by polling a router or switch via snmp.

Here is the small tutorial about installing Cacti on openSUSE 13.2

Install Cacti:

Install MySQL or MariaDB and other tools.

zypper install apache2 php5 php5-mysql php5-snmp  mysql-community-server mysql-community-server-client net-snmp rrdtool

Install Cacti and PHP extension.

zypper install cacti cacti-spine php5-xmlrpc php5-sockets php5-ldap php5-gd apache2-mod_php5

Start the following services.

systemctl start apache2.service
systemctl start snmpd.service
systemctl start mysql.service


Create a database for Cacti, if you are configuring the MySQL for the first time; take a look at how to secure the MySQL.

mysql -u root -p

Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 12
Server version: 5.6.17 openSUSE package

Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.


Create Cacti database.

create database cacti;

Grant permission to the newly created database.

GRANT ALL ON cacti.* TO cactiuser@localhost IDENTIFIED BY 'cactipassword';
flush privileges;

Configure Cacti:

Import the default database to the cacti database.

mysql cacti < /srv/www/cacti/cacti.sql -u root -p

Edit the config file to specify the database type, name, hostname, user and password information.

vi /srv/www/cacti/include/config.php

Make the changes accordingly.

/* make sure these values reflect your actual database/host/user/password */
$database_type = "mysql";
$database_default = "cacti";
$database_hostname = "localhost";
$database_username = "cactiuser";
$database_password = "cactipassword";
$database_port = "3306";
$database_ssl = false;

Change the permission of directory.

chown -R wwwrun:www /srv/www/cacti

Add the following entry in the crontab to poll every five min.

*/5 * * * * cacti php /srv/www/cacti/poller.php > /dev/null 2>&1

If you want Cacti to the default server, edit the file /etc/sysconfig/apache2

# vi /etc/sysconfig/

Add CACTI as a server flag.


Edit apache configuration file to perform the remote installation. In apache 2.4, authorization is handled by mod_authz.

vi /etc/apache2/conf.d/cacti.conf

Remove first directory stanza,

<Directory /srv/www/cacti/>
         Options None
         order deny,allow
         deny from all
         allow from localhost

Place the following stanza.

<Directory /srv/www/cacti/>
<IfModule mod_authz_core.c>
# httpd 2.4
Require all granted
<IfModule !mod_authz_core.c>
# httpd 2.2
Order deny,allow
Allow from all

Restart the services.

systemctl restart apache2.service
systemctl restart snmpd.service
systemctl restart mysql.service

Enable services to start at system start-up.

systemctl enable apache2.service
systemctl enable snmpd.service
systemctl enable mysql.service

Install Cacti:

Visit the following url to start the installation of cacti. http://your-ip-address/cacti. Click on Next to continue.

openSUSE 13.2 – Cacti Installation Main Page

Scroll down for the options, please select New Install for the new installation and then click Next.

openSUSE 13.2 – Cacti Installation Type

It will show you, if there is any package is missing which is mandatory for the cacti.

openSUSE 13.2 – Cacti Installation Package List

Enter User Name and Password (Default admin / admin).

openSUSE 13.2 – Cacti Installation User Login

You must change the default password.

openSUSE 13.2 – Cacti Installation Change Password

The following shows the dashboard of the cacti.

openSUSE 13.2 – Cacti Console

Now you can start configuring the Cacti to monitor your devices. More documentation can be found here. We welcome your comments, please post your valuable comments below.

cactimonitoring-toolsopensuse 13.1opensuse 13.2
Comments (2)
Add Comment
  • Kurniawan Aja

    hi itzgeek
    nice tutorial, can you solve my problem when open into browser localhost/cacti .file index.php
    asked to download ?
    tks alot

    • Raj

      It could be due to PHP version, make sure you hace installed php5. And do not forget to restart the web services