Error 521 from Cloudflare when trying to access site using Plesk
From Cloudflare error:
What happened?
The web server is not returning a connection. As a result, the web page is not displaying.
What can I do?
If you are the owner of this website:
Contact your hosting provider letting them know your web server is not responding. Additional troubleshooting information.
Cloudflare states this is due to two possibilities:
–
The two most common causes of 521 errors are:
- Offlined origin web server application
- Blocked Cloudflare requests
Source: Cloudflare 521 Error Troubleshooting
If your hosting shows your site is online, or you disable cloudflare and don’t have trouble accessing the site, it’s probably “blocked Cloudflare requests.”
Alas, with Plesk you are the hosting provider.
If you are using Cloudflare have Fail2Ban activated in Plesk, it may be overactive, intermittently blocking Cloudflare’s IP.
The Fix
- Look up your Cloudflare IP addresses
Cloudflare claims to have a comprehensive list, but mine was not on there. You can lookup the cloudflare IP you are actually using with MX Toolbox or any DNS lookup tool.
For the result(s) you will see one or more IPs.
Copy these to your Trusted IP Addresses in Plesk
- Using the search bar type “fail2ban” and select IP Address Banning (Fail2Ban) from the instant results.
- Go to the “Trusted IP Addresses” tab
- And “Add Trusted IP” with the IPs from Cloudflare
You should be good to go!
Leave a Reply