AWS EC2 Instance Won’t Stop

If you use a lot – or even just one – EC2 instance on Amazon Web Services (AWS), from time-to-time, you might find that an instance becomes unresponsive, you can’t get in via SSH, and, when in the AWS console, the instance just won’t stop!

When this happens, you select “Stop” in the console, and the spinning wheel just never completes…

If these circumstances sound familiar, then the following has always worked for us. Before you start hitting the forum, asking for support, or doing anything else, press stop AGAIN. You will now be advised that your instance will be “forcefully stopped” and you should (if this is okay by you) say “yes” to this! This should get your instance stopped.

Sometimes, it only seems to work if you click this AGAIN, once or twice more, in 3-4 minutes time, but, in my experience, this always gets your instance stopped.

After which, you have to work out what went wrong… not the problem we’re dealing with here, but it is one we regularly fix on behalf of clients here at Silicon Dales. Usually, this unresponsiveness follows a RAM or CPU spike, which I think triggers limits imposed by AWS on your EC2 instance, and throttling is imposed, which, in some circumstances, probably broke your application. Toggling your Apache / MySQL or whatever services you have running so that they don’t routinely smash your RAM / CPU will certainly do no harm, and prevent recurrences. Clustering / firing up new instances when such events occur will also overcome this, but, again, this is for another article.

Leave a comment

No links of any kind allowed in comments - if you add any links, your comment will automatically be deleted.