[packages/php/PHP_5_2] use /var/run for fpm pid files
glen
glen at pld-linux.org
Mon Jan 21 11:30:06 CET 2013
commit cb14616a3214387c568d08c2bb8db289fbe18e97
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Thu Jan 17 16:37:44 2013 +0200
use /var/run for fpm pid files
currently /var/run/php is cleaned up by php session cleanup script
which cleans up everything in that dir, not only php session files
so as consequence this removes php-fpm pidfiles and service restart
remains confused what to stop.
php-wsdl cache files get nuked by the same problem, so those could be
moved to /var/cache/php, so they could survive reboots
probably it's wrong to have /var/run/php as php-session storage (note
the generic namem it's not /var/run/php/sessions etc), but changing that
would need more efforts, as need to support old and new configuration,
and each php sapi could have different config (they have different
php.ini (or equivalent) files)
php-fpm.init | 4 ++--
php-fpm.logrotate | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/php-fpm.init b/php-fpm.init
index 3006f7e..6cc104a 100644
--- a/php-fpm.init
+++ b/php-fpm.init
@@ -8,7 +8,7 @@
#
# processname: @processname@
# config: /etc/php/fpm.conf
-# pidfile: /var/run/php/@processname at .pid
+# pidfile: /var/run/@processname at .pid
#
# Source function library
@@ -20,7 +20,7 @@
configfile=/etc/php/fpm.conf
lockfile=/var/lock/subsys/@processname@
pidfile=$(sed -ne 's,.*"\?pid_file"\?>\([^<]\+\)<.*,\1,p' $configfile)
-pidfile=${pidfile:-/var/run/php/@processname at .pid}
+pidfile=${pidfile:-/var/run/@processname at .pid}
start() {
# Check if the service is already running?
diff --git a/php-fpm.logrotate b/php-fpm.logrotate
index 3bec7c1..b192547 100644
--- a/php-fpm.logrotate
+++ b/php-fpm.logrotate
@@ -1,5 +1,5 @@
-/var/log/fpm.log
-/var/log/fpm-slow.log
+/var/log/php/@processname at .log
+/var/log/php/@processname at -slow.log
{
notifempty
missingok
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/php.git/commitdiff/cb14616a3214387c568d08c2bb8db289fbe18e97
More information about the pld-cvs-commit
mailing list