0

For the do-release-upgrade command is possible use the -d option. According with the documentation it is:

 -d, --devel-release
        If using the latest supported release, upgrade to the development release

I read these two posts:

But is not clear, when is mandatory use -d and when not.

According with my understanding there are two branches LTS and development, where the former is better because has an EOL longer than the latter.

If do-release-upgrade is used - without any option/parameter - it should go from LTS to LTS (it if exists a new LTS to reach/apply the upgrade, it for example from 16.04LTS to 18.04LTS or from 18.04LTS to 20.04LTS). Previously it could be confirmed/verified with do-release-upgrade -c to know if is possible do an upgrade or not.

Therefore:

  • When is mandatory use the -d parameter for the do-release-upgrade command? And When not?
Manuel Jordan
  • 1,768
  • 7
  • 30
  • 50

1 Answers1

1

The do-release-ugprade will cause a system upgrade to occur, Ubuntu allows the following upgrades

  • one release to the next (eg. 20.04 to 20.10), where this release is EOL (as 20.10 is), it'll allow you to upgrade to the next non-LTS in the same cycle; currently that's 21.10

  • one LTS release to the next LTS release (eg. 20.04 to 22.04 after 22.04.1 has been released)

FYI: Release cycles end with the LTS, but start with the first non-LTS after the prior LTS. ie. the cycle that ended with 20.04 started with 18.10, and the 22.04 cycle started with 20.10.

You use the -d option to upgrade before the release process has been formally opened.

How does it work.

Ubuntu release upgrades tools use by default the following file to ascertain what upgrades are possible - https://changelogs.ubuntu.com/meta-release

The -d option when used, causes the following file to be used instead - https://changelogs.ubuntu.com/meta-release-development ie. it'll currently allow an upgrade from 20.04 or 21.10 to Ubuntu jammy (which will be Ubuntu 22.04 LTS on release) to occur, when currently it's not offered/available (according to the standard file)

Even after the release of Ubuntu 22.04 LTS, this will only cause the offer of upgrade to be offered to Ubuntu 21.10 users, with Ubuntu 20.04 LTS users still needing to use the -d option to upgrade to 22.04. Ubuntu 20.04 LTS users will get offered the upgrade to Ubuntu 22.04 LTS only after the release of Ubuntu 22.04.1 LTS.

Please note: The release of Ubuntu 22.04 LTS does not cause any upgrades to be offered, as those files are changed only when deemed the upgrade path is stable for existing users. The Ubuntu Release Team discuss this regularly and decide from reports, when this is done, thus why the use of after is prominent in the documentation on when this occurs. Releases always occur on a Thursday, with the meta file changes usually first being discussed early the subsequent week.

guiverc
  • 30,396
  • 1
    When I say Thursday I'm referring to UTC time, in my neck of the woods down under (aussieland) that Thursday is usually very early Friday morning... – guiverc Apr 10 '22 at 22:54
  • 1
    Also note: the LTS to next non-LTS is current behavior & has been awhile, but historically this upgrade path was not available (no need when non-LTS releases had 15 months of supported life; it was added when the shortening to 9 months created some issues), and there is no guarantee the current behavior will continue forever into the future. That upgrade path has QA tests for it (with CI testing always done), but it receives less QA than non-LTS to next release, or LTS to next LTS. – guiverc Apr 10 '22 at 22:59
  • I am assuming by common sense that is better go to LTS to LTS and use the -c option to see if is possible or not - Am I correct? and -d should be used if I want upgrade to the next release without matter if it is LTS or not - Am I correct? - Therefore seems at a first glance that -d should be not used - Am I correct? – Manuel Jordan Apr 10 '22 at 23:09
  • 1
    There is no -c option in the man page for my current release, thus I'd avoid using it. If I was going to perform a release-upgrade I'd start by reading the release notes of the release you're moving to (we discuss all problems discovered in alpha, beta & QA tests & non-petty issues are documented in the release notes) then follow the instructions that cover the particular release you're performing as that will be what was QA-tested. ie. what I'd use for say a 18.04 to 20.04 upgrade may differ to 20.04 to 22.04 where release notes/upgrade notes say to do differently. – guiverc Apr 10 '22 at 23:15
  • BTW - about the -c option, it exists: see https://askubuntu.com/questions/1401724/how-does-the-do-release-upgrade-command-work-with-the-c-parameter-option?noredirect=1#comment2432831_1401724 – Manuel Jordan Apr 10 '22 at 23:27
  • 1
    I'm aware of -c but I'd still avoid it as almost no QA/release documentation uses it, and I agree esp. with user535733, but also steeldriver's responses. I'm involved with QA and we have procedures we follow for each release; with the eventual release-notes reflecting our testing & what was learnt during QA. When documentation isn't amended as per bug there will be a reason, even if it's just lack-of-time, and I'd opt to follow recommended paths, if you don't have time to monitor all pre-release QA yourself. – guiverc Apr 11 '22 at 00:11
  • 1
    LTS-to-LTS uses -d only before the upgrade path actually opens, which is three months after initial release. A release-upgrade of 20.04 to 22.04 before July 2022 requires -d because the path isn't open yet -- folks are becoming testers for that path. After the path opens in July 2022, -d is no longer needed. We re-learn this every two years. – user535733 Apr 11 '22 at 02:43
  • Huge thanks for all the explanation - how a polite and friendly suggestion - if in the official Ubuntu documentation can be added this explanation with flow charts would be very valuable, it because the two possible paths (with/without -d) according the date (before/after July) happens each 2 yrs. – Manuel Jordan Apr 11 '22 at 13:53