How to update security patches in Linux using the CLI

How to update security patches in Linux using the CLI

To update security patches in Linux using the command-line interface (CLI), you can use the following steps:

  1. Connect to your Linux system using ssh or another terminal emulator.

  2. Run the following command to update the package lists:

refer to‮iruttual:‬.com
apt update

This will update the list of available packages and their versions from the package repositories.

  1. Run the following command to upgrade all installed packages to the latest version:
apt upgrade

This will upgrade all the packages on your system to the latest version available in the package repositories, including security patches.

If you want to install only security patches, you can use the apt-get dist-upgrade command.

For example, to install security patches only, you can use the following command:

apt-get dist-upgrade --only-upgrade

Note that you may need to reboot the system for the security patches to take effect.

It's recommended to keep your system up to date with the latest security patches to protect against vulnerabilities and exploits. It's also a good idea to set up automatic updates to ensure that your system stays up to date.

Created Time:2017-10-29 22:08:39  Author:lautturi