Apache2.4.2 compile installation 2 common errors and Solutions _linux

Source: Internet
Author: User

Trying out a new version of Apache, the first major update since 2005, not only has the gene added to cloud computing significantly improved performance, I/O read-write and memory-footprint optimization is greater, mainly by adding a enevt mode, which results in a good test.

Actually I tested the simple compiled static file and the Nginx processing performance, indeed, the test is a small difference, testing is the use of AB test, a single nginx and Apache test data obtained after comparison of the results, the next time the system test to send test data, temporarily only tested JPG images and HTML static files The data may not be representative.

The following compile-time, common errors are posted:

Error One:

Copy Code code as follows:
rotatelogs.o:in function Post_rotate ':
ROTATELOGS.C: (. text+0x5ed): Undefined reference to Apr_file_link '
Collect2:ld returned 1 exit status
MAKE[2]: * * * [rotatelogs] Error 1
MAKE[2]: Leaving Directory/root/src/httpd-2.4.2/support '
MAKE[1]: * * * [all-recursive] Error 1
MAKE[1]: Leaving Directory/root/src/httpd-2.4.2/support '
Make: * * * [all-recursive] Error 1

This is because there's no apr bag.

There are 2 solutions:

The first solution:

Copy Code code as follows:
Yum Remove "apr*"
wget http://ftp.jaist.ac.jp/pub/apache/apr/apr-1.4.6.tar.gz
Tar xzf apr-1.4.6.tar.gz
CD apr-1.4.6
./configure; make; Make install
wget http://ftp.jaist.ac.jp/pub/apache/apr/apr-util-1.4.1.tar.gz
Tar zxvf apr-util-1.4.1.tar.gz
CD apr-util-1.4.1
./configure–with-apr=/usr/local/apr
Yum install-y pcre-devel lua-devel libxml2-devel

The second solution:
After the ARP package is downloaded the CP to httpd folder
Copy Code code as follows:
Cp-r apr-1.4.6 HTTPD-2.4.2/SRCLIB/APR
Cp-r apr-util-1.4.1 Httpd-2.4.2/srclib/apr-util

It's going to work out.

The second common error is that only the mini installation will appear most of the rookie will not install Devel package

Copy Code code as follows:
Checking for OpenSSL version >= 0.9.7 ... FAILED
Configure:WARNING:OpenSSL version is too old
No
Checking whether to enable Mod_ssl ... Configure:error:mod_ssl has been requested but can not is built due to prerequisite Failures

Solutions

Copy Code code as follows:
Yum Install Openssl-devel
Yum Update OpenSSL

Recently ready to upgrade all servers to httpd 2.4.2 for better performance

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.