源码安装apache 2.4.29-kanglidebj的博客
安装 apr apr-until prce安装apache的依赖程序。https://www.cnblogs.com/visec479/p/5160297.html
# wget http://mirrors.shu.edu.cn/apache/httpd/httpd-2.4.29.tar.gz 下载apache软件包
# mkdir -p /application/apache2.4.29
#tar -zxvf httpd-2.4.29.tar.gz
# cd httpd-2.4.29
# ./configure \
--prefix=/application/apache2.4.29 \
--with-apr=/usr/local/apr \
--with-apr-util=/usr/local/apr-util/ \
--with-pcre=/usr/local/pcre \
--enable-deflate \
--enable-expires \
--enable-headers \
--enable-modules=most \
--enable-so \
--with-mpm=worker \
--enable-rewrite
#make 编译
#make install 安装
# cd /application/ 切换目录
# ln -s /application/apache2.4.29/ /application/apache 添加软连接
# ll /application/
total 4
lrwxrwxrwx.1 root root 25 Apr3 21:24 apache -> /application/apache2.4.29
drwxr-xr-x. 14 root root 4096 Apr3 21:34 apache2.4.29
#
# /application/apache/bin/apachectl start 启动apache
# ps -ef |grep http 检查apache的启动
root 32129 10 21:29 ? 00:00:00 /application/apache2.4.29/bin/httpd -k start
daemon 32130 321290 21:29 ? 00:00:00 /application/apache2.4.29/bin/httpd -k start
daemon 32131 321290 21:29 ? 00:00:00 /application/apache2.4.29/bin/httpd -k start
daemon 32132 321290 21:29 ? 00:00:00 /application/apache2.4.29/bin/httpd -k start
root 3223312070 21:35 pts/0 00:00:00 grep http
# /etc/init.d/iptables stop 关闭防火墙,用浏览器访问电脑,看是否可以访问。
#
页:
[1]