A Note from Your Trainer
Namaskar mitranno! (Hello, friends!)
Welcome! I have written this handbook the same way I teach in the classroom — slowly, step by step, and always starting with the question "Why do we even need this?" before we touch a single command.
Many of you know some programming already — C, Java, Python or JavaScript — but the words cloud, Linux server, security group or reverse proxy may still feel new. Kalji karu naka (don't worry) — that is perfectly fine. By the time you finish this book, you will launch your own servers on AWS, secure them, host static and dynamic websites, deploy complete application stacks and manage storage — exactly the kind of work cloud and DevOps engineers do every day.
A few requests from my side (dhyan do, these matter):
- Type the commands yourself. Copy-paste is allowed (every command box is copy-paste ready), but read each line and ask yourself what it does. Understanding is more important than speed. Lakshat theva (keep this in mind).
- Break things in your lab. Delete a config line, stop a service, block a port — then fix it. Troubleshooting is the real skill, and you learn it only by making mistakes in a safe environment.
- Don't memorise, understand. In interviews, nobody asks you to recite a command. They ask why it is needed and what happens when it fails. That is why every chapter ends with common mistakes and interview questions.
- Switch off what you start. Stop or terminate your lab instances when you finish. A forgotten server is the most common way students get a surprise bill.
Every topic follows the same simple pattern that I use in my sessions — ekdum simple aahe:
| Step | Question it answers | Example |
|---|---|---|
| Why | Why do we need this? What problem does it solve? | Why use EC2 instead of buying a physical server? |
| What | What exactly is it? What are its parts? | What is an AMI, a key pair, a security group? |
| How | How do I actually do it, step by step? | Commands to launch, connect and configure |
Got it? So open your laptop, keep a terminal ready, and let's learn cloud computing together. Why, What, How – every topic in this order. Come on, let's begin!
समजलं का? तर लॅपटॉप उघडा, टर्मिनल तयार ठेवा, आणि आपण मिळून क्लाउड कॉम्प्युटिंग शिकूया. Why, What, How – या क्रमाने प्रत्येक टॉपिक. चला, सुरू करूया!
समझ आया? तो लैपटॉप खोलो, टर्मिनल तैयार रखो, और हम मिलकर क्लाउड कंप्यूटिंग सीखते हैं. Why, What, How – इसी क्रम में हर टॉपिक. चलो, शुरू करते हैं!
Before we begin: conventions used in this book
- Commands you type are shown in grey boxes. They are copy-paste ready. Lines beginning with
#inside a code block are comments — they are ignored by the shell. $at the start of a line in an example means "normal user prompt"; do not type the$. In most code blocks we have omitted the prompt so you can paste directly.- Words in
<ANGLE_BRACKETS>orYOUR_...must be replaced with your own value, e.g.<PUBLIC_IP>becomes13.233.10.25. sudoruns a command as the administrator (root). Most server set-up commands need it.
Tip boxes
Green boxes give shortcuts and good habits that save time.
Note boxes
Blue boxes give extra background information or differences between operating systems.
Warning boxes
Orange boxes warn you about mistakes that can break your server, lose data or cost money.
Friends, in this book you will also see Ravindra Bagale's Tip and Lab boxes. A Tip holds the lessons from experience that I always tell students in class, and a Lab is a small practice you do yourself. Don't skip the Labs – cloud doesn't come without doing it by hand.
मित्रांनो, या बुकमध्ये तुम्हाला Ravindra Bagale's Tip आणि Lab बॉक्सेस पण दिसतील. टिपमध्ये मी क्लासमध्ये स्टुडंट्सना नेहमी सांगतो ते अनुभवाचे मुद्दे आहेत, आणि लॅब म्हणजे तुम्ही स्वतः करायची छोटी प्रॅक्टिस. लॅब वगळू नका – हाताने केल्याशिवाय क्लाउड येत नाही.
दोस्तों, इस बुक में आपको Ravindra Bagale's Tip और Lab बॉक्सेस भी दिखेंगे. टिप में वो अनुभव की बातें हैं जो मैं क्लास में स्टूडेंट्स को हमेशा बताता हूँ, और लैब मतलब आपको ख़ुद करनी वाली छोटी प्रैक्टिस. लैब छोड़ना मत – हाथ से किए बिना क्लाउड नहीं आता.
The three operating systems we will use together
In our labs we will practise on three popular Linux distributions that are available as free AMIs (machine images) on AWS:
| Item | Amazon Linux 2023 | Ubuntu 22.04 / 24.04 LTS | CentOS Stream 9 |
|---|---|---|---|
| Family | Red Hat–like (Fedora based) | Debian | Red Hat (RHEL upstream) |
| Package manager | yum |
apt |
yum |
| Default SSH user | ec2-user |
ubuntu |
ec2-user (older CentOS AMIs: centos) |
| Apache package / service | httpd |
apache2 |
httpd |
| Nginx default web root | /usr/share/nginx/html |
/var/www/html |
/usr/share/nginx/html |
| Apache default web root | /var/www/html |
/var/www/html |
/var/www/html |
| Host firewall | none active by default | ufw (inactive by default) |
firewalld (may be installed) |
| SELinux | permissive/disabled by default on AMI | not used (AppArmor) | enforcing |
| Default root filesystem | XFS | ext4 | XFS |
Cost awareness
AWS bills by the second/hour for running resources. Always stop or terminate lab instances, delete unused EBS volumes and snapshots, and release unused Elastic IPs when you finish. Set a billing alarm / budget in the AWS Billing console on day one. AWS free-tier offers change from time to time — always check the official AWS Free Tier page for the current rules on your account.
Ravindra Bagale's Tip
At the start, finish each lab on one OS – starting with Amazon Linux 2023 is easy. Then repeat the same lab on Ubuntu or CentOS; you only really remember the yum vs apt and httpd vs apache2 difference after doing it by hand.
Ravindra Bagale's Tip – मराठी
सुरुवातीला एकाच OS वर lab पूर्ण करा – Amazon Linux 2023 ने सुरू करणं सोपं आहे. मग तोच lab Ubuntu किंवा CentOS वर परत करा; yum vs apt आणि httpd vs apache2 चा फरक हाताने केल्यावरच खरंच लक्षात राहतो.
Ravindra Bagale's Tip – हिंदी
शुरुआत में एक ही OS पर lab पूरा करो – Amazon Linux 2023 से शुरू करना आसान है. फिर वही lab Ubuntu या CentOS पर दोबारा करो; yum vs apt और httpd vs apache2 का फ़र्क हाथ से करने के बाद ही सच में याद रहता है.
Practice Tasks
Maple Leaf Books is a bookselling business in Toronto. Emily Tremblay looks after its IT and cloud work. They count money in CAD and run their AWS resources in the ca-central-1 Region. In the tasks below you do real jobs for them using what this lesson teaches. All names, account IDs, IP addresses and numbers are made up for practice.
0 / 12
Easy List your EC2 instances
Why: Before changing anything, see what is running and in which state.
What to do: Show details of all EC2 instances of Maple Leaf Books in ca-central-1.
- Read the task and decide which AWS service it is about.
- Write aws, then the service name, then the operation (the action word).
- Add each needed flag (--name) followed by its value from the task.
- Flags can be in any order. Click Check answer.
Easy List Availability Zones
Why: Spreading servers across AZs keeps you up if one data centre fails.
What to do: List the Availability Zones in ca-central-1.
- Read the task and decide which AWS service it is about.
- Write aws, then the service name, then the operation (the action word).
- Add each needed flag (--name) followed by its value from the task.
- Flags can be in any order. Click Check answer.
Easy List all Regions
Why: Choose a Region close to your users for low delay and the right laws.
What to do: List the AWS Regions available to your account.
- Read the task and decide which AWS service it is about.
- Write aws, then the service name, then the operation (the action word).
- Add each needed flag (--name) followed by its value from the task.
- Flags can be in any order. Click Check answer.
Easy Read a config file
Why: Reading a file on the screen is the quickest way to check its settings.
What to do: Print the whole file /etc/mapleleafbooks/app.conf on the screen.
- Find the Linux command that does this job.
- Add the options (like -r or -h) the task needs.
- Add the file names, folders or users in the right order.
- Use sudo if the job changes system files or users. Click Check answer.
Easy List all files with details
Why: Hidden files (like .env) and file sizes or owners only show with the right options.
What to do: Show a long listing of every file, including hidden ones, in /var/www/mapleleafbooks.
- Find the Linux command that does this job.
- Add the options (like -r or -h) the task needs.
- Add the file names, folders or users in the right order.
- Use sudo if the job changes system files or users. Click Check answer.
Easy Create nested folders in one go
Why: Projects need a clean folder tree. Making all levels in one command saves time and avoids errors.
What to do: Create the folder /srv/mapleleafbooks/reports/2026 for Maple Leaf Books. The parent folders do not exist yet, so create them too.
- Find the Linux command that does this job.
- Add the options (like -r or -h) the task needs.
- Add the file names, folders or users in the right order.
- Use sudo if the job changes system files or users. Click Check answer.
Easy Show where you are
Why: Before you copy or delete anything, you must know which folder you are in.
What to do: Emily Tremblay logged in to the Maple Leaf Books server and is not sure which folder the terminal is in. Print the current folder path.
- Find the Linux command that does this job.
- Add the options (like -r or -h) the task needs.
- Add the file names, folders or users in the right order.
- Use sudo if the job changes system files or users. Click Check answer.
Easy Create an empty file
Why: Some apps need a file to exist before they can write to it.
What to do: Create an empty file named orders-cad.csv in the current folder.
- Find the Linux command that does this job.
- Add the options (like -r or -h) the task needs.
- Add the file names, folders or users in the right order.
- Use sudo if the job changes system files or users. Click Check answer.
Easy List files in a bucket folder
Why: Check that the upload worked and see file sizes.
What to do: List the objects under s3://mapleleafbooks-invoices-2026/reports/.
- Read the task and decide which AWS service it is about.
- Write aws, then the service name, then the operation (the action word).
- Add each needed flag (--name) followed by its value from the task.
- Flags can be in any order. Click Check answer.
Easy Create a bucket
Why: A bucket is the top-level container for your files in S3.
What to do: Create the bucket mapleleafbooks-invoices-2026 in ca-central-1.
- Read the task and decide which AWS service it is about.
- Write aws, then the service name, then the operation (the action word).
- Add each needed flag (--name) followed by its value from the task.
- Flags can be in any order. Click Check answer.
Easy Check who you are logged in as
Why: Always confirm the account and identity before running changes.
What to do: Show the account ID and ARN of the identity your CLI is using.
- Read the task and decide which AWS service it is about.
- Write aws, then the service name, then the operation (the action word).
- Add each needed flag (--name) followed by its value from the task.
- Flags can be in any order. Click Check answer.
Easy How many addresses in a /16?
Why: Picking a VPC size needs this count.
What to do: Maple Leaf Books plans the VPC 10.131.0.0/16. How many IP addresses does it hold in total?
- Write down the numbers the task gives you.
- Work it out step by step on paper.
- Type only the final answer in the box.
- Click Check answer.