Linux下面安装nginx(REAL)

一、安装有 PCRE

安装之前需要确定系统是否安装有 PCRE(Perl Compatible Regular Expressions)包,地址:http://www.pcre.org/

# wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.21.tar.gz

# tar zxvf pcre-8.21.tar.gz
# cd pcre-8.21
# ./configure
# make
# make install

so~PCRE包安装好了(备注:PCRE(Perl Compatible Regular Expressions)是一个Perl库,包括 perl 兼容的正规表达式库

二、安装Nginx

# wget http://nginx.org/download/nginx-1.0.2.tar.gz

# tar zxvf nginx-1.0.2.tar.gz
# cd pcre-8.21
# ./configure --prefix=/usr/local/nginx/ --sbin-path=/usr/local/nginx/nginx --conf-path=/usr/local/nginx/nginx.conf --error-log-path=/usr/local/nginx/nginx.er --with-http_perl_module --with-pcre=/home/hadoop/pcre-8.21
# make
# make install

三、运行Nginx

# cd /usr/local/nginx/

# ./nginx &

四、测试Nginx

 

 

 参考网站:http://wiki.nginx.org/InstallChs

     http://blog.51yip.com/manual/nginx/

 

你可能感兴趣的:(linux)