When I try to access my site I get a 504 error
When I try to access my site I am getting a 504 Bad Gateway error. This has happened a few times over the past month or so. What does this mean? How do I fix this?
A 504 Gateway error happens when the server you are connecting to doesn't receive a quick enough response from another server, and so the request times out. This is usually indicative of a problem with an upstream server or the network connection.
This kind of error can be tricky to troubleshoot and is going to require a bit of investigating on your part. This could be caused by an inaccessible upstream service your web application uses, so if your web app relies on any such services that may be a good place to look first.
Additionally, you may want to check for network issues between the servers using MTR reports. This may help you identify a problem along the route that may be causing the connection to timeout
Aside from that, I'd recommend looking over your Firewall rules as well as checking your server logs for any clues to what could be causing the bad connection. I'd recommend the following guide for the former: