A Minimalist PC-BSD Desktop

by Ostatic Staff - Nov. 11, 2013

PC-BSD is a FreeBSD based desktop operating system known for being user friendly. I've been toying with the idea of going back to FreeBSD for my main desktop at work for a few weeks, and this weekend decided to take the plunge. Unfortunately, the FreeBSD 9.2 installer does not include the option to install to a ZFS formatted disk. FreeBSD 10 Beta does allow installing to ZFS, but had a problem with the Intel video driver for my laptop. The good news is that PC-BSD has both of these features covered, and has let me build up a super fast, Xmonad based desktop environment simply and easily.

The PC-BSD install wizard offers an option to customize the default set of software. To achieve my minimalist setup, I simply deselected all of the available options, which left me with a nearly bare bones system. By default the laptop booted into a GDM login screen, and after logging in I was taken to a Fluxbox desktop environment. PC-BSD installs a few applications along with X11 and Fluxbox, the most interesting one by far is Life Preserver.

One of the reasons I wanted to install to ZFS, besides all the ZFS goodness, was to have the peace of mind of automatic snapshots of my home directory. The PC-BSD Life Preserver uses ZFS snapshots to create timed, automatic, point-in-time recovery options for your data. I tested this out by creating a snapshot, deleting a file, and then attempting to use Life Preserver to restore the file. I was unable to restore the file using the GUI tool, but I found that I now had a new hidden directory in my home directory named ".zfs". Inside that directory was another named "snapshots", and inside of that directory was yet another directory with the name I gave the snapshot I just created and a timestamp. Inside of that directory I found a duplicate of my entire home directory, and was able to browse to the file I deleted, cat it out to the terminal, and copy it back where I wanted it to be. I've setup Life Preserver to take hourly snapshots and to keep them for seven days before deleting. It will be an interesting experement to see how much additional disk space this takes up, but I'm hoping that because ZFS operates on the block level, the snapshots will be fairly small.

Using Xmonad I've been able to replicate a few of my favorite features of my previous desktop. Hitting "Alt-Space" will bring up a prompt at the bottom of the screen waiting for input for a search of DuckDuckGo, which will open in Firefox on my third desktop. Pressing "Ctrl-Space" prompts me for a server name to SSH to, and "Super-P" (or, "Mod-P", as it is better known in Xmonad) prompts me for an application to launch. I also have Xmobar at the top of the screen for status updates on various items, most of the configuration I've been using so far comes straight from this Chips Tips article, and then customizing a little at a time.

The way I have configured PC-BSD is not for everyone, but if you are confortable with KDE, Gnome, or XFCE you should feel right at home choosing one of those desktops. In addition to providing you with a comfortable working environment, the technology at the core of the operating system is top notch quality. If you have been curious about FreeBSD, PC-BSD is a great place to get started.