[HOWTO] Install Cacti 0.8.7b on Fedora 9 using VMWare

If you figure out how to do something interesting/cool in Cacti and want to share it with the community, please post your experience here.

Moderators: Developers, Moderators

Post Reply
jrego
Posts: 44
Joined: Mon Jul 14, 2008 9:55 am

[HOWTO] Install Cacti 0.8.7b on Fedora 9 using VMWare

Post by jrego »

Install Cacti on Fedora 9 using VMWare

Install Fedora 9 with default install information.

Choose Web Server option to be sure all the webserver applications get installed

Run from terminal while logged in as root

yum update
yum -y install gcc gcc-c++ kernel kernel-devel net-snmp net-snmp-utils mysql mysql-server httpd php php-mysql php-snmp rrdtool tcl clamav libtool

Reboot the fedora box

Configure the new services to start automatically

Run the following from terminal

/sbin/chkconfig httpd on
/sbin/chkconfig --add mysqld
/sbin/chkconfig mysqld on
/sbin/service httpd start
/sbin/service mysqld start

Reboot

Install VMWare Tools

1. Download the latest vmware workstation for linux (currently 6.0.4-93057) from VMware Website to a folder that you create now called Cacti-Install located at /Cacti-Install.
2. Extract the tar that you download to the /Cacti-install directory.
3. Create a folder in /mnt called iso
4. Then look for the /Cacti-install/vmware-distrib/lib/isoimages/linux.iso file and mount it like below
5. Mount the extracted vmware-tools for linux as a loopback device.
mount -t iso9660 -o loop /Cacti-install/vmware-distrib/lib/isoimages/linux.iso /mnt/iso
6. Copy the VMwareTools-6.0.4-93057.i386.rpm file to /Cacti-install/Vmwaretools. you will need to create this folder.
7. Install the rpm from the extracted vmware-tools.
rpm -Uhv /Cacti-install/Wmwaretools/VMwareTools-6.0.4-93057.i386.rpm
8. Run vmware-config-tools.pl and take all the defaults.

Configure Database

mysqladmin -u root password 'putyourpasswordhere'
mysql -u root -p
DROP DATABASE test;
DELETE FROM mysql.user WHERE user = '';
FLUSH PRIVILEGES;
set password for root@localhost=password('putyourrootpasswordhere');
create database cactidb;
grant all on cactidb.* to root;
grant all on cactidb.* to root@localhost;
grant all on cactidb.* to cacti;
grant all on cactidb.* to cacti@localhost;
set password for cacti@localhost=password('putyouruserpasswordhere');
exit

Install Cacti

yum -y install cacti

yum should install to /usr/share/cacti

terminal to /Cacti-install directory and run wget http://www.cacti.net/downloads/cacti-0.8.6b.tar.gz

Extract cacti-0.8.7b

copy the cacti.sql file located in the cacti-0.8.7b folder you just extracted to /usr/share/cacti ****make sure the version you are downloading is the same version that yum is installing. check by running "yum list cacti"

terminal to the /usr/share/cacti directory and run the following

mysql --user=root --password=putyourrootpasswordhere cactidb < cacti.sql
exit

Grant the cacti user permissions to the rra and log directories

chown -R cacti /usr/share/cacti/rra/ /usr/share/cacti/log/

disable selinux using GUI
enable www and ssh on the firewall using GUI
reboot

Edit /usr/share/cacti/include/config.php and specify the database type, name, host, user and password for your Cacti

configuration.

$database_type = "mysql";
$database_default = "cactidb";
$database_hostname = "localhost";
$database_username = "cacti";
$database_password = "putyourcactiuserpasswordhere";


Add a line to your /etc/crontab file similar to:

*/5 * * * * cacti /usr/bin/php /usr/share/cacti/poller.php > /dev/null 2>&1

go to /etc/httpd/conf.d and change the cacti.conf file to look like this to allow everyone access to the website.

#
# Cacti: An rrd based graphing tool
#
Alias /cacti /usr/share/cacti

<Directory /usr/share/cacti/>
Order Allow,Deny
Allow from all
</Directory>

Reboot

Cross Fingers

Point your web browser to:

http://localhost/cacti/

Log in the with a username/password of admin. You will be required to change this password immediately. Make sure to fill in all of the path variables carefully and correctly on the following screen. Be sure you choose the correct version of net-snmp and rrdtool

you can check by running yum list rrdtool and yum list net-snmp.

You should now be done your install.
cchytang
Posts: 3
Joined: Mon Sep 15, 2008 10:39 am

Post by cchytang »

HI I install a Fedora 9 and use a build in 0.87b cacti, rrd tools 1.3 build in


After I add new device, it shows status unknow, but it can get information by snmp when it created, eg. version of the switch

i used snmp to dectect the device connection. and i cannot find anything in the poller cache. The rra directory does not have anything.

However, the localhost which created by cacti default is normal

i use tcpdump to c and find out that the switch and cacti has snmp communication.

what i have missed ?
Any body can help me ?

thx very much
BlueSting
Posts: 4
Joined: Sat Jul 04, 2009 1:44 am

Post by BlueSting »

Hi,

Did you ever manage?

I'm having the exact same problem you described above.

Will you please let me know?

Thanks.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest