LPI BSD Specialist study materials
LPI BSD Specialist study resources

LPI BSD Specialist: BSD Installation and Software Management

LPI BSD Specialist · Work through your exam, one topic at a time.

All guide sections

BSD Installation and Software Management

The BSD Installation and Software Management domain tests whether you can put a BSD system onto disk and then keep its software current using that platform's own tooling. FreeBSD, OpenBSD and NetBSD share Unix ancestry but differ sharply in package commands and configuration files, and the exam expects you to keep them apart rather than answer from Linux habits.

Installing the base system

bsdinstall walks through keymap, networking, partitioning and the root password. Auto (UFS) creates a GPT layout with a freebsd-boot partition, swap and a UFS root; Auto (ZFS) builds a single-disk or mirrored pool with datasets. Base-system updates come from freebsd-update fetch followed by install; a release upgrade is freebsd-update upgrade -r 14.1-RELEASE. The base OS is never managed by pkg.

Packages versus ports

Third-party software has two routes. Binary packages: pkg install nginx, where the /usr/sbin/pkg stub bootstraps itself on first use and pkg bootstrap -y forces it. Source ports: cd /usr/ports/www/nginx && make install clean. Repository selection lives in /usr/local/etc/pkg/repos/*.conf, which overrides /etc/pkg/FreeBSD.conf. portsnap is retired in recent FreeBSD, so fetch the tree with git.

OpenBSD uses pkg_add, pkg_delete and pkg_info, reading the mirror from /etc/installurl. NetBSD typically uses pkgin over pkgsrc binaries.

Worked example

Install nginx silently on FreeBSD and verify its files: pkg install -y nginx; pkg info -l nginx. Reasoning: -y suppresses the confirmation prompt and is safe in scripts; pkg info -l lists every file the package owns, which is the reliable way to locate the sample configuration under /usr/local/etc/nginx. pkg info nginx alone prints only name, version and comment.

Traps

freebsd-update patches the base OS while pkg upgrade patches packages; using one for the other leaves a half-patched machine. Mixing ports and packages for the same origin causes version skew unless you pkg lock or use poudriere. On OpenBSD, pkg_add fails without a mirror in installurl or PKG_PATH. Never edit /etc/defaults/rc.conf; use /etc/rc.conf or sysrc.