Topic on Project:Support desk

Page loading time, very very slow

5
Pszemia (talkcontribs)

Hi, i have a problem with my site, i have already turned on APC, and followed all the items in this page http://www.mediawiki.org/wiki/User:Ilmari_Karonen/Performance_tuning

I tried to do a site profiling, but really there is no a good guide i can follow, i dont know how or where to find the debug info. The profiling manual is very confusing for me.

The problem in my site is a very very slow access, all the pages the same problem, around 1 or 2 minutes to load. This happened from one day to another. I have the following variables in my localsettings to improve speed, but no result.

$wgCompressRevisions = true;

$wgDebugLogFile = "$IP/midebug.log";

$wgUseFileCache = true; /* default: false */
$wgFileCacheDirectory = "$IP/cache";
$wgShowIPinHeader = false;
$wgShowExceptionDetails = true;
$wgParserCacheExpireTime = 2592000;
$wgParserCacheType = CACHE_DB;
$wgResourceLoaderMaxage = array('server' => 30 * 24 * 60 * 60, 'client' => 30 * 24 * 60 * 60);
$wgEnableSidebarCache = true;

I also have a debug, but don´t know how to read it, and it doesnt have time stamps.

Thanks!

Ariel

88.130.82.79 (talkcontribs)

Hi Ariel,

if this problem occurred without any changes being done to the wiki itself, then I would guess that it might not be caused by the wiki, but by something else. If your server is run by a host, you might want to contact him and ask, if he changed something.

From inside MediaWiki, you should get some profiling data. This will write information about page requests to the file named in $wgDebugLogFile. This information should contain a table with the time spent in each function. If you are using MediaWiki 1.24 or before, this old version of the profiling page contains the information needed to set up profiling.

Pszemia (talkcontribs)

I think i got it trhough profiling and got this output in profileinfo.php:

Name	Time (%)	Memory (%)	Count	Calls/req	ms/call	kb/call	ms/req	kb/req
-total
100%	100%	2	1	19126.35	10312.6	19126.35	10312.6
MediaWiki::main
34.29%	23.85%	1	0.5	13116.2	4919.77	6558.1	2459.88
Setup.php [–]
29.67%	49%	2	1	5674.05	5052.93	5674.05	5052.93
Setup.php-globals
18.53%	35.29%	2	1	3544.3	3639.79	3544.3	3639.79
Setup.php-memcached
3.6%	1.68%	2	1	687.76	173.62	687.76	173.62
Setup.php-includes
1.9%	5.04%	2	1	364.03	520.21	364.03	520.21
Setup.php-extensions
1.9%	4.63%	2	1	363.44	477.19	363.44	477.19
Setup.php-extensions-efMobileFrontend_Setup
1.9%	4.6%	2	1	363.16	474.52	363.16	474.52
Setup.php-misc1
0.97%	0.77%	2	1	185.1	79.53	185.1	79.53
Setup.php-exception
0.89%	0.45%	2	1	171.13	46.04	171.13	46.04
Setup.php-defaults
0.05%	0.14%	2	1	9.63	14.52	9.63	14.52
Setup.php-defaults2
0%	0.03%	2	1	0.38	3.17	0.38	3.17
Setup.php-session
0%	0.02%	2	1	0.16	1.64	0.16	1.64
Setup.php-tempDir
0%	0.01%	2	1	0.08	0.54	0.08	0.54
WebStart.php-conf
11.85%	5.54%	1	0.5	4532.07	1143.21	2266.03	571.61
MessageCache::get
7.44%	7.4%	1	0.5	2847.27	1526.58	1423.63	763.29
MessageCache::load [–]
7.39%	6.89%	1	0.5	2825.01	1421.7	1412.51	710.85
MessageCache::load-fromcache
7.38%	6.88%	1	0.5	2824.81	1418.52	1412.4	709.26
User::load
6.46%	6.72%	2	1	1236.09	693.18	1236.09	693.18
-setup
5.49%	3.47%	1	0.5	2098.7	715.5	1049.35	357.75
MediaWiki::triggerJobs
3.68%	2.05%	1	0.5	1406.66	422.47	703.33	211.23
DatabaseBase::query
2.99%	3.8%	359	179.5	3.18	2.18	571.63	392.11
SQL Queries [+]
2.87%	0%	0	0	0	0	548.01	0
LoadBalancer::getConnection
2.79%	4.29%	21	10.5	50.91	42.11	534.53	442.2
LoadBalancer::openConnection
2.79%	4.26%	21	10.5	50.76	41.81	532.95	438.98
OutputPage::output
1.85%	2.02%	1	0.5	707.36	416.93	353.68	208.46
MediaWiki::performRequest
1.84%	0.76%	1	0.5	705.69	157.42	352.85	78.71
Title::getUserPermissionsErrorsInternal
0.91%	0.34%	1	0.5	349.82	69.2	174.91	34.6
User::getEffectiveGroups
0.91%	0.23%	1	0.5	348.65	47.03	174.32	23.52
User::getAutomaticGroups
0.91%	0.2%	1	0.5	348.36	41.73	174.18	20.87
WebStart.php-ob_start
0.89%	0.27%	1	0.5	341.45	55.16	170.72	27.58
LocalisationCache::getSubitem-load
0.06%	0.46%	1	0.5	21.59	95.52	10.8	47.76
MobileFrontendHooks::onBeforePageRedirect
0.04%	2.1%	2	1	6.96	216.33	6.96	216.33
hook: BeforePageRedirect
0.03%	1.78%	1	0.5	11.39	367.72	5.7	183.86
DatabaseMysqlBase::open
0.03%	0.05%	3	1.5	3.31	3.39	4.96	5.09
dbconnect-mysql.abcmartin.dreamhosters.com
0.02%	0.02%	3	1.5	2.59	1.45	3.89	2.17
MobileContext::shouldDisplayMobileView
0.01%	0.19%	1	0.5	2.08	39.45	1.04	19.73
LocalisationCache::getItem-load
0%	0.15%	1	0.5	1.74	31	0.87	15.5
JobQueue::getSiblingQueuesWithJobs
0%	0.02%	1	0.5	1.61	3.7	0.8	1.85
MobileContext::getDevice
0%	0.16%	1	0.5	1.11	33.52	0.56	16.76
DeviceProperties::detectMobileDevice
0%	0.05%	1	0.5	0.56	10.5	0.28	5.25
Title::getPageLanguage
0%	0.02%	1	0.5	0.31	3.33	0.16	1.66
SkinFactory::getLegacySkinNames-init
0%	0.01%	1	0.5	0.28	1.55	0.14	0.78
hook: SetupAfterCache
0%	0.01%	2	1	0.11	0.57	0.11	0.57
hook: AuthPluginSetup
0%	0%	2	1	0.1	0.45	0.1	0.45
DeferredUpdates::doUpdates
0%	0.01%	2	1	0.09	0.59	0.09	0.59
hook: TitleExists
0%	0%	2	1	0.06	0.45	0.06	0.45
MediaWiki::checkMaxLag
0%	0%	1	0.5	0.12	0.62	0.06	0.31
MessageCache::saveToCaches
0%	0%	1	0.5	0.11	0.62	0.05	0.31
hook: WebRequestPathInfoRouter
0%	0%	1	0.5	0.1	0.46	0.05	0.23
hook: CanonicalNamespaces
0%	0%	1	0.5	0.1	0.46	0.05	0.23
hook: LoadExtensionSchemaUpdates
0%	0%	1	0.5	0.1	0.47	0.05	0.23
hook: GetAutoPromoteGroups
0%	0%	1	0.5	0.09	0.46	0.05	0.23
hook: PageContentLanguage
0%	0%	1	0.5	0.07	0.46	0.04	0.23
hook: MessageCache::get
0%	0%	1	0.5	0.07	0.45	0.04	0.23
hook: UserLoadFromSession
0%	0%	1	0.5	0.07	0.46	0.03	0.23
hook: UserGetDefaultOptions
0%	0%	1	0.5	0.06	0.46	0.03	0.23
hook: ArticlePageDataBefore
0%	0%	1	0.5	0.06	0.46	0.03	0.23
hook: UserLoadFromDatabase
0%	0%	1	0.5	0.06	0.46	0.03	0.23
hook: MessagesPreLoad
0%	0%	1	0.5	0.06	0.45	0.03	0.23
hook: LanguageGetNamespaces
0%	0%	1	0.5	0.06	0.46	0.03	0.23
hook: UserGetRights
0%	0%	1	0.5	0.06	0.45	0.03	0.23
hook: ArticlePageDataAfter
0%	0%	1	0.5	0.06	0.46	0.03	0.23
hook: UserLoadOptions
0%	0%	1	0.5	0.06	0.45	0.03	0.23
hook: UserLoadAfterLoadFromSession
0%	0%	1	0.5	0.05	0.47	0.03	0.23
hook: TestCanonicalRedirect
0%	0%	1	0.5	0.05	0.46	0.03	0.23
hook: UserEffectiveGroups
0%	0%	1	0.5	0.05	0.46	0.03	0.23
hook: GetFullURL
0%	0%	1	0.5	0.05	0.45	0.03	0.23
hook: SearchableNamespaces
0%	0%	1	0.5	0.05	0.46	0.03	0.23
hook: TitleGetRestrictionTypes
0%	0%	1	0.5	0.05	0.46	0.02	0.23
hook: userCan
0%	0%	1	0.5	0.05	0.45	0.02	0.22
hook: GetLocalURL [+]
0%	0%	1	0.5	0.05	0.45	0.02	0.23
hook: BeforeInitialize
0%	0%	1	0.5	0.05	0.45	0.02	0.23
hook: getUserPermissionsErrors [+]
0%	0%	1	0.5	0.05	0.46	0.02	0.23
Total time: 38252.70
Total memory: 20625.20

any ideas with the slowness?

Pszemia (talkcontribs)
Reply to "Page loading time, very very slow"