Roll for Security
FreeBSD Setup
2026-07-25
For my first post, I will cover my experiences setting up a FreeBSD desktop install. Skip to here if you want just the steps I took to get a working FreeBSD 15.1 XFCE desktop.
Why FreeBSD?
Not long after I joined Mastodon in 2023, there was the concept of “starter packs”. Lists of accounts that were curated by whoever was running the Join Mastodon site. I followed such a list for Cybersecurity. As part of that list there where quite a few community members who posted not only about infosec stuff but also Unix administration. Specifically BSD. This was the first time I had been exposed to so many users of BSD systems. Not just firewall appliances or super paranoid privacy focused listicles covering the wonders of OpenBSD. But regular IT admins like myself, using BSD. Particular FreeBSD. So shout out to Stefano Marinelli who runs the BSD Cafe and more for exposing me to a whole community of people with a passion for security, privacy, IT, and BSD.
So a few years of that background radition of exposure to BSD, plus my own interest in trying something new, got me to spin up FreeBSD on my Raspberry Pi 3, October of 2025. That would have been FreeBSD 14.3. FreeBSD.org provides a ready to use image that you write to your SD card and off you go with the OS already installed.Next comes months of learning, reading the FreeBSD Handbook, installing, uninstalling, and finally pivoting to setting up FreeBSD on my desktop. So for a while I had a triple boot. Debian 13, Windows 11, and FreeBSD 15.
My wife needs to use specific excel add-ons for work that do not even work on MacOS, let alone the online version of Excel that comes with Microsoft 365. She is also only comfortable using Windows as a Desktop OS, not even interested in Macs for the most part either. And of course, many video games work only on Windows, thus my family, we will have a Windows install floating around in some capacity for the time being. I however, have been using Linux since 2015. Going from Kali Linux as my first Linux Operating System to Ubuntu 15.10, “Wiley Werewolf” to Debian, Ubuntu 16.04, Fedora, Arch, back to Debian, Ubuntu, finally settling on Fedora. This would have Fedora 26 I believe? I stayed on Fedora on my laptop for years. It was a rock solid experience from 2017 through 2020. I did however also use Windows for a gaming PC I built at the time. Only switching to Arch on my desktop in 2021 after making some upgrades. I was even able to play Elden Ring at launch with that Arch install which was super cool. I however got sick of the guides pushing the AUR and not having everything setup and being worried about any random update potentially breaking things and the drive to be constantly updating and on and on. I did not actually like Arch. I liked the control it gave me, the understanding of the Linux system the experience setting it up gave me but maintaining it was a chore compared to Debian. I then installed Fedora again in 2022 and proceeded to have a sound driver bug that completely broke all audio on my desktop. And because I was not familar with how pulse audio or pipewire were configured on that Fedora install because I didn’t need to set it up by hand, I for some reason switched over to OpenSUSE. So in late 2022/earlier 2023, I ran OpenSUSE Tumbleweed until the summer of 2025 when Debian 13 came out. OpenSUSE is pretty neat and for a rolling release, that was the most stable experience. But a Debian-based Linux and apt all felt like home to me so I wanted to give the latest Debian a spin and distro hopped again.
All this is to say that I am comfortable distro-hopping and swapping Operating Systems. Then around May of 2026, the YouTube channel Linus Tech Tips started another “30 Day Linux Challenge”. I stumbled onto this and was inspired that for June 2026, I would do my own 30 day challenge. A 30 Day BSD Challenge. Made a hashtag on Mastodon and posted my way through June and by the end I was hooked and now in July of 2026, I am a full time FreeBSD user, blowing away the Debian install.
Now that I have committed the same sins as online recipe websites, what you all have probably been waiting for if you stumbled onto this off a search engine (or god forbid some LLM dumped you here some how), here is how I setup FreeBSD. I am documenting this for my own posterirty to make it easier for myself to find the information again in case I lose my notebook.
Setup
If you plan to use or are new to FreeBSD, I highly recommend the following before getting started:
- Read the first few parts of the FreeBSD Handbook, particularly the first 9 chapters at least. They walk through exactly what you will be doing to install FreeBSD on your desktop.
- When in doubt about something, check the manpages. If you did not know, manpages come in sections. Its what the number next to the application or utility name is like pkg(8). Read man(1) for more information about how the FreeBSD manual works.
- Get a book about FreeBSD or Unix Administration. I picked up the Unix and Linux System Administration Handbook, Fifth Edition by Evi Nemeth et al. I use it as a handbook. But a book like Absolute FreeBSD or anything else by Michael W Lucas would also count. I have only scratched the surface of the book but between the dead tree on my desk, the FreeBSD handbook (which you can install an offline copy of), and the manpages, I hardly ever had to reach for a search engine. And to be honest, I don’t think search engines of 2026 have a lot of up to date or at least as high quality of results as the above material.
However of the online resources, blogs, and other FreeBSD content on the web I would recommend the following: freebsdsoftware.org, blog.hofstede.it, it-notes.dragas.net, and of course the FreeBSD Forums and the FreeBSD Foundation blog.
Now for the meat and potatoes:
Install
This FreeBSD install and setup guide is based on my hardware, preferences, and experience learning FreeBSD in 2026. Please pay attention to where your needs and preferences differ, and of course this is only a snapshot in time of getting FreeBSD 15 installed and updated to the latest branch of 15.1 in 2026.
Download a copy of FreeBSD Go to freebsd.org
to download the ISO or image for your hardware. I started with
the FreeBSD 15.0-RELEASE dvd1.iso I had on hand. note:
Always make sure to validate the checksum. That is easily done
by running
sha256su, -c CHECKSUM.SHA256-FreeBSD-15.1-RELEASE-amd64
if the checksum file and ISO are in the same directory.
Write the ISO to your USB. There are many ways to skin a cat
if you aren’t familiar with how to write an ISO to a USB drive,
FreeBSD is going to be significantly more difficult than that.
*On FreeBSD, however, you would use geom list disk
to find your USB drive, then use
dd if=/path/to/freebsd.iso of=/dev/USBDRIVE.
I then booted the installer, selected the default US keyboard
keymap, set my hostname, picked the pkgbase
experience, went with auto ZFS, striped on a single disk (again,
follow the handbook and look up what makes sense for your
hardware), setup UEFI, encrypted and let the install complete. I
elected to turn on all the hardening options.
My networking card was not recognized, or as a realtek ethernet it does not work out of the box. I learned this and prepared. You need to get your hands on the packages necessary to get your networking card working or a USB to Ethernet dongle to be able to update and install them. Upon learning this I searched for Realtek drivers for FreeBSD and found these two links:1 2. Additionally this forum post got me going.
Once the install is complete I did picked the option to drop into a shell instead of rebooting. I inserted a fat32 formatted flash drive with the realtek driver package and ran these commands:
geom disk list
mount -t msdos /dev/da1s1 /mnt
cd /mnt
pkg -N
pkg add realtek-re-kmod198-198.00.1500068~21236f904c.pkg
# Add to /boot/loader.conf
if_re_load="YES"
if_re_name="/boot/modules/if_re.ko"
sysrc ifconfig_re0="DHCP"
sysrc ifconfig_re0_ipv6="inet6 accept_rtadv"
# Now Reboot
After reboot I confirmed networking worked.
date
ntpdate -v -b freebsd.pool.ntp.org
date
sysrc ntpd_enable="YES" # You can also enable NTP during the install.
pkg update
pkg upgrade
shutdown -r now
Next was running the Desktop installer scrip. to get XFCE and X11 going.
# First create a zfs boot snapshot
bectl list
bectl create fresh
pkg update
pkg install desktop-installer
desktop-installer
At this point you are walked through configuring a desktop,
creating a user, adding them to video and so on. I elected to go
with X11, switch from Quaterly to Latest for packages, nasic
XFCE install. Remember to add your non-root user to the video,
operators, and wheel groups. Video for graphics, operator to be
able to shutdown the desktop, and wheel to su to
root. You accomplish this by running the following command:
pw groupmod GROUP -m USER
TODO: MANUAL STEPS FOR CONFIGURING A DESKTOP
Once I confirmed XFCE was working, I added another
bectl “snapshot” and got about installing and
testing other applications. KeepassXC, Firefox, Vim, etc.
Now that I had a customized desktop, applications, and
everything was working as expected, I updated to 15.1. Pkgbase
is different. The old method was just using
freebsd-update command. It is now different.
Definitely prepare a snapshot and run the following when you are
ready to upgrade the core system:
pkg upgrade -yr freeBSD-ports pkg
pkg -oABI=FreeBSD:15:$(uname -p) -oOSVERSION=1501000 upgrade -r FreeBSD-base
pkg upgrade -r FreeBSD-ports-kmods
find /etc /usr/local/etc -name '*.pkgnew' -ls # To check for broken configuration files
sysctl machdep.bootmethod # To figure out your bootloader.
efibootmgr -v # Identify EFI System Partition
cp /boot/loader.efi /boot/efi/efi/freebsd/loader.efi
cp /boot/loader.efi /boot/efi/efi/boot/bootx64.efi
shutdown -r now
This upgrades the base system from 15 to 15.1, first by making sure Ports and the package maanger are up to date. Follow the steps outlined by the official documentation here..
And that’s where I am at. Using FreeBSD 15.1 with XFCE, zsh, vim, and so on. Everything works as expected.
Conclusion
I had a blast learning to use FreeBSD. As a ~decade or so Linux user I had heard about BSD, the history, and so on but I had never really used it outside of a firewall appliance before last year. FreeBSD has made using my computer fun again.
I like the Base System, 1st Party packages, Ports system (and much better than Arch with the AUR IMO). I like that ZFS has first class support. Jails seem way cooler than containers and much more my style (though I feel docker has its place, it just isn’t designed for security).
I hope to learn more about BSD’s and I would like to share my experiences with that here. Thank you for reading this far and best of luck out there!
-kemotep