Re: FreeBSD 15.0-RELEASE: Trouble after upgrade

From: <freebsd.tug890_at_passmail.net>
Date: Wed, 03 Dec 2025 13:05:54 UTC
Hello @Odhiambo,

You updated your packages from QUATERLY branch on 15.0-RELEASE but you were using LATEST branch on 14.3-RELEASE
You can create your custom pkg conf.

# mkdir -p /usr/local/etc/pkg/repos

Then add the following content into the file /usr/local/etc/pkg/repos/FreeBSD.conf

--- File Begin ---
FreeBSD-ports: {
url: "pkg+https://pkg.FreeBSD.org/${ABI}/latest",
mirror_type: "srv",
signature_type: "fingerprints",
fingerprints: "/usr/share/keys/pkg",
enabled: yes
}

FreeBSD-ports-kmods: {
url: "pkg+https://pkg.FreeBSD.org/${ABI}/kmods_latest_${VERSION_MINOR}",
mirror_type: "srv",
signature_type: "fingerprints",
fingerprints: "/usr/share/keys/pkg",
enabled: yes
}

FreeBSD-base: {
url: "pkg+https://pkg.FreeBSD.org/${ABI}/base_release_${VERSION_MINOR}",
mirror_type: "srv",
signature_type: "fingerprints",
fingerprints: "/usr/share/keys/pkgbase-${VERSION_MAJOR}"
enabled: no
}
--- File End ---

After that, you can type the following command and your doas(1) issue should be solved.
# pkg upgrade -f -y

It works fine for me.

Kind regards.
Alexandre

-------- Original Message --------
On Wednesday, 12/03/25 at 13:13 Odhiambo Washington <odhiambo@gmail.com> wrote:

> On Wed, Dec 3, 2025 at 1:57 PM Odhiambo Washington <odhiambo@gmail.com> wrote:
>
>> On Tue, Dec 2, 2025 at 11:07 PM Dag-Erling Smørgrav <des@freebsd.org> wrote:
>>
>>> Odhiambo Washington <odhiambo@gmail.com> writes:
>>>> On Nov 26, there was an advisory ' FreeBSD Security Advisory
>>>> FreeBSD-SA-25:10.unbound'. On that date I did the freebsd-update
>>>> fetch && freebsd-update install thing. Today, I assumed that I was
>>>> still updated. So it's obviously my mistake that I did not repeat the
>>>> same thing today before upgrading to 15.0-REL.
>>>
>>> No, if you updated on Nov 26 then you should have been fine, so
>>> something else went wrong. I will try to see if I can reproduce it.
>>
>> So, I hosed my upgraded server and restored the VM from the backup I made before upgrade.
>> This is what I had:
>> root@gw:/home/wash # freebsd-version -kru
>> 14.3-RELEASE-p5
>> 14.3-RELEASE-p5
>> 14.3-RELEASE-p6
>> root@gw:/home/wash # uname -a
>> FreeBSD gw.wash.lan 14.3-RELEASE-p5 FreeBSD 14.3-RELEASE-p5 GENERIC amd64
>> root@gw:/home/wash # freebsd-update fetch
>> Looking up [update.FreeBSD.org](http://update.freebsd.org/) mirrors... 3 mirrors found.
>> Fetching metadata signature for 14.3-RELEASE from [update1.freebsd.org](http://update1.freebsd.org/)... done.
>> Fetching metadata index... done.
>> Inspecting system... done.
>> Preparing to download files... done.
>>
>> No updates needed to update system to 14.3-RELEASE-p6.
>> root@gw:/home/wash #
>>
>> So I suppose I was safe to upgrade, since I had also done a `portupgrade -a`.
>>
>> I am now embarking on the upgrade to 15.0-RELEASE once again.
>>
>>>> Also ran the command, but I don't understand the meaning of the
>>>> output:
>>>
>>> None of these are particularly concerning. They are telling you that
>>> you have modified configuration files (which is normal) and that some
>>> files and directories have incorrect permissions (which is something
>>> that sometimes happens with freebsd-update and isn't a big deal). There
>>> are discrepancies in /usr/src but that's easily fixed by replacing the
>>> entire source tree (rm -rf /usr/src then download and extract src.txz).
>>>
>>> You can fix at least some of these issues by running the following
>>> commands as root:
>>>
>>> mtree -deU -p / -f /etc/mtree/BSD.root.dist
>>> mtree -deU -p /var -f /etc/mtree/BSD.var.dist
>>> mtree -deU -p /usr -f /etc/mtree/BSD.usr.dist
>>
>> I will do this after this upgrade.
>>
>>> The only lines that surprise me are these:
>>>
>>> /usr/lib/debug/usr/lib/[libdevinfo.so](http://libdevinfo.so/).7.debug has SHA256 hash d06d59e4913a6103771409c598945e81dbaac857ea11271e2c03c92cd581aeef, but should have SHA256 hash 7653ff2946527fbb764e1932d767e4787fe8814c645f8c2d2359b43d0884f289.
>>> /usr/lib/libdevinfo.a has SHA256 hash 378b792d00971a8d5ffc45ad7882d08190a244b97de5514f5b2eb75ea0f6db47, but should have SHA256 hash 3d412bd84e6a1a9914610c8e838e4c4afe3b131789d5e36e9371bd5de03e0d68.
>>> /usr/lib/[libdevinfo.so](http://libdevinfo.so/).7 has SHA256 hash 667f9592ed95a538077f3fc22461ed3d6ece3deae27b66ec1e6a271807f25110, but should have SHA256 hash 0f1f789aa07dbfdc1df637be1d31f41616ec74188c683d9f706bae0ceb61d904.
>>>
>>> which is not critical and can be fixed by extracting those files from base.txz as explained in my previous email.
>>
>> This [libdevinfo.so](http://libdevinfo.so/) thing must have been created by me when I was struggling with installing qemu-guest-agent after the upgrade to 15.0.
>> Starting with complaints about '[ld-elf.so](http://ld-elf.so/).1: Shared object "[libutil.so](http://libutil.so/).9" not found, required by "pkg"; at some point, I went into a wild goose chase trying to fix things against the counsel of my 6th sense.
>> It's good I have a full backup of this VM so I can blow it away and restore and try the upgrade again until I get it right - or wait a little longer for others to be bitten and a solution found :-)
>>
>>> I assume you will be switching to pkgbase at some point, which will make correcting this kind of issue much easier.
>>
>> I have been following the discussions about pkgbase and I am sure to switch to it after I successfully upgrade to 15.0-RELEASE.
>
> I started from square one and ended up with the [libutil.so](http://libutil.so/).9 error that's been reported by others.
>
> ```
> root@gw:/home/wash # shutdown -r now
> Shutdown NOW!
> shutdown: [pid 70896]
> root@gw:/home/wash #
> *** FINAL System shutdown message from wash@gw.wash.lan ***
>
> System going down IMMEDIATELY
>
> System shutdown time has arrived
> login as: wash
> Keyboard-interactive authentication prompts from server:
> | Password for wash@gw.wash.lan:
> End of keyboard-interactive prompts from server
> wash@gw:~$ doas su
> root@gw:/home/wash # freebsd-update install
> pkg: Warning: Major OS version upgrade detected. Running "pkg bootstrap -f" recommended
> Installing updates... done.
> root@gw:/home/wash # pkg bootstrap -f
> The package management tool is not yet installed on your system.
> Do you want to fetch and install it now? [y/N]: y
> Bootstrapping pkg from pkg+[https://pkg.FreeBSD.org/FreeBSD:15:amd64/kmods_quarterly_0](https://pkg.freebsd.org/FreeBSD:15:amd64/kmods_quarterly_0), please wait...
> pkg: Error fetching [https://pkg.FreeBSD.org/FreeBSD:15:amd64/kmods_quarterly_0/Latest/pkg.pkg](https://pkg.freebsd.org/FreeBSD:15:amd64/kmods_quarterly_0/Latest/pkg.pkg): Not Found
> A pre-built version of pkg could not be found for your system.
> root@gw:/home/wash #
> root@gw:/home/wash #
> root@gw:/home/wash #
> root@gw:/home/wash #
> root@gw:/home/wash # portupgrade -af
> pkg-static: Warning: Major OS version upgrade detected. Running "pkg bootstrap -f" recommended
> pkg-static: Warning: Major OS version upgrade detected. Running "pkg bootstrap -f" recommended
> pkg-static: Warning: Major OS version upgrade detected. Running "pkg bootstrap -f" recommended
> pkg-static: Warning: Major OS version upgrade detected. Running "pkg bootstrap -f" recommended
> [Rebuilding the pkgdb <format:bdb_btree> in /var/db/pkg ... - 0 packages found (-0 +0) nothing to do]
> root@gw:/home/wash # pkg bootstrap -f
> The package management tool is not yet installed on your system.
> Do you want to fetch and install it now? [y/N]: y
> Bootstrapping pkg from pkg+[https://pkg.FreeBSD.org/FreeBSD:15:amd64/kmods_quarterly_0](https://pkg.freebsd.org/FreeBSD:15:amd64/kmods_quarterly_0), please wait...
> pkg: Error fetching [https://pkg.FreeBSD.org/FreeBSD:15:amd64/kmods_quarterly_0/Latest/pkg.pkg](https://pkg.freebsd.org/FreeBSD:15:amd64/kmods_quarterly_0/Latest/pkg.pkg): Not Found
> A pre-built version of pkg could not be found for your system.
> root@gw:/home/wash # pkg-static install -f pkg
> pkg-static: Warning: Major OS version upgrade detected. Running "pkg bootstrap -f" recommended
> Updating FreeBSD-ports-kmods repository catalogue...
> FreeBSD-ports-kmods repository is up to date.
> All repositories are up to date.
> Checking integrity... done (0 conflicting)
> The most recent versions of packages are already installed
> root@gw:/home/wash # pkg-static upgrade -F -y
> pkg-static: Warning: Major OS version upgrade detected. Running "pkg bootstrap -f" recommended
> Updating FreeBSD-ports-kmods repository catalogue...
> FreeBSD-ports-kmods repository is up to date.
> All repositories are up to date.
> Checking for upgrades (0 candidates): 100%
> Processing candidates (0 candidates): 100%
> Checking integrity... done (0 conflicting)
> Your packages are up to date.
> root@gw:/home/wash # pkg upgrade -f -y
> [ld-elf.so](http://ld-elf.so/).1: Shared object "[libutil.so](http://libutil.so/).9" not found, required by "pkg" <=========================================
> root@gw:/home/wash # freebsd-update install
> No updates are available to install.
> Run 'freebsd-update [options] fetch' first.
> root@gw:/home/wash # reboot
> login as: wash
> Keyboard-interactive authentication prompts from server:
> | Password for wash@gw.wash.lan:
> End of keyboard-interactive prompts from server
> wash@gw:~$ doas su
> [ld-elf.so](http://ld-elf.so/).1: Shared object "[libutil.so](http://libutil.so/).9" not found, required by "doas" <========================================
>
> wash@gw:~$
> ```
> --
>
> Best regards,
> Odhiambo WASHINGTON,
> Nairobi,KE
> +254 7 3200 0004/+254 7 2274 3223
> In an Internet failure case, the #1 suspect is a constant: DNS.
> "Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-)
> [How to ask smart questions: http://www.catb.org/~esr/faqs/smart-questions.html]