What is yum-cron ?

What is yum-cron ?

Solution Verified - Updated -

Environment

  • Red Hat Enterprise Linux Server 6.x
  • Red Hat Enterprise Linux Server 7.x

Issue

  • The yum-cron package provides a convenient way to check for, download and apply updates automatically.
  • The cron jobs from the yum-cron package are active immediately after installing the package and there’s no extra configuration necessary. The job will be run when daily cron jobs are set to run.

Resolution

  • To install yum-cron package
# yum -y install yum-cron
# chkconfig yum-cron on
  • Then edit /etc/sysconfig/yum-cron (RHEL 6) to set MAILTO= email address or /etc/yum/yum-cron.conf (RHEL 7) to set email_to= for email notifications.

    • For RHEL 6
MAILTO=sys@example.com
  • For RHEL 7
email_to=sys@example.com
  • To exclude packages using yum-cron:-
  • For RHEL 6
YUM_PARAMETER=kernel* mysql*
  • For RHEL 7 edit below option in the base section of /etc/yum/yum-cron.conf file.
[base]
exclude=kernel* mysql*
  • For RHEL 7 use following option in yum-cron configuration file to install security updates.
[commands]
#  What kind of update to use:
# default                            = yum upgrade
# security                           = yum --security upgrade
# security-severity:Critical         = yum --sec-severity=Critical upgrade
# minimal                            = yum --bugfix upgrade-minimal
# minimal-security                   = yum --security upgrade-minimal
# minimal-security-severity:Critical =  --sec-severity=Critical upgrade-minimal
update_cmd = security
  • To start yum-cron service after editing configuration file.

  • For RHEL 6

# service yum-cron start
  • For RHEL 7
# systemctl start yum-cron
  • Component
  • yum
0 (0)
Article Rating (No Votes)
Rate this article
Attachments
There are no attachments for this article.
Comments
There are no comments for this article. Be the first to post a comment.
Full Name
Email Address
Security Code Security Code
Related Articles RSS Feed
Tunnel SSH Connections Over SSL Using ‘Stunnel’ On Debian 7 / Ubuntu 13.10
Viewed 928 times since Fri, Sep 28, 2018
An easier way to manage disk decryption at boot with Red Hat Enterprise Linux 7.5 using NBDE
Viewed 2834 times since Mon, Aug 6, 2018
LVM basic
Viewed 975 times since Sat, Jun 2, 2018
Top 4 Reasons for Node Reboot or Node Eviction in Real Application Cluster (RAC) Environment
Viewed 10784 times since Thu, Jun 21, 2018
How to disable SSH cipher/ MAC algorithms for Linux and Unix
Viewed 3058 times since Fri, Aug 21, 2020
Tip: SSD and Linux. Enable TRIM and check if it works
Viewed 1009 times since Fri, May 15, 2020
How to retrieve and change partition’s UUID Universally Unique Identifier on linux
Viewed 798 times since Tue, Jul 17, 2018
RHEL: Manually encrypting a filesystem with LUKS
Viewed 1375 times since Sun, May 27, 2018
RHCS6: ’fencing’ basics
Viewed 976 times since Sun, Jun 3, 2018
Setup SSL Tunnel Using Stunnel on Ubuntu
Viewed 649 times since Fri, Sep 28, 2018