Nginx编译安装

● 下载nginx
○ cd /usr/locar/src
○ wget http://nginx.org/download/nginx-1.8.0.tar.gz

● 解压
○ tar zxvf nginx-1.8.0.tar.gz

● 编译配置参数
○ cd nginx-1.8.0
./configure \
–prefix=/usr/local/nginx \
–with-http_realip_module \
–with-http_sub_module \
–with-http_gzip_static_module \
–with-http_stub_status_module \
–with-pcre

● 编译nginx
○ make

● 安装nginx
○ make install

● 启动nginx
○ /usr/local/nginx/sbin/nginx