0

According to the AWS doc:

When you stop a running instance ... The instance is migrated to a new underlying host computer when it's started.

Here is also slightly different statement from the same doc:

When you start your instance, it enters the pending state, and in most cases, we move the instance to a new host computer. (Your instance may stay on the same host computer if there are no problems with the host computer.)

So what is the rationale behind the need to move instances to a new host when they are restarted?

The only reason this question has emerged is that I found a question in an AWS Certification Exam sample asking whether migration to new host happens, and currently see no way how one would be able to guess the correct answer.

3

When you stop an instance compute resource is released. That compute resource can be reused by others while you don't need it, even if it's just a second until you ask for it again. When you request new compute resources you're allocated whatever resources are available. There's no reason it would be started on the same host, this request is not connected to the previous request. It might be that the instance was on an old previous generation host that Amazon wants to derack, or a server showing signs of failure. Most often it's just irrelevant where the instance starts.

Note that a restart of the instance does keep the instance on the same hardware, and ephemeral stores are kept. It's an explicit stop then start that moves it to new hardware.

Update - I checked with Amazon about this and they basically agree with what I said.

"The second sentence is more technically accurate - in most cases, the instance is moved to new hardware but we don't guarantee it. There may be a very small percentage of cases where it isn’t. However, we will not restart the instance on the same hardware if there is an issue with the hardware."

  • But in that case an instance still may be started on the same host, i.e. it is completely random what host it gets started on next time, correct? Why would the fist doc quote then say "instance is migrated" like there is a mechanism to actually make sure it does not start on the same host? – Greendrake Nov 3 '16 at 9:58
  • 1
    I'm not sure that the precise behavior is defined by AWS, documentation is ambiguous. All you know is that stop and start there's a very high chance that your instance is started on different hardware. In the exam I believe the answer is that the instance is migrated to another server after a stop/start. This is based on my experience passing all the AWS associate exams with marks above 90%, and my study towards the professional exams. I have sent feedback to AWS about this just now. – Tim Nov 3 '16 at 18:44
  • I've checked with Amazon. I updated my answer, which perhaps you could accept if you're happy with it. – Tim Nov 4 '16 at 19:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.