The Cacti Manual
Prev | Chapter 2. Installing Under Unix | Next

# Configure PHP

Please ensure, that PHP support is either builtin or installed for the following PHP extension modules:

- mysql (For configuration, see note below)

- SNMP (For configuration, see note below)

- XML

- Session

- Sockets

- LDAP (Required only when using LDAP authentication)

- GD (Required only for some Plugins)

You may run the following command to get the list of all available PHP modules

    php -m

Please verify, that the modules are installed and configured correctly. There are several ways to do so, please consult PHP configuration instructions for a complete description.

We will continue using the most recommended way of configuring php extension modules. Please find the file `/etc/php.ini` and make the following changes to it:

    extension_dir = /etc/php.d

This will enable PHP to find more configuration directives in that very directory. Other distros point to `/usr/lib/php/modules` instead. In each case, you should locate e.g. `mysql.so` in that directory.

Activate the MySQL extension via /etc/php.d/mysql.ini

    ; Enable mysql extension module
    extension=mysql.so

Activate the SNMP extension via /etc/php.d/snmp.ini

    ; Enable snmp extension module
    extension=snmp.so

If you want to allow template importing, uncomment the following line:

    file_uploads = On

Prev | Home | Next
Ports for FreeBSD | Up | Configure the Webserver (Apache)