To sum up the process of installing Apache2.4.1 in Ubuntu12.04LTS. Assume that the installation path is "/usr/local/Apache ". To install Apache2.4.1, you must first prepare three modules: apr, apr-util, and pcre: apr and apr-util, which are downloaded from http://apr.apache.org/download.cgi. The current apr version is 1.4.6apr-u.
To sum up the process of installing Apache 2.4.1 In Ubuntu 12.04 LTS.
Assume that the installation path is "/usr/local/Apache ".
To install Apache 2.4.1, you must first prepare three modules: apr, apr-util, and pcre.
:
Both apr and apr-util are downloaded from http://apr.apache.org/download.cgi.
The current apr version is 1.4.6.
The current apr-util version is 1.4.1.
Download pcre from http://www.pcre.org
The current version is 8.30
# Apr Installation
Tar-zxvf./apr-1.4.6.tar.gz
Cd apr-1.4.6/
Sudo./configure -- prefix =/usr/local/Apache/apr
Make
Sudo make install
# Apr-util Installation
Tar-zxvf./apr-util-1.4.1.tar.gz
Sudo./configure -- prefix =/usr/local/Apache/apr-util -- with-apr =/usr/local/Apache/apr
Make
Sudo make install
# Pcre Installation
Sudo. /configure -- prefix =/usr/local/Apache/pcre -- with-apr =/usr/local/Apache/apr -- with-apr-util =/usr/local/Apache/ apr-util
Make
Sudo make install
If an error occurs during make,
Run
Sudo apt-get install g ++
Sudo apt-get install build-essential
Then make is OK.
# Finally install apache
Sudo. /configure -- prefix =/usr/local/Apache -- enable-so -- enable-modes-shared = all -- with-apr =/usr/local/Apache/apr -- with-apr -util =/usr/local/Apache/apr-util -- with-pcre =/usr/local/Apache/pcre -- enable-rewrite
Make
Sudo make
It takes a little longer to compile apache.
Verification results:
Sudo./apachectl start
Open the browser access url and return
It works!
End.
For more information about Ubuntu, see Ubuntu special page http://www.linuxidc.com/topicnews.aspx? Tid = 2