0% found this document useful (0 votes)
39 views14 pages

AWS EC2 Backup and Migration Guide

The document outlines procedures for backing up AWS EC2 instances, including creating snapshots and AMIs, as well as migrating instances across regions. It details steps for using Elastic Block Store (EBS) and AWS Backup to automate backup processes. Additionally, it describes hosting applications using Elastic Beanstalk and managing backup plans within the AWS Management Console.

Uploaded by

psaran709
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
39 views14 pages

AWS EC2 Backup and Migration Guide

The document outlines procedures for backing up AWS EC2 instances, including creating snapshots and AMIs, as well as migrating instances across regions. It details steps for using Elastic Block Store (EBS) and AWS Backup to automate backup processes. Additionally, it describes hosting applications using Elastic Beanstalk and managing backup plans within the AWS Management Console.

Uploaded by

psaran709
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 14

Assignment 1

How to take a backup of your instance and launch new instance from the Backup.

Synopsis:
Demonstrate how to take a backup of your instance and Launch Brand New instance from
your backup with the same configuration.

 Using EBS with EC2 Linux Server Instances.

Synopsis:
Demonstrate the creation, attaching, accessing, and updating of an additional Elastic Block
Store (EBS) across EC2 Linux Servers in the same Subnet as well as in the subnets (of a user
created Virtual Private Network (VPC)) created in different Availability Zones (AZs) of the
region!

To back up AWS EC2 instance, you need to take the following steps:
1. Sign in to your AWS account to open the AWS console.
2. Select Services in the top bar and click EC2 to launch the EC2 Management Console.
3.Select Running Instances and choose the instance you would like to back up.

4.In the bottom pane, you can view the central technical information about the instance. In
the Description tab, find the Root device section and select the /dev/sda1 link.
5.In the pop-up window, find the volume’s EBS ID name and click it.
6.The Volumes section should open. Click Actions and select Create Snapshot.

7.The Create Snapshot box should open, where you can add a description for the snapshot
to make it distinct from other snapshots, as well as assign tags to easily monitor this
snapshot. Click Create Snapshot.
8.The snapshot creation should start and be completed in a minimal amount of time. The
main factor here is the size of data in your Amazon EBS volume.
After the snapshot creation is complete, you can find your new snapshot by selecting
the Snapshots section in the left pane. As you can see, we have successfully created a point-
in-time copy of the EBS volume, which can later be used to restore your EC2 instance.

For this purpose, you need to select the snapshot of the backed up volume, press
the Actions button above, and click Create Volume. Following the prompts, configure the
volume details (volume type, size, IOPS, availability zone, tags). Then, click Create
Volume for the new volume to be created, which can later be added to the AWS EC2
instance of your choice.
Assignment 2
 Migrate your instance from One Region to Another Region
Synopsis:
I want to move or copy my Amazon Elastic Compute Cloud (Amazon EC2) instance to
another subnet, Availability Zone, or virtual private cloud (VPC).

Use the two methods for migrating the instance:


1.Use the AWS Systems Manager automation document AWSSupport-CopyEC2Instance.
2.Manually copy an instance and a launch a new instance from the copy.

Creating a new AMI


The next approach to performing AWS EC2 backups is creating an Amazon
Machine Image (AMI) of your AWS EC2 instances. An AMI contains all the information
required for creating an EC2 instance in the AWS environment, including configuration
settings, the root volume template, launch permissions, and block device mapping. Basically,
the AMI can act as a template for launching a new AWS EC2 instance and replacing the
corrupted one. Note that, prior to creating the new AMI, it is recommended that you stop
the AWS EC2 instance which you want to back up.
To create a new AMI and ensure AWS EC2 backup, you should do the following:
1. Sign in to your AWS account to open the AWS console.
2. Select Services in the top bar and click EC2 to launch the EC2 Management Console.

3.Select Running Instances and choose the instance you want to back up.

4.Click Actions > Image > Create Image.


5.The Create Image menu should open. Here, you can specify the image name, add the image
description, enable/disable reboot after the AMI creation, and configure instance volumes.
Do note that when you create an EBS image, an EBS snapshot should also be created for each of the
above volumes. You can access these snapshots by going to the Snapshots section.

6.Click Create Image.

7.The image creation process should now start. Click the link to view the pending AMI.

8.It should take some time for the new AMI to be created. You can starting using the AMI when its
status switches from pending to available.

After the AMI has been successfully created, it can then be used to create a new AWS EC2 instance,
which will be an exact copy of the original instance. For this purpose, simply go to
the Instances section, click Launch Instance, select the AMI you have created in the My
AMIs section, and follow the prompts to finish the instance creation.

Creating AMIs is arguably a more effective backup strategy than taking EBS snapshots. This is
due to the fact that AMIs often contain EBS snapshots as well as a software configuration which
allows you to simply and easily launch the new AWS EC2 instance in just a few clicks, created free of
charge (you only pay for snapshot storage).

However, both methods require significant manual input on your part and cannot be set to
run automatically. AWS EC2 backup in large-scale environments using these two approaches has
proven itself to be a complicated and error-prone process.

Assignment 3
 Host and deploy an application using Elastic Beanstalk
Synopsis:
Create your example application, you'll use the Create a web app console wizard. It
creates an Elastic Beanstalk application and launches an environment within it. An
environment is the collection of AWS resources required to run your application code.

Automating AWS EC2 backup.


To create an AWS backup plan, take the following steps:

1. Sign in to your AWS account to open the AWS Management Console.

2. Select Services in the top bar and then type AWS Backup in the search bar. Click Backup
plans in the left pane.

3. Press the Create Backup plan button.


4. Here, you have three start options: Start from an existing plan,
Build a new plan, and Define a plan using JSON.
Click Info if you want to learn more about available options to
help you make the right decision. As we don’t have any
existing backup plans, let’s build a new plan from scratch.
Enter the new backup plan name and proceed further.

5.The next step is Backup rule configuration. Here, you should specify the backup rule name.

6.After that, you can set up a backup schedule. You should determine the backup frequency (Every
12 hours, Daily, Weekly, Monthly, Custom cron expression); backup window (Use backup window
defaults or Customize backup window); backup lifecycle (Transition to cold storage and Expiration of
the backup).
7.At this step, you should select the backup vault for storing your recovery points (the ones created
by this Backup rule). You can click Create new Backup vault if you want to have a new customizable
vault. You can also use the existing Backup vault if you have one. Alternatively, you can choose the
default AWS Backup vault.

8.Next, you must add tags to recovery points and your backup plan in order to organize them and
easily monitor their current status.
After that, you can click Create plan to proceed to the next stage, the backup rule creation.

9.Your backup plan has been successfully created. However, before you can run this plan and deploy
it in your environment, you should also assign resources which need to be backed up. Click
the Assign resources button, which can be found in the top bar.
10.In the next menu, you can specify the resource assignment name and define the IAM (Identity
and Access Management) role. By selecting the IAM role, you specify what a user can or cannot do in
AWS and determine which users are granted permission to manage selected AWS resources and
services. Additionally, you can assign resources to this Backup plan using tags or resource IDs,
meaning that any AWS resources matching these key-pair values should be automatically backed up
by this Backup plan.
11.Click Assign resources to complete the configuration process. After that, the backup job should
run automatically. You can go to the AWS Backup dashboard to see the current status of your backup
jobs and verify that they are working as planned.

As you can see, our backup job is already in progress. In this menu, you can also Manage Backup
plans, Create an on-demand backup, or Restore backup. Choose the required option and set up
another data protection job in AWS environment following the prompts.

You might also like