提示:
gs/nginx.pid --http-log-path=/usr/local/nginx/logs/access.log checking for OS Linux 3.10.0-1062.18.1.el7.x86_64 x86_64 checking for C compiler ... not found ./configure: error: C compiler cc is not found解决:
yum -y install gcc提示:
./configure: error: the HTTP rewrite module requires the PCRE library. You can either disable the module by using --without-http_rewrite_module option, or install the PCRE library into the system, or build the PCRE library statically from the source with nginx by using --with-pcre=<path> option.解决:
yum -y install pcre-devel提示:
./configure: error: the HTTP gzip module requires the zlib library. You can either disable the module by using --without-http_gzip_module option, or install the zlib library into the system, or build the zlib library statically from the source with nginx by using --with-zlib=<path> option.解决:
yum -y install openssl openssl-devel(2 编译:
make && make install查看 nginx 版本: 创建软链接方便访问:
ln -s /usr/local/nginx/sbin/nginx /usr/local/bin/至此,NGINX 安装成功啦!!!