“Unable to allocate memory for pool” in PHP?

Even after increasing your php memory, if you are still getting “unable to allocate memory for pill in PHP” error, then should be related to APC.

For the people having this problem, please specify you .ini settings. Specifically your apc.mmap_file_mask setting.

For file-backed mmap, it should be set to something like:


To mmap directly from /dev/zero, use:


For POSIX-compliant shared-memory-backed mmap, use: