版本升级到最新还是打不开微信小程序

版本升级到最新还是打不开微信小程序,第1张

nginx版本升级到1.10

遇到了一个问题:公司需要在某个站点支持http2。据咨询nginx>:1.9.5支持http2。所以升级nginx版本号。

解决困难:


先做好原nginx的备份数据。(环境变量conf,应用软件/usr/local/nginx/sbin/nginx等备份数据)


1.免费下载nginx的新稳定版本号。

根据nginx官网显示,安装的版本号为nginx1.10.1(新稳定版本号)。


2.查询旧编译器的主要参数

[root@nginx001~]#/usr/local/nginx/sbin/nginx-V

nginx版本:nginx/1.7.6

由gcc4.4.720120313(红帽4.4.7-16)构建(gcc)

TLSSNI支持已启用

配置参数:-prefix=/usr/local/nginx-with-pcre=/mnt/app//pcre-8.36-with-zlib=/mnt/app//zlib-1.2.8-add-module=/mnt/app//ngx_cache_purge-2.1-with-http_perl_module-with-http_SSL_module-http_stub_status_module-add-module=/mnt/app//nginx_TCP_proxy_module-master


3.泄压NGINX版本号nginx1.10.1,重新编译程序。

  • Ngx_cache_purge-2.1不支持nginx1.10,所以再次免费下载ngx_cache_purge-2.3.tar.gz(下载链接:http://labs.frickle.com/files/)。

  • nginx1.10已经支持tcp代理,所以不需要编译程序的主参数-add-module=/mnt/app//NGINX_TCP_proxy_module-master。

    并添加http2支持,-使用-HTTP_V2_模块

    因此,程序的主要参数编译正确:

    cd/mnt/app/nginx-1.10.1

    。/configure-prefix=/usr/local/nginx-with-pcre=/mnt/app/pcre-8.36-with-zlib=/mnt/app/zlib-1.2.8-add-module=/mnt/app/ngx_cache_purge-2.3-with-http_perl_module-with-http_SSL_module-with-http_stub_status_module-with-stream-add-module=/mnt/app/nginnx_upstream_check_check


    制造


    Makeinstall(如果没有实现,说明nginx.pm的版本信息不正确。检测重装后不容易伤害原来的nginx环境变量)


    4.备份数据并替换旧的nginx程序流程

    mv/usr/local/nginx/sbin/nginx/usr/local/nginx/sbin/nginx_1.7.bak

    CP/mnt/app/nginx-1.10.1/objs/nginx/usr/local/nginx/sbin/nginx


    查询更换后的程序流程:版本号1.10。

    [root@nginx001~]#/usr/local/nginx/sbin/nginx-V

    nginx版本:nginx/1.10.1

    由gcc4.4.720120313(红帽4.4.7-16)构建(gcc)

    使用OpenSSL1.0.1e-fips构建,2013年2月11日

    TLSSNI支持已启用

    配置参数:-prefix=/usr/lcoal/nginx-with-pcre=/mnt/app/pcre-8.36-with-zlib=/mnt/app/zlib-1.2.8-add-module=/mnt/app/ngx_cache_purge-2.3-with-http_perl_module-with-http_SSL_module-with-http_stub_status_module-with-stream-add-module=/mnt/app/nginxx_upstream_check


    检查环境变量并重新启动。

    /usr/local/nginx/sbin/nginx-t

    /usr/local/nginx/sbin/nginx-s重新加载


    将nginx版本号升级到1.10.1。

    欢迎分享,转载请注明来源:内存溢出

    原文地址: https://outofmemory.cn/zz/778352.html

    (0)
    打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
    上一篇 2022-05-03
    下一篇 2022-05-03

    发表评论

    登录后才能评论

    评论列表(0条)

    保存