zoukankan      html  css  js  c++  java
  • 安装CoreSeek

    环境需求和详细安装查看CoreSeek的官网

    http://www.coreseek.cn/products-install/install_on_bsd_linux/


    CoreSeek快速安装:

    安装前,建议查看:源码包说明README;4.0/4.1版可参考3.2版本安装,步骤相同;如遇到问题,请看详细安装说明。

    ##下载coreseek:coreseek 3.2.14:点击下载、coreseek 4.0.1:点击下载、coreseek 4.1:点击下载
    $ wget http://www.coreseek.cn/uploads/csft/3.2/coreseek-3.2.14.tar.gz
    $ 或者 http://www.coreseek.cn/uploads/csft/4.0/coreseek-4.0.1-beta.tar.gz
    $ 或者 http://www.coreseek.cn/uploads/csft/4.0/coreseek-4.1-beta.tar.gz
    $ tar xzvf coreseek-3.2.14.tar.gz 或者 coreseek-4.0.1-beta.tar.gz 或者 coreseek-4.1-beta.tar.gz
    $ cd coreseek-3.2.14 或者 coreseek-4.0.1-beta 或者 coreseek-4.1-beta

    ##前提:需提前安装操作系统基础开发库及mysql依赖库以支持mysql数据源和xml数据源
    ##安装mmseg
    $ cd mmseg-3.2.14
    $ ./bootstrap    #输出的warning信息可以忽略,如果出现error则需要解决
    $ ./configure --prefix=/usr/local/mmseg3
    $ make && make install
    $ cd ..

    ##安装coreseek
    $ cd csft-3.2.14 或者 cd csft-4.0.1 或者 cd csft-4.1
    $ sh buildconf.sh    #输出的warning信息可以忽略,如果出现error则需要解决
    $ ./configure --prefix=/usr/local/coreseek  --without-unixodbc --with-mmseg --with-mmseg-includes=/usr/local/mmseg3/include/mmseg/ --with-mmseg-libs=/usr/local/mmseg3/lib/ --with-mysql    ##如果提示mysql问题,可以查看MySQL数据源安装说明
    $ make && make install
    $ cd ..

    ##测试mmseg分词,coreseek搜索(需要预先设置好字符集为zh_CN.UTF-8,确保正确显示中文)
    $ cd testpack
    $ cat var/test/test.xml    #此时应该正确显示中文
    $ /usr/local/mmseg3/bin/mmseg -d /usr/local/mmseg3/etc var/test/test.xml
    $ /usr/local/coreseek/bin/indexer -c etc/csft.conf --all
    $ /usr/local/coreseek/bin/search -c etc/csft.conf 网络搜索


    配置:

    把配置文件拷贝到etc下
    cp -r ./testpack /etx/csft

    创建索引
    /usr/local/coreseek/bin/indexer -c /etc/csft/etc/csft_mysql.conf --all
    /usr/local/coreseek/bin/indexer -c /etc/csft/etc/csft_mysql.conf --rotate
    /usr/local/coreseek/bin/indexer -c /etc/csft/etc/csft_mysql.conf --rotate --all

    搜索关键字
    /usr/local/coreseek/bin/search -c /etc/csft/etc/csft_mysql.conf 网络

    开启和关闭coreseek
    /usr/local/coreseek/bin/searchd -c /etc/csft/etc/csft_mysql.conf
    /usr/local/coreseek/bin/searchd -c /etc/csft/etc/csft_mysql.conf --stop



    碰到的错误

    问题:

    我的是CENTOS5.6,装的是3.2.14
    在安装coreseek
    到make && make install这步的时候,出现下面提示,
    因为我刚弄coreseek,不知道是否有错误,
    /root/coreseek-3.2.14/csft-3.2.14/src/tokenizer_zhcn.h:73: undefined reference to `libiconv'
    collect2: ld returned 1 exit status
    make[2]: *** [indexer] Error 1
    make[2]: Leaving directory `/root/coreseek-3.2.14/csft-3.2.14/src'
    make[1]: *** [all] Error 2
    make[1]: Leaving directory `/root/coreseek-3.2.14/csft-3.2.14/src'
    make: *** [all-recursive] Error 1
    [root@localhost csft-3.2.14]#

    解决:
    修改coreseek-3.2.14目录下的 /src/MakeFile文件

    LIBS = -lm -lexpat -L/usr/local/lib
    改成
    LIBS = -lm -lexpat -liconv -L/usr/local/lib






    linux操作

    关闭端口
    每个端口都是一个进程占用着,用netstat -anp |grep 3306找出占用3306这个端口的进程,再用
    kill -9 PID
    杀掉就行了






  • 相关阅读:
    基于storm和hadoop的广告系统研究【2】
    基于storm和hadoop的广告系统研究【1】
    签名ipa,让其它手机也安装
    UIWebview 截获html并修改内容。
    Resetting the SMC & PRAM
    UITableview 兼容IOS6 和IOS7的方法
    IOS7 APP 升级的10个TIP 建议
    IOS: Xcode报 Undecleared selector Warning错误的解决方法
    十个iOS面试问题
    iOS制作Static Library(静态库),实现多工程的连编
  • 原文地址:https://www.cnblogs.com/gxldan/p/4065004.html
Copyright © 2011-2022 走看看