When I upgraded from 20.04 LTS to 22.04 LTS, the installer told me that it would disable some of my software sources and that I could manually re-enable them after. When I checked the "Software & Updates" > "Other Software" list, I could see a few were disabled, like a VSCode repo, an OBS PPA, and perhaps a Steam repo.

I wasn't sure if simply re-enabling them was the way to go, so I actually just uninstalled those programs and reinstalled. Not sure if that was the best option but it's done now.

Assuming that problem is fixed, my list still seems to be cluttered with some old stuff, notably some 20.04 Focal Fossa entries, and perhaps some others (see image).

Old software sources

Are all these entries necessary? Is there an easy to clean this list out, so that it shows up as if I had done a clean re-install instead of an upgrade?

Thanks for any help!

1 Answer 1


You can manually delete the lines from your file.

First, make a backup.

sudo cp /etc/apt/sources.list /etc/apt/sourcesbackup

Then, open the file using a text editor.

sudo nano /etc/apt/sources.list

Delete each line that contains the word "focal". ONLY delete the lines that say focal.

When you are done, press CTRL+o to save the changes and then press CTRL+x to exit nano.

Finally, run sudo apt update to apply the changes.

  • If you want to get rid of the ppa stuff, those are in different files found in /etc/apt/sources.list.d. Similarly, I would only recommend getting rid of lines that contain the word focal. However, it is possible to have software installed from a focal ppa on a jammy install (although, uncommon). If there are only lines that contain the word focal in a file, you can delete the file. The best thing to do would be to look into installing a jammy version of each ppa if one exists.
    – mchid
    Aug 24, 2022 at 12:41

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .