About the upcoming changes to pkgbase

0 views
Skip to first unread message

Martin

unread,
Oct 10, 2025, 4:26:10 PM (9 days ago) Oct 10
to freebsd-...@freebsd.org
Regarding the upcoming change from freebsd-update to pkgbase, I have
two questions which I haven't been able to find a clear answer to, or
perhaps I have overlooked something.

In the documentation[1] it says that pkgbase will replace tarball
distribution sets, such as base.txz or kernel.txz.

This almost made me cry because it's so easy to manually download
those tarballs and upgrade the system manually without using
freebsd-update.

I don't care about freebsd-update going away, but being able to simply
download those tarballs was gold!

Does this mean that this option is not possible any longer?

It also seems that pkgbase is going to ruin one of the most loved
features of FreeBSD, the clean separation between the base system
and the third party packages?

Even though the pkgbase is going to reside on a separate repository,
which needs it own setup in pkg.conf, this is AFAIK not the same
clean separation.

Doing a "pkg WHATEVER" now always has the potential to either mess up
the base system or the third party packages. Like the documentation
says,

"This step might remove non-base packages, which could include the
running desktop environment. Be careful."

This does actually happen from time to time, pkg is removing installed
packages during an upgrade which it shouldn't remove and you have to
reinstall those packages manually afterwards.

In the past, no matter what you did with the packages, your base system
would always be unaffected, now this doesn't seem to be like that after
this change.

I cannot help vent a bit of frustration, but it feels so much like
FreeBSD has been going in the direction of "datacenter Linux" for the
last X number of years, not only package management related, but also
CI and other areas as well and a push in that direction is perhaps
coming from people in the FreeBSD project being associated with Big
Tech? Wanting FreeBSD to become a major player on those platforms, I
don't know.

At our company we use both Linux and FreeBSD as in the right tool for
the job and we have been for many years. We use FreeBSD for several
reasons, ZFS being a first class citizen is definitely one of them,
jails is another, but the clean separation of the base system from
packages is perhaps the MAIN reason because that gives a so much better
way to handle system administration.

I can certainly understand having more companies and more people use
FreeBSD is better, BUT the more FreeBSD becomes like a Linux distro,
the less reason there is to actually use it.

[1] https://docs.freebsd.org/en/books/handbook/book/#pkgbase

Kind regards,
Martin


Dan Mahoney (ports)

unread,
Oct 10, 2025, 5:14:09 PM (9 days ago) Oct 10
to Martin, freebsd-...@freebsd.org


> On Oct 10, 2025, at 1:25 PM, Martin <ii...@protonmail.com> wrote:
>
> Regarding the upcoming change from freebsd-update to pkgbase, I have
> two questions which I haven't been able to find a clear answer to, or
> perhaps I have overlooked something.
>
> In the documentation[1] it says that pkgbase will replace tarball
> distribution sets, such as base.txz or kernel.txz.
>
> This almost made me cry because it's so easy to manually download
> those tarballs and upgrade the system manually without using
> freebsd-update.

Those tarballs have saved my butt on more than one occasion, especially when other upgrade methods have broken. I really do hope that at the very least someone continues to produce a minimal tarball that can be used to reset everything short of /usr/local to a known good state. I've definitely had actual physical machines out in the field that I couldn't just redeploy from an AWS console. Fixing my system would go from not just copying one tar file over, but hundreds.

I've made extensive use of mfsbsd (which really needs some love, I've heard whispers it'll be more "official" soon).

