Local MediaWiki installation slow despite enabling Squid, parser, file, and sidebar caching

0

I have a local MediaWiki installation on a flash drive using XAMPP. I have enabled every possible form of caching as far as I know except for Varnish, since it's unavailable on Windows. Additionally, miser mode and many other settings that apparently increase speed are enabled. However, it still takes ~40 seconds to load the main page (or any other page) after modifying LocalSettings.php. It's possible that I'm misusing Squid, as I couldn't find anything that said whether or not I could use it locally (though I'm leaning towards no, given that there is no notable speed difference between enabling and disabling it). I have enabled php_apc. Is there any way to speed it up?

This is my LocalSettings.php file (comments removed to condense):

<?php
if ( !defined( 'MEDIAWIKI' ) ) {
    exit;
}
$wgCachePages=true;
$wgSitename = "MyWiki";
$wgScriptPath = "/wiki";
$wgServer = "http://127.0.0.1";
$wgResourceBasePath = $wgScriptPath;
$wgLogo = "$wgResourceBasePath/images/WikiLogo_135px.png";
$wgEnableEmail = true;
$wgEnableUserEmail = true; # UPO
$wgEmergencyContact = "apache@localhost";
$wgPasswordSender = "apache@localhost";
$wgEnotifUserTalk = false; # UPO
$wgEnotifWatchlist = false; # UPO
$wgEmailAuthentication = true;
$wgDBtype = "mysql";
$wgDBserver = "127.0.0.1";
$wgDBname = "wikidb";
$wgDBuser = "wiki";
$wgDBpassword = "[redacted]";
$wgDBprefix = "";
$wgDBTableOptions = "ENGINE=InnoDB, DEFAULT CHARSET=utf8";
$wgDBmysql5 = false;
$wgMainCacheType = CACHE_ACCEL;
$wgMemCachedServers = [];
$wgEnableUploads = true;
$wgUseImageMagick = true;
$wgImageMagickConvertCommand = "C:\\Program Files\\ImageMagick-7.0.7-Q16\\convert.exe";
$wgUseInstantCommons = true;
$wgPingback = false;
$wgShellLocale = "C.UTF-8";
#$wgCacheDirectory = "$IP/cache";
$wgLanguageCode = "en";
$wgSecretKey = "[redacted]";
$wgAuthenticationTokenVersion = "1";
$wgUpgradeKey = "22275bc0e8047d19";
$wgRightsPage = "";
$wgRightsUrl = "";
$wgRightsText = "";
$wgRightsIcon = "";
$wgDiff3 = "";
$wgDefaultSkin = "vector";
wfLoadSkin( 'CologneBlue' );
wfLoadSkin( 'Modern' );
wfLoadSkin( 'MonoBook' );
wfLoadSkin( 'Vector' );
$wgFavicon = "$wgResourceBasePath/favicon.ico";
$wgJobRunRate = 0;
$wgUseFileCache = true;
$wgFileCacheDirectory = "{$wgUploadDirectory}/cache";
$wgEnableSidebarCache = true;
$wgCacheDirectory = "{$wgUploadDirectory}/cache2";
$wgLocalisationCacheConf = array(
    'class' => 'LocalisationCache',
    'store' => 'files',
    'storeClass' => false,
    'manualRecache' => false,
);
$wgUsePrivateIPs = true;
$wgHitcounterUpdateFreq=20000;
$wgEnableParserCache=true;
$wgShowIPinHeader = false;
$wgUseGzip = true;
$wgMiserMode = true;
$wgCompressRevisions = true;
$wgRevisionCacheExpiry = 3*24*3600;
$wgParserCacheExpireTime = 14*24*3600;
$wgGroupPermissions['autopatrolled']['autopatrol'] = true;
$wgSessionsInObjectCache=true;
$wgSessionCacheType=CACHE_ACCEL;
$wgInvalidateCacheOnLocalSettingsChange=false;
$wgDisableQueryPages=true;
$wgUseSquid = true;
$wgSquidServers = array('127.0.0.1'); # improper?
$wgSquidServersNoPurge = array('127.0.0.1');

snorepion

Posted 2017-12-20T21:08:26.463

Reputation: 11

Squid is a service that you need to set up (much like Varnish). You cannot enable it from MediaWiki config; at most you can make MediaWiki interact with it (or it would interact with it if it were there). – Tgr – 2017-12-21T06:17:13.347

If you use file caching the load time should be approximately zero as everything is just loaded from cache; so something is not working. You can use profiling (via MediaWiki support for xhprof/tideways, or via XDebug) to see what that is.

– Tgr – 2017-12-21T06:20:12.850

No answers