Practice Exercises

3 minute read

Test your understanding of the Linux introduction concepts. These exercises are knowledge-based — no terminal needed yet.


Exercise 1 — What is the Linux Kernel?

Question: In your own words, explain what the Linux kernel does and why application programs don’t talk to hardware directly.

Show Answer

The Linux kernel is the core of the operating system. It manages four main responsibilities:

  1. Hardware management — it communicates with CPUs, RAM, disk drives, and network cards so applications don’t have to
  2. Process management — it schedules which programs run on which CPU core
  3. Memory management — it allocates RAM to programs and prevents one program from accessing another’s memory
  4. File system interface — it provides a unified way to read/write files across different storage types

Applications don’t talk to hardware directly because it would be insecure and impossible to coordinate — imagine 100 programs all trying to write to your disk simultaneously with no coordination. The kernel acts as a trusted intermediary.


Exercise 2 — Kernel, Shell, or Distro?

Question: Match each item to its correct category: bash, Ubuntu, Linux 6.8, apt, zsh, Alpine, the program that schedules CPU time

Item Category (Kernel / Shell / Distro)
bash ?
Ubuntu ?
Linux 6.8 ?
apt ?
zsh ?
Alpine ?
CPU scheduler ?
Show Answer
Item Category
bash Shell
Ubuntu Distro
Linux 6.8 Kernel
apt Part of Distro (package manager)
zsh Shell
Alpine Distro
CPU scheduler Kernel

Exercise 3 — Distro Selection

Question: A colleague asks you which Linux distro to use for each situation. What do you recommend and why?

  1. A beginner learning Linux for the first time
  2. Preparing for the RHCSA exam
  3. Building a Docker base image that needs to be as small as possible
  4. A developer who wants the latest package versions on their laptop
Show Answer
  1. Ubuntu 22.04 LTS — largest community, best beginner documentation, default on major cloud providers, easy apt package management

  2. Rocky Linux 9 — free rebuild of RHEL, same package manager (dnf), same SELinux behaviour, same exam environment

  3. Alpine Linux — base image is ~5MB vs Ubuntu’s ~29MB, designed specifically for containers, minimal attack surface

  4. Fedora — upstream of RHEL, always ships the latest versions of packages like kernel, GNOME, Python, GCC — ideal for developers who want cutting-edge tools


Exercise 4 — Linux History Timeline

Question: Place these events in the correct chronological order:

  • Docker released
  • GNU Project launched by Stallman
  • Linus Torvalds’ Usenet post
  • UNIX created at Bell Labs
  • Ubuntu 4.10 released
  • Android launched
Show Answer
  1. 1969 — UNIX created at AT&T Bell Labs
  2. 1983 — GNU Project launched by Richard Stallman
  3. 1991 — Linus Torvalds’ Usenet announcement of Linux kernel
  4. 2004 — Ubuntu 4.10 “Warty Warthog” released
  5. 2007 — Android 1.0 launched (Linux kernel on mobile)
  6. 2013 — Docker released (Linux containers go mainstream)

Exercise 5 — Real World Linux

Question: For each of the following scenarios, identify whether Linux is involved and how:

  1. You upload a photo to Instagram
  2. You run docker run nginx on your MacBook
  3. You send a text message from an Android phone
  4. You browse a website hosted on AWS
Show Answer
  1. Instagram — your photo is processed and stored on Linux-based servers. Instagram’s backend runs on Linux (Meta’s infrastructure uses Linux extensively).

  2. docker run nginx on MacBook — Docker Desktop runs a lightweight Linux VM (LinuxKit) on macOS. The nginx container shares that Linux kernel. Your MacBook runs macOS (BSD-based), but the container runs Linux inside a VM.

  3. Android text message — Android uses the Linux kernel. Your text message is processed on a device running Linux (though with Android’s user space, not GNU tools).

  4. AWS-hosted website — AWS EC2 instances default to Linux. The web server (nginx, Apache) runs on Linux. The request travels from your browser through Linux-based infrastructure to reach the content.


Chapter 1 Complete ✅

You now understand:

  • What Linux is (kernel + GNU tools + package manager = distro)
  • Where Linux came from (UNIX → GNU → Linux kernel)
  • How the three layers relate (kernel ↔ shell ↔ distro)
  • Which distro to use for different situations
  • Why Linux matters in the real world

Next Chapter → Overview of Bash

Updated: