Httpsqsのインストールおよびインストールプロセスエラーの解決方法

5908 ワード

需要:商品検索を行う場合、インデックスから検索します.バックグラウンドで商品を更新したり、商品を挿入したりするため、新しいインデックスをどのように挿入するか、インデックスを更新するかを考慮して、議論を通じて、Httpsqsというメッセージの間に新しいインデックスを挿入したり、インデックスを削除したりして最後にインデックスを統合したりすることを通知して、商品情報のリアルタイム更新を行うことにしました.
次に、Httpsqsのインストール手順と、インストール手順で発生した問題について説明します.
準備:
VMware 7を採用する仮想マシンを用意する必要があります.1,
LinuxはCentOS 5を採用する.4までhttp://vault.centos.org/5.4/isos/i386/CentOS-5.4-i386-bin-DVD.torrentこのサイトをダウンロードします.
httpsqsのインストール
httpsqsをインストールする前にインストールする
libevent-2.0.12-stable.tar.gz okyocabinet-1.4.47.tar.gz  

ulimit -SHn 65535  

1、libevent-2.0を取り付ける.12-stable.tar.gz
wget http://httpsqs.googlecode.com/files/libevent-2.0.12-stable.tar.gz##    
tar zxvf libevent-2.0.12-stable.tar.gz##    
cd libevent-2.0.12-stable/  
./configure --prefix=/usr/local/libevent-2.0.12-stable/  
make  
make install  
cd ../  

tokyocabinet-1.4をインストールします.47.tar.gz
wget http://httpsqs.googlecode.com/files/tokyocabinet-1.4.47.tar.gz  
tar zxvf tokyocabinet-1.4.47.tar.gz  
cd tokyocabinet-1.4.47/  
./configure --prefix=/usr/local/tokyocabinet-1.4.47/  
# : 32 Linux       Tokyo cabinet,   ./configure --enable-off64  ./configure,          2GB   。  
#./configure --enable-off64 --prefix=/usr/local/tokyocabinet-1.4.47/  
make  
make install  
cd ../  

第2のステップを実行するとエラーが発生するのは、bzip 2-1.0が欠けているためである.6.tar.gz
次にインストールを行います
http://www.bzip.org/1.0.6/bzip2-1.0.6.tar.gz    ;  
wget  http://www.bzip.org/1.0.6/bzip2-1.0.6.tar.gz  
tar -xvzf bzip2-1.0.6.tar.gz  
cd bzip2-1.0.6.  
make  
 make install  

tokyocabinet-1.4を繰り返しインストール.47.tar.gzはzlib-1.2が欠けているため失敗した.5.tar.gz
次にインストールを行います
http://www.winimage.com/zLibDll/zlib-1.2.5.tar.gz    ;  
wget  http://www.winimage.com/zLibDll/zlib-1.2.5.tar.gz  
tar -xvzf zlib-1.2.5.tar.gz  
cd zlib-1.2.5.  
./configure  
make  
sudo make instal  

第2ステップOKに進む
3.httpsqs-1.7をインストール.tar.gz
wget http://httpsqs.googlecode.com/files/httpsqs-1.7.tar.gz  
tar zxvf httpsqs-1.7.tar.gz  
cd httpsqs-1.7/  
make  
make install  
cd ../  

httpsqs-hがインストールに成功すると表示されます
--------------------------------------------------------------------------------------------------  
HTTP Simple Queue Service - httpsqs v1.7 (April 14, 2011)  
  
  
Author: Zhang Yan (http://blog.s135.com), E-mail: [email protected]  
This is free software, and you are welcome to modify and redistribute it under the New BSD License  
  
  
-l <ip_addr>  interface to listen on, default is 0.0.0.0  
-p <num>      TCP port number to listen on (default: 1218)  
-x <path>     database directory (example: /opt/httpsqs/data)  
-t <second>   keep-alive timeout for an http request (default: 60)  
-s <second>   the interval to sync updated contents to the disk (default: 5)  
-c <num>      the maximum number of non-leaf nodes to be cached (default: 1024)  
-m <size>     database memory cache size in MB (default: 100)  
-i <file>     save PID in <file> (default: /tmp/httpsqs.pid)  
-a <auth>     the auth password to access httpsqs (example: mypass123)  
-d            run as a daemon  
-h            print this help and exit  
  
  
Use command "killall httpsqs", "pkill httpsqs" and "kill `cat /tmp/httpsqs.pid`" to stop httpsqs.  
Please note that don't use the command "pkill -9 httpsqs" and "kill -9 PID of httpsqs"!  
  
  
Please visit "http://code.google.com/p/httpsqs" for more help information.  

しかし、現れなかったのは:
error while loading shared libraries: /usr/local/tokyocabinet-1.4.47/lib/libtokyocabinet.so.9: cannot restore segment prot after reloc: Permission denied  

Googleでは、ソフト接続が確立されていないと言います.
ln -s /usr/local/tokyocabinet-1.4.47/lib/libtokyocabinet.so.9 /usr/lib/libtokyocabinet.so.9  

しかし、やったのは、やはり間違いを報告してgoogleを続けて、解決方法は:
vi /etc/sysconfig/selinux file  
  SELINUX=disabled  

そして再起動
もう一度
httpsqs -h  
--------------------------------------------------------------------------------------------------  
HTTP Simple Queue Service - httpsqs v1.7 (April 14, 2011)  
  
  
Author: Zhang Yan (http://blog.s135.com), E-mail: [email protected]  
This is free software, and you are welcome to modify and redistribute it under the New BSD License  
  
  
-l <ip_addr>  interface to listen on, default is 0.0.0.0  
-p <num>      TCP port number to listen on (default: 1218)  
-x <path>     database directory (example: /opt/httpsqs/data)  
-t <second>   keep-alive timeout for an http request (default: 60)  
-s <second>   the interval to sync updated contents to the disk (default: 5)  
-c <num>      the maximum number of non-leaf nodes to be cached (default: 1024)  
-m <size>     database memory cache size in MB (default: 100)  
-i <file>     save PID in <file> (default: /tmp/httpsqs.pid)  
-a <auth>     the auth password to access httpsqs (example: mypass123)  
-d            run as a daemon  
-h            print this help and exit  
  
  
Use command "killall httpsqs", "pkill httpsqs" and "kill `cat /tmp/httpsqs.pid`" to stop httpsqs.  
Please note that don't use the command "pkill -9 httpsqs" and "kill -9 PID of httpsqs"!  
  
  
Please visit "http://code.google.com/p/httpsqs" for more help information.  

インストール成功!linux
——————————————————————————————————————————————————————————
http://blog.s135.com/httpsqs/ http://www.linuxidc.com/Linux/2011-08/39902.htm