Book Image

AWS for System Administrators

By : Prashant Lakhera
Book Image

AWS for System Administrators

By: Prashant Lakhera

Overview of this book

Amazon Web Services (AWS) is one of the most popular and efficient cloud platforms for administering and deploying your applications to make them resilient and robust. AWS for System Administrators will help you to learn several advanced cloud administration concepts for deploying, managing, and operating highly available systems on AWS. Starting with the fundamentals of identity and access management (IAM) for securing your environment, this book will gradually take you through AWS networking and monitoring tools. As you make your way through the chapters, you’ll get to grips with VPC, EC2, load balancer, Auto Scaling, RDS database, and data management. The book will also show you how to initiate AWS automated backups and store and keep track of log files. Later, you’ll work with AWS APIs and understand how to use them along with CloudFormation, Python Boto3 Script, and Terraform to automate infrastructure. By the end of this AWS book, you’ll be ready to build your two-tier startup with all the necessary infrastructure, monitoring, and logging components in place.
Table of Contents (18 chapters)
1
Section 1: AWS Services and Tools
4
Section 2: Building the Infrastructure
7
Section 3: Adding Scalability and Elasticity to the Infrastructure
11
Section 4: The Monitoring, Metrics, and Backup Layers

Backing up your data to S3 using the AWS CLI

AWS S3 is an ideal place to back up your data as it is infinitely scalable and can store and retrieve any amount of data. This section will show you how to use the AWS Command Line interface (CLI) (which we set up in Chapter 1, Setting up the AWS Environment) to access S3. We will build our script for backing up our files and easily retrieving them as needed. We will then add this script in cron to schedule tasks at regular intervals—for example, 5 minutes, which means that our script will make a backup of our files every 5 minutes. These are the steps we need to follow:

  1. The first step is to create the bucket. This is an optional step; if you already have a bucket created you can use it. To create a new bucket named my-backup-bucket-master-aws-system-administration, we need to pass the mb (make bucket) option to the s3 command:
    $ aws s3 mb s3://my-backup-bucket-master-aws-system-administration
    make_bucket: my-backup-bucket...