[Bug 1407990] [NEW] libapache2-mod-php5 random segmentation faults in zend_stack_push() and zend_hash_find()

Leszek leszek.eljasz at gmail.com
Tue Jan 6 14:41:11 UTC 2015


Public bug reported:

Hello,

I observe random segfaults in PHP running as Apache module. I see
Segfaults in Apache error log, I have collected multiple core dumps
which indicate that the crashes happen in zend_stack_push()  or
zend_hash_find(). It seems that the crash happens at scripts compile
time since in all the cases, I see the compile_file() function at some
level of the backtrace.

It is a low traffic website, 30-40 page hits /minute, VM hosted by Digital Ocean. Initially the problem was on Ubuntu 14.04 then in order to exclude hardware errors I spawned another VM that is hosted also in DO but in another region and currently I'm running it on Ubuntu 14.10, segfaults still happen:
# lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 14.10
Release:	14.10
Codename:	utopic

Modules loaded by Apache:
# apachectl -M
Loaded Modules:
 core_module (static)
 so_module (static)
 watchdog_module (static)
 http_module (static)
 log_config_module (static)
 logio_module (static)
 version_module (static)
 unixd_module (static)
 access_compat_module (shared)
 alias_module (shared)
 auth_basic_module (shared)
 authn_core_module (shared)
 authn_file_module (shared)
 authz_core_module (shared)
 authz_host_module (shared)
 authz_user_module (shared)
 deflate_module (shared)
 dir_module (shared)
 env_module (shared)
 expires_module (shared)
 filter_module (shared)
 headers_module (shared)
 mime_module (shared)
 mpm_prefork_module (shared)
 negotiation_module (shared)
 php5_module (shared)
 rewrite_module (shared)
 setenvif_module (shared)
 status_module (shared)

Modules loaded by PHP:
# ls -1 /etc/php5/apache2/conf.d/
10-pdo.ini
20-curl.ini
20-gd.ini
20-json.ini
20-mysqli.ini
20-mysql.ini
20-newrelic.ini
20-pdo_mysql.ini
20-readline.ini

Software versions:
libapache2-mod-php5 5.5.12+dfsg-2ubuntu4.1
newrelic-php5 4.17.0.79
newrelic-php5-common 4.17.0.79
php5-cli 5.5.12+dfsg-2ubuntu4.1
php5-common 5.5.12+dfsg-2ubuntu4.1
php5-curl 5.5.12+dfsg-2ubuntu4.1
php5-dbg 5.5.12+dfsg-2ubuntu4.1
php5-dev 5.5.12+dfsg-2ubuntu4.1
php5-gd 5.5.12+dfsg-2ubuntu4.1
php5-json 1.3.6-1
php5-mysql 5.5.12+dfsg-2ubuntu4.1
php5-readline 5.5.12+dfsg-2ubuntu4.1

Attachments:
- php.ini
- phpinfo.html - saved phpinfo()
- index.php: the php script that is being compiled when the segfaults happen seems to be always the same and it is main wordpress index.php file
- bt-zen_stack_push.txt - backtrace of segfault from zend_stack_push()
- bt-zen_hash_find.txt - backtrace of seggault from zend_hash_find()

Let me know if I can provide any more useful info, please.

Cheers,
Leszek

