Study guide · Core notes

LPIC-2: the host and the services

Reference notes for version 4.5 exams 201-450 and 202-450. Each section names the command or file the objective expects, and the mistake that usually follows it.

Version 4.5 · 201-450 and 202-450Topics 200–212Reviewed November 12, 2026

How to read these notes: Unmarked items sit on the published LPIC-2 version 4.5 objectives. Items tagged Extra are job context the objective list does not require. New to the exams? Start with the overview for weights and the version notice. Practice on a system you can rebuild.

Capacity planning

Topic 200. Objective 200.1 is weight 6, the heaviest item on exam 201.

Live counters

vmstat prints processes, memory, swap, blocks, and CPU. wa is I/O wait. si and so are swap in and out. iostat splits CPU from device I/O. iotop names the process doing the I/O. top and htop are the live process views. uptime and w show the 1, 5, and 15 minute load averages.

What load average means

The load average counts tasks that are running or stuck in uninterruptible sleep. It is not a CPU percentage. A high load with idle us and sy and a large wa is a disk problem. A high si/so with little free memory is paging.

History and owners

sar reads counters the sysstat collector stored, so you can graph yesterday. ss and the older netstat list sockets. lsof shows which process holds a file or a port. pstree shows parent and child.

Trends

Objective 200.2 asks you to watch growth and name the point where a resource runs out. Icinga2, Nagios, collectd, MRTG, and Cacti are awareness. They are not a substitute for reading vmstat on a sick host.

Kernel

Topic 201. Runtime management is weight 4.

Images

bzImage is the usual compressed boot image and can be larger than the older zImage. xz is a compression option the version 4.5 objective adds. Documentation lives under the kernel source tree, often /usr/src/linux/Documentation. uname -r is the running release and must match /lib/modules.

Build

make menuconfig edits .config. oldconfig updates an existing file. make and make modules build. modules_install copies modules into /lib/modules/version. mrproper deletes generated files, including the config. Install an initramfs with mkinitramfs or mkinitrd. dracut is awareness. Then point the bootloader at the new kernel.

Modules

modprobe loads dependencies from modules.dep and applies files in /etc/modprobe.d. insmod loads one object and does not resolve dependencies. rmmod removes a module whose use count is zero. depmod rebuilds the dependency file. modinfo shows parameters. lsmod lists what is loaded.

Runtime

sysctl reads and writes /proc/sys. Persistent values go in /etc/sysctl.conf or /etc/sysctl.d. dmesg is the kernel ring buffer. lspci, lsusb, and lsdev describe hardware. udevadm monitor watches udev events. DKMS rebuilds registered out-of-tree modules after a new kernel is installed.

Startup and recovery

Topic 202. System recovery is weight 4. BIOS and UEFI are both in scope, including NVMe boot.

systemd and SysV

systemctl get-default and set-default choose the boot target. Local overrides live in /etc/systemd/system and beat vendor units in /usr/lib/systemd. systemd-delta shows the difference. SysV still appears as /etc/init.d, /etc/inittab, telinit, chkconfig, and update-rc.d.

Rescue versus emergency

rescue.target mounts local filesystems and starts a few early services. emergency.target is the smaller root shell, and filesystems may still be unmounted. Use the smaller one when a mount itself is the fault.

GRUB and UEFI

grub-install writes the boot loader to the MBR, a partition, or the EFI system partition. grub-mkconfig regenerates grub.cfg. efibootmgr lists UEFI boot entries. The ESP is usually mounted at /boot/efi. The initramfs is what assembles LVM, RAID, or LUKS before the real root mounts.

Other loaders

SYSLINUX boots FAT, ISOLINUX boots optical media, extlinux boots an ext filesystem, and PXELINUX boots from the network. BIOS PXE uses pxelinux.0 and pxelinux.cfg/. The UEFI files on the objective list include shim.efi and grubx64.efi. systemd-boot and U-Boot are awareness. Version 4.5 does not test LILO in detail.

Filesystems

Topic 203. Operating the filesystem is weight 4. Unmount a filesystem before you repair it.

Mounts and swap

