← All articles
Information TechnologyMay 6, 20238 min read

Introduction to Linux

The open-source operating system that runs the cloud — and the administration fundamentals every engineer should know.

What is Linux?

Linux is a free and open-source operating system kernel first released in 1991 by Linus Torvalds. Strictly speaking, "Linux" is just the kernel — the software that talks directly to hardware. What most people call Linux is a distribution: the kernel plus GNU utilities, a package manager, and an ecosystem. That combination now powers the majority of the world's servers, all of the top 500 supercomputers, Android phones, network routers, and nearly every cloud instance you will ever deploy to.

Why it won the server room

  • It's free and open: no per-core licensing fees, and every behavior is inspectable. When something breaks at 3 AM, you can read the source instead of opening a support ticket.
  • Stability: Linux servers routinely measure uptime in years. Process isolation and memory management are battle-hardened at planetary scale.
  • Flexibility: the same kernel family runs on a Raspberry Pi and a 128-core cloud VM — stripped down or scaled up as the workload demands.
  • The ecosystem: Docker, Kubernetes, Ansible, Terraform, Prometheus — the entire DevOps toolchain was built Linux-first.

Everything is a file

This is the single most important Linux mental model. Hardware devices (/dev/sda), per-process information (/proc/1234), kernel tunables (/sys) — all exposed as files. Learn to read files and you can debug almost anything.

The directories you will live in:

  • /etc — configuration files. If you changed a behavior, the file is probably here.
  • /var/log — logs. Your first stop whenever anything breaks.
  • /home — user home directories.
  • /opt — third-party software.
  • /tmp — temporary files, wiped on reboot.
  • /proc and /sys — virtual filesystems exposing kernel and process state.

Users, groups, and permissions

Every file has an owner, a group, and three permission triples — read (4), write (2), execute (1) — for user, group, and others. chmod 755 means rwxr-xr-x: full control for the owner, read and execute for everyone else. Directories need the execute bit just to be entered, which is why a 750 directory stays invisible to the web-server user even when the files inside are world-readable — a gotcha that has bitten every administrator at least once.

  • useradd, usermod, userdel — the account lifecycle.
  • passwd, chage — passwords and expiry policy.
  • groupadd, usermod -aG — groups. Always use -a with -G, or you will silently wipe existing memberships.
  • chown, chmod — ownership and permissions; chmod -R recurses.
  • id — shows your UID, primary GID, and supplementary groups.
Default to least privilege: grant the minimum access that gets the job done, and prefer groups over per-user grants so permissions stay auditable.

Disks and storage

  • Discovery: lsblk and fdisk -l show block devices and partitions.
  • Partitioning: fdisk / gdisk for MBR/GPT layouts.
  • Filesystems: mkfs.ext4 or mkfs.xfs, then mount to attach — with persistent mounts declared in /etc/fstab.
  • LVM: pvcreate → vgcreate → lvcreate gives resizable logical volumes — the professional default on servers.
  • Health: df -h for usage, du -sh /* for hunting space hogs, fsck for repair (unmounted filesystems only).

Packages: apt vs dnf

Debian/Ubuntu use apt; the RHEL family uses dnf (formerly yum). The workflow is identical everywhere: refresh the index, upgrade deliberately, install from trusted repositories.

  • apt update && apt upgrade / dnf check-update && dnf upgrade
  • Pin critical versions in production — blind upgrades on a Friday afternoon are how outages are born.
  • Prefer signed distro packages over curl-piped-to-bash installers: they are versioned, verifiable, and cleanly removable.

systemd: the init system

Modern Linux is managed by systemd. Services are units described in files under /etc/systemd/system/:

  • systemctl status nginx — is it running, and what did it log recently?
  • systemctl enable --now nginx — start it now and on every boot.
  • journalctl -u nginx -f — follow a service's logs; add -p err to filter errors.
  • systemctl daemon-reload — run after editing any unit file.

Networking basics

  • ip addr / ip route — the modern replacements for ifconfig and route.
  • ss -tulpn — what is listening on which port, and which process owns it. Your best friend during "connection refused".
  • /etc/hosts and /etc/resolv.conf — local name resolution and DNS.
  • Firewalls: ufw on Ubuntu, firewalld on RHEL. Default-deny inbound; open only what you need.
  • curl -v, ping, traceroute — for answering "is it the network or the app?"

A troubleshooting methodology

Tools matter less than method. When a Linux box misbehaves, work the same loop every time:

  1. Reproduce and scope: what exactly fails, for whom, since when? One host or many?
  2. Read the logs: journalctl, /var/log/*, dmesg for kernel and hardware issues.
  3. Check resources: top, free -h, df -h, ss — CPU, memory, disk, sockets.
  4. Isolate the layer: DNS? firewall? service down? bad config? Bisect until one variable remains.
  5. Fix, verify, document: confirm the fix survives a reboot, then write down what happened.
Ninety percent of "mysterious" Linux issues are disk full, permissions, DNS, or a service that didn't start on boot. Check those four first and you'll look like a wizard.

Where to go from here

These fundamentals compound: every container host, CI runner, and cloud instance you will ever manage sits on top of them. Get comfortable with users, permissions, disks, packages, systemd, and the network stack — then shell scripting and automation multiply everything you just learned.

MK
Mohankrishna PodileDevOps Engineer & Cloud Architect · Irving, Texas

Comments

Questions, corrections, war stories — all welcome. Sign in with GitHub to join the discussion.