My goal is to implement APC for the opcode cache for the drupal 6 production site. I have so far tested APC with several php files with and without including other php files with include_once.
Also tried setting apc.ini values ββfor shm_size, apc.include_once_override and apc.stat. Each time apache reboots.
The result in apc.php does not show any changes in any values. (except, of course, the modified apc.ini values ββare shown as they should)
Each time I refresh the apc.php test page, the start time is reset as the current time, showing uptime of 0 minutes.
apc.php -testpage shows:
General Cache InformationAPC Version 3.1.9 PHP Version 5.2.10 APC Host xxxx.xx.xx Server Software Apache/2.2.3 (CentOS) Shared Memory 1 Segment(s) with 128.0 MBytes (mmap memory, pthread mutex Locks locking) Start Time 2011/07/26 11:53:56 Uptime 0 minutes File Upload Support 1 Cached Files 0 ( 0.0 Bytes) Hits 1 Misses 1 Request Rate (hits, misses) 2.00 cache requests/second Hit Rate 1.00 cache requests/second Miss Rate 1.00 cache requests/second Insert Rate 0.00 cache requests/second Cache full count 0 Cached Variables 0 ( 0.0 Bytes) Hits 0 Misses 0 Request Rate (hits, misses) 0.00 cache requests/second Hit Rate 0.00 cache requests/second Miss Rate 0.00 cache requests/second Insert Rate 0.00 cache requests/second Cache full count 0 apc.cache_by_default 1 apc.canonicalize 1 apc.coredump_unmap 0 apc.enable_cli 0 apc.enabled 1 apc.file_md5 0 apc.file_update_protection 2 apc.filters apc.gc_ttl 3600 apc.include_once_override 0 apc.lazy_classes 0 apc.lazy_functions 0 apc.max_file_size 16 apc.mmap_file_mask /tmp/apcphp5.095eRm apc.num_files_hint 1024 apc.preload_path apc.report_autofilter 0 apc.rfc1867 0 apc.rfc1867_freq 0 apc.rfc1867_name APC_UPLOAD_PROGRESS apc.rfc1867_prefix upload_ apc.rfc1867_ttl 3600 apc.serializer default apc.shm_segments 1 apc.shm_size 128M apc.slam_defense 0 apc.stat 0 apc.stat_ctime 0 apc.ttl 7200 apc.use_request_time 1 apc.user_entries_hint 4096 apc.user_ttl 7200 apc.write_lock 1 Host Status Diagrams: Free: 128.0 MBytes (100.0%) Hits: 1 (50.0%) Used: 20.3 KBytes (0.0%) Misses: 1 (50.0%) Detailed Memory Usage and Fragmentation: Fragmentation: 0%
phpinfo shows:
Server API CGI/FastCGI APC: Version 3.1.9 APC Debugging Enabled MMAP Support Enabled MMAP File Mask /tmp/apcphp5.JkKDk7 Locking type pthread mutex Locks Serialization Support php Revision $Revision: 308812 $ Build Date Jul 21 2011 14:31:12
I followed these steps to determine if suexec settings would affect caching: http://www.litespeedtech.com/support/forum/showthread.php?t=4189
[ root@host /]# ps -ef|grep lsphp root 20402 17833 0 11:21 pts/0 00:00:00 grep lsphp [ root@host /]
.. indicates that lsphp is not working on the host
I also read the following article and comments, concluding that in my case the problem is not suexec, since the apache user is the owner of the httpd process http://www.brandonturner.net/blog/2009/07/fastcgi_with_php_opcode_cache/
also the suexec command is not recognized when registering and running as root @host
I am also pretty sure that there is no cPanel on the host to check if the reset parameter of the running cache process will be on a certain interval
This leaves me with a few tips on where to go next. I tried to install (with chown and chgrp) apache as the owner of the apc.php file and some test php files, which resulted in a 500 server error.
Is there a way to check if file permissions are allowed? I am extremely grateful for any suggestions or help.