我认为Apache的httpd.conf通常位于/etc/httpd/conf/httpd.conf.但对于我在Centos 6.4上所述的安装,它位于/usr/local/apache2/conf/httpd.conf.最重要的是,DocumentRoot设置为/usr/local / apache2 / htdocs而不是传统的/ var / www / html.
这些位置最常见的位置在哪里?如果与我所展示的不同,我做错了什么?谢谢
首先,我做了以下事情:
>将Apache 2.4.4解压缩到/usr/local / src
>将APR 1.4.6解压缩到/usr/local/src/httpd-2.4.4/srclib/apr
>将APR-Util 1.5.2打包到/usr/local/src/httpd-2.4.4/srclib / apr-util
>将PCRE 8.33打包到/usr/local / src
然后我做了以下
$cd /usr/local/src/httpd-2.4.4/srclib/apr
$./configure
$make
$make install
$cd /usr/local/src/httpd-2.4.4/srclib/ apr-util
$./configure --with-apr=../apr (verify if any other options are desired)
$make
$make install
$cd /usr/local/src/pcre-8.33
$./configure
$make
$make install
$cd /usr/local/src/httpd-2.4.4
$./configure --enable-so –enable-rewrite –enable-ssl –with-pcre
$make
$make install
最佳答案
你所做的“错误”是不读文档,其中clearly states:
PREFIX must be replaced with the filesystem path under which the server should be installed. If PREFIX is not specified,it defaults to /usr/local/apache2.