Error 520 (classic)


Since precisely midnight (midnight sharp!) my website is innnacessible with an error page 520. I followed the procedure and paused Cloudfare and when I do it the website is accessible without errors. I also access my site via another URL outside Cloudfare without worries:
If I overwrite my index.php with just a “hello world” in it I have the same issue…

Example with just “hello world” file : (with Cloudfare) (no CF)

I know the error is “classic” but I really searched all day, read all the topics, followed all the methods …
It’s just a “hello world” page and I haven’t touched my website / server for days :frowning:
(and the “midnight sharp” for the beginning of the 520 error logs is strange)

Could you help me?
Thanks :slight_smile:

/cdn-cgi/trace :
uag=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36

I assume you’d expect to get content on that site about Mylène Farmer, right? *)

All right, you probably already found it - considering you called it classic - but 520s are covered at Community Tip - Fixing Error 520: Web server is returning an unknown error and you’ll most likely find the fix there.

But the other issue you need to fix is the broken certificate on your server and the encryption mode on Cloudflare, which currently won’t be “Full strict” - and that’s what it should be.

*) Nice song, Mylene Farmer - Maman A Tort (1984) HD 720 - YouTube, me likes :+1:t2:

1 Like

I am seeing inconsistent behaviour from your origin. Every second request results in a 307 redirect to the same asset as in the request. While I have not seen such a redirect cause a 520 error, it might point to something strange going on in your load balancer.

% curl  --resolve -v
< HTTP/1.1 200 OK
< Date: Sun, 16 May 2021 19:38:30 GMT
< Content-Type: text/html; charset=UTF-8
< Transfer-Encoding: chunked
< Server: Apache
< X-Powered-By: PHP/7.4
< Vary: Accept-Encoding
< X-IPLB-Request-ID: 25E4EE1F:B9F4_91EF25A2:0050_60A174B6_10DE:599D
< X-IPLB-Instance: 37649
* Connection #0 to host left intact
hello world* Closing connection 0
 ~ % curl  --resolve -v
< HTTP/1.1 307 Temporary Redirect
< Connection: close
< Pragma: no-cache
< cache-control: no-cache
< Location: /coucou.php
* Closing connection 0

IMHO this will be the issue. You seem to have a partial SSL setup and no valid certificate at all.

I’d suggest you pause Cloudflare for now and make sure your site loads fine on HTTPS in all cases and only then unpause Cloudflare. In that case it should also work fine on Cloudflare. Right now the whole SSL setup is broken.

If SSL is not important you could also disable it altogether and switch to “Off”.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.