PKG update error - unresolved

I am having considerable trouble now, while trying to install packages.

My system is FreeBSD 14.2 -RELEASE and worked fine for some time. But now I am getting the following result when I try to install a package:

Code:
Updating FreeBSD repository catalogue...
pkg: packagesite URL error for pkg+https://pkg.freebsd.org/FreeBSD:14:amd64/quarterly/meta.conf -- pkg+:// implies SRV mirror type
pkg: packagesite URL error for pkg+https://pkg.freebsd.org/FreeBSD:14:amd64/quarterly/meta.txz -- pkg+:// implies SRV mirror type
repository FreeBSD has no meta file, using default settings
pkg: packagesite URL error for pkg+https://pkg.freebsd.org/FreeBSD:14:amd64/quarterly/data.pkg -- pkg+:// implies SRV mirror type
pkg: packagesite URL error for pkg+https://pkg.freebsd.org/FreeBSD:14:amd64/quarterly/data.txz -- pkg+:// implies SRV mirror type
pkg: packagesite URL error for pkg+https://pkg.freebsd.org/FreeBSD:14:amd64/quarterly/packagesite.pkg -- pkg+:// implies SRV mirror type
pkg: packagesite URL error for pkg+https://pkg.freebsd.org/FreeBSD:14:amd64/quarterly/packagesite.txz -- pkg+:// implies SRV mirror type
Unable to update repository FreeBSD
Error updating repositories!

I tried to follow the advice given by SirDice in a previous thread by editing the file FreeBSD.conf which was supposed to be in /usr/local/etc/pkg/repos but there is no such file there.

I DID find FreeBSD.conf in two other directories, but editing them according to SirDice's advice made no difference.

I will try copying the FreeBSD.conf into the directory suggested by SirDice by making that dir, but at the moment, I am stuck.

Ha! I edited FreeBSD.conf and removed the "words" pkg+ which were ahead of the URL and now everything works correctly. I don't understand why, but it now works.

Ken Gordon
 
Hi,

/usr/local/etc/pkg/repos directory doesn't exist by default, you need to create that directory and copy the /etc/pkg/FreeBSD.conf file there and make the change, i.e. changing from quarterly to latest repository:

Rich (BB code):
FreeBSD: {
  url: "pkg+https://pkg.FreeBSD.org/${ABI}/latest",
  mirror_type: "srv",
  signature_type: "fingerprints",
  fingerprints: "/usr/share/keys/pkg",
  enabled: yes
}

If you made a change and didn't include the lines including srv then maybe this is what caused the error you got.
 
Re-checking my FreeBSD.conf file, in order to NOT get the error message, I MUST remove the words pkg+ from the URL. Otherwise, no matter what ELSE is in that file, I get the error message.

My FreeBSD.conf is identical with that one you posted with the exception of my removal of pkg+ from the url line.

I am still confused.

Ken Gordon
 
I tried to follow the advice given by SirDice in a previous thread by editing the file FreeBSD.conf which was supposed to be in /usr/local/etc/pkg/repos but there is no such file there.
Just so you know instructions are on top of the file /etc/pkg/FreeBSD.conf :
#
# To disable this repository, instead of modifying or removing this file,
# create a /usr/local/etc/pkg/repos/FreeBSD.conf file:
#
# mkdir -p /usr/local/etc/pkg/repos
# echo "FreeBSD: { enabled: no }" > /usr/local/etc/pkg/repos/FreeBSD.conf
#
 
Yeah, you only need to put your changes in /usr/local/etc/pkg/repos/FreeBSD.conf. You don't need to copy the entire /etc/pkg/FreeBSD.conf file. It will 'inherit' the other settings from /etc/pkg/FreeBSD.conf.

Code:
FreeBSD: {
  url: "pkg+https://pkg.FreeBSD.org/${ABI}/latest"
}
 
Back
Top