Forum Moderators: coopster

Message Too Old, No Replies

How to install Alternative PHP Cache

         

artie2004

12:05 am on Oct 24, 2007 (gmt 0)

10+ Year Member



Hi. I am trying to install APC using the following instructions below. Can somebody please tell me how to do step 1(copy the proper php_apc.dll (depending on your version) into your php extensions directory)? Thanks.

Installing

APC Cache is not included with the latest release of php (although it is planned on being included with version 6). It says on the main PHP website that the .dlls can be downloaded from the pecl extensions package, but after downloading and extracting it, I realized that it is not there. I have found the correct .dlls and other files that are needed and they can be download from my server here.

After downloading and extracting the above zip file, complete the following steps:

1) copy the proper php_apc.dll (depending on your version) into your php extensions directory

2) add the following to your php.ini: extension=php_apc.dll (this should be placed under the other extension lines)

3) add the following to your php.ini:

apc.shm_segments=1
apc.optimization=0
apc.shm_size=128
apc.ttl=7200
apc.user_ttl=7200
apc.num_files_hint=1024
apc.mmap_file_mask=/tmp/apc.#*$!#*$!
apc.enable_cli=1

Note: APC needs a temp path to exist, and be writable by the web server. It checks TMP, TEMP, USERPROFILE environment variables in that order and finally tries the WINDOWS directory if none of those are set.

4) copy apc.php (included with the .zip file) to directory on your web server and launch it.

coopster

1:32 pm on Oct 24, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



Sine APC isn't bundled with PHP, you need to download and get the executables into the PHP path and setup the extension so PHP can use it.

The PHP extensions directory for a Windows install is typically "ext" and can be found in your php installation folder (path). The following links should be helpful:

Manual Installation Steps [php.net]
How do I add my PHP directory to the PATH on Windows? [php.net]