编译安装http-2.4.10

编译安装http-2.4.10:

一、安装开发工具:

# yum groupinstall -y "Development Tools" "Server Platform Development"

lftp 172.16.0.1:/pub/Sources/sources/httpd>

下载这3个包:

mget apr-1.5.0.tar.bz2

apr-util-1.5.3.tar.bz2

httpd-2.4.10.tar.bz2

最好是以上面的顺序进行编译安装:

# tar xf apr-1.5.0.tar.bz2

# cd apr-1.5.0

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

# make && make install

# cd

# tar xf apr-util-1.5.3.tar.bz2

# cd apr-util-1.5.3

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

# make && make install

# cd

# tar xf httpd-2.4.10.tar.bz2

# cd httpd-2.4.10

# ./configure --help | less

安装这两个兼容包:

# yum install  pcre-devel  zlib-devel -y

# ./configure --prefix=/usr/local/apache --sysconfdir=/etc/httpd24 --enable-so --enable-ssl --enable-cgi --enable-rewrite --with-zlib --with-pcre --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr-util/ --enable-modules=most --enable-moms-shared=all --with-mom=event

# make && make install

# vim /etc/profile.d/httpd.sh

添加一行: export PATH=/usr/local/apache/bin:$PATH

# . /etc/profile.d/httpd.sh

# apachectl start

# ss -tnl

此时80端口已经被打开;

现在可以通过浏览器访问网站了:172.16.8.101

# ln -sv /usr/local/apache/include /usr/include/httpd

# vim /etc/man.config 把http的man手册添加到主man手册文件中;

添加:MANPATH /usr/local/apache/man

# mkdir /data/web/htdocs -pv

# vim /data/web/htdocs/index.html

添加:<h1>Hello  World</h1>

把主配置文件做一下备份(为以后还原做好准备工作):

# cp /etc/httpd24/httpd.conf /etc/httpd24/httpd.conf.bak

# vim /etc/httpd24/httpd.conf

修改为:DocumentRoot "/data/web/htdocs"

<Directory "/data/web/htdocs">

# killall -SIGHUP httpd

此时重新登录浏览器里:输入 172.16.8.101  就可以看到我们刚刚新建的内容了;

增加httpd24的服务脚本:

# cd /etc/rc.d/init.d/

# cp httpd httpd24

# vim httpd24

修改为:

apachectl=/usr/local/apache/bin/apachectl

httpd=${HTTPD-/usr/local/apache/bin/httpd}

pidfile=${PIDFILE-/usr/local/apache/logs/httpd.pid}

# ll httpd24  查看 是否有执行权限;

# chkconfig --add httpd24

# chkconfig --list httpd24

# chkconfig httpd24 on

# service httpd24 start

# ss -tnl

此时编译安装的http-2.4.10 就可以正常使用了;

时间: 2024-08-27 02:53:08

编译安装http-2.4.10的相关文章

centos 6.5源码编译安装subversion 1.8.10

一.简介 CentOS 6.5的yum源可以安装的SVN客户端版本太低了,1.6.11,所以需要升级到1.8.10,而官网有没有找到1.8.10的安装包,只能选择源码编译安装. 二.安装步骤 参考官网:http://svn.apache.org/repos/asf/subversion/trunk/INSTALL 源码下载:http://archive.apache.org/dist/subversion/ 源码编译subversion依赖许多别的工具,比如:apr.apr-util.libto

CentOS 5.9编译安装配置mysql-5.6.10

说明:操作系统:CentOS 5.9 64位MySQL版本:mysql-5.6.10MySQL安装目录:/usr/local/mysqlMySQL数据库存放目录:/data/mysql准备篇:一.配置好IP.DNS .网关,确保使用远程连接工具能够连接服务器,服务器yum命令可以正常使用二.配置防火墙,开启3306端口vi /etc/sysconfig/iptables  #编辑-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp -

CentOS6.5-源码编译安装最新MySQL5.7.10

接着使用YUM方式安装mysql后,本文将介绍下在CentOS6.5 64位虚拟机上通过编译源码安装MYSQL5.7.10服务. 环境: OS: CentOS6.5 x86_64 最小化安装 CPU: 1 MEM: 1G 注:上面的CPU/MEM参数太小了,编译时间会很长,很长... 1. 准备编译安装依赖环境 shell> yum install gcc gcc-c++ cmake ncurses ncurses-devel -y # 5.7.5后,依赖boost工具,GEO支持 shell>

在win7系统上,使用3台CentOS 6, (编译安装http2.4、php、mysql)

实验要求:搭建lamp (1) 三者分离于三台主机: (2) 一个虚拟主机用于提供phpMyAdmin:另一个虚拟主机用于提供wordpress: (3) xcache (4) mpm为worker机制: 物理机使用win7系统,在VMware虚拟机中准备了3台centos6.7的linux系统: 其中IP地址设计: web服务器地址为:192.168.255.60 php服务器地址为:192.168.255.61 mysql数据库服务器地址为:192.168.255.62 分别在每台服务器上编

64bit centos 6.5 编译安装 LAMP 环境

MySQL5.5.40 编译安装 请参考 MySQL5.5.40编译安装 Apache 2.4.10 编译安装 请参考 Apache 2.4.10 编译安装 PHP 5.4.33 编译安装 下面我们开始编译安装PHP5.4.33 首先下载源码包到用户目录下, 下载PHP5.4.33 也可以使用命令行下载: [[email protected] ~]# wget http://kr1.php.net/get/php-5.4.33.tar.bz2/from/this/mirror 然后解压源码 [[

CentOS 6.9编译安装新版本内核

一.编译安装前准备: 1.安装依赖包组:# yum -y groupinstall "Server Platform Development""Development Tools" 2.从https://www.kernel.org/下载需要编译的内核源码包linux-3.10.105.tar.xz,并上传至服务器 二.编译安装新版本内核linux-3.10.105.tar.xz: 1.查看系统原有内核版本:# uname -r  -->  2.6.32-69

数据库的编译安装

MySQL编译安装 camke定制功能:存储引擎.字符集.压缩定制安装位置.数据存放位置.文件位置(socket) 使用CentOS6 -- IP 10.0.0.52 主机名db021.下载5.6.36包(这里本文使用的是5.6.36,比较稳定一点) wget -q http://mirrors.sohu.com/mysql/MySQL-5.6/mysql-5.6.36.tar.gz 2.修改epel源 wget -O /etc/yum.repos.d/epel.repo http://mirr

16、编译安装bind 9.10.6及queryperf性能测试 学习笔记

1.安装开发环境 [[email protected] ~]# yum -y groupinstall "Server Platform Development" "Development tools" 2.编译安装bind [[email protected] ~]# tar xf bind-9.10.6.tar.gz [[email protected] ~]# cd bind-9.10.6 [[email protected] bind-9.10.6]# ./

CentOS6.8编译安装Nginx1.10.2+MySQL5.7.16+PHP7.0.12

1.    下载 #MySQL下载地址 http://dev.mysql.com/downloads/mysql/ #Nginx下载地址 http://nginx.org/en/download.html #PHP下载地址 http://php.net/downloads.php 使用WinSCP把下载好的压缩包上传到/usr/local/src目录 mysql-5.7.16.tar.gz nginx-1.10.2.tar.gz php-7.0.12.tar.gz 2.    安装 2.1