Skip to content

Instance got unreasonably disconnected from ssh remote while installing

0

Hello, I m trying to install an open source online chat system in my Ubuntu. I connect to my instance through ssh command using VScode. However, my instance was always disconnected for no reason while installing and it didnt work when I attempted to reconnect. What I could only do is to force to stop my instance immediately and restart even though the status still showed RUNNING. What should I do? Increase the space of Ec2 instance?

asked 2 years ago328 views
2 Answers
1

Hello, Please check the cloudwatch metrics for resources (cpu , memory , iops) of your system once it comes back online and if the resource limits are reaching and the system getting hung due to the heavy application that you are trying to install, then upscale the size of your instance with large cpu & memory , also look for storage full issues and increase the filesystems as well.

AWS
answered 2 years ago
0

One place to start looking would be under the Monitoring tab of the EC2 instance in AWS Console, and note if there is anything that looks concerning, e.g. if CPU usage becomes unusually high.

It would also be worthwhile setting up CloudWatch agent to collect more detailed system logs https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/Install-CloudWatch-Agent.html - this may show that your root cause is exhaustion of some system resources.

What is the EC2 instance type?

EXPERT
answered 2 years ago
  • Just the basic free one. Is that a problem? I noticed that my cpu was occpied like 99.7% while installing

  • The free tier instances are very low-spec, which is not a problem until you're doing something that needs a lot of memory as they can quickly run out of it.

    Did you manage to install CloudWatch Agent and did it indicate anything in this area that might be of concern.

    If it looks like you may be short of memory, a quick fix could be to add more swap space https://repost.aws/knowledge-center/ec2-memory-swap-file

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.