How To: Upgrade WSL Ubuntu 18.04 to 18.10

After reading that Ubuntu 19.04 has been release it got me thinking “can WSL Ubuntu be upgraded?”. TL;DR: Yes: BUT. I am no Linux expert nor do I understand the inner workings of Linux. I am very much a user in most cases. Consider this upgrade an experiment at best, a disaster at worse.

The Commands

The actual upgrade process is, surprisingly, un-changed from the typical Ubuntu upgrade. As a series of 4 commands, waiting, re-starting when the snapd Retry/Abort option appears, one last command, and finally a confirmation lsb_release -a.

sudo su
apt update -y
apt upgrade -y
apt dist-upgrade
# now wait...
# When the 'snapd could not reach the snap store' error appears. Close the WSL window, then start a new session.
apt-get autoremove
lsb_release -a
Sometimes things really are _that_ easy.

But… the snapd (systemd) issue

WSL does not support a LOT of Linux system services. Infact, WSL does not support system service from my understanding. This creates problems for things like dbus, snapd, and many others. Thankfully it appears that the core Ubuntu processes do not require it. So, the upgrade from 18.04 to 18.10 seems to not have any adverse effect on the stability or usability of WSL Ubuntu. Though, like anything experimental, YMMV

If you found this helpful, have a neat tip, or would like to chat about computing; drop a comment below. I’d love to hear about your experience.

Resources