apache-2.4.x 编译安装方法apache-2.4.x 编译安装方法
2012-12-03 06:23
288 查看
apache-2.2与新出的apache-2.4安装不同的地方在于,2.4版的已经不自带apr库,所以在安装apache-2.4之前,需要下载apr。
1、下载软件
cd /tmp
wget http://mirrors.axint.net/apache//httpd/httpd-2.4.2.tar.gz wget http://mirrors.axint.net/apache//apr/apr-1.4.6.tar.gz wget http://mirrors.axint.net/apache//apr/apr-util-1.4.1.tar.gz tar xzf httpd-2.4.2.tar.gz
tar xzf apr-1.4.6.tar.gz
tar xzf apr-util-1.4.1.tar.gz
2、移动apr到srclib
mv apr-1.4.6 httpd-2.4.2/srclib/apr
mv apr-util-1.4.1 httpd-2.4.2/srclib/apr-util
3、安装apache-2.4
cd /tmp/httpd-2.4.2
./configure --prefix=/usr/local/apache --enable-so --enable-deflate=shared --enable-ssl=shared --enable-expires=shared --enable-headers=shared --enable-rewrite=shared --enable-static-support --with-included-apr --with-mpm=prefork
make && make install
cp -f build/rpm/httpd.init /etc/init.d/httpd
chmod +x /etc/init.d/httpd
chkconfig --add httpd
chkconfig httpd on
cd /etc
mv httpd httpd_old
ln -s /usr/local/apache/ httpd
cd /usr/sbin/
ln -fs /usr/local/apache/bin/httpd
ln -fs /usr/local/apache/bin/apachectl
cd /var/log
rm -rf httpd/
ln -s /usr/local/apache/logs httpd
1、下载软件
cd /tmp
wget http://mirrors.axint.net/apache//httpd/httpd-2.4.2.tar.gz wget http://mirrors.axint.net/apache//apr/apr-1.4.6.tar.gz wget http://mirrors.axint.net/apache//apr/apr-util-1.4.1.tar.gz tar xzf httpd-2.4.2.tar.gz
tar xzf apr-1.4.6.tar.gz
tar xzf apr-util-1.4.1.tar.gz
2、移动apr到srclib
mv apr-1.4.6 httpd-2.4.2/srclib/apr
mv apr-util-1.4.1 httpd-2.4.2/srclib/apr-util
3、安装apache-2.4
cd /tmp/httpd-2.4.2
./configure --prefix=/usr/local/apache --enable-so --enable-deflate=shared --enable-ssl=shared --enable-expires=shared --enable-headers=shared --enable-rewrite=shared --enable-static-support --with-included-apr --with-mpm=prefork
make && make install
cp -f build/rpm/httpd.init /etc/init.d/httpd
chmod +x /etc/init.d/httpd
chkconfig --add httpd
chkconfig httpd on
cd /etc
mv httpd httpd_old
ln -s /usr/local/apache/ httpd
cd /usr/sbin/
ln -fs /usr/local/apache/bin/httpd
ln -fs /usr/local/apache/bin/apachectl
cd /var/log
rm -rf httpd/
ln -s /usr/local/apache/logs httpd
相关文章推荐
- apache-2.4.x 编译安装方法
- apache-2.4.x 编译安装方法
- Apache2.4.x 编译安装mod_perl-2.08错误
- CentOS 6.3 安装配置Apache2.2.6的方法(源码编译安装)
- apache编译安装方法及配置
- Linux---CentOS下编译安装Apache后只显示测试页面解决方法
- CentOS编译安装Apache 2.4.x时报错:configure: error: Bundled APR requested but not found at ./srclib/. Downlo
- CentOS编译安装Apache 2.4.x时报错:configure: error: Bundled APR requested but not found at ./srclib/. Downlo
- ache-2.4.x 编译安装方法
- Apache编译安装:/usr/lib/libexpat.so: could not read symbols解决方法
- CentOS编译安装Apache 2.4.x时报错:configure: error: Bundled APR requested but not found at ./srclib/. Download and unpack the corresponding apr and apr-util packages to ./srclib/.
- apache-2.4.x 编译安装
- CentOS 6.5上编译安装Apache服务器的方法(最小化安装)
- 编译安装完Apache之后发现modules目录下没有libphp5.so 解决方法
- Apache2.4.2编译安装2个常见错误和解决方法
- apache-2.4.2 编译安装方法
- Centos 6.5系统下编译安装PHP 7.0.13的方法
- CentOS 7.0 安装配置LAMP服务器方法(Apache+PHP+MariaDB)(转)
- Qt/QTE 编译安装问题与解决方法(2)
- 不重新编译apache安装mod_deflate模块