Bad Gateway 502 following AWS maintenance on EC2 instance

0

Hi,

Could someone explain in layman's terms, I'm not technical, why my App running perfectly until AWS did some maintenance work on my instance is now returning a 502 Bad Gateway Error?

And can anyone help fix it?

Thanks,

Gary

질문됨 일 년 전344회 조회
2개 답변
2
수락된 답변

Hello Gary,

The causes can be multiple and it really depends on what type of services or applications you're running in your EC2 instance. If I take here some assumptions: you're running a web based application that runs in a web server like apache or nginx or other, which means that for some reason those services cannot reach the application (e.g. PHP application).

Please consider provide more details on which type of workload/services or applications you're running in your EC2.

Thanks, Luis

AWS
luis
답변함 일 년 전
0

Thanks Luis,

We've solved the issue now.

My app service was down. Also apache was causing an issue.

We ran these commands:

sudo service apache2 stop

sudo systemctl restart nginx

rails s -d

It was frustrating as the error occurred following AWS maintenance work and they weren't keen to help solve the issue.

But, again, thanks for trying to help.

Gary

답변함 일 년 전
  • Great and sorry to hear that - it looks like that apache2 overlaps with nginx and the most likely raison is that they use the same service ports (80 HTTP, 443 HTTPS). I would recommend to, if apache is not used at all, to remove it from your instance.

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