Reputation: 3913
I am trying to change the max_memory parameter so I went into my php.ini and set max_memory = 500M
For some reason, when I use phpinfo(), that setting still displays 128M
(the default setting). I read that some hosts restrict max_memory
. Is there a way to change this value manually, or override this option in a config file, or do I have to recompile php?
Upvotes: 1
Views: 1184
Reputation: 4082
a few other things to check:
the report from phpinfo states that it is using the php.ini file that you're editing, not some more "specific" .ini file somewhere else
you haven't overridden the memory_limit variable through an apache .htaccess file or using ini_set in a PHP script somewhere
if you're in a shared environment, as Itay suggests, you may not have more than 128M available to your account, and you probably don't have access to reset apache either.
if that's the case, try making the value smaller to see if the changes you're making take effect. If they are, and you can't increase it above 128M, time to upgrade your hosting account.. otherwise, try making the change through .htaccess or ini_set in your script because those methods don't require an apache restart.
if you still can't get it to work, contact the host and ask them to make you a local copy of the global php.ini file for your account.
Upvotes: 1
Reputation: 53603
If you can recompile PHP, then you, obviously, have full control of the web server.
I would guess, as written in the comments, you:
Upvotes: 2