2 Instances, both running. Websites going down.

0

Why are my websites going down when the instance is still running?

  1. I run two instances. 1 x t3.small 1 x t3a.large
  2. The t3a.large instance hosts two websites. Both of those websites go down at the same time, but the instance remains running.
  3. Re-booting the instance that hosts those two websites brings the websitess back up quickly
  4. The t3.small websites and instance running as normal
  5. When trying to access websites, returns "Error establishing a database connection".

I have increased storage to 32GB recently. I dont think that is the issue or the instance would have stopped (also gets no where near that limit). IMDS v2 has a brown coloured warning "EC2 recommends setting IMDSv2 to required", but the smaller instance also has this, so assume also not the issue. Nothing out of the ordinary showing on the monitoring I run gravity forms on just one of the websites.

質問済み 24日前82ビュー
2回答
0

Hello.

Have you checked the OS system log or web server error log?
Also, are EC2's CPU and memory usage rates high?
I think "Error establishing a database connection" is an error that occurs when the database to which you are connecting is not running or there is some kind of connection problem.
Is the database hosted on RDS or something?

profile picture
エキスパート
回答済み 24日前
profile picture
エキスパート
レビュー済み 24日前
0

I have increased storage to 32GB recently.

This just increases disk, and not memory. And you would still need to extend the filesystem https://docs.aws.amazon.com/ebs/latest/userguide/recognize-expanded-volume-linux.html (I know the URL has linux in it, but it gives you the method for Windows as well).

From what you describe, both websites going down at the same time suggests either a problem with the webserver (is it IIS?) or it could be a resource exhaustion issue (which is my hunch). It would be worthwhile setting up CloudWatch agent to collect more detailed system logs and this may show that your root cause is exhaustion of some system resources.

See https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/install-CloudWatch-Agent-commandline-fleet.html#download-CloudWatch-Agent-on-EC2-Instance-commandline-fleet (a bit Linux-centric but the download link is in the table) and https://repost.aws/knowledge-center/cloudwatch-push-metrics-unified-agent

profile picture
エキスパート
Steve_M
回答済み 24日前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