【问题标题】:Mediawiki memory exhausing at 12MB while limit is at 2GBMediawiki 内存耗尽为 12MB,而限制为 2GB
【发布时间】:2014-01-14 03:09:39
【问题描述】:

我已多次尝试在我的网站上安装 MediaWiki。使用手动安装的最新版本(1.22.0)我没有取得任何成功。

它安装良好,安装过程中的所有内容都以“OK”报告。那时没有关于内存使用的错误,我在 PHP 中的内存限制已定义为 2048MB,确实应该足够了。

这里有一个问题:当我登录到我自己的 wiki 时,页面进入“无尽加载”模式,并且 php_error 日志显示如下:

[26-Dec-2013 04:20:31 CST6CDT] PHP Fatal error:  Out of memory (allocated 12320768) (tried to allocate 28834 bytes) in /home/velocit1/public_html/bartpelle.com/infowiki/includes/AutoLoader.php on line 1191
[26-Dec-2013 04:20:32 CST6CDT] PHP Fatal error:  Out of memory (allocated 12058624) (tried to allocate 116268 bytes) in /home/velocit1/public_html/bartpelle.com/infowiki/includes/AutoLoader.php on line 1191
[26-Dec-2013 04:20:42 CST6CDT] PHP Fatal error:  Out of memory (allocated 12320768) (tried to allocate 30720 bytes) in /home/velocit1/public_html/bartpelle.com/infowiki/includes/cache/CacheDependency.php on line 331

当我尝试登录时会发生这种情况当我尝试创建帐户时。在我清除 cookie 之前,此时每个页面都无法访问,因此会话丢失。

我尝试将内存限制设置为不同的高度,在软件中通过将 $wgMemoryLimit 设置为各种大小,以及在 PHP 配置内部。到目前为止没有任何帮助。

【问题讨论】:

  • phpinfo() 给你什么限制?
  • @Pekka 2048MB,如指定的那样。 :(
  • 不过,我不确定这是内存限制。难道你只是用完了实际内存? PHP out of memory error even though memory_limit not reached
  • 我使用的服务器是一个共享主机,内存约为 80GB。我可以在我的控制面板中看到所有用户的使用量远低于最大值。
  • 查看 accepted answer 到 Pekka 链接到的帖子:可能您的网络服务器配置了一些内存使用限制,或者 PHP 或您的整个网络服务器在 ulimit 下运行。

标签: php apache http mediawiki shared-hosting


【解决方案1】:

在不知道 Ilmari 的问题的情况下无法真正回答,但我的猜测是这与 changes to the job queue in 1.22 有关。

尝试在您的LocalSettings.php 中也增加$wgMaxShellMemory 并尝试增加get a job queue crontab running

【讨论】:

    猜你喜欢
    • 2014-06-28
    • 1970-01-01
    • 1970-01-01
    • 2013-07-06
    • 2018-12-07
    • 2013-02-08
    • 2019-07-10
    • 2011-10-01
    • 2015-08-23
    相关资源
    最近更新 更多