I understand that it is generally recommended to always upgrade Debian sequentially. For example upgrade Debian Jessie (8) to Stretch (9) and then to Buster (10). But I couldn't find any clear instructions on how to do this exactly.

Is it sufficient to edit APT's source-list files (/etc/apt/sources.list and files under /etc/apt/sources.list.d/) to refer to my target release version while following the upgrade instructions in the release notes?

E.g. to upgrade from Jessie to Stretch I'd replace every reference to jessie (or stable, ...) with stretch and perform the upgrade? And afterwards again replace stretch with buster and perform the next upgrade?

Answers to other questions here like Upgrade Debian Jessie (8) to Buster (10) possible or need to go sequential in versions upgrades? only explain that it is recommended to upgrade sequentially but don't explain how. Maybe this is really obvious and I just lack the experience.

I'm a little worried that apt-get dist-upgrade might directly upgrade from Jessie to Buster leaving out Stretch.

Kind regards :)


1 Answer 1


The release notes explain how to go about each upgrade, and as you say, each upgrade needs to be performed in sequence, following each release’s upgrade notes. The Debian 10 release notes mention this explicitly:

Direct upgrades from Debian releases older than 9 (stretch) are not supported. Please follow the instructions in the Release Notes for Debian 9 to upgrade to Debian 9 first.

If you follow the release notes, you won’t end up upgrading directly when using apt-get dist-upgrade. That could happen if you tried upgrading to “stable” rather than a release codename: if your repositories were configured to reference Jessie, and you changed them to reference “stable”, apt-get dist-upgrade would attempt to upgrade directly to Buster (and soon, Bullseye). Using codenames ensures you only end up upgrading to the named release.

Repository configuration is also addressed in the release notes, and can’t generally be simplified to a replacement operation (because the repository structure might change from one release to the next, and some repositories should be removed before upgrading). Thus the Stretch release notes list the repositories which need to be added, and instruct the administrator to remove obsolete repositories.

There is an unfortunate, large caveat though: the upgrade section of the release notes doesn’t mention the security update repositories, which should be configured for the last upgrade; for Debian 10 you should end up with something like

deb http://deb.debian.org/debian buster main
deb http://security.debian.org buster/updates main

as a minimum. The relevant repository configuration can always be found on Debian’s security information page.

(This will change for Debian 11, and is mentioned in the release notes.)

  • So, the most simple answer to my question would be: "Follow the release Notes of each Debian release. They cover configuring the APT sources correctly to go from one release to the next. Which in case of upgrading from Jessie to Buster includes editing sources.list as suggested in the question, but there's more to do." Which is basically what you wrote, but maybe you could have a similar statement stand out in your answer to make it more clear?
    – Karl
    Jun 7, 2021 at 10:34
  • What I was worried about before (and should have mentioned in the question) is that apt-get dist-upgrade would directly upgrade from Jessie to Buster leaving out Stretch. And since I lack experience in working with Debian and APT repository configuration, I was unsure if I understood the release notes correctly. But thanks again for your reply, Stephen. Especially for the hint about the security repo, I would have missed that otherwise.
    – Karl
    Jun 7, 2021 at 10:36
  • 1
    The first sentence of my answer is supposed to be its summary. In your version of the simplified answer, I disagree with “editing sources.list as suggested in the question”: the release notes don’t mention replacing releases in repository configuration lines, they describe how to add repository configuration and remove obsolete configuration. This is important because when upgrading, the number of repositories might increase or decrease, and some might need to be removed during the upgrade. Jun 7, 2021 at 11:51

You must log in to answer this question.

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