Skip to content
This repository has been archived by the owner on Aug 29, 2018. It is now read-only.

Commit

Permalink
Fix bug 1173796
Browse files Browse the repository at this point in the history
  • Loading branch information
VojtechVitek committed Dec 16, 2014
1 parent 3b0b28e commit f308026
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 14 deletions.
13 changes: 0 additions & 13 deletions cartridges/openshift-origin-cartridge-php/bin/control
Original file line number Diff line number Diff line change
Expand Up @@ -36,20 +36,8 @@ function start() {
return $?
}

# Explicitely stop and start instead of reload/restart, until the
# https://bugzilla.redhat.com/show_bug.cgi?id=1173796 is fixed (segfault)
function bug_1173796() {
# PHP 5.4 + Zend OPCache enabled?
if [[ "$OPENSHIFT_PHP_VERSION" == "5.4" && -n "$(php_context 'php -m' | grep -i opcache)" ]]; then
stop
start
exit $?
fi
}

function reload() {
echo "Reloading PHP ${OPENSHIFT_PHP_VERSION} cartridge (Apache+mod_php)"
bug_1173796
pre_start_httpd_config
httpd_pid=`cat "$HTTPD_PID_FILE" 2> /dev/null`
kill -USR1 $httpd_pid && wait_for_pid_file $HTTPD_PID_FILE
Expand All @@ -58,7 +46,6 @@ function reload() {

function restart() {
echo "Restarting PHP ${OPENSHIFT_PHP_VERSION} cartridge (Apache+mod_php)"
bug_1173796
ensure_httpd_restart_succeed "$HTTPD_PID_FILE" "$HTTPD_CFG_FILE"
if [ -f "$HTTPD_PID_FILE" ]; then
pre_start_httpd_config
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ apc.enabled=1
apc.shm_size=<%= (ENV['OPENSHIFT_PHP_APC_SHM_SIZE'] =~ /^[0-9]+[MG]$/) ? ENV['OPENSHIFT_PHP_APC_SHM_SIZE'] : ((ENV['OPENSHIFT_GEAR_MEMORY_MB'].to_i/16).to_i.to_s+"M") %>

; The shared memory size reserved for strings, with M/G suffixe
apc.shm_strings_buffer=8M
; WARNING: only enable this buffer if you don't use Zend Opcache
;
; OpenShift disabled to fix https://bugzilla.redhat.com/show_bug.cgi?id=1173796. Don't turn this on.
apc.shm_strings_buffer=0

; A "hint" about the number of distinct source files that will be included or
; requested on your web server. Set to zero or omit if you are not sure;
Expand Down

0 comments on commit f308026

Please sign in to comment.