It’s been a while since I’ve written anything in here so I’ll try to remember how things work…
A few weeks, like a lot of people, I ordered a RaspberryPi to use as a mediacenter. Unfortunately it still hasn’t arrived and I got tired of my good old xbox that’s starting to be quite limiting in terms of what I can ask it. Anyway, I had an old-ish desktop in the attic that I decided to use in place of the RPi in the meantime. The thing is, it was running FreeBSD 8.1-BETA1, which also was quite old. I could have simply reinstalled everything but: a) I didn’t have an install cd and b) I decided to give pkgng a proper try (as opposed to just running it in a vm).
First step: upgrading to 9.0-RELEASE. Pretty easy thanks to freebsd-update, I did have to go via 8.1-RELEASE because of some metadata integrity check failing. Didn’t add too long to the process, so I’m not complaining.
Second step: updating the ports tree with portsnap (my tool of choice) and installing ports-mgmt/pkg.
Last step (ok this one is fairly long and more complicated): point PACKAGESITE to pkgbeta.freebsd.org and force-upgrade all packages (pkg update && pkg upgrade -fy).
Tada!
Backtracking slightly, the last step didn’t go without any trouble, pkgng complained about ports having file conflicts. In some cases, ports had been merged/deleted (so the easy fix was to pkg delete them first). In other cases, we were going from a versioned port to another one (e.g. mysql50-client to mysql55-client) so the register origin for the package had to be changed with pkg set –o databases/mysql50–client:databases/mysql55–client. Finally pkg upgrade -fy wasn’t complaining anymore.
So that was a few days ago, yesterday a new package set was uploaded. Since I pointed PACKAGESITE to http://pkgbeta.freebsd.org/freebsd-9-i386/latest/, pkg update picked up on the new packageset and more packages were available for upgrade. pkg upgrade worked without a hitch but a couple of apps that I had installed via ports (and not yet available as packages) weren’t upgraded along with graphics/png, which caused x11/slim to look for a non-existent png library. Note that I only used pkg(ng), not portmaster or portupgrade which would have picked up on the update since PORTREVISION for x11/slim was bumped. I am told that preserving shared libraries might be added to pkgng v1.1.
Anyway, congratulations to bapt@ and everybody else working on this! There are still a few rough edges but it’s working pretty darn well already!





What happened to needing a repo parameter for pkg-ng?
That’s what PACKAGESITE is for (telling pkg which remote repo to use), and the “pkg update” step (telling pkg to update it’s db of available packages and versions).
Just wanted to say thanks for this post. It happened at just the right time to save me a lot of extra research online.
In the process of doing the same, upgrade from 8.3+portmaster+pkg to 9-STABLE+pkg.
Here’s hoping it goes as smoothly…
Glad it helped!