Skip to content

Latest commit

 

History

History
64 lines (43 loc) · 1.34 KB

FREEBSD.md

File metadata and controls

64 lines (43 loc) · 1.34 KB

FreeBSD

Updating

Typically do single branch clones of /usr/src so that it doesnt take up too much space:

git clone <url> --branch <branch> --single-branch /usr/src

Move to a new branch/release

git remote set-branches --add upstream releng/12.1
git fetch upstream releng/12.1
git checkout releng/12.1

Build FreeBSD:

make buildworld && make buildkernel && make installkernel && make installworld

Post upgrade make sure to run mergemaster:

mergemaster -Ui

Update pkgng:

pkg-static install -f pkg
pkg update
pkg upgrade

Kernel Dump

Set dumpdev=AUTO in its /etc/rc.conf, and have sufficiently large swap partition, configured at boot time.

Induce a panic

On FreeBSD, a kernel core file can be generated by intentionally crashing:

# sysctl debug.kdb.panic=1

Save

For machines that are configured to enter the on-line kernel debugger (aka kdb), the following command is also needed, at the system console during a panic:

kdb> call doadump

Otherwise, the kernels dump routines will automatically save the core file to a swap partition, if configured.

Upon reboot, the savecore rc startup script will automatically identify the core file in the swap partition, and save it to /var/crash by default.

Refs