Suppose I want to use some GUI programs that were provided in an old release of Ubuntu. I am currently using a later version of Ubuntu that does not provide these GUI programs. Is there a reliable way install these old programs without messing up my existing packages, and without having to use virtualization (e.g. VirtualBox)?

I have read this question: How do I install Qtstalker on Ubuntu 17.10?, which is about installing Qtstalker, a program that was available in Ubuntu 12.04 Precise Pangolin, but which has been removed from later Ubuntu releases because the upstream has ceased development. The answer there uses chroot. I am wondering: is the method generally applicable to other programs too? Is chroot the proper and usual solution to the problem?

Suppose I want to play XBattle, which was available in Ubuntu 12.04 Precise Pangolin, but was subsequently removed. Should I use chroot to play it in Ubuntu 18.04 Bionic Beaver?

I read https://packaging.ubuntu.com/html/chroots.html, but the page seems to imply that chroot is a packaging tool rather than something that one would use for running programs regularly.

Other answers suggesting a chroot solution to such problems: The packages for old releases are not available anymore?

  • My first attempt is to try the .deb to see if it installs on newer versions. Quite frequently, it does. If there aren't too many dependencies, I may try to make it work. Then, my next tool is a virtual machine - but that's because I am acclimated to them and use VMs every day. This isn't really an answer, it's just what I do.
    – KGIII
    Nov 17 '20 at 4:17
  • @KGIII I don't want to try the deb solution because it is too risky. Qtstalker, for example, has many dependencies (e.g. MySQL, old version of Qt, etc.). VM is too heavy.
    – Flux
    Nov 17 '20 at 4:19

If you have software that requires use of an EOL (end of life) operating system, you should do your best to isolate it away from your primary system and quarantine it from the internet.

The best way to do this is to set up a virtual machine using VM software like VirtualBox. Make sure that you disable the network adapter for the container.



As you have already know from my other answers, I use schroots very often.
On my personal machine I have at least two such schroots - one for self-patched version of Referencer application and one for GCC toolchain for old OpenWRT 12.07 branch. It works normally.


The second possible way to run old application - is to use Docker container for it. With your xbattle package it is possible with the creation of Dockerfile as follows

sudo apt-get install docker.io
sudo usermod -a -G docker $USER
# reboot

mkdir ~/docker-xbattle
cat > ~/docker-xbattle/Dockerfile << EOF
FROM ubuntu:12.04
RUN apt-get update
RUN apt-get install -y xbattle
CMD /usr/games/xbattle -black me -farms 5 -militia 5 -decay 5 -hills 9  -hex

docker build -t ubuntu:xbattle ~/docker-xbattle

and creation of special launcher script for it

docker run -it -e DISPLAY -v /tmp/.X11-unix:/tmp/.X11-unix --user="$(id --user):$(id --group)" ubuntu:xbattle

to play it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.