1、卸载apr、apr-util
  [root@centos6 LAMP]# yum remove apr apr-util

2、编译安装apr-1.5.1.tar.gz
  [root@centos6 LAMP]# tar zxvf apr-1.5.1.tar.gz
  [root@centos6 LAMP]# cd apr-1.5.1
  [root@centos6 apr-1.5.1]# ./configure --prefix=/usr/local/lamp/apr-httpd
  [root@centos6 apr-1.5.1]# make
  [root@centos6 apr-1.5.1]# make install

3、编译安装apr-util-1.5.4.tar.gz
  [root@centos6 LAMP]# tar zxvf apr-util-1.5.4.tar.gz
  [root@centos6 LAMP]# cd apr-util-1.5.4
  [root@centos6 apr-util-1.5.4]# ./configure --prefix=/usr/local/lamp/apr-util-httpd --with-apr=/usr/local/lamp/apr-httpd
  [root@centos6 apr-util-1.5.4]# make
  [root@centos6 apr-util-1.5.4]# make install

4、编译安装pcre-8.35.zip
  [root@centos6 LAMP]# unzip -o pcre-8.36.zip
  [root@centos6 LAMP]# cd pcre-8.36
  [root@centos6 pcre-8.36]# ./configure --prefix=/usr/local/lamp/pcre
  [root@centos6 pcre-8.36]# make
  [root@centos6 pcre-8.36]# make install

5、编译安装apache
  [root@centos6 LAMP]# tar -zxvf httpd-2.4.10.tar.gz
  [root@centos6 LAMP]# cd httpd-2.4.10
  [root@centos6 httpd-2.4.10]# ./configure --prefix=/usr/local/lamp/apache --enable-mods-shared=all --enable-deflate --enable-speling --enable-cache  --enable-file-cache --enable-disk-cache --enable-mem-cache --enable-so --enable-expires=shared --enable-rewrite=shared --enable-static-support --sysconfdir=/etc/httpd
--with-z=/usr/local/lamp/zlib --with-apr=/usr/local/lamp/apr-httpd --with-apr-util=/usr/local/lamp/apr-util-httpd --with-pcre=/usr/local/lamp/pcre/ --disable-userdir
  [root@centos6 httpd-2.4.10]# make && make instal

6、修改配置
  [root@centos6 httpd-2.4.10]# vi /etc/httpd/httpd.conf

  修改成 ServerName localhost:80

7、启动apache
  [root@centos6 httpd-2.4.10]# /usr/local/apache/bin/apachectl start

  浏览器访问本机IP地址,出现It works!,就OK了!

8、做成服务  [root@localhost apache]# echo "/usr/local/lamp/apache/bin/apachectl start" >> /etc/rc.d/rc.local
  [root@centos6 LAMP]# /usr/local/lamp/apache/bin/apachectl start
  [root@centos6 LAMP]# cp /usr/local/lamp/apache/bin/apachectl /etc/init.d/httpd
  [root@centos6 LAMP]# chmod +x /etc/init.d/httpd
  [root@centos6 ~]# chkconfig --add httpd
  注意:如果提示service httpd does not support chkconfig错误,解决办法:编辑/etc/rc.d/init.d/httpd在文件第二行加入         
    #chkconfig:2345 10 90
    #description:Activates/Deactivates Apache Web Server
  [root@centos6 ~]# chkconfig --level 2345 httpd on
  [root@centos6 LAMP]# service httpd restart

