# 128 MB php memory limit per script?

## gEry

hello

i made a etc-update, which set the memory_limit to 128MB per script (in php.ini). Isn't that enough!? Earlier, it was always 8 MB and imho, this is enough. Consider a server with for e.g. 5 buggy scripts... what a power server do you need then...

That's not a mistyped configuration? :S

----------

## jexxie

I would argue that the default configuration should work for just about everything / anything.

If you're wanting secured or more ... optimized configs, you're going to want to tweak the config manually yourself anyways.

----------

## hoffie

 *gEry wrote:*   

> 
> 
> i made a etc-update, which set the memory_limit to 128MB per script (in php.ini). Isn't that enough!? Earlier, it was always 8 MB and imho, this is enough. Consider a server with for e.g. 5 buggy scripts... what a power server do you need then...
> 
> That's not a mistyped configuration? :S

 

No. In earlier PHP versions it was possible to enable/disable memory limit using ./configure (or on the "Gentoo" level: a USE flag); only if you had it enabled the default limit of 8MB was actually enforced. This changed with recent PHP versions: Upstream decided to remove the configure switch (and as such we don't have a USE flag for that anymore either) and always enable memory_limit, but use a pretty high default limit to not break any scripts.

We are using the php.ini file which is provided by upstream with some minor changes -- this change was not done by us and we still think it's OK to leave it as it is. :)

----------

