Free preview. This lesson is open to everyone. Enroll to get the whole course and keep track of your progress.

Lesson

1.1 Objective review

The boot process

Every Linux boot follows the same chain. Knowing which stage owns which job is what most troubleshooting questions test.

  1. Firmware (BIOS or UEFI) runs the power-on self test, finds a boot device and loads the bootloader. UEFI reads an EFI executable from the EFI System Partition (a FAT32 partition, usually mounted at /boot/efi); legacy BIOS reads the first 446 bytes of the MBR.
  2. Bootloader (GRUB 2 on almost every distribution) shows the menu, then loads the kernel and the initial RAM disk into memory and passes the kernel its parameters.
  3. Kernel initializes hardware, mounts the initrd as a temporary root filesystem and runs its init program.
  4. initrd / initramfs contains just enough drivers and tools (storage, LVM, RAID, LUKS) to find and mount the real root filesystem, then hands over.
  5. init (PID 1, which is systemd on modern distributions) starts services and brings the system to its default target.

Bootloader configuration files

File Purpose
/etc/default/grub The settings you edit: GRUB_TIMEOUT, GRUB_DEFAULT, GRUB_CMDLINE_LINUX (kernel parameters for every entry)
/etc/grub.d/ Scripts that generate menu entries (40_custom for your own entries)
/boot/grub2/grub.cfg (RHEL family) or /boot/grub/grub.cfg (Debian family) The generated file GRUB reads. Never edit it by hand

After changing /etc/default/grub, regenerate the configuration with grub2-mkconfig -o /boot/grub2/grub.cfg (RHEL family) or update-grub (Debian family, a wrapper around grub-mkconfig). On RHEL family systems grubby changes kernel arguments directly, for example grubby --update-kernel=ALL --args="quiet".

Kernel parameters

The parameters the running kernel was booted with are in /proc/cmdline. Useful ones to know:

Parameter Effect
ro / rw Mount root read only (then remounted by systemd) or read write
root=UUID=... Which device holds the root filesystem
quiet, rhgb, splash Fewer messages, graphical boot screen
systemd.unit=rescue.target Boot to single user rescue mode (single or 1 also works)
systemd.unit=emergency.target Minimal emergency shell, root mounted read only
rd.break Stop inside the initramfs before root is switched (classic root password reset)
init=/bin/bash Replace init with a shell

To change parameters for one boot, press e at the GRUB menu, edit the linux line and press Ctrl+X. To make them permanent, edit GRUB_CMDLINE_LINUX and regenerate, or use grubby. Runtime kernel tunables (not boot parameters) are handled by sysctl, covered in objective 2.5.

PXE

Preboot Execution Environment boots a machine over the network with no local disk. The network card's firmware asks a DHCP server for an address; the DHCP reply includes the boot server (next-server) and boot file name, which the client downloads with TFTP, followed by the kernel and initrd. PXE is the usual first step of unattended installs (Kickstart, objective 4.1).

Filesystem Hierarchy Standard (FHS)

Directory Contents
/ Root of the single directory tree
/bin Essential user commands (ls, cp). On modern distributions a symlink to /usr/bin
/sbin Essential system administration commands (fdisk, ip). Often a symlink to /usr/sbin
/boot Kernel (vmlinuz-*), initramfs images and the GRUB directory
/dev Device files (/dev/sda, /dev/null), managed by udev
/etc Host specific configuration files, text only
/home Users' home directories (root's home is /root)
/lib Shared libraries and kernel modules (/lib/modules/<version>)
/proc Virtual filesystem exposing kernel and process information (/proc/cpuinfo, /proc/<PID>)
/tmp Temporary files, often cleared at boot and sometimes a tmpfs in RAM
/usr Read only, shareable programs, libraries and documentation
/var Variable data that grows: logs (/var/log), spools, caches, databases

Related: /sys (virtual view of devices and drivers), /run (runtime data since boot, a tmpfs), /opt (add-on software), /srv (data served by this host), /mnt and /media (mount points).

Virtual filesystems use no disk

