1.首先安装依赖。
2.下载nginx
3.安装编译
./configure --prefix=/home/nginx \
--with-pcre \
--with-http_ssl_module \
--with-http_v2_module \
--with-http_realip_module \
--with-http_addition_module \
--with-http_sub_module \
--with-http_dav_module \
--with-http_flv_module \
--with-http_mp4_module \
--with-http_gunzip_module \
--with-http_gzip_static_module \
--with-http_random_index_module \
--with-http_secure_link_module \
--with-http_stub_status_module \
--with-http_auth_request_module \
--with-http_image_filter_module \
--with-http_slice_module \
--with-mail \
--with-threads \
--with-file-aio \
--with-stream \
--with-mail_ssl_module \
--with-stream_ssl_module
最终结果如下图这样就表示预编译成功了
再用make && make install命令编译,成功如下图(只截取了最后几行)
做完去目录文件下检查下,确保万无一失
4.查看网页
同理另外两台服务器也是如此配置。