xunsearch 安裝的過程出現的錯誤


Confirm the installation directory
請確認安裝目錄:/usr/local/xunsearch [Y/n]y

Checking scws ... no
Installing scws (1.2.3) ...
Extracting scws package ...
Configuring scws ...
Compiling & installing scws ...
Checking scws dict ... no
Extracting scws dict file ...
Checking libuuid ... no, try to install it
Extracting libuuid package ...
Configuring libuuid ...
Compiling & installing libuuid ...
Checking xapian-core-scws ... no
Installing xapian-core-scws (1.2.22) ...
Extracting xapian-core-scws package ...
Configuring xapian-core-scws ...
-----
checking whether g++ accepts -g... no
checking dependency style of g++... none
checking whether g++ is a working C++ compiler... no
configure: error:
*** You need a working C++ compiler to compile Xapian, but configure failed to
*** find one.  If you have a working C++ compiler, you can tell configure where
*** to find it by invoking it like so:
***
***   ./configure CXX=/opt/bin/c++

-----
ERROR: failed to configure xapian-core-scws, see 'setup.log' for more detail

解決方案  安裝g++

yum install gcc-c++

Checking scws ... 1.2.3
Checking scws dict ... ok
Checking libuuid ... yes: /usr/local/xunsearch
Checking xapian-core-scws ... no
Installing xapian-core-scws (1.2.22) ...
Extracting xapian-core-scws package ...
Configuring xapian-core-scws ...
-----
checking whether strerror_r is declared... yes
checking for strerror_r... yes
checking whether strerror_r returns char *... yes
checking whether sys_errlist is declared... yes
checking whether _sys_errlist is declared... yes
checking whether sys_nerr is declared... yes
checking whether _sys_nerr is declared... yes
checking for working ISO C90 conforming snprintf... snprintf
checking for zlib.h... no
configure: error: zlib.h not found - required for brass, chert and flint (you may need to install the zlib1g-dev or zlib-devel package)
-----
ERROR: failed to configure xapian-core-scws, see 'setup.log' for more detail


解決方法 安裝 zlib模塊

yum install zlib-devel
 
 
[XSException] ../lib/XS.php(2551): Connection refused(C#111, localhost:8383)
#0 ../lib/XS.php(2363): XSServer->connect()
#1 ../lib/XS.php(2348): XSServer->open('8383')
#2 ../lib/XS.php(370): XSServer->__construct('8383', Object(XS))
#3 ../lib/XS.php(262): XS->getIndex()
#4 Indexer.php(157): XSComponent->__get('index')
#5 {main}
 
端口沒有啟動
如果您的 SDK 調用和 xunsearch 服務端不在同一服務器,請使用 -b inet 方式啟動腳本, 並注意借助類似 iptables 的防火牆來控制 xunsearch 的 8383/8384 兩個端口的訪問權限。 啟動腳本用法舉例如下,以下均為合法使用方式:

bin/xs-ctl.sh -b local start    // 監聽在本地回環地址 127.0.0.1 上
bin/xs-ctl.sh -b inet start     // 監聽在所有本地 IP 地址上
bin/xs-ctl.sh -b a.b.c.d start  // 監聽在指定 IP 上 我是不在同一服務器上,因此我選擇這一種(bin/xs-ctl.sh -b 195.241.23.32 start)
bin/xs-ctl.sh -b unix start
 
/usr/local/xunsearch/bin/xs-ctl.sh start
 
借鑒http://www.cnblogs.com/houdj/p/5358724.html
 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM