12

I have a few Ubuntu VMs on Azure running Server 17.10 and I'm wondering if it's safe to upgrade them to 18.04.1 LTS using do-release-upgrade.

If so, what precautions should I take?

georgiosd
  • 289
  • 2
  • 5
  • 13

2 Answers2

11

Yes

I just did this to about 110 EC2 instances. I actually did it from Ubuntu 14.04 through 16.04 and up to 18.04 using an automated the process for that many instances. It turns out it is possible to automate do-release-upgrade

If you want to be really safe, take a snapshot of the root disk before going forward.

Make a clone of your instance or spin up a test instance and do the upgrade. There are a lot of changes in Ubuntu from 14.04 to 18.04, a lot. A number of things broke, and SystemD changes a lot of default behavior.

But there are quite a bit fewer changes from 17.10 to 18.04, so I expect you to have a pretty reasonable time of it.

JDS
  • 2,598
  • 4
  • 30
  • 49
  • May I ask, how did you manage to automate the `do-release-upgrade` calls? – Axel Jan 15 '19 at 18:58
  • 2
    i've been meaning to post the scripts to github but i don't own them, so i need to clean them and post them to my own github, which i haven't had time to do. anyway, to sum up, it is a combination of `export DEBIAN_FRONTEND=noninteractive` and `do-release-upgrade -f DistUpgradeViewNonInteractive` – JDS Jan 16 '19 at 19:25
  • I found both of those in the meantime, but good that it's recorded for posterity now. ;-) – Axel Jan 17 '19 at 16:55
  • @JDS > I just did this to about 110 EC2 instances. I actually did it from Ubuntu 14.04 through 16.04 and up to 18.04 using an automated the process for that many instances. It turns out it is possible to automate do-release-upgrade. How did you automate the process of do-release upgrade command without asking any questions or prompts. – chandra sekhar Jan 07 '20 at 17:45
  • @chandrasekhar I'll see if I can get my scripts into a publicly available github; they are owned by my company, not me, so I might not be able to – JDS Jan 08 '20 at 13:40
  • What do you mean "snapshot of the root disk" with Azure? How? – pauljohn32 Jan 31 '20 at 06:00
  • @pauljohn32 I did this in EC2; on EC2 you can make snapshots of any EBS volume, including the root disk. I don't know how to perform that type of operation on Azure – JDS Feb 01 '20 at 15:40
1

It really depends on what you have installed. In general, I've come to prefer fresh installations of new OS versions rather than upgrading. There are a ton of fancy deployment and CM tools out there, and OS upgrades in general are complex operations even on "vanilla" installs.

Perhaps take a snapshot and try. Just make sure you can roll back quickly somehow.

Spooler
  • 7,046
  • 18
  • 29
  • Agree on fresh install. But moving user accounts and their programs not easy. Preserving permissions, group membership looks tough. – pauljohn32 Jan 31 '20 at 06:01