Bug 742363 - yum-cron runs at nice 10 (from anacrontab), restarted service inherit that priority
yum-cron runs at nice 10 (from anacrontab), restarted service inherit that pr...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: yum (Show other bugs)
6.1
All Linux
urgent Severity high
: rc
: ---
Assigned To: James Antill
BaseOS QE Security Team
: ZStream
Depends On:
Blocks: 795455
  Show dependency treegraph
 
Reported: 2011-09-29 16:29 EDT by Orion Poplawski
Modified: 2014-01-21 01:24 EST (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
The anacron scheduler starts the yum-cron utility with the "nice" value of 10. This caused Yum's RPM transactions to run at very low priority level. Also, any updated service inherited this "nice" value, which influenced the system behavior. This update adds the "reset_nice" configuration option, which allows Yum to reset the "nice" value to 0 before running an RPM transaction. With this option set, Yum's RPM transactions run at normal priority level so that updated services are restarted with normal priority as expected.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-06-20 09:53:47 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Orion Poplawski 2011-09-29 16:29:01 EDT
Description of problem:

yum-cron runs at nice 10 (from anacrontab), restarted service inherit that priority.

Adding:

# Reset our priority so restarted services don't inherit the lower priority
# from cron
renice 0 $$

To the 0yum.cron script should fix.

Version-Release number of selected component (if applicable):
yum-cron-3.2.29-17.el6.noarch
Comment 2 Orion Poplawski 2011-09-29 21:45:16 EDT
Looks like you would want:

renice 0 $$ > /dev/null

to avoid the output from renice.
Comment 3 RHEL Product and Program Management 2011-10-07 12:20:36 EDT
Since RHEL 6.2 External Beta has begun, and this bug remains
unresolved, it has been rejected as it is not proposed as
exception or blocker.

Red Hat invites you to ask your support representative to
propose this request, if appropriate and relevant, in the
next release of Red Hat Enterprise Linux.
Comment 4 Mike Lococo 2011-10-07 17:08:45 EDT
yum-updatesd suffers from the same issue (at nice +19 instead of nice +10), see Bug 552279 for details and a workaround.

packagekit-cron is probably the last option for doing automatic updates on a
standalone RHEL6 system.  I haven't tested it to see whether it suffers from a
similar bug, but it's a more ambitious framework than either yum-updatesd or
yum-cron so it might address the issue.

Alternately one would have to look at satellite or spacewalk, which are pretty
heavyweight solutions generally targeted toward large shops.
Comment 12 Miroslav Svoboda 2012-02-27 05:08:50 EST
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
The anacron scheduler starts the yum-cron utility with the "nice" value of 10. This caused Yum's RPM transactions to run at very low priority level. Also, any updated service inherited this "nice" value, which influenced the system behavior. This update adds the "reset_nice" configuration option, which allows Yum to reset the "nice" value to 0 before running an RPM transaction. With this option set, Yum's RPM transactions run at normal priority level so that updated services are restarted with normal priority as expected.
Comment 16 errata-xmlrpc 2012-06-20 09:53:47 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2012-0857.html

Note You need to log in before you can comment on or make changes to this bug.