CentOS / RHEL 6 : How to list or install only security updates with yum
Question: Is it possible to limit yum so that it lists or installs only security updates? How to patch the system only with security errata ?
Answer :
Install the yum-security plugin
It is now possible to limit yum to install only security updates (as opposed to bug fixes or enhancements) by installing the yum-security plugin. Contrary to RHEL 7, in RHEL 6 the yum-security plugin is not part of yum. So to install the plugin use :# yum install yum-plugin-security
listing available erratas
To list all available erratas without installing them, run:# yum updateinfo list available
Listing available security updates
To list all available security updates without installing them, run:# yum updateinfo list security all # yum updateinfo list sec
# yum info-sec
Listing currently installed security updates
To get a list of the currently installed security updates this command can be used:# yum updateinfo list security installed
Installing available security updates
Run the following command to download and apply all available security updates :# yum -y update --security
NOTE: It will install the last version available of any package with at least one security errata thus can install non-security erratas if they provide a more updated version of the package.
To only install the packages that have a security errata use# yum update-minimal --security -y
# man yum-security
No comments:
Post a Comment