PHP - Plesk - Cron - Allowed memory size exhausted?

Posted by John on Stack Overflow See other posts from Stack Overflow or by John
Published on 2010-04-13T06:41:07Z Indexed on 2010/04/13 6:42 UTC
Read the original article Hit count: 287

Filed under:
|
|
|
|
ini_set('max_execution_time',0);
ini_set('memory_limit','1000M');

These are the first two lines at the very top of my script.

I was under the impression if I ran something via cron memory limits didn't apply, but I was wrong. Safe mode is off and when I test to see if these values are being set they are but I keep getting the good ol' "PHP Fatal: Memory exhausted" error.

Any ideas what I may be doing wrong? And whats the "more elegant way" of writing "infinite" for the "memory limit" value is it -1 or something?

© Stack Overflow or respective owner

Related posts about php

Related posts about cron