Sphinx is a free software. It is designed to provide full-text search functionality to client applications.
Install Sphinx
The latest Sphinx version can be found from Here
Download the package and install it using the following link.
wget http://sphinxsearch.com/files/sphinx-2.2.10-release.tar.gz tar xzf sphinx-2.2.10-release.tar.gz cd sphinx-2.2.10-release ./configure --prefix=/usr/local make make install
After the installation, please create a configuration file.
cp -pr /usr/local/etc/sphinx.conf.dist /usr/local/etc/sphinx.conf
Then, we need to create the start-up scripts.
vim /etc/init.d/searchd
and add the following:
#!/bin/bash case "${1:-''}" in 'start') /usr/local/bin/searchd ;; 'stop') /usr/local/bin/searchd --stop ;; 'restart') /usr/local/bin/searchd --stop && /usr/local/bin/searchd ;; *) echo "Usage: $SELF start|stop|restart" exit 1 ;; esac
Make the start-up script file executable.
chmod 755 /etc/init.d/searchd
and start the service.
/etc/init.d/searchd start
Also, you can set autostart after server reboot by adding the start-up script on rc.local file.
vim /etc/rc.local
and add the following on it.
/etc/init.d/searchd start
That’s it!