loading...
Cover image for AWS: EC2 Hibernation
ExamPro

AWS: EC2 Hibernation

coffeecraftcode profile image Christina Gorton Updated on ・2 min read

Amazon Elastic Compute Cloud (Amazon EC2) is a web service that provides secure, resizable compute capacity in the cloud.

It is designed to make web-scale computing easier for developers.

What is EC2 Hibernation?

Have you ever put your computer to "sleep"?
When you close the computer your work is still saved and available as soon as you open the computer back up.

In the same way we can put our EC2 instances "to sleep" or hibernation.

Hibernation Flow:

EC2 Hibernation flow

Benefits

Hibernation saves the contents from the instance memory (RAM) to your Amazon EBS root volume.

This leads to a faster boot up time for your instances.

AWS persists the instance's Amazon EBS root volume and any attached Amazon EBS data volumes.

When an instances is started again:

  • Your Amazon EBS volume is restored to it's previous state. (Like when opening a computer that has been "put to sleep")
  • Your RAM contents are reloaded and the processes that previously were running on the instance are resumed.

Important Information

EC2 hibernation is available for On-Demand and Reserved Instances.

An Instance can only be put in to hibernation if it meets the hibernation prerequisites.

Examples of prerequisites include:

  • The root EBS volume must be encrypted.
  • Supported instance families include: C3, C4, C5, M3, M4, M5, R3, R4, and R5
  • Instance RAM size must be less than 150 GB
  • The Amazon Machine Images it currently supports are Amazon Linux 2, Linux AMI, Ubuntu and Windows

AWS does not charge for a hibernated instance when it is in a stopped state.

There are limitation and actions not supported for hibernation.

For a complete list of limitations check out the AWS documentation.

Use Cases for Hibernation:

  • Apps with long-running processing
  • To save RAM state for quicker boot-up
  • For services that take a lot of time to initialize

This topic is addressed in the new AWS Solutions Architect Exam[SAA-C02]

If you want to learn even more and prepare for the AWS Certified Solutions Architect Associate Exam then check out our course on ExamPro.

Posted on by:

coffeecraftcode profile

Christina Gorton

@coffeecraftcode

Open Source Community Manager, Technical Writer, Developer, and Instructor. Courses on Egghead, Design + Code, and Skillshare. https://egghead.io/instructors/christina-gorton

ExamPro

We create cloud certification courses. Videos, Quizlets, Flashcards, Cheatsheet and Practice Exams!

Discussion

pic
Editor guide