summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPhil Davis <phil.davis@inf.org>2015-01-10 21:38:50 +0545
committerRenato Botelho <garga@FreeBSD.org>2015-01-12 11:49:58 -0200
commit3fbfbe902e3bbc31a250bf23b3d012f7ae3e40e0 (patch)
treed2889f2d6fead6e8c20170a0119d528641826e95
parent2ea976b71c3660bb549042b1a81fa3204e1add19 (diff)
downloadpfsense-3fbfbe902e3bbc31a250bf23b3d012f7ae3e40e0.zip
pfsense-3fbfbe902e3bbc31a250bf23b3d012f7ae3e40e0.tar.gz
Restart PHP-FPM allow to setup ini file
I was just using console menu option 16 Restart PHP-FPM and it hung on a nanoBSD system. I found /tmp/php_errors.txt with this in it: "override rw-r--r-- root/wheel for /usr/local/etc/php.ini?" Flying blind at the console I entered "y", then /tmp/php_errors.txt had this: -------- rm: /usr/local/etc/php.ini: Read-only file system override rw-r--r-- root/wheel for /usr/local/lib/php.ini? -------- Pressed return at the console and it proceeded, presumably without re-writing php.ini It works much better when the file system is mounted RW :)
-rwxr-xr-xetc/rc.php-fpm_restart2
1 files changed, 2 insertions, 0 deletions
diff --git a/etc/rc.php-fpm_restart b/etc/rc.php-fpm_restart
index 25b4d40..41c8df2 100755
--- a/etc/rc.php-fpm_restart
+++ b/etc/rc.php-fpm_restart
@@ -6,7 +6,9 @@ sleep 2
# Run the php.ini setup file and populate
# /usr/local/etc/php.ini and /usr/local/lib/php.ini
+/etc/rc.conf_mount_rw
/etc/rc.php_ini_setup 2>/tmp/php_errors.txt
+/etc/rc.conf_mount_rw
echo ">>> Restarting php-fpm" | /usr/bin/logger -p daemon.info -i -t rc.php-fpm_restart
echo ">>> Starting php-fpm"
/usr/local/sbin/php-fpm -c /usr/local/lib/php.ini -y /usr/local/lib/php-fpm.conf -RD 2>&1 >/dev/null
OpenPOWER on IntegriCloud