开发者

Fatal error: Allowed memory size, but it shouldn't be

I'm porting an installation of Joomla, and I'm getting this error:

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 116 bytes) in

in \wwwroot\libraries\joomla\error\exception.php on line 117

I've tried upping the limit, but that doesn't help (well, it wouldn't, it's only trying to allocated 116 byte开发者_如何学Gos)

Any ideas?


I've usually encountered errors like this when doing image manipulation with GD. As Yogesh suggests adding a line to up the memory limit has solved it for me. For example:

ini_set('memory_limit', '128M');


This issue can also arise if you have memcache enabled and you don't have the memcache client installed.

If this is the case, just pecl install memcache (make sure the extension is then enabled accordingly in your php.ini) and restart apache and you should be good to go.


It looks like there was some problem with the joomla core files - as taking a fresh copy and overriding the index.php with a fresh copy, all is good now. Weird!


Fatal error: Allowed memory size of 67108864 bytes exhausted (tried to allocate 40 bytes) in /home/site/public_html/libraries/joomla/error/exception.php on line 117

What I did (thanks to a couple of fragmented suggestions is change the line on 117 to the following

$this->backtrace = debug_print_backtrace();


Check Your memory_limit parameter in your php.ini.

It is exceeding that limit.

Change it to your requirement and then try.

Hope this helps.


Another possibility that I've run in to is that one of your MySQL tables could be crashed. As odd as it sounds, that sometimes manifests itself this way.

Simply run mysqlcheck -rA to check and repair all of your mysql tables.


To solve that I went to the backend and checked the debug for the site.

I saved the configuraztion and the site now works.


It's a very old question, but I had the same problem right now and I want to share the solution (other answer didn't help me).

If you are porting your joomla instalation you need to check all packages related with PHP in source and destination hosts.

If you are using debian based linux you need to type in both of them:

dpkg -l | grep "^ii  php5\?-"

And test that there is the same packages installed. If not, you can type this on source host:

echo $(dpkg -l | grep "^ii  php5\?\-" | cut -d " " -f 3)

Copy the result and paste it on destination host (if you are using an SSH client, for example):

apt-get install php-mail-mime ... (lot of packages) ... php5-curl

Or you can try this:

apt-get install $(ssh source_host dpkg -l | grep "^ii  php5\?\-" | cut -d " " -f 3)

Check that source_machine is correct (and use root@source_host or another_user@source_host if needed).

Restart apache2 server (it's not necessary, but it's for safe):

service apache2 restart

And check again.

If you are using windows check enabled extensions after and before migration (upload a "info.php" file to test them) and change php.ini according. Later restart apache2 service as administrator using services.msc or command line:

net apache2 stop
net apache2 start

I noticed the mistake when installing again from start and failed requirements checking.

Hope this will be useful to people with same problem.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