pfsense

While working on upgrading one of my pfsense boxes in home network, i encountered an issue where i was not able update the pfsense package via GUI or via shell. After some digging, found out that the package URl in the /usr/local/share/pfSense/pkg/repos/pfSense-repo.conf was borked for some reason.

After pulling my hair for an hour, i noticed this issue and was able to resolve it using following steps.

  1. Check if pfsense package url are correct
sudo pkg-static -d update
  1. If it throws invalid URL then you need to check and update url in repo config at /usr/local/share/pfSense/pkg/repos/pfSense-repo.conf. It should look something like this
FreeBSD: { enabled: no }
pfSense-core: {
url: "pkg+https://firmware.netgate.com/pkg/pfSense_plus-v22_01_amd64-core",
mirror_type: "srv",
signature_type: "fingerprints",
fingerprints: "/usr/local/share/pfSense/keys/pkg",
enabled: yes
}
pfSense: {
url: "pkg+https://firmware.netgate.com/pkg/pfSense_plus-v22_01_amd64-pfSense_plus_v22_01",
mirror_type: "srv",
signature_type: "fingerprints",
fingerprints: "/usr/local/share/pfSense/keys/pkg",
enabled: yes
}

Note: Notice the url, mine did not had pkg+https://firmware.netgate.com/pkg defined in it.

  1. Once file is update, run package update again
sudo pkg-staic -d update

I hope this will help if you are having this issue. Cheers