致命错误:耗尽了268435456字节的允许的内存大小(试图分配71个字节) [英] Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 71 bytes)

查看:2063
本文介绍了致命错误:耗尽了268435456字节的允许的内存大小(试图分配71个字节)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试在wordpress脚本中打开仪表板页面之一时出现错误

I'm getting an error when I try to open one of my dashboard pages in my wordpress script

错误消息如下:

严重错误:耗尽的268435456字节的允许内存大小(尝试 分配71个字节) /home/admin/domains/filesick.com/public_html/wp-includes/taxonomy.php 在第2685行

Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 71 bytes) in /home/admin/domains/filesick.com/public_html/wp-includes/taxonomy.php on line 2685

我四处询问,并被告知我必须将memory_limit增加到大于256M的值,因此我将其更改为512M,并且仍然是相同的问题.然后我将其更改为3024M,这就是我现在所拥有的,但这并不能解决问题.

I asked around and was told I have to increase the memory_limit to something higher than 256M, so I changed it to 512M and still the same problem. Then I changed it to 3024M and this is what I have now, but that didn't fix the problem.

那么您能告诉我如何解决此问题,我该怎么办?

So could you please tell me how to fix this and what should I do?

等待您的答复.

推荐答案

WordPress将PHP的内存限制改写为256M,并假设之前设置的内容将太低而无法呈现仪表板.您可以通过在wp-config.php中定义WP_MAX_MEMORY_LIMIT来覆盖它:

WordPress overrides PHP's memory limit to 256M, with the assumption that whatever it was set to before is going to be too low to render the dashboard. You can override this by defining WP_MAX_MEMORY_LIMIT in wp-config.php:

define( 'WP_MAX_MEMORY_LIMIT' , '512M' );

我同意DanFromGermany的观点,256M实际上是用于渲染仪表板页面的大量内存.更改内存限制实际上是在解决这个问题.

I agree with DanFromGermany, 256M is really a lot of memory for rendering a dashboard page. Changing the memory limit is really putting a bandage on the problem.

这篇关于致命错误:耗尽了268435456字节的允许的内存大小(试图分配71个字节)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