Upgrading DragonFly BSD

I have two DragonFly BSD boxes that I want to upgrade to the latest rev. At the moment, they’re running:

$ uname -a
DragonFly screw.lodden.com 2.10-RELEASE DragonFly v2.10.1.1.gf7ba0-RELEASE #1: Mon Apr 25 19:48:10 UTC 2011 root@pkgbox32.dragonflybsd.org:/usr/obj/usr/src/sys/GENERIC i386

Unlike most other BSDs, DragonFly uses git for source code management. DragonFly provides make wrappers to git updates, however. If you don’t have the source code already installed, get it with:

$ cd /usr
$ make src-create

mkdir -p /usr/src
cd /usr/src && git init
Initialized empty Git repository in /usr/src/.git/
cd /usr/src && git remote add origin git://git.dragonflybsd.org/dragonfly.git

Walk away for a little while, and you’ll come back to see:

Checking out files: 100% (31175/31175), done.
Already on 'master'
cd /usr/src && git pull
Already up-to-date.

This will get you the latest DragonFly BSD source code.

Before going any further, look at /usr/src/UPDATING. This contains warnings and instructions for avoiding bumps in the upgrade process. For example, as I write this the post-2.10 UPDATING notes list several ISA-only device drivers that have been removed from the system. If I was running on an ISA system, I’d care about that. But I’m not, so I don’t. On to building the system!

$ cd /usr/src
$ make buildworld

Once your world is built, follow up with:

$ make kernel
$ make installworld

Those of us from other BSDs would expect an etcmerge or mergemaster here, but DragonFly replaces that with:

$ make upgrade

The make upgrade process is much faster and less interactive than any merge tool.

After this is done, reboot. Log back in and you’ll find:

$ uname -a
DragonFly mwltest2.lodden.com 2.13-DEVELOPMENT DragonFly v2.13.0.49.gf6ce8-DEVELOPMENT #0: Tue Oct 18 10:51:40 EDT 2011 mwlucas@mwltest2.lodden.com:/usr/obj/usr/src/sys/GENERIC i386

We’re running.

My next task is to build a few jails and make them usable. But that’s for another post.

2 Replies to “Upgrading DragonFly BSD”

  1. This is a very nice one-stop clear and informative guide for upgrading a DragonFly instance from scratch. I was surprised to be able to successfully upgrade from 2.6.3 to 3.1.0-DEVELOPMENT! ( After allowing the VM 1G of RAM rather than 128M 🙂 ).

    Although I didn’t require it myself I particularly like the bootstrap, make src-create, for getting the source tree; a great tip to remember for the future.

Comments are closed.