================安装mediawiki错误及解决方法=====================


错误提示一:

PHP Fatal error:  require_once(): Failed opening required

'/var/www/html/mwiki/LocalisationUpdate/LocalisationUpdate.php'

(include_path='.:/usr/share/pear:/usr/share/php') in /var/www/html/mwiki/LocalSettings.php

//文件路径错误

解决方法:

修改LocalSettings.php,

找到

"require_once( "$EXT/LocalisationUpdate/LocalisationUpdate.php" );"

修改为:

"require_once( "$IP/extensions/LocalisationUpdate/LocalisationUpdate.php" );"


错误提示二:

页面提示:

"Fatal exception of type MWException Error",apache日志没有信息提示。


解决方法:

修改LocalSettings.php,

在合适的位置添加:

$wgShowExceptionDetails = true;


错误提示三:

CACHE_ACCEL requested but no suitable object cache is present. You may want to install APC.

Backtrace:

0 [internal function]: ObjectCache::newAccelerator(Array)

1 /home/liquidfr/public_html/lf_wiki/includes/objectcache/ObjectCache.php(62): call_user_func('ObjectCache::ne...', Array)

2 /home/liquidfr/public_html/lf_wiki/includes/objectcache/ObjectCache.php(50): ObjectCache::newFromParams(Array)

3 /home/liquidfr/public_html/lf_wiki/includes/objectcache/ObjectCache.php(23): ObjectCache::newFromId(3)

4 /home/liquidfr/public_html/lf_wiki/includes/GlobalFunctions.php(3600): ObjectCache::getInstance(3)

5 /home/liquidfr/public_html/lf_wiki/includes/Setup.php(402): wfGetMainCache()

6 /home/liquidfr/public_html/lf_wiki/includes/WebStart.php(157): require_once('/home/liquidfr/...')

7 /home/liquidfr/public_html/lf_wiki/index.php(53): require('/home/liquidfr/...')

8 {main}


解决方法:

修改LocalSettings.php,

"#$wgMainCacheType = CACHE_ACCEL;"

替换为:

"$wgMainCacheType = CACHE_ANYTHING;"