Table of Contents
Web Application
最多站点使用的WEBservice
./configure --prefix=/usr/local/httpd-2.2.14 --with-mysql=/usr/local/mysql/ --enable-module=so --enable-shared=max make make install http://neo.zenw.org 中对编译参数的解释: configure --with-mpm=worker 进程,线程混合方式效率提高不少 --enable-modules='dir mime' 没有它就找不到index.*文件 --enable-rewrite=shared Rewrite用于表态化 --enable-expires=shared 禁止页面被 cache --enable-authz_host=shared Order权限 --enable-setenvif=shared --enable-log_config=shared 日志格式 --enable-speling=shared 允许自动修正拼错的URL --enable-deflate=shared 压缩传送 --enable-mods-shared='cache file-cache disk-cache mem-cache proxy proxy-ajp proxy-balancer' 代理和缓存 tar zxvf httpd-2.2.4.tar.gz cd httpd-2.2.4 ./configure --prefix=/usr/local/httpd-2.2.4 \ --with-mpm=worker \ --enable-modules='dir mime' \ --enable-rewrite=shared \ --enable-authz_host=shared \ --enable-alias=shared \ --enable-setenvif=shared \ --enable-log_config=shared \ --enable-speling=shared \ --enable-filter=shared \ --enable-deflate=shared \ --enable-headers=shared \ --enable-expires=shared \ --enable-mods-shared='cache file-cache disk-cache mem-cache proxy proxy-ajp proxy-balancer' \ --disable-include \ --disable-actions \ --disable-alias \ --disable-asis \ --disable-autoindex \ --disable-auth_basic \ --disable-authn_file \ --disable-authn_default \ --disable-authz_groupfile \ --disable-authz_user \ --disable-authz_default \ --disable-cgi \ --disable-cgid \ --disable-env \ --disable-negotiation \ --disable-status \ --disable-userdir make make test make install 启动 /usr/local/httpd-2.2.4/bin/apachectl start
同以往的安装PHP方式一样,但需要在安装命令中加入--with-apxs2=apache安装目录 如: ./configure ...省略... --with-apxs2=/usr/local/apache/bin/apxs ...省略... 在apache配置文件中加入: AddType application/x-httpd-php .php .phtml AddType application/x-httpd-php-source .phps
推荐阅读 http://blog.chinaunix.net/u1/37270/showart.php?id=302175 LAMP安装全攻略 - web - 杨军的Linux学习笔记: http://neo.zenw.org/linux/ch25.html#id1346754 第 25 章 Compile install LAMP: