[Solved] Install FreeBSD package
-
Trying to install openBGPd from the FreeBSD repository on a new install of pfSense 2.6. (Yeah, I know, not supported, etc).
Following the instructions in the documentation I've had no luck at all. I did do this successfully on 2.5.2 when that was set up.
I edited /usr/local/etc/pkg/repos/pfSense.conf to enable FreeBSD, rebooted and tried:
pkg add http://pkg.freebsd.org/FreeBSD:12:amd64/quarterly/All/openbgpd-5.2.20121209_4,1.txz
That and other variations - https, no .txz, just openbgpd - return "Not Found".
The FreeBSD pkg repo has had browsing disabled below a certain level, so it's no longer possible to find the exact path and file name.
Anyone have any ideas how to work around this?
Thanks
-
So I discovered that it has to be:
openbgpd-5.2.20121209_4,1.pkg
not
openbgpd-5.2.20121209_4,1.txz
Perhaps the documentation needs to change.
-
Any particular page?
The main recommendation is do not install FreeBSD packages at all.
You shouldn't need to enable the FreeBSD repo in the pkg conf file. Installing a single pkg directly like that doesn't require it. And doing so means it will pull in any dependencies from there potentially overwriting the custom pfSense versions.And also use FRR for BGP
Steve
-
@stephenw10 said :
Any particular page?
Thanks, Steve. Sorry, it was getting late. This is what I was following.
I do know about the recommendation not to install FreeBSD packages. OpenBGPd has no dependencies - something I checked when I first installed it a few years ago.
I don't use OpenBGPd (or anything else) for "proper" BGP.
In my case, it's used to directly update a pfSense alias containing fail2ban'd IPs sent from my mail server. It's instantaneous and very low overhead. -
Ah, that's fine then. You've obviously done the work in advance.
I mention the issues here because unfortunately there are many users who do not do the work and reap the consequences!
Yes, we could update that page to use a current example with the alternative file suffix.
Steve
-
@stephenw10 said:
Yes, we could update that page to use a current example with the alternative file suffix.
Curiously, I couldn't find any FreeBSD documentation or discussion about that change of file extension. Still wondering whether I might have got something wrong. OpenBGPd is installed though.
-
If you run
pkg -d update
you'll see it tries both in current versions. I have no insight into the change though. -
So, I set /usr/local/etc/pkg/repos/pfSense.conf back to "no" and deleted the OpenBGPd pkg. Thanks for that tip, Steve. Although, I hadn't made a note of doing this originally but, after a few failed attempts, I went back to the pfSense documentation.
Tried this again after making the change:
pkg add http://pkg.freebsd.org/FreeBSD:12:amd64/quarterly/All/openbgpd-5.2.20121209_4,1.txz
and the result was:
pkg: http://pkgmir.geo.freebsd.org/FreeBSD:12:amd64/quarterly/All/openbgpd-5.2.20121209_4,1.txz: Not Found
Changed .txz to .pkg and it installed OK.
Might post a question on the FreeBSD forum.
-
If you specify the exact filename, as you must when using a different repo, then it will only use that. If you do something like
pkg install nano
the pkg system will try both file types. But only against the configured repo. -
Hi Steve,
Yes, in fact I tried the following variations:
pkg add http://pkg.freebsd.org/FreeBSD:12:amd64/quarterly/All/openbgpd pkg add http://pkg.freebsd.org/FreeBSD:12:amd64/quarterly/All/openbgpd.txz pkg add http://pkg.freebsd.org/FreeBSD:12:amd64/quarterly/All/openbgpd.pkg
All returned "Not Found".
Edit: Same with "pkg install . . ."
-
Yup you need the precise file name including the build number to use pkg add.
-
Yep, sorry, I misread your previous post.
Thanks again.
-
Just to follow up on this, I found this post from Feb '22 on the FreeBSD forum:
"The extension for FreeBSD packages changed from .txz to .pkg recently. The static pkg tool in base still expects the old name.t"