bolt / site-market-bolt-cm

Extensions Repository for Bolt CMS
4 stars 5 forks source link

Timeout on IPv6 https://market.bolt.cm/satis/packages.json #76

Closed znegva closed 6 years ago

znegva commented 6 years ago

Hi,

I am not able to install extensions on my local testing machine.

What is working is:

What is not working:

I tried it with nut server:run and php -S localhost:8000, both didn't work, the second gave some logging:

[Mon Feb 26 01:03:35 2018] ::1:63383 [200]: /bolt/extensions/installInfo?package=bobdenotter/passwordprotect
[Mon Feb 26 01:05:28 2018] ::1:63420 [200]: /bolt/extensions/installInfo?package=bolt/robots
[Mon Feb 26 01:09:38 2018] ::1:63428 [500]: /bolt/extensions/install?package=bolt%2Frobots&version=v1.0.1

Internal Server Error 500 in /bolt/extensions/install.

So I tried to download the file by hand:

~/temp % wget "https://market.bolt.cm/satis/packages.json"
--2018-02-26 00:24:43--  https://market.bolt.cm/satis/packages.json
Resolving market.bolt.cm (market.bolt.cm)... 2a03:b0c0:0:1010::20f:5001, 82.196.12.59
Connecting to market.bolt.cm (market.bolt.cm)|2a03:b0c0:0:1010::20f:5001|:443... failed: Operation timed out.
Connecting to market.bolt.cm (market.bolt.cm)|82.196.12.59|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 192 [application/json]
Saving to: 'packages.json'

packages.json                           100%[============================================================================>]     192  --.-KB/s    in 0s

2018-02-26 00:26:00 (6.10 MB/s) - 'packages.json' saved [192/192]

~/temp % more packages.json
{
    "packages": [],
    "includes": {
        "include/all$111d59491eb841b6744af5b48d2ddfbdc4e9d7c1.json": {
            "sha1": "111d59491eb841b6744af5b48d2ddfbdc4e9d7c1"
        }
    }
}
~/temp %

It seems my box (macOS 10.13.3) seems to prefer the IPv6 -IP- adress of the server - which times out. wget is clever enough to use the IPv4 adress for the next try, the Bolt Backend unfortunately just stops.

On another box (Cent OS, other internet-provider) the installation of extensions through the Bolt-Backend works as expected - there the setup seems to prefer the IPv4 adress ("tested" with the wget approach shown above).


Maybe this is just a misconfiguration of the DNS-Server? It seems the IPv6 Adress (2a03:b0c0:0:1010::20f:5001) points to bolt.cm, not market.bolt.cm ??


Or maybe the configuration of IPv6 in cooperation with HTTPS wasn't done correctly.
I had contact to a similar problem some time ago - but unfortunately I have no detailed infos what exactly had to be changed.

GwendolenLynch commented 6 years ago

Thanks mate! I think I know "why" but I might not have time for a few days to address the problem. Bear with me :smile_cat:

GwendolenLynch commented 6 years ago

I can not seem to reproduce the problem here, and the server's network & NGINX configuration looks correct.

The DNS records are correct, and resolving correctly from a non-authoritative server:

$ dig AAAA market.bolt.cm @8.8.8.8

; <<>> DiG 9.11.2-P1-RedHat-9.11.2-1.P1.fc27 <<>> AAAA market.bolt.cm @8.8.8.8
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 65157
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 512
;; QUESTION SECTION:
;market.bolt.cm.            IN  AAAA

;; ANSWER SECTION:
market.bolt.cm.     21599   IN  CNAME   bolt.cm.
bolt.cm.        3599    IN  AAAA    2a03:b0c0:0:1010::20f:5001

Forcing wget to use IPv6 from another host also completes the request you were testing correctly.

$ wget -6 https://market.bolt.cm/satis/packages.json
--2018-03-03 14:14:05--  https://market.bolt.cm/satis/packages.json
Resolving market.bolt.cm (market.bolt.cm)... 2a03:b0c0:0:1010::20f:5001
Connecting to market.bolt.cm (market.bolt.cm)|2a03:b0c0:0:1010::20f:5001|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 192 [application/json]
Saving to: ‘packages.json’

100%[=========================================================================================================================================================================>] 192         --.-K/s   in 0s      

2018-03-03 14:14:05 (25.3 MB/s) - ‘packages.json’ saved [192/192]

So my guess would be that your provider's IPv6 routing might be b0rked for some reason. If you can find something else that points to us, please feel to reopen. But without reproducible problems I can only conclude it isn't our end :smile_cat:

znegva commented 6 years ago

Testing today everything works as expected (installing extension from the backend as well as wget - still via IPv6). If there was nothing changed on market.bolt.cm then the problem was on my (providers) side.

Sorry for the inconvenience.

GwendolenLynch commented 6 years ago

Good to know! Thanks for the feedback, and no inconvenience incurred. :+1: :smile_cat: