It must have been in 1989 that I literally spent weeks of my life trying to get X11 compiled and running on a 486 Compaq running SCO Unix; compilation times were a thing which took many hours, but having to cross fingers that the parameters for the screen wouldn’t burn anything is what I recall most vividly. Times have changed of course, and I’d think there are not many people who do that any more – I for one have thankfully forgotten most of it, but it still rankles, and when I think of (non-commercial) Unix on a laptop I see the ghost of RAMDAC in my nightmares.

I know many who use some variant of GNU/Linux (or systemd/Linux? ;-) on a laptop, and I’ve done it myself, albeit typically sans X11, but the combination has never tempted me away from a Mac. I can’t nail it: Linux is more than fast enough (probably faster than BSDs), certainly reliable enough – that’s not it. I think it’s an increasing dislike of the environment in terms of the documentation, the disparity of syadmin procedures and utilities, the adoption of systemd, the differences across distributions, and the feeling that there’s so much wrong in that environment due to different groups recreating the same stuff in different wrappings, losing track of what bug has been fixed where, and has it been upstreamed, and has it been re-downstreamed, etc. It’s difficult for me to put a finger on it. Linux is here to stay, of course, and that’s good, but I don’t feel like carrying it around with me.

Early February I had an idea which sparked a bit of response:

tweet suggesting talk

So the question I wanted answered is: can you make a laptop so attractive that I’ll be tempted to move away from a Mac? TL;DR: you can.

For some time now I’ve been happy with OpenBSD; the installer is slim and fast, the software is very stable, and the documentation is almost unbeatably good. Have you an idea how valuable it is to type man and get a manual page which actually describes the program or file that’s on your system? I had an excellent experience with OpenBSD a year ago when I slapped the OS onto an old Thinkpad.

I quit smoking 922 days ago (at the time of this writing, and yes, I still keep count), and have kept track of the real money I’ve saved. I took some of that and splurged: I purchased a Lenovo Thinkpad X1 Carbon 6th gen, and I was really very impressed when I opened the carton: quite an Apple-like look-and-feel on unboxing.

root xwd

The device is lovely, and I think it’s slimmer even than my MacBook Air, and it feels lighter. I booted it up, intending to shrink the Windows 10 installation (who knows what a copy of Windows might be good for one day), and changed my mind on that after waiting for many minutes for Windows to welcome me.

I had decided I wanted FreeBSD because of ZFS and the possibility of running VirtualBox. I started off installing the latest version of TrueOS as it’s supposed to be a good method for noobs in terms of ease of installation. The installer was fine until when creating a user (username jpm) it said “Jan-Piet Mens” contains an invalid character. For the gecos field. I kid you not. The result was a bootable system (on a second try), but it left me crying as to the sluggishness of almost everyting. Then I installed Trident as TrueOS’ successor but had to attach an external USB mouse to click the GUI installer. The result didn’t boot; didn’t boot as in “it doesn’t boot”, if you know what I mean.

I should have stuck to plain FreeBSD of course, so I installed that. Several times. And then I stopped. I gave up having basically bricked the X1 in terms of not being able to give it to somebody who wants a Windows laptop.

Henrik again (he’s tireless in that respect) said OpenBSD, so I tried. To be honest my expectations in terms of “laptop and graphics and wifi and all that jazz with OpenBSD” were rock-bottom. OpenBSD as server? Any time, but on a laptop … ?

The installation worked, and I got more than I expected (which surprised the heck out of me), but the result was dreadful: FireFox hardly able to scroll a page, no video output (YouTube), a miserable window manager, … I went to bed and read a book.

It was Henrik (yeah, the same chap), who pointed me to a blog post by Cullum Smith entitled OpenBSD on a Laptop. After spending a few hours working through that text, I was gratified with a very workable environment using an “i3”-like window manager called cwm.

All in all the result is a laptop which can, for me, almost compete with a Mac, at least for most of my use-cases. It has full-disk encryption, working Ethernet and Wifi (imagine being able to type man iwm for the name of the WiFi network interface and being shown up-to-date documentation with examples). S3 works as do volume buttons on the keyboard. I have a development environment (C compiler with all the Unix utilities I’d ever want), I’ve got syncthing, restic, and matterhorn installed, and I have OpenBSD’s built-in httpd and smtpd up and running. (The former because I sometimes test clients and need an HTTP server, and the latter because I like being able to send mails with pastes etc, to myself or others.).

There are, at the end of this first day, a few things for which I need solutions: VLC plays audio but doesn’t show an image and video, using the X11 driver (moving pictures work in Firefox and Chrome), and there are a few “usability” things I have to either tweak or get used to, e.g. copy/paste from an xterm into a Web browser or vice versa. Also, the right side of the laptop gets very hot; I haven’t yet determined where the CPUs are, but I’m guessing right there in which case something’s running too hot, literally. (top doesn’t show anything untoward.) It was Thunderbolt BIOS setting.

It’s really pleasant to work on a system in which, when I want to use, say mosquitto, all I do is pkg_add mosquitto, and I get all binaries, and libraries, and header files without having to guess what the package with the binaries and the package with the libraries is called. (I’m looking mainly at you, Debian.) Everything is properly documented, all programs and files have man-pages, and the quality of the guides is very good.

I’m not done, and I’m not sure I will abandon Macs and macOS, but this is very promising. Some things which I’ve relied upon are going to be difficult or impossible to replace. They include:

  • iTerm2
  • Enpass
  • Calendar.app
  • being asked to connect to WiFi networks
  • and instantaneous wakeup on opening the laptop’s lid

There might be workarounds for some or all of these, but they’d be just that. All in all, however, I’m impressed with the result so far. FWIW, it’s likely that an appropriately configured Linux laptop would be just as good or maybe even better; as I said earlier: I cannot put my finger on it.

The question I have is: will I be brave enough to take this machine to BSDCan and do a presentation with it? We’ll see. (Certainly not if I cannot practice projecting beforehand.)

Further reading:

openbsd, laptop, and os :: 06 Apr 2019 :: e-mail