** Affects: php5 (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: fault php segmentation

** Attachment added: "info.zip"
   https://bugs.launchpad.net/bugs/1407990/+attachment/4292937/+files/info.zip

** Description changed:

  Hello,
  
  I observe random segfaults in PHP running as Apache module. I see
  Segfaults in Apache error log, I have collected multiple core dumps
  which indicate that the crashes happen in zend_stack_push()  or
  zend_hash_find(). It seems that the crash happens at scripts compile
  time since in all the cases, I see the compile_file() function at some
  level of the backtrace.
  
  It is a low traffic website, 30-40 page hits /minute, VM hosted by Digital Ocean. Initially the problem was on Ubuntu 14.04 then in order to exclude hardware errors I spawned another VM that is hosted also in DO but in another region and currently I'm running it on Ubuntu 14.10, segfaults still happen:
  # lsb_release -a
  No LSB modules are available.
  Distributor ID:	Ubuntu
  Description:	Ubuntu 14.10
  Release:	14.10
  Codename:	utopic
  
- 
  Modules loaded by Apache:
  # apachectl -M
  Loaded Modules:
-  core_module (static)
-  so_module (static)
-  watchdog_module (static)
-  http_module (static)
-  log_config_module (static)
-  logio_module (static)
-  version_module (static)
-  unixd_module (static)
-  access_compat_module (shared)
-  alias_module (shared)
-  auth_basic_module (shared)
-  authn_core_module (shared)
-  authn_file_module (shared)
-  authz_core_module (shared)
-  authz_host_module (shared)
-  authz_user_module (shared)
-  deflate_module (shared)
-  dir_module (shared)
-  env_module (shared)
-  expires_module (shared)
-  filter_module (shared)
-  headers_module (shared)
-  mime_module (shared)
-  mpm_prefork_module (shared)
-  negotiation_module (shared)
-  php5_module (shared)
-  rewrite_module (shared)
-  setenvif_module (shared)
-  status_module (shared)
- 
+  core_module (static)
+  so_module (static)
+  watchdog_module (static)
+  http_module (static)
+  log_config_module (static)
+  logio_module (static)
+  version_module (static)
+  unixd_module (static)
+  access_compat_module (shared)
+  alias_module (shared)
+  auth_basic_module (shared)
+  authn_core_module (shared)
+  authn_file_module (shared)
+  authz_core_module (shared)
+  authz_host_module (shared)
+  authz_user_module (shared)
+  deflate_module (shared)
+  dir_module (shared)
+  env_module (shared)
+  expires_module (shared)
+  filter_module (shared)
+  headers_module (shared)
+  mime_module (shared)
+  mpm_prefork_module (shared)
+  negotiation_module (shared)
+  php5_module (shared)
+  rewrite_module (shared)
+  setenvif_module (shared)
+  status_module (shared)
  
  Modules loaded by PHP:
  # ls -1 /etc/php5/apache2/conf.d/
  10-pdo.ini
  20-curl.ini
  20-gd.ini
  20-json.ini
  20-mysqli.ini
  20-mysql.ini
  20-newrelic.ini
  20-pdo_mysql.ini
  20-readline.ini
- 
  
  Software versions:
  libapache2-mod-php5 5.5.12+dfsg-2ubuntu4.1
  newrelic-php5 4.17.0.79
  newrelic-php5-common 4.17.0.79
  php5-cli 5.5.12+dfsg-2ubuntu4.1
  php5-common 5.5.12+dfsg-2ubuntu4.1
  php5-curl 5.5.12+dfsg-2ubuntu4.1
  php5-dbg 5.5.12+dfsg-2ubuntu4.1
  php5-dev 5.5.12+dfsg-2ubuntu4.1
  php5-gd 5.5.12+dfsg-2ubuntu4.1
  php5-json 1.3.6-1
  php5-mysql 5.5.12+dfsg-2ubuntu4.1
  php5-readline 5.5.12+dfsg-2ubuntu4.1
  
- 
  Attachments:
  - php.ini
  - phpinfo.html - saved phpinfo()
  - index.php: the php script that is being compiled when the segfaults happen seems to be always the same and it is main wordpress index.php file
  - bt-zen_stack_push.txt - backtrace of segfault from zend_stack_push()
  - bt-zen_hash_find.txt - backtrace of seggault from zend_hash_find()
  
- 
- Let me know if I can provide any more usefull info, please.
+ Let me know if I can provide any more useful info, please.
  
  Cheers,
  Leszek

-- 
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to php5 in Ubuntu.
https://bugs.launchpad.net/bugs/1407990

Title:
  libapache2-mod-php5 random segmentation faults in zend_stack_push()
  and  zend_hash_find()

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/php5/+bug/1407990/+subscriptions



More information about the Ubuntu-server-bugs mailing list