I can't upgrade pkg after upgrading 11.2 to 12.0

No, it does not. It will only update packages that happen to be out of date. After a major version upgrade you must reinstall all packages, which is what pkg upgrade -f does.
 
I did it without these recommendations:
$sudo pkg-static del -f pkg
Password:
pkg-static: Warning: Major OS version upgrade detected. Running "pkg-static install -f pkg" recommended
Checking integrity... done (0 conflicting)
Deinstallation has been requested for the following 1 packages (of 0 packages in the universe):

Installed packages to be REMOVED:
pkg-1.10.5_5

Number of packages to be removed: 1

The operation will free 12 MiB.

Proceed with deinstalling packages? [y/N]: y
[1/1] Deinstalling pkg-1.10.5_5...
[1/1] Deleting files for pkg-1.10.5_5: 100%
nat:[~]$sudo pkg upgrade
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+http://pkg.FreeBSD.org/FreeBSD:12:amd64/quarterly, please wait...
Verifying signature with trusted certificate pkg.freebsd.org.2013102301... done
Installing pkg-1.10.5_5...
Extracting pkg-1.10.5_5: 100%
Updating FreeBSD repository catalogue...
pkg: Repository FreeBSD has a wrong packagesite, need to re-create database
Fetching meta.txz: 100% 944 B 0.9kB/s 00:01
Fetching packagesite.txz: 100% 6 MiB 2.2MB/s 00:03
Processing entries: 100%
FreeBSD repository update completed. 31468 packages processed.
All repositories are up to date.
Updating database digests format: 100%
Checking for upgrades (119 candidates): 100%
Processing candidates (119 candidates): 100%
The following 118 package(s) will be affected (of 0 checked):

Installed packages to be UPGRADED:
ca_root_nss: 3.40 -> 3.41

Installed packages to be REINSTALLED:
unixODBC-2.3.7 (ABI changed: 'freebsd:11:x86:64' -> 'freebsd:12:x86:64')
unbound-1.8.0 (ABI changed: 'freebsd:11:x86:64' -> 'freebsd:12:x86:64')
tshark-2.6.3 (ABI changed: 'freebsd:11:
etc etc
 
I just installed 12.0-STABLE on a Raspberry PI 3B and I get the same error. Running "pkg-static del -f pkg" followed by "pkg upgrade" (with and without the -f) does not resolve this issue: I still get the shared object not found error.

Does anyone have any recommendations?
 
How you install 12-STABLE? Upgrade from 11.x? If yes, in which way make buildworld ..... or freebsd-upgrade ...?
And what shows error if you say that you already do pkg upgrade -f?

Give all information!
 
The 12-STABLE install was directly from a .img file downloaded from freebsd.org and installed on a 16GB microSD card using "dd" on an iMac:

% sudo dd bs=1m if=FreeBSD-12.0-STABLE-arm64-aarch64-RPI3-20181213-r341991.img of=/dev/rdisk11
2560+0 records in
2560+0 records out
2684354560 bytes transferred in 193.926793 secs (13842103 bytes/sec)

Very soon after the install I attempted to install an additional port (I do not recall which) and ran into the above shared object issue. I have repeated the pkg-static del -f pkg followed by pkg upgrade actions several times, adding reboots between the steps and other variations (like running pkg upgrade with and without -f).

pkg-static del -f pkg appears to run with no errors.

The output from the pkg upgrade -f:

root@generic:~ # pkg upgrade -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+http://pkg.FreeBSD.org/FreeBSD:12:aarch64/latest, please wait...
Verifying signature with trusted certificate pkg.freebsd.org.2013102301... done
Installing pkg-1.10.5_3...
Extracting pkg-1.10.5_3: 100%
ld-elf.so.1: Shared object "libssl.so.8" not found, required by "pkg"
 
root@generic:~ # pkg upgrade -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+http://pkg.FreeBSD.org/FreeBSD:12:aarch64/latest, please wait...
Verifying signature with trusted certificate pkg.freebsd.org.2013102301... done
Installing pkg-1.10.5_3...
Extracting pkg-1.10.5_3: 100%
ld-elf.so.1: Shared object "libssl.so.8" not found, required by "pkg"

I just struck this issue upgrading from 12-CURRENT to 13-CURRENT on my rpi3.

The solution was to compile the ports version of pkg and install that. It then, of course, links against the correct openssl libraries and resolves pkg's missing libraries issue.
 
So on a raspberry pi I have to install the ports tree and compile from source? Really?
(I flashed the 12-STABLE image on RPI-B: FreeBSD-12.0-STABLE-arm-armv6-RPI-B-20190307-r344851.img)
 
The solution was to compile the ports version of pkg and install that.
That did it! Thank you.
What did I misunderstand?

[FONT=courier new][1/1] Deinstalling pkg-1.10.5_3...
[1/1] Deleting files for pkg-1.10.5_3: 100%
root@rpi-b:/home/freebsd # pkg upgrade
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+http://pkg.FreeBSD.org/FreeBSD:12:armv6/latest, please wait...
Verifying signature with trusted certificate pkg.freebsd.org.2013102301... done
Installing pkg-1.10.5_3...
Extracting pkg-1.10.5_3: 100%
ld-elf.so.1: Shared object "libssl.so.8" not found, required by "pkg"[/FONT]
 
I still don't understand. "compile the ports version" means

[FONT=courier new]# cd /usr/ports/ports-mgmt/pkg/ && make install[/FONT]

right?
 
Post #3:
Code:
pkg-static install -f pkg
pkg upgrade
I still get the error like this.

Code:
# ldd /usr/local/sbin/pkg
/usr/local/sbin/pkg:
...
    libssl.so.8 => not found (0)
    libcrypto.so.8 => not found (0)
...
    libssl.so.8 => not found (0)
    libcrypto.so.8 => not found (0)
...
 
Last edited:
Back
Top