XF 2.1 Unfurl error: Could not fetch metadata from URL with error: cURL error 28: Resolving timed out after 3000 milliseconds

Ok, what I've found is interesting. If I add the XenForo link to a post (from my other XF forum or from this official one) it will not unfurl. If I add for instance this one: https://www.nytimes.com , it will unfurl immediately.

I'm using the latest XenForo version on all forums.
 
The particular error you posted is a DNS resolution error, so it might indicate a DNS issue of some sort on your server (or with regards to how PHP itself is using the network stack).

I don't know if you're getting the same error for other scenarios.
 
@Mike
I've been resolving this with my host, but there is nothing on their side, they said. I even changed the DNS server from Cloudflare to host one, just for a test. But there is still a problem with unfurling.

They can't help further unless I pay for a technician to check the software... Not sure if I'll do that, really. Not sure if it's my host, Cloudflare, XF, or something completely else. Kind of lost here now and I'm still getting lots of server errors for this:
 
Note that this is a DNS resolution issue on the server itelf -- your server appears to be having issues resolving the URL given in the first message. This is distinct from the DNS server your domain is using. It's hard to really say why that is. If this is a shared server, you won't really have any control over the DNS resolution settings on the server. If it's a VPS then you would, though the process for changing this can vary pretty significantly depending on the specific OS in use.

Though it's worth mentioning that if some unfurls are working, then some amount of DNS resolution is working. We don't allow a ton of time for this (3 seconds), though that should almost always be enough, but perhaps it could indicate that DNS resoltuion is simply very slow. That might require changing to different DNS resolution servers, but I don't know if that's really viable.
 
Ok, what I've found is interesting. If I add the XenForo link to a post (from my other XF forum or from this official one) it will not unfurl. If I add for instance this one: https://www.nytimes.com , it will unfurl immediately.

I'm using the latest XenForo version on all forums.
If you have ssh root access to your servers, you can try ssh command line curl checks against different dns resolvers including your server's own dns resolvers in /etc/resolv.conf and see what you find

against server default DNS resolver
Bash:
curl -skvD - https://xenforo.com -o /dev/null
against 1.1.1.1
Bash:
curl -skvD - --dns-servers 1.1.1.1 https://xenforo.com -o /dev/null
against 8.8.8.8
Bash:
curl -skvD - --dns-servers 8.8.8.8 https://xenforo.com -o /dev/null
Code:
curl -skvD - https://xenforo.com -o /dev/null
*   Trying 172.67.1.198:443...
* Connected to xenforo.com (172.67.1.198) port 443 (#0)
* Initializing NSS with certpath: sql:/etc/pki/nssdb
*   CAfile: none
  CApath: none
* loaded libnssckbi.so
* skipping SSL peer certificate verification
* ALPN, server accepted to use h2
* SSL connection using TLS_AES_128_GCM_SHA256
* Server certificate:
*       subject: CN=xenforo.com,O="Cloudflare, Inc.",L=San Francisco,ST=CA,C=US
*       start date: Jun 14 00:00:00 2020 GMT
*       expire date: Jun 14 12:00:00 2021 GMT
*       common name: xenforo.com
*       issuer: CN=Cloudflare Inc ECC CA-3,O="Cloudflare, Inc.",C=US
* Using HTTP2, server supports multi-use
* Connection state changed (HTTP/2 confirmed)
* Copying HTTP/2 data in stream buffer to connection buffer after upgrade: len=0
* Using Stream ID: 1 (easy handle 0x6d0740)
> GET / HTTP/2
> Host: xenforo.com
> user-agent: curl/7.70.0
> accept: */*

see which IP address the DNS resolver picks up for each

FYI cloudflare DNS now have 3 DNS A records with a 3rd 172.xxx recently added for each domain
Code:
dig +short A xenforo.com
104.20.86.95
104.20.87.95
172.67.1.198
 
Top Bottom