最简安装nginx
第一步下载编译所需软件yum即可
'''yum install zlib zlib-devel openssl openssl-devel pcre pcre-devel
yum install gcc gcc-c++ autoconf automake
yum install wget'''
第二步下载官网安装包并解压
wget http://nginx.org/download/nginx-1.10.3.tar.gz
tar zxvf nginx-1.10.3.tar.gz
第三步-编译(不带任何参数默认参数);make && make install 编译加安装. 默认路径(/usr/local/nginx)
./configure
make
make install
完事启动(默认路径sbin下执行文件,-c 加载配置文件路径)
/usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf
在centos 6.8下测试