Today I did a LTS upgrade from trusty to xenial using do-release-upgrade
. It went through without an error. But after the upgrade I'm not sure on which version my system is now.
The do-release-upgrade
tool said it would upgrade to xenial and my sources.list
now points to the xenial package archive. apt
claims all packages are fully upgraded (doing update
, upgrade
and dist-upgrade
).
But when I run lsb_release -a
I'm still getting this
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 14.04.5 LTS
Release: 14.04
Codename: trusty
And when I check the version of base-files
(which to my understanding contains the /etc/lsb-release
file) with dpkg --list
I'm getting version 10.1
which is the most recent package version in the bionic package archive.
Also when I run do-release-upgrade -c
it still tries to upgrade to xenial.
I must say I'm pretty confused. Has anyone any idea what's going on?
Update
I think I know what happened here. While updating, the installation process for base-files
asks for user confirmation on whether to update the /etc/lsb-release
file if it was edited since the last installation.
Configuration file '/etc/lsb-release'
==> Modified (by you or by a script) since installation.
==> Package distributor has shipped an updated version.
What would you like to do about it ? Your options are:
Y or I : install the package maintainer's version
N or O : keep your currently-installed version
D : show the differences between the versions
Z : start a shell to examine the situation
The default action is to keep your current version.
The file looked like it had the same contents as in the trusty base-file
package before updating, so I don't really understand why I got get asked before replacing it. Anyways, I think I might have taken the default action, resulting in a mismatch between the actually installed release and the contents of the file.
Replacing the file with the one from the xenial package allowed me to successfully update to bionic with do-release-upgrade
. This time I selected to update the lsb-release
while upgrading. Manually messing with the contents of that file before upgrading again didn't seem to have any adverse effects.
lsb_release
is a Python script that simply reads from the file /etc/lsb-release
and dumps output to the screen. You can edit the file using:
sudo -H gedit /etc/lsb-release
Then change the contents to suit your platform. Mine contains:
$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=16.04
DISTRIB_CODENAME=xenial
DISTRIB_DESCRIPTION="Ubuntu 16.04.5 LTS"
No comments:
Post a Comment