Chapter . Getting Started with Sphinx
In this chapter, we will cover basic installation, configuration, and maintenance of Sphinx. Donât be fooled by the adjective âbasicâ and skip the chapter. By âbasic,â I donât mean something simple to the point of being obviousâinstead, I mean features that literally everyone uses.
Sphinx, by default, uses MySQL as its source for data and assumes that you have both MySQL and the MySQL development libraries installed. You can certainly run Sphinx with some other relational database or data source, but MySQL is very popular and this chapter is based on it for convenience. There are at least half a dozen easy ways to install MySQL on most systems, so this chapter wonât cover that task. Iâll also assume you know some basic SQL.
Workflow Overview
Installation, configuration, and usage are all pieces of a larger picture. A complete search solution consists of four key components:
- Your client program
This accepts the userâs search string (or builds a search string through its own criteria), sends a query to searchd, and displays the results.
- A data source
This stores your data and is queried by the indexer program. Most Sphinx sites use MySQL or another SQL server for storage. But thatâs not a fundamental requirementâSphinx can work just as well with non-SQL data sources. And weâll see, in the following section, that you can populate Sphinxâs index from an application instead of a fixed source such as a database.
- indexer
This program ...
Get Introduction to Search with Sphinx now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.