Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 338471 - dev-lang/php-5.3.3-r1 and dev-php5/pecl-apc-3.1.4 lead to "Unable to allocate memory for pool"
Summary: dev-lang/php-5.3.3-r1 and dev-php5/pecl-apc-3.1.4 lead to "Unable to allocate...
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal
Assignee: PHP Bugs
URL: http://pecl.php.net/bugs/bug.php?id=1...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-09-23 18:14 UTC by Frank
Modified: 2010-11-10 07:03 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Frank 2010-09-23 18:14:16 UTC
When dev-lang/php-5.3.3-r1 and dev-php5/pecl-apc-3.1.4[-mmap] are installed and apc.mmap_file_mask is not explicitely set in the .ini-file, output of php scripts include "Unable to allocate memory for pool" warning message.

Reproducible: Always

Steps to Reproduce:
1. USE="-mmap" emerge -av "=dev-lang/php-5.3.3-r1" "=dev-php5/pecl-apc-3.1.4"
2. check, that /etc/php/apache2-php5/ext-active/apc.ini includes the line ";apc.mmap_file_mask="/tmp/apcphp5.XXXXXX" (commented out!)
3. run an php-skript with lots of "include_once" (e.g. drupal - update.php)

Actual Results:  
Output includes "warning: require_once(): Unable to allocate memory for pool. in <FILENAME> on line <LINE NUMBER WITH require_once()"

Expected Results:  
no warning.

should not exluding "mmap" from being build into APC prevent any mmap-related errors from happening? What else is the USE flag for?
Comment 1 Matti Bickel (RETIRED) gentoo-dev 2010-10-17 20:42:09 UTC
Seems to be known (and fixed?) upstream as per URL.

The USE flag essentially passes --disable-apc-mmap to configure if you turn it off. So yes, mmap should not be used here. The mmap_file_mask setting is irrelevant if you do this.

Can you be more specific about the environment? Like, are you hitting actual RAM limits, do you have selinux enabled (and see something in it's logs)?
Comment 2 Frank 2010-10-20 06:28:32 UTC
Just to give a quick feedback (I hope, I can provide more later on...): I am not hitting physical RAM limits. SELinux is not activated on my machine. It seems like I am seeing the same problem as hanwoody from upstream.
Comment 3 Ole Markus With (RETIRED) gentoo-dev 2010-11-10 05:43:17 UTC
Can you please try to upgrade to 3.1.5 and see if you hit the same issues?
Comment 4 Frank 2010-11-10 07:03:08 UTC
At first sight the error seems to be gone on dev-php5/pecl-apc-3.1.5-r2 with dev-lang/php-5.3.3-r3. But since I was not able to create an always failing test case for the initial problem, this might have been pure luck. 

On the other hand there has been some changes upstream concerning the same error message, so I would not mind the ticket being closed...