How do I update Ubuntu using terminal command line

To update your Ubuntu system using the terminal command line, follow these steps:

  1. Open a terminal window.
  2. Update the package index:
sudo apt update
  1. Upgrade all installed packages to the latest available version:
sudo apt upgrade
  1. After the upgrade process is completed, you can use the apt list --upgradable command to verify that all upgrades have been installed successfully.

Note: The apt-get command is being deprecated and is gradually being replaced by apt, but it still works in Ubuntu.

If you also want to upgrade packages that may have a new version of dependencies, use the following command:

sudo apt dist-upgrade

After the upgrade is complete, it is a good idea to reboot the system to ensure that all the updates have been applied correctly.

Leave a Comment