一、安装apache2.2.8 首先,前往 http://www.apache.org 网站下载 apache2.2.8 的源码包。下载完成后直接解压缩: #tar zxvf httpd-2.2.8.tar.gz 解压后得到 httpd-2.2.8 文件夹,进入该目录: #cd httpd-2.2.
FreeBSD 7.0 Apache 2.2 MySQL 5 PHP 5安装配置方法
时间:2026-07-30
浏览:330
文章目录
一、安装apache2.2.8
首先,前往 http://www.apache.org 网站下载 apache2.2.8 的源码包。下载完成后直接解压缩:
#tar zxvf httpd-2.2.8.tar.gz
解压后得到 httpd-2.2.8 文件夹,进入该目录:
#cd httpd-2.2.8
接下来进行配置。注意一个小技巧:如果希望后续能够动态加载模块,并使用 rewrite 功能,可按照以下命令配置:
#./configure --prefix=/usr/local/apache --enable-so --enable-module=rewrite
然后依次执行编译和安装:
#make
#make install
安装完成后,进入 apache 的 bin 目录,启动服务进行测试:
#cd /usr/local/apache/bin
#./apachectl start
不过,启动时很可能会看到类似以下提示:
httpd: apr_sockaddr_info_get() failed for
httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
[Thu Apr 03 09:37:41 2008] [warn] (2)No such file or directory: Failed to enable the 'httpready' Accept Filter
这些提示在 FreeBSD 系统中较为常见。第一个错误(Could not reliably determine...)的解决方法很简单:编辑 /usr/local/apache/conf/httpd.conf 文件,将 ServerName 修改为 127.0.0.1 或实际域名即可。第二个警告(httpready Accept Filter)是 FreeBSD 特有的,系统自带的 http filter 会自动过滤不完整的 HTTP 请求,若不影响正常使用,可忽略该警告。
实用工具推荐
绿化、压缩、噪点和虚拟水印,自由调节做旧程度。
选择画质和输出格式,预览压缩前后的大小。