/etc/fstab records device, mount point, type, options, dump, and pass. Prefer UUID= from blkid over a /dev/sdX name that can change. /proc/mounts is the kernel table. mkswap then swapon enables swap. sync flushes buffers. systemd .mount units are in scope beside fstab.

ext, XFS, and Btrfs

tune2fs, dumpe2fs, and debugfs maintain ext. xfs_repair repairs an unmounted XFS filesystem, and xfs_growfs grows one. XFS cannot shrink. btrfs subvolume snapshot is the basic snapshot. ZFS is awareness, not the tool you use for the Btrfs task. smartctl and smartd read disk health.

AutoFS and LUKS

/etc/auto.master points a directory at a map such as /etc/auto.misc. The map names the key, the options, and the source. cryptsetup luksFormat creates a container and luksOpen maps it under /dev/mapper. Format and mount the mapped device, not the locked container.

SSDs and optical names

fstrim discards freed blocks on an SSD. ISO9660 and UDF are the optical filesystems. Joliet, Rock Ridge, El Torito, and HFS are awareness. mkisofs builds an image.

RAID, device access, and LVM

Topic 204. RAID and LVM are weight 3 each.

Software RAID

RAID 0 stripes and has no redundancy. RAID 1 mirrors. RAID 5 needs at least three devices, stores distributed parity, and survives one failure. mdadm --create builds an array. /proc/mdstat shows healthy, degraded, or rebuilding. The historical MBR type 0xFD is Linux RAID autodetect. Current arrays also store their own metadata.

Disks and SAN

hdparm tunes ATA devices. sdparm is the SCSI awareness command. nvme manages NVMe disks. iscsiadm discovers a target and logs in. iscsid reads iscsid.conf. WWID, WWN, and LUN identify the storage. AoE and FCoE are awareness.

LVM order

pvcreate, then vgcreate, then lvcreate. vgchange -ay activates a group. Devices appear under /dev/mapper. lvm.conf holds the host settings. A snapshot is lvcreate -s against the origin, with its own size.

Resize

The logical volume and the filesystem have separate sizes. lvextend grows the volume. resize2fs grows ext, and can shrink it only while unmounted. lvextend -r can call the filesystem resize. xfs_growfs grows XFS online and cannot shrink it.

Network configuration

Topic 205. Advanced configuration and troubleshooting are weight 4 each. This is the host, not the DNS server. The server is exam 202.

Addresses and routes

ip addr, ip link, and ip route are the current tools. ifconfig, route, and arp are still on the version 4.5 list. iwconfig configures a wireless interface. A missing default route leaves the local subnet working and everything else dark.

Sockets and captures

ss lists sockets. ping and ping6 test reachability. traceroute, traceroute6, and mtr show the path. tcpdump captures packets. nmap scans. nc opens a simple connection. Use them after the address and route look right.

Files

Debian-style interface files live under /etc/network. Enterprise Linux ifcfg files live under /etc/sysconfig/network-scripts. /etc/resolv.conf lists resolvers. /etc/hosts is local. /etc/hosts.allow and hosts.deny are TCP wrappers, not a firewall. NetworkManager can overwrite a file you edited by hand.

Order of a fault

Check the link, then the address, then the route, then the name. If the IP works and the name does not, stay in the resolver. If the name resolves and the path fails, capture or trace. Do not recompile the kernel as the first step.

Source builds, backups, and notices

Topic 206. Backups are weight 3. Notifying users is weight 1.

From source

Unpack with tar and gzip, bzip2, or xz. ./configure writes the makefiles, often with a prefix of /usr/local. make compiles and make install copies the files. patch applies a diff. uname tells you which kernel a module must match.

Backups

rsync copies files and can skip unchanged ones. tar archives files. dd copies blocks, including empty space, and will destroy the target you name. /dev/st0 rewinds a tape on close. /dev/nst0 does not. mt controls the drive. Amanda, Bacula, Bareos, and BackupPC are awareness.

Who sees a message

/etc/issue is the console banner before login. /etc/issue.net is the remote pre-login banner for services that use it. /etc/motd is printed after login. wall writes to terminals that are already logged in. shutdown and systemctl can warn as part of a halt.

DNS

Topic 207. BIND 9 is the server you configure. dnsmasq, djbdns, and PowerDNS are awareness.

named.conf

Options, logging, and zones live in named.conf. Zone files are often under /var/named. named-checkconf checks the configuration. rndc reload applies it. An authoritative server answers for zones it hosts. A recursive server looks up other zones for clients. Leaving recursion open to the Internet is a common mistake.

Zones

The SOA holds the serial and the timers. Raise the serial or secondaries will not transfer the edit. named-checkzone checks a file. named-compilezone can write a raw zone. An A or AAAA record stores an address. A CNAME is an alias. An NS record delegates.

Transfers

allow-transfer limits who may copy the zone. TSIG authenticates that transfer. DNSSEC and DANE are awareness. A chroot or a view is part of locking the server down. Checking the zone file comes before the reload.

HTTP services

Topic 208. Apache configuration is weight 4. Squid and nginx are weight 2 each.

Apache 2.4

A VirtualHost selects an IP, a port, and a ServerName. Authorization uses Require. Require all granted opens a directory. The old Order, Allow, and Deny lines need mod_access_compat. A 403 on a readable tree is often an authorization rule, not a missing file.

HTTPS

SSLEngine on, SSLCertificateFile, and SSLCertificateKeyFile enable TLS. Version 4.5 removed SSLCertificateChainFile from the objective. SNI lets one address present a different certificate per hostname. Disable SSLv2, SSLv3, and weak ciphers.

Squid and nginx

Squid is a caching forward proxy. acl and http_access decide who may use it. nginx serves sites from server blocks. proxy_pass makes it a reverse proxy in front of an application. A forward proxy is for the clients. A reverse proxy is for your own site.

File sharing

Topic 209. Samba is weight 5, the heaviest single objective on exam 202.

Samba 4

Version 4.5 focuses on a standalone server and an Active Directory member, not on building a classic workgroup. Standalone uses security = user. An AD member uses security = ads and a domain join. testparm checks smb.conf. pdbedit and smbpasswd manage the local Samba account database.

NFS

/etc/exports lists the path, the clients, and the options. exportfs -ra reloads it. showmount -e asks a server what it exports. root_squash maps client root to an unprivileged user and is the safe default. no_root_squash keeps client root as root. nfsstat shows counters.

DHCP, PAM, and LDAP

Topic 210. The OpenLDAP server objective is weight 4 and uses cn=config.

DHCP

Inside a subnet, range is the pool. option routers is the gateway. option domain-name-servers is DNS. A client with an address and no gateway can talk only to its own subnet. radvd sends IPv6 Router Advertisements and is awareness, not the DHCPv4 server.

PAM and SSSD

A service stack lives in /etc/pam.d. requisite fails immediately. required records the failure and continues. sufficient can return success early. SSSD lets PAM and NSS use LDAP without every program speaking LDAP. The client file is ldap.conf, and ldapsearch tests the directory.

OpenLDAP

Version 4.5 expects directory-based configuration in cn=config, edited as LDIF. The old slapd.conf file is not the configuration you write. ldapadd inserts LDIF. nsswitch.conf lists files and then sss or ldap. If local users work and directory users do not, the directory source is the part that failed.

Mail

Topic 211. Postfix is weight 4. Sieve replaced procmail as the filter you are expected to know.

Postfix

main.cf holds myhostname, mydestination, and relayhost. mydestination is local delivery. relayhost is the smarthost for mail that is not local. master.cf defines services. TLS uses smtpd_tls_cert_file, smtpd_tls_key_file, and a security level. mailq shows the queue.

Delivery and access

newaliases rebuilds the database after you edit /etc/aliases. Sieve filters mail at delivery. procmail is awareness. Dovecot serves IMAP or POP, with its own certificate settings. Courier is awareness. Postfix moves mail. Dovecot lets a user read it.

Routing, SSH, and host security

Topic 212 is weight 14, the largest topic on exam 202. SSH is weight 4.

Forwarding and NAT

net.ipv4.ip_forward=1 lets the host route. It does not create a return path for private addresses. iptables -t nat -A POSTROUTING -o uplink -j MASQUERADE rewrites the source. ip6tables is a separate table. Unique local IPv6 is fc00::/7. Link-local is fe80::/10.

SSH

PermitRootLogin can be yes, no, or prohibit-password. PasswordAuthentication no does not disable keys. ssh -L listens on the client and forwards through the server. ssh -R listens on the server. ssh -D is a SOCKS proxy. The public key still belongs in authorized_keys.

FTP, fail2ban, and SUID

vsftpd is the FTP server to configure. Pure-FTPd and ProFTPD are the other names. fail2ban matches a log and bans the source, often with a firewall rule. find / -perm -4000 lists SUID programs. /etc/hosts.deny affects libwrap services on this host. It does not replace the FORWARD chain.

OpenVPN

dev tun is a routed IP tunnel. dev tap is a virtual Ethernet segment. Both ends must agree. The server needs the device node, the CA, the certificate, and the key. A missing tun module stops the process before any client connects.

Six checks on a disposable lab

Say what you expect to see before you run the command. Then change one fact and say what should change.

High load, idle CPU

Run uptime and vmstat 1 while a process writes a large file.

What to verify: wa rises with the copy, and it falls when the copy stops. If us is the column that rises, you are looking at CPU, not the disk.

A module that will not unload

Load a module with modprobe, read lsmod, and try rmmod while something still uses it.

What to verify: the use count is nonzero and rmmod refuses. Unload the dependent module first. Do not force a removal on a machine you cannot reboot.

Emergency versus rescue

On a test VM, boot emergency.target and then rescue.target.

What to verify: emergency leaves you to mount filesystems yourself. Rescue mounts local filesystems. Neither target is a normal multi-user boot.

LVM size versus filesystem size

Create a small ext4 logical volume, run lvextend without resizing the filesystem, and compare df with lvs.

What to verify: the volume is larger and the filesystem is not, until resize2fs or lvextend -r. Growing the volume alone does not grow ext4.

A zone that will not load

Break a zone file on purpose, run named-checkzone, fix it, raise the serial, and rndc reload.

What to verify: the check fails before the reload, and a second server does not see the edit until the serial increases.

Forwarding without NAT

Turn on ip_forward and try to route a private client before you add MASQUERADE. Then add the POSTROUTING rule.

What to verify: forwarding alone does not give the upstream a route back to the private address. Replies appear only after the source is translated. Use addresses on a lab network you control.

Frequently asked questions

Which objective version do these notes follow?

These notes follow LPIC-2 version 4.5, exams 201-450 and 202-450. Version 5.0 on the LPI wiki is still a draft. Items tagged Extra are job context the objective list does not require.

Do the notes replace the official objectives?

No. Use them with the published objectives. Command names can differ by distribution, so check the man page on the system you practice on.

Should I practice on one distribution?

Practice on a disposable VM. Debian-family and Enterprise Linux paths differ for network files, the Apache layout, and the BIND path. The objectives cover both styles.

Continue the LPIC-2 study path

Use the notes, then test recall with cards and a timed exam.

LPIC-2 hub →
Available

Overview

Exam format, the 500 passing score, topic weights, and a study plan.

Available · You are here

Core Notes

Reference notes for the kernel, storage, DNS, Apache, Samba, mail, and the host firewall.

Available

Practice Exams

400 original questions with custom exams, explanations, and a practice percentage.

Official technical sources

Start with the LPIC-2 version 4.5 objectives to separate configuration tasks from awareness terms. For implementation details, use the documentation for the system you operate, including the Linux kernel, BIND 9, Apache HTTP Server 2.4, and Samba. Distribution defaults and file locations can differ, so confirm commands in the local manual pages.

CompTIA Server+

Compare vendor-neutral server hardware, storage, recovery, and troubleshooting skills.

CompTIA Network+

Reinforce routing, addressing, ports, and troubleshooting used throughout LPIC-2.

Apply concepts in the Scenario Workshop →