美文网首页
whatsns全文检索xunsearch-问题模块配置

whatsns全文检索xunsearch-问题模块配置

作者: 米哥smalrice | 来源:发表于2017-08-16 08:21 被阅读70次
  1. 安装xunserch

下载和安装(安装需要gcc gcc-c++ make支持,记得事先安装)

wget http://www.xunsearch.com/download/xunsearch-full-latest.tar.bz2
tar -xjf xunsearch-full-latest.tar.bz2
cd xunsearch-full-1.4.8/
sh setup.sh
1.1 安装的默认路劲 /usr/local/xunsearch/ ,如果你不是很精通就不要改了,方便照着我下面的操作来做。
1.2 正常情况下5分钟后安装完成,如果失败请看提示编译到哪里出错了,对应出错的所需库,进行安装。

如果发现有警告或者错误,对于响应的模块进行安装,如apc模块。(centos 安装命令就是 yum install php-pecl-apc)

以下是question.ini文件,放入到/usr/local/xunsearch/sdk/php/app/ 下

project.name = questionproject.default_charset = utf-8server.index = 8383server.search = 8384[id]type = id[cid]type = numeric[cid1]type = numeric[cid2]type = numeric[cid3]type = numeric[author][authorid]type = numeric[answers]type = numeric[status]type = numeric[time]type = numeric[title]type = title[description]type = body

上面都ok了,重启一下服务,并把服务放入到开机启动项

/usr/local/xunsearch/bin/xs-ctl.sh restart

安装conv

wget http://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.14.tar.gz
tar -zxvf libiconv-1.14.tar.gz
cd libiconv-1.14
./configure --prefix=/usr/local/iconv
make && make install

让php支持conv

在php.ini中加入一行 extension=/usr/local/iconv/lib/libiconv.so

重启http服务

service httpd restart

问答系统后台开始全文搜索功能

数据库 my.cnf 加入 ft_min_word_len=1

PHP-SDK文件全路径 /usr/local/xunsearch/sdk/php/lib/XS.php


本文来自:https://www.ask2.cn/article-14732.html

相关文章

  • whatsns全文检索xunsearch-问题模块配置

    安装xunserch 下载和安装(安装需要gcc gcc-c++ make支持,记得事先安装) wget http...

  • Django 引入全文检索

    1.安装模块 全文检索管理模块haystack、全文搜索引擎模块whoosh和中文分词jiebapip insta...

  • ElasticSearch - Lucene

    Lucene 全文检索的心,天才的想法。 一个高效的,可扩展的,全文检索库。 全部用 Java 实现,无须配置。 ...

  • ElasticSearch-搜索查询

    URL querystring语法 全文检索: 单字段全文检索: 条件组合 单字段精确检索: 多个检索条件的组合:...

  • django-haystack(全文检索-jieba分词)

    安装和配置 1.安装。 pip install django-haystack==2.6.1# 安装全文检索框架 ...

  • 全文检索

    概念 从文本或者数据库中,不限定资料字段,自由地萃取出讯息的技术 执行全文检索任务的程式,一般称作搜索引擎, 将使...

  • 全文检索

    概述 Full-Text Search 是将存储于数据库中的整本书或整篇文章中的任意内容信息查找出来的技术。 倒排...

  • sphinx全文检索配置参考文章

    http://www.cnblogs.com/mingaixin/p/5085708.html http://ww...

  • django中的全文检索

    全文检索 全文检索不同于特定字段的模糊查询,使用全文检索的效率更高,并且能够对于中文进行分词处理 haystack...

  • Django 2.1.7 全文检索

    全文检索 全文检索不同于特定字段的模糊查询,使用全文检索的效率更高,并且能够对于中文进行分词处理。 haystac...

网友评论

      本文标题:whatsns全文检索xunsearch-问题模块配置

      本文链接:https://www.haomeiwen.com/subject/iobbrxtx.html