FreeBSD. Installing MySQL 5.5.9 and SphinxSE
I wanted to install MySQL 5.5 on a new server, but the SphinxSE installation documentation doesn’t cover this version of MySQL. After some Googling and trying different approaches, I put together a short article…
Building the plugin
It’s all straightforward here: grab the MySQL sources from ports, download the patch, grab sphinx from trunk, and build everything together.
cd /usr/ports/database/mysql55-server
make fetch
cp /usr/ports/distfiles/mysql-5.5.9.tgz /tmp
cd /tmp
svn co http://sphinxsearch.googlecode.com/svn/trunk sphinx-trunk
fetch http://www.coreseek.cn/uploads/csft/patch/Sphinx_1.11-dev_sphinxse_mysql-5.5.8.diff
tar -xzf mysql-5.5.9.tar.gz
cd sphinx-trunk
patch -p0 < ../Sphinx_1.11-dev_sphinxse_mysql-5.5.8.diff
cp -R mysqlse ../mysql-5.5.9/storage/sphinx
cd ../mysql-5.5.9
cmake . -DCMAKE_BUILD_TYPE=Release -DWITH_SPHINX_STORAGE_ENGINE=1
make
cp storage/sphinx/ha_sphinx.so /usr/local/lib/mysql/plugin/ha_sphinx.so
Since I already had MySQL 5.5 installed from ports, I didn’t run make install, so I haven’t included it here. I recommend installing it from ports too.
Installing the plugin
Open the mysql client:
INSTALL PLUGIN sphinx SONAME "ha_sphinx.so";
SHOW ENGINES;
Based on http://sphinxsearch.com/forum/view.html?id=6862#32268
Comments are closed. Read the original discussion in Russian →