With pkgdb, the system is also now at the mercy of a sqlite DB (and the *same* db as your ports-pkgs, if I'm not mistaken) and I've definitely seen db corruption events over the years (less so recently, to be fair).

I do also find it troubling that the command to use pkgbase will be "pkg" and not "pkgbase" or "pkg --base" or whatever. That you'll effectively be upgrading OS components right alongside ports, using the same commands to upgrade only ports you've been using for a decade or more. This has been mentioned on several lists, by several people.

Now, this is the way linux has worked for a long time (every discrete OS component is its own package) -- whether it's an RPM based distro or a .deb based one, and I'm sure documentation will emerge as to how to do all the things we need to. I just hope it all eventually winds up being first-party documentation, and not buried some some wiki page, or some forum post with "try this" and zero replies thereafter.

-Dan

Graham Perrin

unread,
Oct 10, 2025, 8:40:32 PM (9 days ago) Oct 10
to freebsd-...@freebsd.org
On 10/10/2025 21:25, Martin wrote:

> … In the documentation[1] it says that pkgbase will replace tarball
> distribution sets, such as base.txz or kernel.txz. …

The FreeBSD Handbook is somewhat outdated.

<https://reviews.freebsd.org/D52999#1211510> yesterday:

> … For 15.1 I'll probably want to call distribution sets "legacy"


Graham Perrin

unread,
Oct 10, 2025, 8:49:11 PM (9 days ago) Oct 10
to freebsd...@freebsd.org, freebsd-...@freebsd.org
<https://lists.freebsd.org/archives/freebsd-questions/2025-October/007045.html>,
on 10/10/2025 22:13, Dan Mahoney (ports) wrote:

> … to reset everything short of /usr/local to a known good state. …

When I last checked, pkgbasify was good for this.

> … db corruption …

You can backup the database,

/usr/local/etc/periodic/daily/411.pkg-backup


People: the freebsd-pkgbase@ list will be a better place for discussion
of pkgbase. (Just one list, please, if you can.)


Dave Cottlehuber

unread,
Oct 11, 2025, 7:41:57 AM (8 days ago) Oct 11
to Martin, freebsd-questions
On Fri, 10 Oct 2025, at 20:25, Martin wrote:
> Regarding the upcoming change from freebsd-update to pkgbase, I have
> two questions which I haven't been able to find a clear answer to, or
> perhaps I have overlooked something.
>
> In the documentation[1] it says that pkgbase will replace tarball
> distribution sets, such as base.txz or kernel.txz.

Hi Martin

TLDR don't worry they will be around for 15.0. Similar to the snapshots,
this will line up for BETA1 (albeit under /releases/ not snapshots)

https://download.freebsd.org/snapshots/amd64/15.0-ALPHA5/

This is the current deprecation plan for dist sets:

https://lists.freebsd.org/archives/freebsd-current/2025-September/008918.html

This snippet answers most of your questions:

15.0-RELEASE:
* PKGBASE becomes the default in release/Makefile and a new NOPKGBASE
option is added.
* The installer supports both install options, with dist sets marked
as "legacy" in the pick-how-to-install menu.
* The disc1 images only contain a pkgbase repo; people who want to install
from disc1 without pkgbase will need an internet connection.
* The dvd images contain both dist sets and a pkgbase repo suitable for
offline installation with either mechanism.
* Traditional FreeBSD Update will work for the entire 15.x branch, including
security updates, since this is relatively easy to do as long as we have dist
sets.
* Work is underway to make freebsd-update behave as a wrapper around pkgbase
on pkgbase-enabled systems (right now it just refuses to do anything).

> It also seems that pkgbase is going to ruin one of the most loved
> features of FreeBSD, the clean separation between the base system
> and the third party packages?

No. Even with pkgbase, packages are still just tarballs, you can go and
see for yourself:

https://pkg.freebsd.org/FreeBSD:15:amd64/base_latest/

Just download one and unpack it.

> Even though the pkgbase is going to reside on a separate repository,
> which needs it own setup in pkg.conf, this is AFAIK not the same
> clean separation.

I've been actively using pkg base sets for the last few months, and
while there were earlier issues, I think these have all been covered
- development in both pkg, and CURRENT & STABLE/15 has been vigorous.

`pkg upgrade -r FreeBSD-base` or `pkg upgrade -r FreeBSD-ports` should
do the right thing.

> Doing a "pkg WHATEVER" now always has the potential to either mess up
> the base system or the third party packages. Like the documentation
> says,
>
> "This step might remove non-base packages, which could include the
> running desktop environment. Be careful."
>
> This does actually happen from time to time, pkg is removing installed
> packages during an upgrade which it shouldn't remove and you have to
> reinstall those packages manually afterwards.

Let's see where we're at with 15.0 BETA1 and follow up any remaining
bugs closely.

It has been a fast & rough road to get to where we're at in the last
months, but I am really pleased with using this in production already.

Using pkgbase has allowed me to reduce the footprint of our production
servers significantly, a win both for security and a disk space, and
operationally it's a delight to upgrade systems with it, and build
and run podman containers with it too.

A+
Dave
———
O for a muse of fire, that would ascend the brightest heaven of invention!

Reply all
Reply to author
Forward
0 new messages