Hongmu Notes
Home Program Notes Troubleshooting errors when installing Xunsearch on CentOS 8.0
Program Notes sphinx

Troubleshooting errors when installing Xunsearch on CentOS 8.0

Troubleshooting errors when installing Xunsearch on CentOS 8.0

Error message:

sh setup.sh
+==========================================+
| Welcome to setup xunsearch(full)         |
| 欢迎使用 xunsearch (完整版) 安装程序     |
+------------------------------------------+
| Follow the on-screen instructions please |
| 请按照屏幕上的提示操作以完成安装         |
+==========================================+

Please specify the installation directory
请指定安装目录 (默认为中括号内的值)
[/www/server/xunsearch]:

Confirm the installation directory
请确认安装目录:/www/server/xunsearch [Y/n]

Checking scws ... 1.2.3
Checking scws dict ... ok
Checking libuuid ... yes: /usr
Checking xapian-core-scws ... 1.4.20
Checking libevent ... no
Installing libevent (2.0.21-stable) ... 
Extracting libevent package ...
Configuring libevent ...
Compiling & installing libevent ...
-----
      |        ^~
bufferevent_openssl.c: At top level:
bufferevent_openssl.c:228:19: error: storage size of 'methods_bufferevent' isn't known
  228 | static BIO_METHOD methods_bufferevent = {
      |                   ^~~~~~~~~~~~~~~~~~~
make[2]: *** [Makefile:793: bufferevent_openssl.lo] Error 1
make[2]: Leaving directory '/root/xunsearch-full-1.4.17/libevent-2.0.21-stable'
make[1]: *** [Makefile:857: install-recursive] Error 1
make[1]: Leaving directory '/root/xunsearch-full-1.4.17/libevent-2.0.21-stable'
make: *** [Makefile:1182: install] Error 2
-----
ERROR: failed to compile libevent, see 'setup.log' for more detail

The Error2 encountered during the installation of XunSou is, upon testing, primarily caused by a mismatch between the Linux version and the libeven version required for XunSou installation.

Most commonly used Linux distributions currently ship OpenSSL version 1.1.0 or later; however, the installation directory of the XunSearch package contains libeven 2.0.x. This requires OpenSSL version <1.1.0; therefore, this version discrepancy can cause the libeven error (Error 2) during the installation of XunSearch.

The solution involves upgrading XunSearch to version libeven 2.0.x to achieve consistent matching.

Method one:

1. Download the libevent 2.1.12 installation package and upload it to the xunsearch installation folder;

 隐藏内容:登录后可查看

Links:https://pan.baidu.com/s/1xpOfHtNSSydiZldZ8bstnw?pwd=dzqx
code:dzqx
--Sharing from Baidu Netdisk Super Member V4

2. Unzip using libevent (run the following command or use a graphical unzipping tool)

tar -zxvf libevent-2.1.12-stable.tar.gz

3. Compress the file into BZ2 format – this is a format supported by the XunSearch installation package (use the following command or the visual compression tool).

tar -cjf libevent-2.1.12-stable.tar.bz2 libevent-2.1.12-stable

4. Copy the file to the `packages` folder within `xunsearch` (use the following command or perform a visual copy).

cp libevent-2.1.12-stable.tar.bz2 xunsearch-full-1.4.15/packages/

5. Remove the built-in installation package for XunSearch(Use the following command or the visual deletion tool)

cd xunsearch-full-1.4.15/packages/ rm -f libevent-2.0.X

6. Simply rerun the XunSearch installation command.

./setup.sh

Method 2:

I have already modified the Xunsearch package as described in the above steps: simply upload it to the root directory, extract it, and then run the command.

cd xunsearch-full-1.4.17
sh setup.sh

Backup Package Link:

 隐藏内容:登录后可查看

Links:https://pan.baidu.com/s/1PJ4Aw9mxR_hbBE0_b3fZrg?pwd=ibct
code:ibct
--Sharing from Baidu Netdisk Super Member V4

+=================================================+
| Installation completed successfully, Thanks you |
| 安装成功,感谢选择和使用 xunsearch              |
+-------------------------------------------------+
| 说明和注意事项:                                |
| 1. 开启/重新开启 xunsearch 服务程序,命令如下: |
|    /www/server/xunsearch/bin/xs-ctl.sh restart
|    强烈建议将此命令写入服务器开机脚本中         |
|                                                 |
| 2. 所有的索引数据将被保存在下面这个目录中:     |
|    /www/server/xunsearch/data
|    如需要转移到其它目录,请使用软链接。         |
|                                                 |
| 3. 您现在就可以在我们提供的开发包(SDK)基础上    |
|    开发您自己的搜索了。                         |
|    目前只支持 PHP 语言,参见下面文档:          |
|    /www/server/xunsearch/sdk/php/README
+=================================================+
微信赞赏

WeChat

支付宝赞赏

Alipay

✍️ Author: Hong Mu

webmaster · Thanks for reading, stay tuned for more exciting content

Author homepage View home page →

Related articles

Summary of experience in installing sphinx on Linux

Summary of experience in installing sphinx on Linux Program Notes sphinx

1. The installation directory must be located within the same directory as MySQL; the Ptao directory is: /www/server/2. The `etc` folder contains three files: `example.sql`, `sphinx.conf.dist`, and `sphinx-min.conf.dist`. The first file is an MySQL instance file provided for importing your database; using this instance can help you better understand the setup. The second file is for configuration...
👁 351
Can Sphinx PHP perform a single search for multiple terms at once?

Can Sphinx PHP perform a single search for multiple terms at once? Program Notes sphinx

Yes, Sphinx allows you to search for multiple terms in a single query. You can use multiple keywords in your search query to search for text within an index. For example, here is a simple PHP code snippet that uses the Sphinx API to perform a search across multiple keywords: require_once('sphinxapi.php'); // Connect to the Sphinx server $sphinx = new S...
👁 267
How can I use PHP code to import data from a MySQL database?

How can I use PHP code to import data from a MySQL database? Program Notes sphinx

To import data from a MySQL database using Xunsearch, you need to use the Xunsearch PHP extension and its related APIs. Below is a simple example of code – assuming you have already installed Xunsearch and configured the indexing and database connection: <?php // Include the Xunsearch extension require_once '/path/to/xun...';
👁 253
Resource website typecho001 template

Resource website typecho001 template Program Notes Typecho

typecho001 template template please do not modify the folder name of this template. The folder name is: typecho001 1.4 Fix the js output problem on the article page 1.3 Fix the error prompt when the plug-in is not installed Optimize the list page code output 1.2 Fix the comment function and add a custom homepage title 1.1 Fix the comment reply asymmetry function Add a separate title setting function on the homepage Add the website favicon.ico icon Add one...
👁 197
Modification of typecho paging style

Modification of typecho paging style Program Notes Typecho

Sir, times have changed! Typecho is currently the most perfect solution, because Baidu can only see the code of fixed thinking. The actual generated HTML code is breathtakingly clean and fully customized, including adding classes to the li element, adding classes to the a element, adding classes to the previous page and next page, and removing the li tags that come with typecho to express more. I can even add some text to the content inside...
👁 516
Typecho article page comment style modification

Typecho article page comment style modification Program Notes Typecho

When you need to use typecho for template development, the default comment style is ugly. Therefore, comments need to be re-output or styled. The default comment template file path is: comments.php Mainly used related variables<?php $comments->gravatar('40', ''); ?> //Avatar has two parameters, size,...
👁 386

Recommended reading

Empire cms related search call optimization

Empire cms related search call optimization Program Notes Empire cms

Within the Empire framework, I have a new idea: to add a custom table that stores the keywords for all articles and aggregates the corresponding article IDs – essentially creating a search aggregation feature. The advantage of this approach is that it allows you to retrieve articles containing specific keywords directly within the article itself, effectively replacing Empire's built-in related search aggregation functionality! This is because Empire's native related search aggregation feature is too slow – it relies on SQL fuzzy matching and handles datasets of over 100,000 records; if your server performance is suboptimal...
👁 354
(Adaptive Mobile Version) Orange Domestic Services Company – PBootCMS Website Template; Download Source Code for Cleaning and Maintenance Service Websites – 0361

(Adaptive Mobile Version) Orange Domestic Services Company – PBootCMS Website Template; Download Source Code for Cleaning and Maintenance Service Websites – 0361 Practical Collection pbootcms Template

This is an adaptive, mobile-friendly orange-colored PbootCMS website template designed for domestic service companies. Its warm and energetic design is ideal for showcasing service offerings such as housekeeping, cleaning services,保姆 (nanny) services, and postpartum care services. It helps domestic service companies effectively showcase their brand image online and attract customers seeking household services. Template Preview | Installation Instructions | Website Backend: /admin.php | Username: admin | Password: admin | Extraction Password: www.4s5.cn | Related Articles...
👁 45
(Adaptive mobile version) Precision Instrument Website Template – Download Source Code for Instrumentation Websites – 1079

(Adaptive mobile version) Precision Instrument Website Template – Download Source Code for Instrumentation Websites – 1079 Practical Collection pbootcms Template

A PbootCMS website template for precision instrumentation and measuring equipment, compatible with both PC and WAP devices. The professional and sophisticated design is ideal for showcasing precision instrument products and demonstrating technical expertise. It helps instrumentation companies present their products online and attract both research and industrial clients. Template Display | Installation Instructions | Website Backend: /admin.php | Username: admin | Password: admin | Extraction Password: www.4s5.cn...
👁 51
Dryer Mechanical General Website Template 0647

Dryer Mechanical General Website Template 0647 Practical Collection Yiyou template

This EyouCMS template is designed for the general machinery and equipment industry, featuring a professional industrial design style ideal for showcasing drying machine products, mechanical equipment, technical specifications, and industrial applications. It helps machinery manufacturing enterprises showcase their products online and attract industrial customers. Template Display | Installation Instructions | Website Backend: /login.php | Username: admin | Password: admin | Related Articles: Summary of Common Installation Issues for EyouCMS | EyouCMS (...
👁 40
Website optimization adds a music player

Website optimization adds a music player Summary of pitfalls

Plug-in effect: It is used to improve website user experience, such as Baidu ranking. If you install this plug-in, your website's bounce rate may be reduced, which is naturally good for rankings. You know what you know. I had nothing to do today and found a music player website. It only needs a piece of js code to let you play music. It is quite powerful. You only need to go to their website to register and get the js code. So I installed it and played it. The result was not bad, but the main website was too stuck...
👁 155
(Adaptive mobile phone version) Water sports equipment pbootcms website template Diving service company website source code download 0362

(Adaptive mobile phone version) Water sports equipment pbootcms website template Diving service company website source code download 0362 Practical Collection pbootcms Template

A mobile-adaptive PbootCMS website template for water sports equipment and diving services. The design style is refreshing and dynamic, suitable for displaying diving equipment, water sports equipment and training services. Helps outdoor sports companies attract action sports enthusiasts online. Template display Installation instructions Website backend: /admin.php Account: admin Password: admin Decompression password: www.4s5.cn Related articles Pb...
👁 62