Hi all! Finally I'm able to give something back to the community http://forums.cacti.net/images/smilies/icon_smile.gif
Before I begin though, I must admit that I cannot take all of the credit for this "How To". I've only added small bits and pieces to a great "How To" I found on the internet, but can no longer find the original source unfortunately.
Please Note: I am not a Linux nor a Cacti expert, so if there are any unnecessary steps/installations, please let me know so that I can edit this How To accordingly. For example, I don't know if all of the packages listed below are required... I've basically put them together from several guides based on several different versions of Cacti and RRDTool.
Also Note: This is on a clean install which is why packages like gcc and nano are in the package install list.
Anyway, here goes http://forums.cacti.net/images/smilies/icon_smile.gif
***************************************************
Step One:
***************************************************
Install packages for Cacti & RRDTool:
Code:
yum install -y mysql mysql-server httpd mod_ssl php php-snmp php-mysql net-snmp net-snmp-utils nano cairo-devel libxml2-devel pango-devel pango libpng-devel freetype freetype-devel libart_lgpl-devel gcc
yum update ***************************************************
Step Two:
***************************************************
Download Cacti & move it to your web server directory:
Code:
cd /tmp
wget http://www.cacti.net/downloads/cacti-0.8.8.tar.gz
tar zxvf cacti-0.8.8.tar.gz
mv /tmp/cacti-0.8.8 /var/www/html/cacti ***************************************************
Step Three:
***************************************************
Reconfigure include/config.php path. Change it from / to /cacti/.
Note: Be sure to uncomment this line too by removing the //, as per the before and after example below.
***************************************************
Step Four:
***************************************************
Add a new user and then change the ownership and permissions of the rra and log directories.
Code:
cd /tmp
wget http://oss.oetiker.ch/rrdtool/pub/rrdtool.tar.gz
tar zxvf rrdtool.tar.gz
cd rrdtool-1.4.7
./configure
make prefix=/usr/local/ all
make prefix=/usr/local/ install ***************************************************
Step Five:
***************************************************
Start MySQL, Sendmail, snmpd and Apache, and make sure they start on boot:
Code:
chkconfig httpd on --levels 235
chkconfig mysqld on --levels 235
chkconfig sendmail on --levels 235
chkconfig snmpd on --levels 235
service mysqld start
service httpd start
service sendmail start
service snmpd start ***************************************************
Step Six:
***************************************************
Configuring MySQL
Code:
/usr/bin/mysql_secure_installation
Then, you will be asked a few questions. Provide the following responses:
Code:
current root password is <LEAVE BLANK>
set root password to: <ENTER PASSWORD>
remove anonymous users <YES>
disallow remote root login <YES>
remove test database <YES>
reload privilege tables <YES> ***************************************************
Step Seven:
***************************************************
Create the Cacti Database:
Code:
mysqladmin -u root -p create cacti
mysql -p cacti < /var/www/html/cacti/cacti.sql
mysql -u root -p mysql
GRANT ALL ON cacti.* TO cactiuser@localhost IDENTIFIED BY 'cactiuser';
flush privileges;
exit ***************************************************
Step Eight:
***************************************************
Set up Cacti via the web interface:
Code:
http://<ip_address>/cacti
***************************************************
Step Nine:
***************************************************
Add a cron job to make the Cacti poll every 5 minutes. Note: The username used here must be the same as the one created in Step 4.
Code:
nano /etc/crontab
*/5 * * * * cactiuser php /var/www/html/cacti/poller.php > /dev/null 2>&1 ***************************************************
Step Ten:
***************************************************
If your "Localhost" is staying in the "Unknown" state and is not transitioning to the "Up" state, turn on SNMPv1 in its "Device Configuration" and change its "Downed Device Detection" to "SNMP Uptime". ***************************************************
Step Eleven:
***************************************************
Due to a bug in 8.8 (which will be resolved in 8.8a), users cannot import templates (see cacti 0.8.8 templates issue for more information). To resolve this issue, download global_arrays.php from the SVN here and put it in your <cacti_dir>/include/ directory. ***************************************************
All Done!
***************************************************
And now your done! http://forums.cacti.net/images/smilies/icon_smile.gif
As mentioned above, if there are any unnecessary packages or if you have any suggestions, please let me know and I'll be happy to make the corrections.
Last edited by Voiper99 on Sun Apr 15, 2012 6:26 pm, edited 2 times in total.