Media Wiki CirrusSearch: Difference between revisions
Jump to navigation
Jump to search
Line 18: | Line 18: | ||
tar -xzf CirrusSearch-REL1_35-95b958b.tar.gz -C /var/www/mediawiki-x.y.z/extensions | tar -xzf CirrusSearch-REL1_35-95b958b.tar.gz -C /var/www/mediawiki-x.y.z/extensions | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Add the following statement to LocalSettings.php: | Add the following statement to <tt>[[Media_Wiki_Concepts#LocalSettings.php|LocalSettings.php]]</tt>: | ||
<syntaxhighlight lang='php'> | <syntaxhighlight lang='php'> | ||
wfLoadExtension( 'CirrusSearch' ); | wfLoadExtension( 'CirrusSearch' ); | ||
Line 27: | Line 27: | ||
Follow the installation instructions delivered with <code>/var/www/mediawiki-1.35.0/extensions/CirrusSearch/README</code>. | Follow the installation instructions delivered with <code>/var/www/mediawiki-1.35.0/extensions/CirrusSearch/README</code>. | ||
In LocalSettings.php: | In <tt>[[Media_Wiki_Concepts#LocalSettings.php|LocalSettings.php]]</tt>: | ||
<syntaxhighlight lang='php'> | <syntaxhighlight lang='php'> |
Revision as of 20:13, 21 November 2021
External
- https://www.mediawiki.org/wiki/Extension:CirrusSearch
- https://www.mediawiki.org/wiki/Help:CirrusSearch
Internal
Installation
Install elasticsearch. Use the latest recommended major version elasticsearch. Do not use 7.x if they recommend 6.x.
Install Elastica extension:
Download the correct CirrusSearch version from https://www.mediawiki.org/wiki/Special:ExtensionDistributor/CirrusSearch
Unzip it in the extensions
directory:
tar -xzf CirrusSearch-REL1_35-95b958b.tar.gz -C /var/www/mediawiki-x.y.z/extensions
Add the following statement to LocalSettings.php:
wfLoadExtension( 'CirrusSearch' );
Smoke test: go to Special:Version and verify that the extension is successfully installed.
Follow the installation instructions delivered with /var/www/mediawiki-1.35.0/extensions/CirrusSearch/README
.
wfLoadExtension( 'Elastica' );
wfLoadExtension( 'CirrusSearch' );
$wgDisableSearchUpdate = true;
As root:
php /var/www/mediawiki-.../extensions/CirrusSearch/maintenance/UpdateSearchIndexConfig.php
Remove
$wgDisableSearchUpdate = true;
from LocalSettings.php.
php /var/www/mediawiki-.../extensions/CirrusSearch/maintenance/maintenance/ForceSearchIndex.php --skipLinks --indexOnSkip
php /var/www/mediawiki-.../extensions/CirrusSearch/maintenance/maintenance/ForceSearchIndex.php --skipParse
In LocalSettings.php:
$wgSearchType = 'CirrusSearch';
Troubleshooting
Enable debugging as shown in:
[CirrusSearchRequests] near_match search for 'test' against {index} took 5 millis. Requested via web for 5b7883dcb7cd761f62397caa67819012 by executor 2078481799
[CirrusSearch] Search backend error during near_match search for 'test' after 5: unknown: Couldn't connect to host, Elasticsearch down?