Hosting4life > Blog > How To > Upgrading VPS from Ubuntu 14.04 LTS to 16.04 LTS

Upgrading VPS from Ubuntu 14.04 LTS to 16.04 LTS

If your VPS is running Ubuntu 14.04 LTS you might want to upgrade to the latest LTS release but you shouldn’t feel rushed to it because 14.04 will be supported until 2019. If you still feel you’d like to upgrade this guide will show you the steps to do it. This guide is focused on upgrading one of our VPS plans but most of the steps applies to any system running Ubuntu 14.04 LTS. Note that Ubuntu 16.04 only has PHP7.0 available officially so if you still need to run PHP5 then after the upgrade you’ll need to install it from a PPA. Also if you’ve installed anything from a third party such as Java, MariaDB, Nginx etc. you’ll need to upgrade them manually.

1) Backup your data

Before any major change it’s always good idea to backup your data. If you run one of our VPS one is automatically made for you every night but it’s still good idea to make sure there is a fresh full backup available so start your backup with /opt/tartarus/ You can also request from support for us to take a snapshot of the system so it’s easy to revert back to the same state as before upgrade if something goes wrong.

2) Make sure your system is up to date

Always before making upgrade you need to update your system to latest available version on the release.

apt-get update
apt-get upgrade

If you encounter any issues during the upgrade resolve them before continuing otherwise the release upgrade will also fail.

3) Prepare for release upgrade

Since you’ll be doing the upgrade through SSH connection there is a change it may be cut if something goes wrong. That is why the release upgrade process opens an additional sshd on port 1022. In order to use that you need to allow connection to that port which is by default blocked on the Shorewall firewall. To unblock it insert following rule to both /etc/shorewall/rules and /etc/shorewall6/rules

ACCEPT  net  $FW tcp 1022

One you’ve inserted it restart shorewall for both IPv4 and IPv6

shorewall restart
shorewall6 restart

4) Do release upgrade

Now you should be ready to do the actual upgrade.

apt-get install update-manager-core

During the release upgrade it asks you to if you want to install new version of a configuration file from the maintainer you should answer NO to those question in most cases. Once the release upgrade has processed you are asked to restart. After the restart you need to make sure that you upgrade all the third party entries in /etc/apt/sources.list and /etc/apt/sources.list.d

Leave a Reply

Your email address will not be published. Required fields are marked *