Linux Introduction

What Linux is, why backend engineers rely on it, and the major distribution families.

What Linux actually is

Linux is an open-source, Unix-like operating system kernel, originally written by Linus Torvalds in 1991 and now maintained by thousands of contributors worldwide. Strictly speaking, "Linux" refers only to the kernel — the core program that talks to hardware, manages memory, and schedules processes. What most people call "a Linux system" is actually GNU/Linux: the Linux kernel bundled with the GNU userland tools (bash, coreutils, compilers), a package manager, and (usually) a desktop or server-oriented set of defaults. A packaged bundle like this is called a distribution, or "distro."

Because the kernel is open source and free to redistribute, hundreds of distributions exist, each making different choices about package management, defaults, and philosophy — but they all share the same kernel underneath.

Why every backend engineer needs it

If you write server-side software, you are almost certainly deploying it onto Linux, whether you notice or not:

  • Servers. The overwhelming majority of public web servers, and virtually all major cloud providers' default compute images, run Linux. Windows Server exists, but Linux dominates general-purpose backend hosting.
  • Containers. Docker containers share the host kernel (more on this in the Docker tutorials) — even a container labeled "based on a minimal image" is running on a Linux kernel underneath. This is true even when you develop on macOS or Windows: Docker Desktop runs a lightweight Linux VM behind the scenes.
  • CI/CD runners. GitHub Actions, GitLab CI, and most other pipelines default to Linux runners because they're faster to start and cheaper to run than Windows or macOS equivalents.
  • The cloud. AWS, Google Cloud, and Azure are themselves built on custom Linux distributions, and the default, cheapest compute instances on every one of them boot Linux.

In short: the code you write locally on a laptop eventually runs, gets tested, and gets deployed on Linux. Being comfortable at a Linux shell is not a niche "sysadmin" skill — it's baseline literacy for shipping backend software.

Major distribution families

Nearly every distribution you'll encounter traces back to one of two lineages, which mostly differ in package format and package manager:

Family Package format Package manager Examples
Debian-based .deb apt / apt-get Debian, Ubuntu, Linux Mint
Red Hat-based .rpm dnf (formerly yum) RHEL, Fedora, CentOS Stream, Rocky Linux, AlmaLinux

Ubuntu (Debian-based) is the most common choice for cloud servers and CI images — it has predictable release cycles (a new LTS, or Long Term Support, release every two years, supported for five years) and the widest amount of "how do I install X on Ubuntu" documentation available.

RHEL (Red Hat Enterprise Linux) and its free derivatives dominate enterprise and regulated environments, where long support contracts and certified compatibility matter. Fedora is RHEL's faster-moving, community-driven upstream — newer packages, shorter support windows, popular with developers who want current software.

Day to day, the commands you run (ls, cd, grep, chmod) are identical across every distribution — they come from the same GNU/Linux userland. What differs between families is almost entirely how you install software (apt install nginx vs. dnf install nginx) and where a few configuration files live by convention.

The shell and the terminal

The terminal (or terminal emulator) is the program that gives you a text window to type into. The shell is the program that actually reads what you type, interprets it, and runs it — it's a command interpreter, not just a text box. When you open a terminal on Linux, you're almost always talking to a shell called Bash (Bourne Again Shell), though zsh and others are common too.

The shell does far more than run one command at a time. It supports:

  • variables and control flow (loops, conditionals) — a real, if minimal, programming language (covered in Shell Scripting Basics);
  • piping output from one program directly into another's input (|);
  • redirection of output to files (>, >>);
  • a persistent, scriptable environment you can automate — which is exactly why servers are administered through it instead of a GUI.

A typical session looks like this:

Bash
$ whoami
deploy
$ pwd
/home/deploy
$ uname -a
Linux web-01 6.8.0-45-generic #45-Ubuntu SMP x86_64 GNU/Linux

The $ at the start of a line is the prompt — it's printed by the shell, not something you type. Every example in this section shows commands after a $ and their output on the following lines, exactly as you'd see them in a real terminal.

Common mistakes

  • Assuming "Linux" means one specific thing — in practice you should think in terms of "which distribution, which package manager, which shell" since defaults vary.
  • Confusing the terminal (the window) with the shell (the program interpreting commands) — you can run different shells inside the same terminal emulator.
  • Avoiding the command line in favor of GUI file managers when working on remote servers — most servers don't have a GUI installed at all, and even when they do, the shell is faster and scriptable.

Interview questions

Q: What is the difference between Linux and a Linux distribution? Linux, strictly, is just the kernel — the core software managing hardware, memory, and processes. A distribution ("distro") packages that kernel together with the GNU userland tools, a package manager, and configuration defaults into a complete, installable operating system, such as Ubuntu or Fedora.

Q: Why do cloud providers and CI systems default to Linux instead of Windows? Linux is free to redistribute with no per-instance licensing cost, has a smaller resource footprint, boots faster, and its ecosystem of server software (web servers, databases, container runtimes) is built Linux-first. That combination makes Linux instances cheaper to run and faster to provision at scale.

Q: What's the practical difference between Debian-based and Red Hat-based distributions? Mainly the package format and package manager — .deb packages installed with apt on Debian/Ubuntu versus .rpm packages installed with dnf on RHEL/Fedora. The core command-line tools and kernel behavior are otherwise the same; the difference shows up almost entirely when installing or updating software.