1分钟搞定 Nginx 版本的平滑升级与回滚( 二 )

2、编译安装新旧版本

编译安装nginx-1.12.2

[root@nginx nginx
# tar zxf nginx-1.12.2.tar.gz \n[root@nginx nginx
# cd nginx-1.12.2\n[root@nginx nginx-1.12.2
# ./configure --prefix=/usr/local/nginx-1.12.2\n[root@nginx nginx-1.12.2
# echo $?\n0\n[root@nginx nginx-1.12.2
# make && make install\n[root@nginx nginx-1.12.2
# echo $?\n0\n[root@nginx nginx-1.12.2
# ll /usr/local/nginx-1.12.2/\ntotal 0\ndrwxr-xr-x 2 root root 333 Mar  1 09:01 conf\ndrwxr-xr-x 2 root root  40 Mar  1 09:01 html\ndrwxr-xr-x 2 root root   6 Mar  1 09:01 logs\ndrwxr-xr-x 2 root root  19 Mar  1 09:01 sbin

推荐阅读