Updating Linux Mint via the Terminal

Linux Mint gives you the option to click the shield icon to launch Mint Update Manager, in order to update the system and upgrade the currently installed apps, tools and other elements. However, if you want to get to grips with Linux properly, using the Terminal as much as possible is important, so lets take a look at updating Mint using command lines.

Using Apt-get

To update and upgrade via the Terminal you use the APT (Advanced Packaging Tool) command. It’s a powerful command and combines different elements depending on its use.

Start by opening a new Terminal or if you already have one opened clear its contents with the clear command. This starts you off with a clean slate on which to work.

Enter: apt-get into the Terminal. This brings up a list of the most used apt-get commands, along with a brief description of what the command does. It’s worth having a look at, even if it doesn’t make a huge amount of sense at this time.

Apt-get is used to update and upgrade the software in Mint, as well as Ubuntu and other Debian-based distros. Using the Update element retrieves new package lists and updates the list of source files. Upgrade downloads and performs an upgrade to the latest versions of those files. To start the entire Upgrade and Update process, enter: sudo apt-get update, followed by your password.

Notice now the addition of the sudo command. The sudo command once meant Super User Do; these days it’s more acceptable as Substitute User Do. It means that the administrative user (Super User) uses APT (Advanced Packaging Tool) to Get any Updates. Now try this: sudo apt-get upgrade.

Depending on the state of your updates, if you have any waiting to be installed, you might be asked if you want to apply the results of the sudo apt-get upgrade command. You can press y to accept and continue. What’s happening here is that apt-get has some updated software to apply to Mint, and you’re okaying the action.

There’s likely to be a long list of what seems gibberish now filling your Terminal window but don’t worry. The files necessary for the upgrade have been downloaded, prepared, unpacked, processed, installed and set up correctly. There’s a lot going on when you perform an upgrade, even with the smallest package.

Essentially, that’s it, your system is now up to date according to the available list of packages from the apt-get update command. You can run through the process one more time, just to check if everything went okay. To recap, enter: sudo apt-get update, press Enter, then type: sudo apt-get upgrade and press Enter.

Interestingly, Linux Mint, among other distros, offers you the ability to chain several commands together. In this example, therefore, we can use sudo apt-get update && sudo apt-get upgrade. The double ampersand is what combines the commands and works perfectly, providing the preceding command went without a hitch. It’s recommended to start any session with the update and upgrade combo.

Terminal Vs Update Manager?

Why use the Terminal to update and upgrade over the Update Manager, regardless of the distro you’re using? Some users greatly prefer using the Terminal to update their Linux systems and accompanying apps, in the belief that it’s better. However, that’s not often the case. Using the Terminal, apt-get upgrade, doesn’t handle changing dependencies between versions of packages, so if a package has its dependent files changed from one version to another, then the upgrade is held back.

The Update Manager, or Software Manager (depending on the distro), often phases its updates and marks those packages with changed dependencies for updating. However, and this is where Linux can often get confusing, sometimes it doesn’t.

It all boils down to the developer of the package being updated and the way the package is held in the distro’s repositories and whether the update is classified as stable or not. In essence, from the point of view of the user, if you update and upgrade using both the Terminal and the Update Manager regularly, then you will be as up to date as possible, and get the essential and necessary stable versions of the packages and core software. If you’re looking for cutting edge package updates, then it’s best to opt for a rolling release distro instead.

David Hayward

David has spent most of his life tinkering with technology, from the ZX Spectrum, getting his hands on a Fujitsu VPP5000/100 supercomputer, and coding on an overheating Raspberry Pi. He's written for the likes of Micro Mart, Den of Geek, and countless retro sites and publications, covering reviews, creating code and bench testing the latest tech. He also has a huge collection of cables.

Related Articles

Back to top button