Register for the iXsystems Community to get an ad-free experience and exclusive discounts in our eBay Store.

Is it possible to use portdowngrade in a Jail (running 11.2)?

Oct 14, 2016

This doubt began when I wanted to test mldonkey inside a jail. But the question in general is how to get older software versions in a jail. Keep in mind that I'm a noob with freebsd, I have done some custom jails like setting up my own custom DNS server with dnsmasq.

I will keep with mldonley as an example, I think there is a bug in actual version but let's ignore this, I want to downgrade it to learn how to do it. In linux I usually grab the version I want from an older repo, but in freebsd I can go back only to 11, and that's my version actually.

Ok so actual version is:
mldonkey-core-3.1.5_2          Client 'core' for the MLDonkey peer-to-peer network

This is the one I want to avoid. And I learned about portdowngrade here:

I check the as the manual says but I get this error:

mldonkey-core-3.1.5_3    -> net-p2p/mldonkey-core

Choose a port origin (directory) from the list
above, and then run portdowngrade category/port

root@transmission_1:~/mldonkey # portdowngrade net-p2p/mldonkey-core
Choose a revision from this list and run /usr/local/sbin/portdowngrade net-p2p/mldonkey-core revision
svn: E170013: Unable to connect to a repository at URL ''
svn: E000065: Error running context: No route to host
Choose a revision from the above list and run /usr/local/sbin/portdowngrade net-p2p/mldonkey-core revision
root@transmission_1:~/mldonkey # 

Now as a bonus track I can see that ports has a newer version but if I try to install I get this:

root@transmission_1:/usr/ports/net-p2p/mldonkey-core # make install clean
===>  mldonkey-core-3.1.5_3 pkg(8) must be version 1.13.0 or greater, but you
have 1.10.5. You must upgrade the ports-mgmt/pkg port first.
*** Error code 1

make: stopped in /usr/ports/net-p2p/mldonkey-core
root@transmission_1:/usr/ports/net-p2p/mldonkey-core #

And if I try to upgrade pkg:

root@transmission_1:/usr/ports/ports-mgmt/pkg # make install clean
/!\ ERROR: /!\

Ports Collection support for your FreeBSD version has ended, and no ports are
guaranteed to build on this system. Please upgrade to a supported release.

No support will be provided if you silence this message by defining

*** Error code 1

make[1]: stopped in /usr/ports/ports-mgmt/pkg
*** Error code 1

make: stopped in /usr/ports/ports-mgmt/pkg
root@transmission_1:/usr/ports/ports-mgmt/pkg #

Now the questions are: Can I use portsnap at all in a jail? Is this related to the error with portdowngrade? If that's the case how do I get an older version of a package?


Nov 7, 2020
You need to have working Internet access in your jail- this is why it's failing.

Portsnap, portdowngrade and pretty much everything else work in jails!

The last error is because you're using an old version of FreeBSD- if you type

root@transmission_1:/usr/ports/ports-mgmt/pkg # make ALLOW_UNSUPPORTED_SYSTEM=yes install clean

then you can work around it... but do expect things to break if you're still using FreeBSD-11.

You can install older ports on new OSes just fine (within reason).
Oct 14, 2016
Thanks for answering. I didn't kept with this, but I'm pretty sure the jail had internet all the time.

If have to try again I will take into account your comments.