Cacti (home)ForumsDocumentation

Install PHP

  1. Download the latest version of PHP 7.0 from
  2. Extract the ZIP file to C:\PHP\
  3. Add C:\PHP\ to your Windows PATH environment variable.
    • The Windows path variable can be accessed via the Control Panel at: System | Advanced | Environment Variables
    • In the System Variables groupbox, find Path and click Edit and add: C:\PHP\
  4. Add a new system variable called PHPRC. Its value should be: C:\PHP\
  5. Add a new system variable called MIBDIRS. Its value should be: C:\PHP\Extras\mibs
  6. Rename C:\PHP\php.ini-production to C:\PHP\php.ini
  7. Find and then uncomment/modify the following lines in C:\PHP\php.ini.
    doc_root = C:\inetpub\wwwroot\
    expose_php = Off
    extension_dir = C:\PHP\ext
    upload_tmp_dir = C:\PHP\Uploadtemp
    session.save_path = C:\PHP\Session
    error_log = C:\php\php_errors.txt
    date.timezone = "America/Los_Angeles"  //(set your correct zone from
  8. If using IIS, find, uncomment or add the following lines in C:\PHP\php.ini
    fastcgi.impersonate = 1
    cgi.fix_pathinfo = 1
    cgi.force_redirect = 0
  1. If you have had previous versions of PHP installed, you had likely moved the PHP system files to in the Windows directory structure. If so, you will have to remove those files. Please review your PHP installation documentation for instructions on removing those files.
  2. Verify PHP is functional by running the following at the command prompt:
    php -m

If messages with, Cannot find module are appearing, then there is something wrong with the MIBDIRS variable or missing mib file(s) in the PHP\Extras\mib folder.

Configure Permissions

  1. Change NTFS permissions on C:\PHP\Uploadtemp and C:\PHP\Session to grant Modify rights to the IUSR_ and IIS_WPG users for only files in the directory.
  2. Give the user who will be running the scheduled task, Modify rights to: c:\php\extras\mibs\.index

Personal Tools