Cacti (home)ForumsDocumentation

Install Cacti

  1. Download the current version from
  2. Extract the ZIP file to the root of your web server directory:
    1. IIS: C:\Inetpub\wwwroot\cacti\
    2. Apache: C:\Apache2\htdocs\cacti\


  1. There are two methods of applying patches:
    1. Visit<cacti version>/pre-patched/ and manually download and replace the patched files.
    2. If you have Cygwin installed, then the patch instructions which use wget and patch, will work.
  2. You might need to reapply file/folder security on the files patched. Double check they are correct.


Throughout this section, cacti_web_root is referenced. It's intended to be substituted with the real Cacti web server path of your environment. Typically this is:

  1. Edit \cacti_web_root\cacti\include\config.php and specify the database type, name, host, user, password, and url_path for your Cacti configuration.
    $database_type = "mysql";
    $database_default = "cacti";
    $database_hostname = "localhost";
    $database_username = "cactiuser";
    $database_password = "cacti";
       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/";
  1. From within Cacti, go to Settings → Paths and verify the paths to point to the correct locations. Recommended examples are posted below.

If you plan on using Spine, then it is very important that all paths include forward slashes instead of backslashes.

Path Setting
PHP Binary Path: c:/php/php.exe
RRDTool Binary Path: c:/rrdtool/rrdtool.exe
SNMPGET Path: c:/net-snmp/bin/snmpget.exe
SNMPWALK Path: c:/net-snmp/bin/snmpwalk.exe
SNMPBULKWALK Path: c:/net-snmp/bin/snmpbulkwalk.exe
SNMPGETNEXT Path: c:/net-snmp/bin/snmpgetnext.exe
Cacti Logfile Path: c:/cacti_web_root/log/cacti.log
Spine Path: c:/spine/Spine.exe
  1. Click on Devices. Delete the Localhost device as it intended for a Linux environment.
  2. In the upper right corner, click Add. Fill in the following information and then click Add.
    Description: My Windows localhost
    Hostname: localhost
    Host Template: Windows 2000/XP
  3. You should now be looking at the localhost device screen. Right under it's name, there should be some SNMP information listed, if not you should double check the SNMP settings on the server and firewall settings.
  4. In the upper right-hand corner, click on Create Graphs for this Host.
  5. On the following screen, select a disk partition and network interface.
  6. At the bottom of the page, click on Create.
  7. Log into the user account you'll be using for the scheduled task and verify starting a Cacti polling cycle works. Do this by running the following from the command prompt:
    C:\>php c:/cacti_web_root/poller.php

    The output should look something like the following:

    C:\>php c:/cacti_web_root/cmd.php
    11/04/2012 10:01:57 PM - CMDPHP: Poller[0] Time: 1.1106 s, Theads: N/A, Hosts: 1

    After this has ran once, you should have “cacti.log” in ”/cacti/log/” and rrd files in /cacti/rra/.

Configure Task

You are going to need to schedule a task while logged on as an Administrator. This task is required to you can run “poller.php” every 5 minutes. Make sure the Task Scheduler service is started and follow the steps below to begin.

Windows XP/2003
  1. In Control Panels, open Scheduled Tasks.
  2. Double click on Add Scheduled Task.
  3. Click Next and Browse on the following screen. Find “C:\php\” and select “php.exe”. Choose Daily on and click Next.
  4. Click Next again without changing the time or date settings.
  5. When entering a username and password make sure the user has read and write access to the following directories:

    Make sure the user has read, write, and execute access to the following directories:

  6. Click Next and Finish to close the wizard.
  7. Right click on the task you just created, and select Properties.
  8. Select the Schedule Tab.
  9. Make sure Daily is selected and click the Advanced button.
  10. Check the Repeat checkbox, set it for 5 minutes and set the duration for 24 hours.
  11. Click OK
  12. In the Run textbox enter the following text making sure to use the appropriate paths.

    The start in box should say



Windows 2008+
  1. Open Task Scheduler
  2. Create a new Task
  3. General Tab
    1. Name: Cacti Poller
    2. Security Options:
      1. Specify the user/service account the task will run under.
      2. Select Run whether user is logged on or not
  4. Triggers Tab
    1. Create a new trigger.
    2. Select Daily
    3. Reoccur every: 1 days
    4. Repeat Task every: 5 minutes for a duration of Indefinitely
    5. Select Enabled
    6. Click OK
  5. Actions Tab
    1. Create a new action.
    2. Program: C:\PHP\php.exe
    3. Argument: C:\cacti_web_root\poller.php
    4. Start In: C:\cacti_web_root\
  6. Conditions & Settings Tabs
    1. Configure per your IT standards.
  7. Click OK to create the Task.

Personal Tools