Solved pkg: No SRV record found for the repo FreeBSD

Any idea how to fix this?

Code:
# pkg update
Updating FreeBSD repository catalogue...
Fetching meta.conf: 100%    178 B   0.2kB/s    00:01
Fetching packagesite.pkg: 100%    7 MiB   7.0MB/s    00:01
Processing entries: 100%
FreeBSD repository update completed. 32886 packages processed.
All repositories are up to date.

# pkg upgrade
Updating FreeBSD repository catalogue...
pkg: No SRV record found for the repo 'FreeBSD'
pkg: packagesite URL error for pkg+http://pkg.FreeBSD.org/FreeBSD:14:aarch64/quarterly/packagesite.pkg -- pkg+:// implies SRV mirror type
pkg: packagesite URL error for pkg+http://pkg.FreeBSD.org/FreeBSD:14:aarch64/quarterly/packagesite.txz -- pkg+:// implies SRV mirror type
Unable to update repository FreeBSD
Error updating repositories!
 
Last time I had this same problem I manually set a mirror in
/usr/local/etc/pkg/repos/FreeBSD.conf (but only temporarily)
Code:
FreeBSD: {
      url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest"
}
Change it with any specific mirror:
FreeBSD pkg mirrors
But I don't know why this problem occurs, probably your automatically selected mirror is unreachable

Edit: Better go with the answer above mine.
 
Back
Top