/proc, /sys and /run exist only in memory. Files there are generated by the kernel when you read them, which is why ls -l /proc/cpuinfo shows a size of 0.

Server architectures

Name Notes
x86 32-bit Intel compatible (i386, i686). Mostly legacy
x86_64 / AMD64 64-bit extension of x86, designed by AMD. The most common server architecture
AArch64 64-bit ARM (also called ARM64). Low power, used by many cloud instances and single board computers
RISC-V An open, royalty-free instruction set architecture based on reduced instruction set principles

uname -m and lscpu show the architecture. Packages are built per architecture (for example x86_64, aarch64, or noarch for scripts and data), and Debian uses its own names such as amd64 and arm64.

Distributions

Family Package format and tools Examples
RPM-based .rpm; rpm, dnf (formerly yum), zypper on SUSE RHEL, Fedora, Rocky Linux, AlmaLinux, CentOS Stream, openSUSE, SLES
dpkg-based .deb; dpkg, apt Debian, Ubuntu, Linux Mint

Graphical user interface

  • X server (X11, Xorg): the classic display server. Network transparent, so applications can display on a remote X server (X forwarding over SSH). The DISPLAY variable says which display to use.
  • Wayland: the modern replacement protocol. The compositor is the display server, which simplifies the stack and isolates applications from each other. XWayland runs X11 applications on it.
  • Display manager: the graphical login screen that starts a session (GDM, SDDM, LightDM).
  • Window manager: places and decorates windows (Mutter, KWin, Openbox, i3). A desktop environment such as GNOME or KDE Plasma bundles one with panels, settings and applications.

Servers normally run without a GUI and boot to multi-user.target; desktops boot to graphical.target.

Software licensing

Term Meaning
Open source Source is available and the license meets the Open Source Definition (use, study, modify, redistribute)
Free software The Free Software Foundation's four freedoms: run, study and change, redistribute, distribute modified copies. "Free as in freedom", not price
Proprietary Source is closed; use is limited by an end user license agreement
Copyleft Derivative works must be distributed under the same license (GNU GPL). Permissive licenses (MIT, BSD, Apache 2.0) let derivatives become proprietary

The Linux kernel itself is licensed under GPL version 2.

Course outline

1.1 Explain basic Linux concepts

Not started: 1.1 Objective review Lesson
Locked: 1.1 Practice exam Enroll to unlock Quiz

1.2 Summarize Linux device management concepts and tools

Not started: 1.2 Objective review Lesson
Locked: 1.2 Practice exam Enroll to unlock Quiz

1.3 Given a scenario, manage storage in a Linux system

Not started: 1.3 Objective review Lesson
Locked: 1.3 Practice exam Enroll to unlock Quiz

1.4 Given a scenario, manage network services and configurations on a Linux server

Locked: 1.4 Objective review Enroll to unlock Lesson
Locked: 1.4 Practice exam Enroll to unlock Quiz

1.5 Given a scenario, manage a Linux system using common shell operations

Locked: 1.5 Objective review Enroll to unlock Lesson
Locked: 1.5 Practice exam Enroll to unlock Quiz

1.6 Given a scenario, perform backup and restore operations for a Linux server

Locked: 1.6 Objective review Enroll to unlock Lesson
Locked: 1.6 Practice exam Enroll to unlock Quiz

1.7 Summarize virtualization on Linux systems

Locked: 1.7 Objective review Enroll to unlock Lesson
Locked: 1.7 Practice exam Enroll to unlock Quiz

2.1 Given a scenario, manage files and directories on a Linux system

Locked: 2.1 Objective review Enroll to unlock Lesson
Locked: 2.1 Practice exam Enroll to unlock Quiz

2.2 Given a scenario, perform local account management in a Linux environment

Locked: 2.2 Objective review Enroll to unlock Lesson
Locked: 2.2 Practice exam Enroll to unlock Quiz

2.3 Given a scenario, manage processes and jobs in a Linux environment

Locked: 2.3 Objective review Enroll to unlock Lesson
Locked: 2.3 Practice exam Enroll to unlock Quiz

