V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
hanjunlei
V2EX  ›  问与答

为什么全站 HTTP 转 HTTPS 慢的不行, 每次打开网站要一分钟,才跳转!~~~~

  •  
  •   hanjunlei · 2018-04-03 17:59:53 +08:00 · 2852 次点击
    这是一个创建于 2217 天前的主题,其中的信息可能已经有所发展或是发生改变。

    server { listen 80; server_name www.fengyibbk.com; rewrite ^ https://$http_host$request_uri? permanent; # force redirect http to https #return 301 https://$http_host$request_uri; }

    每次打开网站要一分钟,才跳转!~~~~
    
    什么问题。。。。。。。。。。。。
    
    5 条回复    2018-04-04 06:15:54 +08:00
    hanjunlei
        1
    hanjunlei  
    OP
       2018-04-03 18:00:22 +08:00
    取消跳转后访问很快!~~
    torbrowserbridge
        2
    torbrowserbridge  
       2018-04-03 18:01:09 +08:00
    http 跳 https ?直接访问 https 速度呢?
    yytsjq
        3
    yytsjq  
       2018-04-03 18:36:22 +08:00
    那条 rewrite 规则没必要吧。。

    server {
    listen 80 default_server;
    listen [::]:80 default_server;

    # Redirect all HTTP requests to HTTPS with a 301 Moved Permanently response.
    return 301 https://$host$request_uri;
    }

    https://mozilla.github.io/server-side-tls/ssl-config-generator/
    hanjunlei
        4
    hanjunlei  
    OP
       2018-04-03 22:19:02 +08:00
    不跳转很快的。
    msg7086
        5
    msg7086  
       2018-04-04 06:15:54 +08:00
    请把这一分钟里浏览器的请求和时间分片信息贴出来。
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3014 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 28ms · UTC 14:29 · PVG 22:29 · LAX 07:29 · JFK 10:29
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.