lighttpd安装学习文档
时间:2010-04-13 来源:xhq6632
前提条件 需要安装pcre
pcre是一个和perl兼容的正规表达式库, 当然不安装他lighttpd也可以正常运行,但是这样一来就无法使用正则来进行复杂配置了, pcre对于支持rails,虚拟主机还是很有必要的, pcre的主站 ,linux下面本人的机器默认有安装, solaris上没有内置,需要下载安装, solaris到这里找对应的版本
下载好pcre后,解压进入相应目录,按照下面的方式编译安装即可./configure --enable-utf8 --enable-unicode-properties --enable-bsr-anycrlf --enable-pcregrep-libz --enable-pcregrep-libbz2
make
make install
Lighttpd的安装
可以到lighttpd的主站进行下载,目前最新版本是lighttpd-1.4.19.tar.gz
wget http://www.lighttpd.net/download/lighttpd-1.4.19.tar.gz
tar zxvf lighttpd-1.4.19.tar.gz
cd lighttpd-1.4.19
./configure --prefix=/usr/local/lighttpd
make
make install
mkdir -p /usr/local/lighttpd/conf
vi /usr/local/lighttpd/conf/lighttpd.conf
server.port = 80 |
mkdir -p /usr/local/lighttpd/var/logs
使用 /usr/local/lighttpd/sbin/lighttpd -f /usr/local/lighttpd/conf/lighttpd.conf
启动服务
在doc文件夹下建立index.html文件,加入内容如下
<body> |
然后通过http://www.test.com
之后就可以看到我们刚刚建立的简单的页面了
上传一个整理过的
|