CentOS6.5安装LAMP环境APACHE的安装的更多相关文章

  1. CentOS 7.4 yum安装LAMP环境

    配置防火墙,开启80.3306端口.CentOS 7.0默认使用的是firewall作为防火墙,这里改为iptables防火墙. #停止firewall服务 systemctl stop firewa ...

  2. ubuntu下安装lamp环境

    使用普通用户来安装lamp环境: 1.安装apache: sudo apt-get install apache2

  3. CentOS6.5下编译安装LAMP环境

    LAMP(Linux-Apache-MySQL-PHP)网站架构是目前国际流行的Web框架.该框架能够满足大流量.大并发量的网站需求:当然.也可以直接使用高性能的服务器.高性能的负载均衡硬件以及CDN ...

  4. Centos6.5添加Epel和Remi源安装Lamp环境

    想搭建一个Lamp环境,因为编译安装太麻烦,对于我这样的新手来说,太过于复杂.而CentOS自带的Apache.MySql和PHP的版本都太低,不想用.上百度搜了一轮,原来可以通过添加Epel和Rem ...

  5. 转:CentOS/Debian/Ubuntu一键安装LAMP(Apache/MySQL/PHP)环境

    CentOS/Debian/Ubuntu一键安装LAMP(Apache/MySQL/PHP) 今天遇到一个网友提到需要在Linux VPS服务器中安装LAMP(Apache/MySQL/PHP)网站环 ...

  6. CentOS 6.3下源码安装LAMP(Linux+Apache+Mysql+Php)环境【转载】

    本文转载自 园友David_Tang的博客,如有侵权请联系本人及时删除,原文地址: http://www.cnblogs.com/mchina/archive/2012/11/28/2778779.h ...

  7. CentOS6.3 编译安装LAMP(2):编译安装 Apache2.2.25

    所需源码包: /usr/local/src/Apache-2.2.25/httpd-2.2.25.tar.gz 编译安装 Apache2.2.25 #切换到源码目录 cd /usr/local/src ...

  8. CentOS 6.5系统使用yum方式安装LAMP环境和phpMyAdmin详细过程

    介绍如何在CentOs6.2下面使用YUM配置安装LAMP环境,一些兄弟也很喜欢使用编译的安装方法,个人觉得如果不是对服务器做定制,用yum安装稳定简单,何必去download&make&am ...

  9. CentOS 6.5系统使用yum方式安装LAMP环境和phpMyAdmin,mysql8.0.1/mysql5.7.22+centos7,windows mysql安装、配置

    介绍如何在CentOs6.2下面使用YUM配置安装LAMP环境,一些兄弟也很喜欢使用编译的安装方法,个人觉得如果不是对服务器做定制,用yum安装稳定简单,何必去download&make&am ...

随机推荐

  1. 数据结构——N皇后放置方法种数

    Description 在N*N的方格棋盘放置了N个皇后,使得它们不相互攻击(即任意2个皇后不允许处在同一排,同一列,也不允许处在与棋盘边框成45角的斜线上. 你的任务是,对于给定的N,求出有多少种合 ...

  2. vijosP1603迷宫

    vijosP1603迷宫 链接:https://vijos.org/p/1603 [思路] 参考Matrix67的文章: [代码] #include<cstdio> #include< ...

  3. Prime Ring Problem(搜索)

    http://acm.hdu.edu.cn/showproblem.php?pid=1016 / 题意; 给你一个数n ,求出所有的排列 这些排列的特征是任意相邻的两数只和是素数,而且首位只和也是素数 ...

  4. 分页过滤SQL求总条数SQL正则

    public static void main(String[] args) throws Exception { String queryForScanUsers_SQL = "selec ...

  5. AngularJS测试二 jasmine测试路由 控制器 过滤器 事件 服务

    测试应用 1.测试路由 我们需要检测路由是否在运作,是否找到了,或者是404了.我们要确认路由事件触发了,预期的模板是否真的加载了.既然路由会改变页面的地址(URL)和页面内容,我们需要检测路由是否被 ...

  6. npm常用命令总结

    p.p1 { margin: 0.0px 0.0px 0.0px 0.0px; font: 11.0px Menlo; color: #000000; background-color: rgba(2 ...

  7. js~一个列表中包含上移下移删除等功能

    最近做了一个项目,包括了一个列表页,为了用户体验,操作均使用JS实现,其中包括在列表中实现上移,下移,删除等功能,前台JS,后端数据修改使用AJAX,本文主要说一下前台JS这块 先看一下页面的截图

  8. motan源码分析十:流量切换

    motan提供了流量切换的功能,可以实现把一个group的流量切换到另一个group(一个或多个服务都可以).大家可以使用tomcat部署motan的管理工具,并设置几个组,例如可以参考demo代码: ...

  9. OpenGL ES2.0基础入门

    1.OpenGL ES 1.x渲染管线(又称为渲染流水线) (1).基本处理: 基本处理主要是设定3D空间中物体的顶点坐标.顶点对应的颜色.顶点的纹理坐标等属性,并且指定绘制方式. 常见的绘制方式有: ...

  10. js判断字符串是否包含指定的字符

    判断字符串是否包含指定字符是很常用的功能,比如说,注册时用户名限制不能输入"管理员",或者需要js判断url跳转链接是否包含某个关键词等-- <!DOCTYPE html&g ...