Is it safe to upgrade Ubuntu from 14.04 to 16.04.1 via do-release-upgrade, and how-to

I did the upgrade without any problems on DO a few weeks ago.

what I did:

  1. Live snapshot on DO

  2. stop discourse: ./launcher stop app

  3. upgrade with screen: do-release-upgrade

I believe I had to manually start docker service docker start once the upgrade was done, but didn’t have any issues otherwise.

4 Likes

Its actually faster if you create new droplet and set up discourse.
Its just system configuration, docker installation (simple apt-get) and rsync from old instance.

1 Like

Hi Oleg, may you please show an example of working rsync commands for the approach proposed? What folders exactly need to be synced?

Except speed, are there any other benefits of going this way?

1 Like

It’s just the time it takes to bootstrap. I think it’s the case that if you don’t know the rsync command, you don’t care.

Just a note that might be vital for someone:

Taking an online snapshot, even with your DigitalOcean droplet OFF, might be pretty time consuming:

3 Likes
  • The DigitalOcean snapshot took ~20 minutes for a 40GB instance.
  • don’t forget running ./launcher cleanup before turning off your droplet and making a snapshot - it may a big difference in the snapshot size, sometimes up to 10GB
  • The do-release-upgrade took about 20 minutes for me (upgrading from 14.06 LTS to 16.06 LTS)

A few notes from the upgrade process I run through:


Answered NO.


Answered YES.



At the end:


After restarting:

Didn’t need this in my case.


Something I did not pay too much attention to, but should have done so when upgrading through a SSH connection - only googled about it later:

11 Likes

@mr8, I just ran the do-release-upgrade upgrade but got disconnected when it asked me to restart. Now I am getting the error message:
Device "docker0" does not exist. Cannot connect to the docker daemon - verify it is running and you have access

How were you able to manually restart it once the upgrade was done? I am not trained as a programmer so everyone’s detailed instruction would be much appreciated!

1 Like

Running the following command solved the problem:

./launcher stop app
./launcher start app

Thanks everyone!

4 Likes

I am upgrading a droplet from 14.04 to 16.04 right now using do-release-upgrade and following @meglio’s excellent summary. So far so good!

edit: completed and running as 16.04 without any issues at all.

5 Likes

I’ve used the same process on a number of Digital Ocean servers, so it is good to hear this works as expected.

One point, it looks like you are on an older Digital Ocean server, so it has not upgraded the Kernel. You can switch (in the Digital Ocean control panel) the Kernel to the Grug 0.2 kernel, and then Ubuntu will use the latest version (4.4 something).

BTW, the Snapshot is definitely essential - I just tried this process and it corrupted the harddisk and refused to boot properly - I’m lucky like that. I restored from the snapshot and everything was good again (tried again and the same thing happened so now I’ll see what the DO folks have to suggest).

So kids, always do the Snapshot (ideally from a powered off state, event if that means your server is down for an hour).

3 Likes

I’m with @meglio, I’d like to see instructions on transferring a forum from one instance to a new one.

Those instructions already exist in the #howto area unless you insist that the transfer has to be rsync, versus simple web download of backup, web upload of backup, then web restore.

1 Like

Turns out my fstab had an incorrect UUID for the root disk which was the root cause (get it! ;- ) of the resulting disk corruption. Fixing that meant the update to Ubuntu 16 worked without further problems.

2 Likes

Any idea how much free disk space is needed to do this?

I had at least 7GB free, but don’t know how many are needed actually.

Is this guide ok also to upgrade from 18.04.02 to 20.04.01?

It should be. I’m old school, though and prefer to do a clean installation and copy over the data.

3 Likes

Give it a shot and let us know how it goes!

well I upgraded our root server (no droplet) from 18.04.5 LTS to 20.04.1 LTS two weeks ago and discourse is running fine.
Just for the upgrade I had to manually change /etc/apt/sources.list and replace bonic by focal and ftp by http (ftp is deactived by default in 20).
But when I did the upgrade vom 16.04.6 LTS to 18.04.3 LTS beginning of the year I also had to change it manually from xenial to bionic since do-release-upgrade did run on error.
So this might only be a problem caused by my hoster Strato here in Germany.

2 Likes

Thank You,
I have a Discourse Droplet on Digital Ocean and I’m wondering what’s the safest way to upgrade.