第一步:php
作以前先删掉httpd yum remove httpdlinux
查看服务启动状态 systemctl starus httpdc++
关闭服务 systemctl stop httpdapache
安装编译工具及库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-develcurl
第二步:Ls 查看工具
第三步:url
安装相应的包 yum install apr apr-util apr-devel apr-util-develspa
解压文件 tar xzf httpd-2.4.34.tar.gzxml
cd httpd-2.4.34目录下 编译安装目录 ./configure --prefix=/usr/local/apache2 --disable-proxyblog
第四步:进行 make && make install
第五步:
安装的文件放在/usr/local/apache2
ls查看
第六步:
启动服务 /usr/local/apache2/bin/apachectl start
查看进程 ps -ef | grep httpd
第七步:清空防火墙设置 iptables -F
iptables -X
iptables -L
第八步:输入ip进行网页访问