二进制编译安装

1.先将httpd-2.4.34.tar.gz文件添加到Xshell里面
2.安装编译文件和库
yum install -y apr autoconf automake bison bzip2 bzip2 cloog-ppl compat cpp curl curl-devel fontconfig fontconfig-devel freetype freetype freetype-devel gcc gcc-c++ gtk+-devel gd gettext gettext-devel glibc kernel kernel-headers keyutils keyutils-libs-devel krb5-devel libcom_err-devel libpng libpng-devel libjpeg libsepol-devel libselinux-devel libstdc++-devel libtool libgomp libxml2 libxml2-devel libXpm libtiff libtiff make mpfr ncurses ntp openssl openssl-devel patch pcre-devel perl php-common php-gd policycoreutils telnet t1lib t1lib nasm nasm* wget zlib-devel
3.安装相应的包
yum install apr apr-util apr-devel apr-util-devel
4.解压文件
tar jxf http-2.4.34.tar.gz
5.预编译文件安装目录
cd http-2.4.34
./configure --prefix=usr/local/apache2 --disable-proxy
6.进行:make && make install
7.安装的文件放在了 /usr/local/apache2目录下
cd /usr/local/apache2
8.启动服务
/usr/local/apache2/bin/apachectl start
9.查看进程
ps -ef | grep httpd
10.清空防火墙
iptables -F/X/L
11.网页访问 (ip)

猜你喜欢

转载自blog.51cto.com/13958204/2174279