0

The exact error message is this:

12)Cannot allocate memory: couldn't create child process: /usr/sbin/suphp for <php script file>

This is not a VPS, it's a generic Gentoo server. There is 1G of RAM for the server and 700M of RAM free at any given time, including when running this rather tiny script that only creates 1 connection to a MySQL DB. There's a cron job that runs this script every 30 seconds and suPHP runs out of memory almost every single time.

Can anybody please help?

user183037
  • 101
  • 1
  • Recompiling apache/php is not an option as uptime for other scripts is critical. Thanks! – user183037 Jun 06 '11 at 19:55
  • Nobody........? :( – user183037 Jun 07 '11 at 02:31
  • Can you check the dmesg and see if there are OOM (Out of Memory Killer) messages saying that the kernel killed the process. As you cite that there's memory available and you do not see the OOM Killer in dmesg, then the memory restriction you are encountering is a memory limit within the LAMP stack. – Citizen Kepler Sep 26 '18 at 18:48

1 Answers1

1

Use something like <?php print system('ulimit -a'); ?> to check system limits. Check apache configuration for RLimitMEM directive.

AlexD
  • 8,747
  • 2
  • 29
  • 38