Bootstrap upgrades are optional unless a ZFS root pool is upgraded (15.0 to 15.1)

Reading the upgrading docs about upgrade loader bios, and I'm not sure what the following means:

...bootstrap upgrades are optional unless a ZFS root pool is upgraded...

How to tell if the ZFS root pool is upgraded or not?!
I have ZFS but haven't touched anything as far as I know.

This is what I have:

Code:
# pkg which /usr/bin/uname
/usr/bin/uname was installed by package FreeBSD-runtime-15.0p10


# sysctl machdep.bootmethod
machdep.bootmethod: BIOS


# gpart show
=>       40  146800560  da0  GPT  (70G)
         40       1024    1  freebsd-boot  (512K)
       1064        984       - free -  (492K)
       2048   16777216    2  freebsd-swap  (8.0G)
   16779264  130019328    3  freebsd-zfs  (62G)
  146798592       2008       - free -  (1.0M)

Thanks,
 
Good question IMO.

Ok... ZFS is - as I like to call it - an "evolving filesystem", meaning so much that new features get added to the system as time goes by. But as you can imagine: those new features in the core mechanics don't "magically" manifest themselves on your storage media ("hard disks" aka ZFS pool).

I'm sure you know this part, but I'm going all-in => the zpool is basically the heart of your storage: that's where everything gets "connected", it's basically the "link" between your storage hardware (= harddisks, ssd's, etc.) and the filesystem(s) (or datasets) themselves.

Also: ZFS support is provided in 2 ways... the bootloader which allows you to boot your system from a ZFS pool, and your userland tools (stuff like zfs, zpool, etc.).

Here's the thing: a zpool (on your disk(s), not the command!) can also have a certain version number. And that zpool can be upgraded over time to add support for possible new features.

Lemme show you:

peter@zefiris:/home/peter $ zpool status
pool: zroot
state: ONLINE
status: Some supported and requested features are not enabled on the pool.
The pool can still be used, but some features are unavailable.
action: Enable all features using 'zpool upgrade'. Once this is done,
the pool may no longer be accessible by software that does not support
the features. See zpool-features(7) for details.
config:
See what I mean? So here's the thing... In order to boot a system from ZFS you'll need a specific bootloader. This is handled somewhat differently with EFI, but using the BIOS method (like you use as well!) you'd rely on /boot/gptzfsboot which you can install using gpart(8).

It's easy to overlook, but those bootloaders get updates too over time. And that's what they're hinting at above: you don't have to update your bootloader (/boot/gptzfsboot), unless you decide to upgrade your ZFS pool (see my quote above). Because then you'll need an updated bootloader that can handle the new zpool version.

I hope this can help!
 
How to tell if the ZFS root pool is upgraded or not?!
You'r being asked, if you want to upgrade your pools, resp. zpool status says, the pool(s) shall be upgraded.
If you do so or not depends on you. Recommendation is not to upgrade ZFS pools unless you really have to (while it's still a puzzler to me, how to suppress that zpool's status entry by but just ignoring it, since it feels somehow unproper to be reminded everytime that you shall upgrade.)
Anyway, if nothing changed with 15, which I doubt (I am still running 14.3), then the pools are never upgraded automatically, and particulary not without asking you.

So, bottom line, if you did not upgrade your pools conciously then they are not upgraded.
Don't upgrade your pools unless you have to.
If you upgrade your pools, first upgrade the boot partition before upgrading the pools. Otherwise your machine is not booting correctly, and you have to copy the new version into the EFI partition afterwards. A bit more fumbling, but no catastrophy when you know what went wrong.
 
Recommendation is not to upgrade ZFS pools unless you really have to (while it's still a puzzler to me, how to suppress that zpool's status entry by but just ignoring it, since it feels somehow unproper to be reminded everytime that you shall upgrade.)
I think "zpool upgrade" is distinct from "kernel bits going to a newer version of ZFS".
The zpool upgrade specifically tells the on disk stuff what features are supported. If you don't need a new feature, you don't need to upgrade.
I think the message should say more like "...you may want to zpool upgrade if you need the new features" or a way to list what new features are not enabled.
If you upgrade your pools, first upgrade the boot partition before upgrading the pools.
One also needs to upgrade all bootable partitions before upgrading the pools.
Example:
A mirror pair of devices that hold zroot. You need to upgrade both bootloaders before zpool upgrade.
If you don't you can wind up with an unbootable system. I think we've all done that once: you update bootloader on one device, zpool upgrade, reboot, the system decides to boot off the other device in the mirror and won't boot.

Another aspect of zpool upgrade:
Boot environments and upgrades across releases.
Example:
You are currently running 14.x-RELEASE and want to upgrade to 15.X-RELEASE. You do the smart thing and create a new BE and upgrade into that, leaving you with 2 BEs, one at 14.x the other at 15.x.
If you are booted into 15.x and do zpool upgrade, you can no longer boot into the 14.x BE, which means "I hope everything works in 15.x".

Bottom line (my opinion):
Make sure you think about everything before doing zpool upgrade.
 
If you don't need a new feature, you don't need to upgrade.
I think the message should say more like "...you may want to zpool upgrade if you need the new features" or a way to list what new features are not enabled.
That's exactly what I meant.
But I couldn't remember what the text in zpool status says exactly.
Anyway I find it somehow not proper to read that text everytime when I look at my pools. Anyhow delivers an urge to update.
 
Unless you type zpool upgrade, your pool isn't upgraded. It's as simple as that.

Anyway, I advise to systematically upgrade the loaders after an OS upgrade. Moreover, there is an amazing software that does this for you. ;)
 
Back
Top