sphinxsearchHow can I configure SphinxSearch to work with MediaWiki?
- Install SphinxSearch:
$ apt-get install sphinxsearch
- Create SphinxSearch configuration file:
$ nano /etc/sphinxsearch/sphinx.conf
-
Add the following lines to the configuration file:
source mediawiki { type = mysql sql_host = localhost sql_user = <username> sql_pass = <password> sql_db = <database> sql_port = 3306 # default sql_query = \ SELECT page_id, page_title, page_touched \ FROM page sql_attr_uint = page_id sql_attr_timestamp = page_touched }
- Index the data from the MediaWiki database:
$ indexer --all --config /etc/sphinxsearch/sphinx.conf
- Start the searchd daemon:
$ searchd --config /etc/sphinxsearch/sphinx.conf
- Connect to SphinxSearch by using a library such as SphinxQL:
$ mysql -h127.0.0.1 -P9306
- Execute the query to search the MediaWiki database:
mysql> SELECT * FROM mediawiki WHERE MATCH('<query>');
Helpful links
More of Sphinxsearch
- How do I configure SphinxSearch using YAML?
- How can I use Sphinx Search to manage my team of workers?
- How do I use the word count ranker in SphinxSearch?
- How do I use Sphinxsearch with Zsh?
- How do I integrate Sphinxsearch with Yii2?
- How do I configure SphinxSearch to listen for incoming requests?
- How do I use SphinxSearch with XMLPipe2?
- How can I use SphinxSearch and Zabbix together to monitor my system?
- How do I configure SphinxSearch to ignore certain stop words?
- How can I use Sphinxsearch with Django?
See more codes...