2.4 Given a scenario, configure and manage software in a Linux environment

Locked: 2.4 Objective review Enroll to unlock Lesson
Locked: 2.4 Practice exam Enroll to unlock Quiz

2.5 Given a scenario, manage Linux using systemd

Locked: 2.5 Objective review Enroll to unlock Lesson
Locked: 2.5 Practice exam Enroll to unlock Quiz

2.6 Given a scenario, manage applications in a container on a Linux server

Locked: 2.6 Objective review Enroll to unlock Lesson
Locked: 2.6 Practice exam Enroll to unlock Quiz

3.1 Summarize authorization, authentication, and accounting methods

Locked: 3.1 Objective review Enroll to unlock Lesson
Locked: 3.1 Practice exam Enroll to unlock Quiz

3.2 Given a scenario, configure and implement firewalls on a Linux system

Locked: 3.2 Objective review Enroll to unlock Lesson
Locked: 3.2 Practice exam Enroll to unlock Quiz

3.3 Given a scenario, apply operating system (OS) hardening techniques on a Linux system

Locked: 3.3 Objective review Enroll to unlock Lesson
Locked: 3.3 Practice exam Enroll to unlock Quiz

3.4 Explain account hardening techniques and best practices

Locked: 3.4 Objective review Enroll to unlock Lesson
Locked: 3.4 Practice exam Enroll to unlock Quiz

3.5 Explain cryptographic concepts and technologies in a Linux environment

Locked: 3.5 Objective review Enroll to unlock Lesson
Locked: 3.5 Practice exam Enroll to unlock Quiz

3.6 Explain the importance of compliance and audit procedures

Locked: 3.6 Objective review Enroll to unlock Lesson
Locked: 3.6 Practice exam Enroll to unlock Quiz

4.1 Summarize the use cases and techniques of automation and orchestration in a Linux environment

Locked: 4.1 Objective review Enroll to unlock Lesson
Locked: 4.1 Practice exam Enroll to unlock Quiz

4.2 Given a scenario, perform automated tasks using shell scripting

Locked: 4.2 Objective review Enroll to unlock Lesson
Locked: 4.2 Practice exam Enroll to unlock Quiz

4.3 Summarize Python basics used for Linux system administration

Locked: 4.3 Objective review Enroll to unlock Lesson
Locked: 4.3 Practice exam Enroll to unlock Quiz

4.4 Given a scenario, implement version control using Git

Locked: 4.4 Objective review Enroll to unlock Lesson
Locked: 4.4 Practice exam Enroll to unlock Quiz

4.5 Summarize best practices and responsible uses of artificial intelligence (AI)

Locked: 4.5 Objective review Enroll to unlock Lesson
Locked: 4.5 Practice exam Enroll to unlock Quiz

5.1 Summarize monitoring concepts and configurations in a Linux system

Locked: 5.1 Objective review Enroll to unlock Lesson
Locked: 5.1 Practice exam Enroll to unlock Quiz

5.2 Given a scenario, analyze and troubleshoot hardware, storage, and Linux OS issues

Locked: 5.2 Objective review Enroll to unlock Lesson
Locked: 5.2 Practice exam Enroll to unlock Quiz

5.3 Given a scenario, analyze and troubleshoot networking issues on a Linux system

Locked: 5.3 Objective review Enroll to unlock Lesson
Locked: 5.3 Practice exam Enroll to unlock Quiz

5.4 Given a scenario, analyze and troubleshoot security issues on a Linux system

Locked: 5.4 Objective review Enroll to unlock Lesson
Locked: 5.4 Practice exam Enroll to unlock Quiz

5.5 Given a scenario, analyze and troubleshoot performance issues

Locked: 5.5 Objective review Enroll to unlock Lesson
Locked: 5.5 Practice exam Enroll to unlock Quiz

Full XK0-006 practice exam

Locked: About the XK0-006 exam Enroll to unlock Lesson
Locked: XK0-006 Full practice exam (90 questions) Enroll to unlock Quiz