CentOS 6.2 二进制安装apache2.4.3出现configure: error: APR-util not found. Please read the documentation的解决方
CentOS 6.2 二进制安装apache2.4.3出现configure: error: APR-util not found. Please read the documentation的解决方
一。准备环境
1.安装gcc
[root@localhost /]# yum install gcc gcc-c++
2.安装apr,apr-util
下载apr-1.4.6.tar.gz与apr-util-1.5.1.tar.gz,地址:http://apr.apache.org ,上传至/usr/local,安装目录分别为/usr/local/apr 与/usr/local/apr-util
a.安装apr-1.4.6.tar.gz
[root@localhost local]# mkdir -p apr
[root@localhost local]# tar -zxf apr-1.4.6.tar.gz
[root@localhost local]# cd apr-1.4.6
[root@yahoo apr-1.4.6]# ./configure --prefix=/usr/local/apr
[root@yahoo apr-1.4.6]# make
[root@yahoo apr-1.4.6]# make install
b.安装apr-util-1.5.1.tar.gz
[root@localhost local]# mkdir -p apr-util
[root@localhost local]# tar -zxf apr-util-1.5.1.tar.gz
[root@localhost local]# cd apr-util-1.5.1
[root@yahoo apr-util-1.5.1]# ./configure --prefix=/usr/local/apr-util -with-apr=/usr/local/apr/bin/apr-1-config
[root@yahoo apr-util-1.5.1]# make
[root@yahoo apr-util-1.5.1]# make install
3.安装pcre-8.20.tar.gz
下载地址:http://sourceforge.net/projects/pcre/files/pcre/ ,上传至/usr/local,安装目录为/usr/local/pcre
[root@localhost local]# mkdir -p pcre
[root@localhost local]# tar -zxf pcre-8.20.tar.gz
[root@localhost local]# cd pcre-8.20
[root@yahoo pcre-8.20]# ./configure --prefix=/usr/local/pcre
[root@yahoo pcre-8.20]# make
[root@yahoo pcre-8.20]# make install
二。安装apache
1.下载httpd-2.4.3.tar.gz,地址是:http://httpd.apache.org/ ,上传至/usr/local,安装目录为/usr/local/apache2
2.安装
[root@localhost local]# mkdir -p /usr/local/apache2
[root@localhost local]# tar zxvf httpd-2.4.3.tar.gz
[root@localhost local]# cd httpd-2.4.3
[root@localhost httpd-2.4.3]# ./configure --prefix=/usr/local/apache2 --with-pcre=/usr/local/pcre --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr-util
[root@localhost httpd-2.4.3]# make
[root@localhost httpd-2.4.3]# make instll
用浏览器访问http:localhost,看到It works!,说明CentOS Apache安装成功了,恭喜您!
3.启动
第一种方法[root@localhost apache2]# /usr/local/apache2/bin/apachectl start
第二种方法[root@localhost apache2]#service httpd start
第二种方法[root@localhost apache2]#/etc/init.d/httpd start
三。安装出现的问题
1.configure: error: no acceptable cc found in $PATH
解决办法:yum install gcc gcc-c++
2.configure: error: APR not found. Please read the documentation.
解决方法:安装Apache的关联软件
如上安装apr-1.4.6.tar.gz
3.configure: error: APR-util not found. Please read the documentation
解决方法:安装apr-util
如上安装apr-util-1.5.1.tar.gz
4.configure: error: APR version 1.3.0 or later is required
主要是因为apr版本过低造成的,应该卸载相关旧版本
5. 启动时报错:
AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1. Set the 'ServerName' directive globally to suppress this message
解救办法:绝对路径即可:/usr/local/apache2/bin/apachectl start
四。重要配置文件目录
/etc/httpd/conf/httpd.conf 最主要的配置文件
/usr/lib/httpd/modules:apache 支持很多的模块,所以你想要使用的模块默认都放置在此目录
/var/log/httpd apache默认的log
/var/www/html cenos默认的首页所在目录
五。配置apache,最后修改httpd.conf,使apache能使用php
增加如下参数
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
AddType image/x-icon .ico
DirectoryIndex index.php index.html index.html.var
CentOS 6.2 二进制安装apache2.4.3出现configure: error: APR-util not found. Please read the documentation的解决方的更多相关文章
- CentOS 7 离线环境安装nginx时报错:./configure: error: C compiler cc is not found
先说解决方法: 在nginx目录下,查看objs/autoconf.err文件,该文件记录了具体的错误信息 vi objs/autoconf.err 一般就是缺少一些文件,因为我的gcc.g++也是离 ...
- Linux二进制安装apache2.4.25
Linux二进制安装apache2.4.25 安装环境:CentOS 6.2 先检查是否安装了Apache 如通是通过rpm包安装的话直接用下面的命令:rpm -q httpd 也可以使用如下两种方法 ...
- CentOS下源码安装Apache2.4+PHP5.4+MySQL5.5
一.准备(把所有的源文件放在‘/home/yuanjun’目录下) apr http://mirror.bjtu.edu.cn/apache/apr/apr-1.4.6.tar.gz apr-util ...
- centos 7.3二进制安装mariadb10.2.8完美步骤
(1)在centos7系统上,yum info mariadb可以找到提供mariadb包的官方网站,在到官方网站下载最新的mariadb包,然后rz到linux系统上去 (2)准备用户 1.user ...
- Centos下安装apahce的configure: error: APR not found. Please read the documentation解决办法
今天从Apache官网上http://httpd.apache.org/下载httpd web服务器,由于我的虚拟机上之前安装过,我先yum remove httpd进行卸载,然后重新安装.我采用的是 ...
- 转 Centos下安装apahce的configure: error: APR not found. Please read the documentation解决办法
转自: http://www.cnblogs.com/Anker/p/3355573.html 今天从Apache官网上http://httpd.apache.org/下载httpd web服务器,由 ...
- [apache2.4]configure: error: APR not found. Please read the documentation.
apache2.4 安装出现如下错误 ``` [lzz@localhost httpd-2.4.10]$ ./configure checking for chosen layout... Apac ...
- Apache安装问题:configure: error: APR not found . Please read the documentation
Linux上安装Apache时,编译出现错误: checking for APR... no configure: error: APR not found . Please read the do ...
- linux 上安装apache 出现 configure: error: APR not found. Please read the documentation错误
今日编译apache时出错: #./configure --prefix……检查编辑环境时出现: checking for APR... noconfigure: error: APR not fou ...
随机推荐
- Canvas使用渐变之-线性渐变详解
在canvas里面,除了使用纯色,我们还能把填充和笔触样式设置为渐变色:线性渐变和径向渐变. 线性渐变 createLinearGradient(x0,y0,x1,y1) 返回 CanvasGrad ...
- discuz bbs注册,登录流程整理!想打通bbs又不想读一遍代码可以参考一下
bbs 用户注册流程 第一步: /source/class/class_member.php: on_register注册入口 L602 左右 if(!$activation) {//不为空,说明用户 ...
- FreeCodeCamp:Title Case a Sentence
要求: 确保字符串的每个单词首字母都大写,其余部分小写. 像'the'和'of'这样的连接符同理. 结果: titleCase("I'm a little tea pot") 应该 ...
- 「Foundation」结构体
一.基本知识 Foundation—基础框架.框架中包含了很多开发中常用的数据类型,如结构体,枚举,类等,是其他ios框架的基础. 如果要想使用foundation框架中的数据类型,那么包含它的主头文 ...
- 杭电ACM求平均成绩
求平均成绩 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Subm ...
- 在Eclipse中使用JDBC访问MySQL数据库的配置方法
在Eclipse中使用JDBC访问MySQL数据库的配置方法 分类: DATABASE 数据结构与算法2009-10-10 16:37 5313人阅读 评论(10) 收藏 举报 jdbcmysql数据 ...
- JQuery标签去重与数组去重
如图所示: 代码: <!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml"> <head ...
- 13. Roman to Integer
Given a roman numeral, convert it to an integer. Input is guaranteed to be within the range from 1 t ...
- hdu 3641 Treasure Hunting 强大的二分
/** 大意:给定一组ai,bi . m = a1^b1 *a2^b2 * a3^ b3 * a4^b4*...*ai^bi 求最小的x!%m =0 思路: 将ai 质因子分解,若是x!%m=0 那么 ...
- Windows Phone 8初学者开发—第12部分:改进视图模型和示例数据
原文 Windows Phone 8初学者开发—第12部分:改进视图模型和示例数据 第12部分:改进视图模型和示例数据 原文地址:http://channel9.msdn.com/Series/Win ...