Skip to content

Instance or Server keeps shutting down

0

Hello everyone, my AWS server keeps shutting down and I always have to reboot my instance before my site gets visible again, Can someone please help me fix this issue?

asked a year ago216 views

2 Answers
0
Accepted Answer

When you say shutting down, do you mean it goes to a STOP state? You can check the following.

  • Is this part of auto-scaling, is it being shut down by auto-scaling rules?
  • Is there any health check in auto-scaling, maybe health check is failing.
  • Check instance status checks, maybe there is a misconfiguration that's causing status checks to fail.
  • Is this a t2/t3 instance type, if so, maybe it has run out of credits.
EXPERT

answered a year ago

EXPERT

reviewed a year ago

0

Frequent instance shutdowns are not normal behavior for a properly functioning AWS EC2 instance. There are several possible reasons why your instance might be shutting down repeatedly:

  1. Resource constraints: Your instance may be running out of memory, CPU, or disk space, causing it to become unresponsive. Monitoring your instance's metrics in the AWS console can help identify if this is the issue.

  2. Operating system initiated shutdown: If there's no "StopInstances" event in CloudTrail, the shutdown might be initiated by the operating system itself. This could be due to crashes, kernel panics, or other OS-level issues.

  3. Application issues: Problems with the application or service running on your instance could cause it to crash or become unresponsive.

  4. Hardware degradation: In some cases, AWS may take your instance offline to move it to another host if the hardware is degraded. This would typically be accompanied by a notification in your AWS Health Dashboard.

  5. High traffic or potential DoS attacks: Your site might be experiencing unusually high traffic or even a Denial of Service attack.

To troubleshoot and resolve this issue:

  1. Check the "State transition message" for your instance in the EC2 console when it's in the stopped state. This can provide clues about why it stopped.

  2. Review your application and system logs for error messages or warnings.

  3. Monitor CPU, memory, and disk utilization to identify potential resource constraints.

  4. Consider upgrading to a larger instance type if resource constraints are the issue.

  5. Implement an architecture with multiple instances behind a load balancer or use an auto-scaling group to improve reliability.

  6. Check the AWS Health Dashboard for any notifications about your instance.

If the problem persists after trying these steps, you may need to contact AWS Support for further assistance.
Sources
Windows server EC2 is constantly shutting down | AWS re:Post
Instance reboot | AWS re:Post
EC2 instance shutdown without alert & CloudTrail event. | AWS re:Post
TopInstance going down all the time | AWS re:Post

answered a year ago

AWS
EXPERT

reviewed a year ago

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.