brewedbits.dev

Personal blog with guides and news on selfhosting, Linux and AI, from the Netherlands

nextDash nextdash --aboutYour bookmarks. Your terminal. checks your links knows your Docker host one container, no cloudLive demo →nextdash.cc ↗

Tip: ppa-purge takes an Ubuntu system back to the official packages

Ubuntu
~/tips/tip-ubuntu-ppa-purge

sudo apt install ppa-purge

Remove an extra PPA and downgrade what came from it.

A PPA gave you a newer version of something and now it misbehaves. Removing the repository leaves the newer packages installed, so you are still running them.

ppa-purge handles both steps:

sudo apt install ppa-purge
sudo ppa-purge ppa:owner/name

Replace owner/name with the PPA you added. It disables the PPA and downgrades its packages to the versions from the Ubuntu archive. The list of sources shows what you have:

ls /etc/apt/sources.list.d/

Read the proposed changes before you agree to them. Downgrades can pull other packages along, and sometimes apt proposes removing something you need. If that happens, say no and look closer.

I would run this before a release upgrade too, since third party packages are a common reason for an upgrade to go wrong.

Take a backup first. A downgrade does not turn back configuration files or data that the newer version already converted, so an application may refuse to start with its own newer database. It only works for PPAs on Launchpad or a similar layout. Packages that exist only in the PPA have no Ubuntu version to fall back to, so check what happens to them in the proposal.

Further reading: ppa-purge man page

More Ubuntu tips grep ^Prompt /etc/update-manager/release-upgrades sudo tee /etc/update-motd.d/60-disk >/dev/null <<'EOF' ubuntu-bug openssh-server sudo update-alternatives --config editor pro status All Ubuntu tips (8) All topics

Link