yum -y install gcc pcre pcre-devel zlib zlib-devel openssl openssl-devel
 
./configure --prefix=/Nginx --with-http_ssl_module --with-http_realip_module  --with-stream
vim /usr/local/nginx/conf/nginx.conf

4. 配置新版本
# ./configure --prefix=/usr/local/nginx --with-pcre=/usr/local/pcre-8.35 --with-http_stub_status_module --with-http_v2_module --with-http_gzip_static_module --with-http_sub_module --with-http_ssl_module --with-stream
5. 编译新版本
# make 
# ls 
auto  CHANGES  CHANGES.ru  conf  configure  contrib  html  LICENSE  Makefile  man  objs  README  src

vim /usr/local/nginx/conf/nginx.conf

stream 
{
    upstream server_upstreams {
        server server1.bobobk.com:443;
        server server3.bobobk.com:443;
    }
    #将8080端口转发到server3.bobobk.com的443端口
    #将udp 8080端口转发到server3.bobobk.com 443端口
    server {
        listen 8080;
        listen 8080 udp;
        proxy_pass server_upstreams;
    }
}