502 Bad Gateway on Lightsail Instance

0

We get the 502 Bad Gateway error twice a week. After restarting the instance, everything runs normally again. What could be the problem. Thanks for your help

Alex
asked 20 days ago91 views
1 Answer
1
Accepted Answer

Hello.

What is the load on Lightsail?
Also, which Lightsail plan are you using?
Depending on the Lightsail plan, the specs may be quite low, so errors may occur depending on the load.
https://docs.aws.amazon.com/lightsail/latest/userguide/amazon-lightsail-viewing-instance-burst-capacity.html

profile picture
EXPERT
answered 20 days ago
profile picture
EXPERT
reviewed 20 days ago
profile picture
EXPERT
reviewed 20 days ago
  • 4 GB RAM, 2 vCPUs, 80 GB SSD Your instances receive data traffic from this load balancer via port 80. The data traffic is only forwarded to a single instance:

  • How much CPU usage is your Lightsail instance using? If your Lightsail instance plan uses more than 20% CPU usage, it will consume burst credits. Once these burst credits are consumed, performance will drop to below the baseline throughput, which may cause errors.
    Also, if the CPU usage rate is not that high, you may want to try setting the timeout value on the web server side a little higher. https://repost.aws/knowledge-center/apache-backend-elb

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions