阿里云-云小站(无限量代金券发放中)
【腾讯云】云服务器、云数据库、COS、CDN、短信等热卖云产品特惠抢购

Red Hat Enterprise Linux 7.3下Apache安装

280次阅读
没有评论

共计 2246 个字符,预计需要花费 6 分钟才能阅读完成。

一、简介

Apache HTTP Server(简称 Apache)是 Apache 软件基金会的一个开放源码的网页服务器,可以在大多数计算机操作系统中运行,由于其多平台和安全性被广泛使用,是最流行的 Web 服务器端软件之一。它快速、可靠并且可通过简单的 API 扩展,将 Perl/Python 等解释器编译到服务器中。

二、准备

1、环境

系统平台:Red Hat Enterprise Linux Server release 7.3 (Maipo)

内核版本:3.10.0-514.el7.x86_64

2、下载 APR 和 APR-Util 包

http://apr.apache.org/download.cgi

3、下载 pcre 包

https://sourceforge.net/projects/pcre/files/pcre/

4、下载 apache 包

http://httpd.apache.org/download.cgi#apache24

三、安装

按照官方文档的要求,必须安装 APR、APR-Util、PCRE,gcc-c++ 等包,文档 URL 地址 http://httpd.apache.org/docs/2.4/install.html

1、安装 gcc 相关依赖

# yum -y install  gcc*

2、安装 apr

# tar zxvf apr-1.5.2.tar.gz

# cd apr-1.5.2

# ./configure –prefix=/usr/local/apr

# make

# make install

Red Hat Enterprise Linux 7.3 下 Apache 安装

3、安装 apr-util

 # tar zxvf apr-util-1.5.4.tar.gz

# cd apr-util-1.5.4

# ./configure –prefix=/usr/local/apr-util –with-apr=/usr/local/apr/bin/apr-1-config

# make

# make install

Red Hat Enterprise Linux 7.3 下 Apache 安装

4、安装 pcre

# tar zxvf pcre-8.38.tar.gz

# cd pcre-8.38

# ./configure –prefix=/usr/local/pcre –with-apr=/usr/local/apr/bin/apr-1-config

# make

# make install

Red Hat Enterprise Linux 7.3 下 Apache 安装

5、安装 apache

# tar zxvf httpd-2.4.23.tar.gz

# cd httpd-2.4.23

# ./configure –prefix=/usr/local/apache –with-pcre=/usr/local/pcre –with-apr=/usr/local/apr –with-apr-util=/usr/local/apr-util

# make

# make install

6、测试是否安装成功

查看 apache 版本

Red Hat Enterprise Linux 7.3 下 Apache 安装

四、启动

1、启动命令

# /usr/local/apache/bin/apachectl start

Red Hat Enterprise Linux 7.3 下 Apache 安装

2、访问测试

Red Hat Enterprise Linux 7.3 下 Apache 安装

更多 Apache 相关教程见以下内容

CentOS6.8 编译安装 Apache2.4.25、MySQL5.7.16、PHP5.6.29  http://www.linuxidc.com/Linux/2016-12/138993.htm

CentOS 6.6 下安装 Apache 2.2.31 http://www.linuxidc.com/Linux/2017-02/140803.htm

Apache 配置多站点访问及二级域名配置  http://www.linuxidc.com/Linux/2017-03/141339.htm

Ubuntu 16.04 LTS 安装 Apache2+PHP7.0+MySQL+phpMyAdmin 图文详解  http://www.linuxidc.com/Linux/2017-02/140098.htm

CentOS 6 下 Apache 和 Tomcat 整合  http://www.linuxidc.com/Linux/2017-04/143021.htm

Apache 启用 gzip 压缩模块节约网站带宽  http://www.linuxidc.com/Linux/2017-04/142821.htm

Apache 配置 https  http://www.linuxidc.com/Linux/2017-02/140801.htm

使用 Apache 搭建 Web 网站服务器  http://www.linuxidc.com/Linux/2017-05/143468.htm

Linux 下 Apache 安装及实例  http://www.linuxidc.com/Linux/2017-02/140800.htm

Apache2.4.6 服务器安装及配置  http://www.linuxidc.com/Linux/2017-01/140006.htm

Ubuntu 16.04 下搭建 Web 服务器(MySQL+PHP+Apache) 教程  http://www.linuxidc.com/Linux/2017-01/139570.htm

CentOS 7 下 Apache 2.4.18 编译安装详解  http://www.linuxidc.com/Linux/2017-03/142003.htm

Linux 下编译安装 Apache httpd 服务器  http://www.linuxidc.com/Linux/2017-08/146567.htm 

本文永久更新链接地址:http://www.linuxidc.com/Linux/2017-05/143939.htm

正文完
星哥说事-微信公众号
post-qrcode
 0
星锅
版权声明:本站原创文章,由 星锅 于2022-01-21发表,共计2246字。
转载说明:除特殊说明外本站文章皆由CC-4.0协议发布,转载请注明出处。
【腾讯云】推广者专属福利,新客户无门槛领取总价值高达2860元代金券,每种代金券限量500张,先到先得。
阿里云-最新活动爆款每日限量供应
评论(没有评论)
验证码
【腾讯云】云服务器、云数据库、COS、CDN、短信等云产品特惠热卖中