This seems like a useful tool:
"pkg-be-plugin is a pkg(8) plugin that automatically creates a ZFS boot environment before each install, upgrade, or deinstall transaction. If a transaction leaves the system in a broken state, the pre-transaction BE provides a clean rollback point.
The plugin uses libbe(3) directly with no subprocess invocations of bectl(8) or zfs(8). Boot environments are pruned automatically basedon a configurable keep count and minimum age."
When do FreeBSD commits happen?
docs - https://news.freshports.org/2026/09/26/when-do-commits-happen-in-the-freebsd-docs-tree/
ports - https://news.freshports.org/2026/09/26/when-do-commits-happen-to-the-freebsd-ports-tree/
src - https://news.freshports.org/2026/09/26/when-do-commits-happen-in-the-src-tree/
@dvl Claude in the right hands can help you create better code than either of you individually. You know what you’re doing even if you had to write it all yourself — so as long as you’re asking it to produce the level of quality code you would (given infinite time), this can be a good approach in my experience.
FYI, ports which get their PORTVERSION from outside their own Makefile has been a years-old problem for FreshPorts. Unless FreshPorts knows it has changed, it can't keep the database current. The most likely solution now appears to be INDEX, as suggested by mat - parse it, compare against the DB, update.
Full disclosure, most of this coding is being done by Claude. It's a 425 line shell script, with some of that being an SQL query.
Comments on that approach welcome: https://gist.github.com/dlangille/74f5de44b4b8534674d45e35e2a0cb24
Here's a clever way to know if any updates have happened since the last time we ran. Run an md5 over all the active port for name, version, revision, epoch....
It's a fast query: about 1.3 seconds.
I'm not using it for anything. It's just something that came up...
freshports.dev=# SELECT md5(string_agg(category || '/' || name || ' ' || version ||
coalesce('_' || revision, '') ||
coalesce(',' || portepoch, ''), E'\n' ORDER BY category, name))
FROM ports_active;
md5
----------------------------------
88d6a009e0bfc523a56e896cae43dc23
(1 row)
freshports.dev=#
In case you didn't know: the Starbucks union is actively calling for a boycott.
Please respect the union. Get your coffee elsewhere.
Claude AI has noticed that FreshPorts has transposed EXTRACT_DEPENDS and PATCH_DEPENDS in the database.
This was previously unknown.
There are at least 5300 ports which this affects.
Claude also supplied a fix. I'll deploy that to test and try it out there.
FYI, all this was in support of providing support RUN_AND_BUILD_DEPENDS before it gets implemented: https://reviews.freebsd.org/D59664
I'm being cyberattacked by Tesla, Inc
An NVMe stick disappeared. I'll wait a bit before booting the host.
And have I mentioned https://watchgoose.com ?
See https://dan.langille.org/2026/09/12/data04-degraded-oh-and-have-i-mentioned-watchgoose/
Progress on parsing Mk/bsd.default-versions:
* the table of known *_DEFAULT value is populated, and very quickly
* staring to query each port to find out if PORTVERSION is affected by any one of those *_DEFAULT values
Imagine something like this:
make -C /jails/freshports/usr/ports/sysutils/qdirstat -V PORTVERSION -V DISTVERSION GUILE_DEFAULT=1.8
make -C /jails/freshports/usr/ports/sysutils/qdirstat -V PORTVERSION -V DISTVERSION IMAGEMAGICK_DEFAULT=999999.9999
etc, contine through all 39 *_DEFAULT values to find out if one of the affects PORTVERSION
Then repeat those 2 * 39 make calls for every active port.
This may take a while.
See https://news.freshports.org/2026/09/11/creating-and-populating-the-tables-for-defaultversions/
This morning I did some update to a dev instance of #FreshPorts - I'll know more after the next commit to Mk/bsd.default-versions.mk how it's working.
Yes, I could rerun an old commit.
And I probably will, but for now, the code is in there and I'm working on other things for now.
I was wondering why my #FreeBSD dev host was sluggish this morning:
[12:06:49] dvl@pkg01:~/ports/head(main) % w
12:06PM up 6 days, 18:29, 3 users, load averages: 85.75, 83.82, 70.43
...
[12:06:50] dvl@pkg01:~/ports/head(main) % jls | wc -l
47
It's busy building via #poudriere.
Now that I'm into pkgbase on #FreeBSD, I've updated my procedure for updating FreshPorts working jails. These are jails in a jail. In short, I'm using bsdinstall for that.
https://news.freshports.org/2026/09/08/updating-a-jail-by-replacing-it-2-0-0/
mkjail-0.2.2 is now in the #FreeBSD ports tree.
The previous release added pkgbase to `mkjail update` and `mkjail upgrade`. This release converts `mkjail create` to be pkgbase aware.
Legacy jails are still supported.
Yesterday and today I started using mkjail-0.2.1 for creating a new jail. It works well for updating and upgrading pkgbase jails.
The newly created jail wasn't pkgbase. I fixed it. There are optimizations available but a new release will come soon. Perhaps later today.
Walk first. Run later.
dvl@FreeBSD.org
I've been contributing to open source since 1998.