How to install Httpsqs and troubleshoot installation errors

Source: Internet
Author: User
Requirement: when searching for products, you need to search from the index. Because the background needs to update products and insert products, how to insert new indexes and update indexes was taken into consideration, after discussion, we decided to use the Httpsqs message to notify you to insert a new index and delete the last merged index of the index to update the product information in real time. Here I come

Requirement: when searching for products, you need to search from the index. Because the background needs to update products and insert products, how to insert new indexes and update indexes was taken into consideration, after discussion, we decided to use the Httpsqs message to notify you to insert a new index and delete the last merged index of the index to update the product information in real time.

Next I will talk about the installation process of Httpsqs and the problems encountered during the installation process.

Preparations:

You need to prepare a virtual machine. Here we use VMware7.1,

In Linux, centOs5.4 can be used.

Install httpsqs

Install httpsqs

  1. Libevent-2.0.12-stable.tar.gzand okyocabinet-1.4.47.tar.gz
  1. Ulimit-SHn 65535
1. Install libevent-2.0.12-stable.tar.gz
  1. Wget http://httpsqs.googlecode.com/FileS/libevent-2.0.12-stable.tar.gz # download
  2. Tar zxvf libevent-2.0.12-stable.tar.gz ##Extract
  3. CdLibevent-2.0.12-stable/
  4. ./Configure-- Prefix=/Usr/local/libevent-2.0.12-stable/
  5. Make
  6. Make install
  7. Cd ../
Install tokyocabinet-1.4.47.tar.gz
  1. Wget http://httpsqs.googlecode.com/files/tokyocabinet-1.4.47.tar.gz
  2. Tar zxvf tokyocabinet-1.4.47.tar.gz
  3. Cd tokyocabinet-1.4.47/
  4. ./Configure-- Prefix=/Usr/local/tokyocabinet-1.4.47/
  5. # Note: To compile Tokyo cabinet on a 32-bit Linux operating system, use./configure --Enable-Replace./configure with off64, which can break the limit of 2 GB for database files.
  6. #./Configure -- enable-off64-- Prefix=/Usr/local/tokyocabinet-1.4.47/
  7. Make
  8. Make install
  9. Cd ../
When the second step is executed, an error occurs because B is missing. Zip2-1.0.6.tar.gz

Install

  1. Http://www.bzip.org/1.0.6/Bzip2-1.0.6.tar.gz installation starts;
  2. Wget http://www.bzip.org/1.0.6/bzip2-1.0.6.tar.gz
  3. Tar-xvzf bzip2-1.0.6.tar.gz
  4. Cd bzip2-1.0.6.
  5. Make
  6. Make install
The re-installation of tokyocabinet-1.4.47.tar.gzis still a failure because zlib-1.2.5.tar.gz is missing.

Install

  1. Http://www.winimage.com/zlibdll/zlib-1.2.5.tar.gzinstallation started;
  2. Wget http://www.winimage.com/zLibDll/zlib-1.2.5.tar.gz
  3. Tar-xvzf zlib-1.2.5.tar.gz
  4. Cd zlib-1.2.5.
  5. ./Configure
  6. Make
  7. SuDo make instal
Continue Step 1 OK

32.16install httpsqs-1.7.tar.gz

  1. Wget http://httpsqs.googlecode.com/files/httpsqs-1.7.tar.gz
  2. Tar zxvf httpsqs-1.7.tar.gz
  3. Cd httpsqs-1.7/
  4. Make
  5. Make install
  6. Cd ../
If the installation is successful, run httpsqs? H will appear
  1. Bytes --------------------------------------------------------------------------------------------------
  2. HTTP Simple Queue Service-httpsqs v1.7 (April 14,201 1)
  3. Author: Zhang Yan (http://blog.s135.com), E-mail: net@s135.com
  4. This isFreeSoftware, and you are welcome to modify and rEdIsTrIbute it under the New BSD License
  5. -L<Ip_aDdR>Interface to listen on, default is 0.0.0.0
  6. -P<Num>TCP port number to listen on (default: 1218)
  7. -X<Path>Database directory (ExAmple:/opt/httpsqs/data)
  8. -T<Second>Keep-aliveTimeOut for an http request (default: 60)
  9. -S<Second>The interval to syNcUpDateD contents to the disk (default: 5)
  10. -C<Num>The maximum number of non-leaf nodes to be cached( default: 1024)
  11. -M<Size>Database memory cache size in MB (default: 100)
  12. -I<File>Save PID in<File>(Default:/tmp/httpsqs. pId)
  13. -<Auth>The auth password to access httpsqs (example: mypass123)
  14. -D run as a daemon
  15. -H print this help and exit
  16. Use command \"KillAll httpsqs \ ", \" pkill httpsqs \ "and \" kill'Cat/Tmp/httpsqs. pid '\ "to stop httpsqs.
  17. Please note that don \'t use the command \ "pkill-9 httpsqs \" and \ "kill-9 PID of httpsqs \"!
  18. Please visit \ "http://code.google.com/p/httpsqs\"MoreHelp infoRmAtion.
But none of them appear:
  1. Error while loading shared libraries:/usr/local/tokyocabinet-1.4.47/lib/libtokyocabinet. so.9: cannotRestoreSegment prot after reloc: Permission denied
At google, it is said that it has not been set up with a soft connection:
  1. Ln-S/usr/local/tokyocabinet-1.4.47/lib/libtokyocabinet. so.9/usr/lib/libtokyocabinet. so.9
However, google still reports an error. The solution is as follows:
  1. Vi/etc/sysconfig/selinux file
  2. ModifySELINUX=Disabled
Then restart

Try again

  1. Httpsqs-h
  2. Bytes --------------------------------------------------------------------------------------------------

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.