Apache installation process
Step 1: Install the package gcc or gcc-c++
# yum Install gcc
#yum Install gcc-c++
Step 2: Install packages Apr and Apr-util
Apr-1.4.8.tar.gz apr-util-1.5.2.tar.gz
# TAR-ZXF Apr-1.4.8.tar.gz
# CD apr-1.4.8
Create a new directory/USR/LOCAL/APR to use as the installation directory:
# MKDIR/USR/LOCAL/APR
#./configure--PREFIX=/USR/LOCAL/APR
# make
# make Install
Installing Apr-util
#./configure--prefix=/usr/local/apr-util--WITH-APR=/USR/LOCAL/APR
# make
# make Install
Step 3: Installation package Prce
# CD pcre-8.33
#mkdir/usr/local/pcre
./configure--prefix=/usr/local/apache--WITH-APR=/USR/LOCAL/APR--with-apr-util=/usr/local/apr-util
# make
# make Install
Step 4: Install Apache Http Server
# tar ZXVF httpd-2.4.6.tar.gz
#cd httpd-2.4.6
#./configure--prefix=/opt/data/apache2 \
--ENABLE-SO \
--enable-mods-shared=most \
--with-mpm=worker \
--WITH-APR=/USR/LOCAL/APR \
--with-apr-util=/usr/local/apr-util \
--WITH-INCLUDED-APR \
--with-pcre=/usr/local/pcre \
#make
#make Install
Step 5: Start the Apache service
#/opt/data/apache2/bin/apachectl start
Prompt it works! when accessing http://localhost with a browser
Start Error:
#/usr/local/apache/bin/apachectl Start
AH00558:httpd:Could not reliably determine the server ' s fully qualified domain name, using getlnx05.gfg1.esquel.com. Set the ' ServerName ' directive globally to suppress this message
This time you need to edit the httpd.conf configuration file and add the specific IP address of the seravername.
Seravername 192.168.1.123:80
If you are accessing Apache from another computer, enter the URL address: HTTP://IP page does not show normal, and the above configuration is OK, then you must shut down the firewall, sometimes even need to restart the computer to OK, restart Apache service is not valid.
# chkconfig Iptables off
# chkconfig Iptables off
#/usr/local/apache/bin/apachectl Restart
Compile and install under apache-rhel5.8 environment