Running an application using php 5.4 on AWS using Amazon Linux.
The PHP version is PHP 5.4.28. memcache lib installed from the AWS repository - php54-pecl-memcache-3.0.8-1.11.amzn1.x86_64
I checked that php uses /etc/php.ini:
[ root@ip-xx.xx.xx.xx ]
The parameter shows that I should use memcache:
[ root@ip-10-40-17-119 etc]# grep "^session.save" php.ini session.save_handler="memcache" session.save_path="tcp://<elasticache-endpoint>:11211" [ root@ip-10-40-17-119 php.d]# php -i | grep session.save session.save_handler => memcache => memcache session.save_path => tcp://<elasicache-endpoint>:11211?persistent=1&weight=1&timeout=1&retry_interval=15 => tcp://<elasticache-endpoint>:11211?persistent=1&weight=1&timeout=1&retry_interval=15
I can install telnet from the box to the endpoint and port and connect correctly so that the instance can connect to the memcached server.
What we tried:
- I deleted tcp: // from the php.ini file, and it didnβt matter - the sessions are still stored in the files.
- We changed from session.save_handler = "memcache" to session.save_handler = "memcached"
- every time we make changes, we stop the httpd server and then start it again
- we even tried to restart the servers
No matter what we tried, the sessions are stored on disk in / var / lib / php / sessions. Is there something I'm missing, or is this a known issue of 5.4 or AWS?
php memcached session centos libmemcache
chris
source share