Apache is the name of a foundation, HTTPD is the package that we want to install, earlier its name is Apache
Apache official website www.apache.org
wget http://mirrors.cnnic.cn/apache/httpd/httpd-2.4.26.tar.gz
wget http://mirrors.hust.edu.cn/apache/apr/apr-1.5.2.tar.gz
wget http://mirrors.hust.edu.cn/apache/apr/apr-util-1.5.4.tar.gz
Apr and Apr-util are a common library of functions that allow httpd to be easily ported (from Linux to Windows) and 2.4 dependent on APR, without caring for the underlying operating system platform. The difference is Apr.
Tar zxvf httpd-2.4.26.tar.gz
Tar zxvf apr-util-1.5.4.tar.gz
Tar zxvf apr-1.5.2.tar.gz
cd/usr/local/src/apr-1.5.2
./configure--PREFIX=/USR/LOCAL/APR
Make && make install
Can customize module installation
cd/usr/local/src/apr-util-1.5.4
./configure--prefix=/usr/local/apr-util--WITH-APR=/USR/LOCAL/APR
Make && make install
cd/usr/local/src/httpd-2.4.27
./configure \//The backslash here is a caret, plus it allows us to write a line of commands into multiple lines
--prefix=/usr/local/apache2.4 \
--WITH-APR=/USR/LOCAL/APR \
--with-apr-util=/usr/local/apr-util \
--ENABLE-SO \
--enable-mods-shared=most
Make && make install
View All Modules
Ls/usr/local/apache2.4/modules
/USR/LOCAL/APACHE2.4/BIN/HTTPD-M//View loaded Modules
Linux9.3 Apache Installation