如何解决sphinx启动失败?

分类:Sphinx,问题集 | 作者:凹凸曼 | 发表于2012/02/07 如何解决sphinx启动失败?已关闭评论

错误提示:/usr/local/sphinx/bin/searchd: error while loading shared libraries: libmysqlclient.so.16: cannot open shared object file: No such file or directory

ldconfig -v|grep mysql
发现加载:/usr/lib/mysql:
libmysqlclient_r.so.15 -> libmysqlclient_r.so.15.0.0
libmysqlclient.so.15 -> libmysqlclient.so.15.0.0

ldd /usr/local/sphinx/bin/searchd
发现错误 libmysqlclient.so.16 => not found

解决办法:只能找到libmysqlclient.so.16 的库copy到/lib/ 下

sphinx安装

分类:Sphinx | 作者:凹凸曼 | 发表于2012/02/07 sphinx安装已关闭评论

安装sphinx前,需要安装

yum -y install gcc-c++
yum -y install libtool
不然会报错

wget http://www.coreseek.cn/uploads/csft/3.2/coreseek-3.2.13.tar.gz
tar zxvf coreseek-3.2.13.tar.gz

如何在没安装MySQL的服务器上安装Sphinx(远程连接)

分类:Sphinx | 作者:凹凸曼 | 发表于2011/03/15 1条评论

linux(CentOS)服务器里,从已经安装mysql的机子上把usr/local/mysql/bin、usr/local/mysql/include、usr/local/mysql/lib目录拷过来然后执行 # ./configure –prefix=usr/local/sphinx –with-mysql=usr/local/mysql # make # make install 在/etc/ld.so.conf.d目录下新建一个文件mysql.conf,内容为:usr/local/mysql/lib/mysql 执行 # /sbin/ldconfig –v Sphinx就安装好了哈

Sphinx 编译的问题及解决办法(sphinxclient.c:1358: error: ‘SO_NOSIGPIPE’ undeclared)

分类:Sphinx,问题集 | 作者:凹凸曼 | 发表于2011/03/14 Sphinx 编译的问题及解决办法(sphinxclient.c:1358: error: ‘SO_NOSIGPIPE’ undeclared)已关闭评论

编译sphinx库 —-libsphinxclient遇到的错误如下: A错误: sphinxclient.c:1358: error: ‘SO_NOSIGPIPE’ undeclared (first use in this function) B错误: .libs/libsphinxclient.a(sphinxclient.o): In function `vi sphinxclient.cset_error’: 解决这两个问题都需要修改sphinxclient.c 文件,如下所示: A错误详细表述: [root@localhost libsphinxclient]# make make all-am make[1]: Entering directory `/usr/local/src/sphinx-1.10-beta/api/libsphinxclient’ /bin/sh ./libtool –mode=compile –tag=CC gcc -DHAVE_CONFIG_H -I. -I. -I. -g -O2 -c -o sphinxclient.lo sphinxclient.c gcc -DHAVE_CONFIG_H -I. -I. -I. -g -O2 -c sphinxclient.c -fPIC […]

Sphinx 配置文件说明

分类:Sphinx | 作者:凹凸曼 | 发表于2011/03/14 Sphinx 配置文件说明已关闭评论

一. 创建sphinx.conf文件 其结构组成主要如下: Source 源名称1{ //指定数据源 一些配置 } Index 索引名称1{ Source=源名称1 } Source 源名称2{ 一些配置 } Index 索引名称2{ Source=源名称2 } Indexer{ mem_limit = 32M } Searchd{ //配置 searchd 守护程序本身 } 二. Source 源名称 相关配置说明 Type=数据库类型(Mysql 或SQL); Sql_host= 数据库主机地址(如果是外网,请确保防火墙允许链接) Sql_user= 数据库用户名 Sql_pass= 数据库密码 Sql_db= 数据库名称 Sql_port=

Sphinx配置过程及使用

分类:Sphinx | 作者:凹凸曼 | 发表于2011/03/09 2条评论

Linux(CentOS为案例)下怎样安装sphinx, 怎样建立索引,并且是自动的建立所需要的,怎样通过php调用sphinx,并查询! 一系列问题等着起的! 接下来就开始吧! 一、安装 #确保又mysql库 没有的话预编译的时候会报错的,那就要先安mysql库,不过我这里就不讲了! 查看–如何在没安装MySQL的服务器上安装Sphinx(远程连接)? 官网:http://sphinxsearch.com/ wget http://sphinxsearch.com/files/sphinx-1.10-beta.tar.gz tar zxvf sphinx-1.10-beta.tar.gz cd sphinx-1.10-beta ./configure –prefix=/usr/local/sphinx –with-mysql=/usr/local/mysql