If, after moving to pkgbase (for me, that was via pkgbasify), you discover you can’t find the package in question, you might, like me, run this command:
% pkg repos -e
[18:25 r720-02 dvl ~] % pkg repos -e
local: {
url : "https://fedex.example.org/packages/FreeBSD:15:amd64/",
enabled : yes,
priority : 0,
signature_type : "PUBKEY",
pubkey : "/etc/ssl/slocum.unixathome.org.cert"
}
Not to worry, that’s my local repo. What’s missing there is pkgbase. When I compare this to another host, I saw:
[18:25 gw01 dvl ~] % pkg repos -e
FreeBSD-base: {
url : "pkg+https://pkg.FreeBSD.org/FreeBSD:15:amd64/base_release_0",
enabled : yes,
priority : 0,
mirror_type : "SRV",
signature_type : "FINGERPRINTS",
fingerprints : "/usr/share/keys/pkgbase-15"
}
local: {
url : "http://fedex.int.example.org/packages/FreeBSD:15:amd64/",
enabled : yes,
priority : 0,
signature_type : "PUBKEY",
pubkey : "/etc/ssl/slocum.unixathome.org.cert"
}
[18:25 gw01 dvl ~] % sudoedit /usr/local/etc/pkg/repos/FreeBSD-base.conf
Where is FreeBSD-base in the first host?
Checking:
[18:25 gw01 dvl ~] % cat /usr/local/etc/pkg/repos/FreeBSD.conf
FreeBSD-ports: { enabled: no }
FreeBSD-ports-kmods: { enabled: no }
OK, I’ve disable those two, on purpose.
I had the same thing on r720-02
This took me a while to figure out. It was /usr/local/etc/pkg.conf, which contained:
REPOS_DIR : [ /usr/local/etc/pkg/repos/, ] BACKUP_LIBRARIES=yes
I’ve been using that approach for many years. It’s not the best. I’m now using the enabled: no approach instead.
My solution:
[18:35 r720-02 dvl /usr/local/etc] % sudo mv pkg.conf.sample pkg.conf
Now I have:
[18:36 r720-02 dvl /usr/local/etc] % pkg repos -e
FreeBSD-base: {
url : "pkg+https://pkg.FreeBSD.org/FreeBSD:15:amd64/base_release_0",
enabled : yes,
priority : 0,
mirror_type : "SRV",
signature_type : "FINGERPRINTS",
fingerprints : "/usr/share/keys/pkgbase-15"
}
local: {
url : "https://fedex.unixathome.org/packages/FreeBSD:15:amd64/",
enabled : yes,
priority : 0,
signature_type : "PUBKEY",
pubkey : "/etc/ssl/slocum.unixathome.org.cert"
}
Success.











