Bon.....
Voici mon fichier cacti.conf:
#
# Cacti: An rrd based graphing tool
#
# Change the following ACLs to open up Cacti to other network devices.
# For example:
# On httpd 2.4, change "Require host localhost" to "Require all granted".
# On httpd 2.2, change "Allow from localhost" to "Allow from all".
#allow from all
#allow from 127.0.0.1
#Allow from all
Alias /cacti /usr/share/cacti
<Directory /usr/share/cacti/>
<IfModule mod_authz_core.c>
# httpd 2.4
Require host localhost
</IfModule>
<IfModule !mod_authz_core.c>
# httpd 2.2
Order deny,allow
Deny from all
Allow from localhost
</IfModule>
</Directory>
<Directory /usr/share/cacti/install>
# mod_security overrides.
# Uncomment these if you use mod_security.
# allow POST of application/x-www-form-urlencoded during install
#SecRuleRemoveById 960010
# permit the specification of the rrdtool paths during install
#SecRuleRemoveById 900011
</Directory>
# These sections marked "Require all denied" (or "Deny from all")
# should not be modified.
# These are in place in order to harden Cacti.
<Directory /usr/share/cacti/log>
<IfModule mod_authz_core.c>
Require all denied
</IfModule>
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
</Directory>
<Directory /usr/share/cacti/rra>
<IfModule mod_authz_core.c>
Require all denied
</IfModule>
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
</Directory>
Mon fichier /etc/cacti/db.php:
/* make sure these values refect your actual database/host/user/password */
$database_type = "mysql";
$database_default = "cacti";
$database_hostname = "localhost";
$database_username = "cactiuser";
$database_password = "cactiuser";
$database_port = "3306";
$database_ssl = false;
/*
Edit this to point to the default URL of your Cacti install
ex: if your cacti install as at http://serverip/cacti/ this
would be set to /cacti/
*/
//$url_path = "/cacti/";
/* Default session name - Session name must contain alpha characters */
//$cacti_session_name = "Cacti";
et enfin :
# mysql -u root –p
(mot de passe vide par défaut)
Création d’un mot de passe mysql : (mysqlpwd)
mysql> set password for root@localhost=password('mysqlpwd');
mysql> exit
(après reconnection dans mysql):
Creation de la bd :
Mysql> Create database cacti ;
Mysql> grant all on cacti.* to root;
Mysql> grant all on cacti.* to root@localhost;
Mysql> grant all on cacti.* to cactiuser;
Mysql> grant all on cacti.* to cactiuser@localhost;
Mysql> set password for cactiuser@localhost=password('cactiuserpwd');
Mysql> exit