關於coreseek介紹
http://www.coreseek.cn/products-install/install_on_bsd_linux/
mmseg 安裝(中文分詞)
# wget http://www.coreseek.cn/uploads/csft/3.2/coreseek-3.2.14.tar.gz
cd mmseg-3.2.14
#./bootstrap
#./configure --prefix=/usr/local/mmseg3
# make
# make install
sphinx 安裝
#cd coreseek-4.1/csft-4.1
#./buildconf.sh
#./configure --prefix=/opt/sphinx \
--with-mmseg \
--with-mmseg-includes=/opt/mmseg/include/mmseg \
--with-mmseg-libs=/opt/mmseg/lib/ \
--with-mysql=/opt/mysql
#make
#make install
啓動
#/opt/sphinx/bin/indexer --config /opt/sphinx/etc/sphinx.conf --all #建立索引
#/opt/sphinx/bin/searchd --config /opt/sphinx/etc/sphinx.conf #啓動索引服務
#/opt/sphinx/bin/indexer --config /opt/sphinx/etc/sphinx.conf --rotate --all #重建增量索引
crontab五分鐘重建增量索引
#crontab -e
*/5 * * * */opt/sphinx/bin/indexer --config /opt/sphinx/etc/sphinx.conf --rotate --all
sphinx存儲引擎 for mysql支持
將sphinx程序目錄的mysqlse複製到mysql程序目錄storage
# cp coreseek-4.1/csft-4.1/mysqlse /root/soft/mysql-5.1.61/storage/shpinx
# cd /root/soft/mysql-5.1.61
# sh BUILD/autorun.sh
# ./configure \
--prefix=/opt/mysql \
--enable-assembler \
--with-charset=utf8 \
--with-extra-charsets=complex \
--with-plugins=partition,innobase,myisam,sphinx \
--enable-thread-safe-client \
--with-client-ldflags=-all-static \
--with-mysqld-ldflags=-all-static
# make
# make install
查看mysql sphinx存儲引擎
mysql> show engines;
Engine | Support | Comment
SPHINX | YES | Sphinx storage engine
配置/opt/sphinx/etc/sphinx.conf