RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 616976 - cpuspeed does not reset MIN/MAX values when config file is emptied
Summary: cpuspeed does not reset MIN/MAX values when config file is emptied
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: cpuspeed
Version: 6.0
Hardware: All
OS: Linux
low
medium
Target Milestone: beta
: ---
Assignee: Petr Šabata
QA Contact: John Brier
URL:
Whiteboard:
Depends On:
Blocks: 767187 836169
TreeView+ depends on / blocked
 
Reported: 2010-07-21 20:58 UTC by François Cami
Modified: 2013-08-14 23:05 UTC (History)
5 users (show)

Fixed In Version: cpuspeed-1.5-17.el6
Doc Type: Bug Fix
Doc Text:
Cause: The cpuspeed does not reset MIN/MAX values, when config file is emptied. Consequence: The MIN_SPEED or MAX_SPEED values weren't reset properly. Fix: Conditionals in init script were added to check these values. Result: The MIN_SPEED or MAX_SPEED values are reset properly.
Clone Of: 616507
Environment:
Last Closed: 2012-10-25 13:10:40 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
patch for /etc/init.d/cpuspeed (566 bytes, patch)
2010-07-21 20:58 UTC, François Cami
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:1404 0 normal SHIPPED_LIVE cpuspeed bug fix update 2012-10-25 17:08:38 UTC

Description François Cami 2010-07-21 20:58:01 UTC
+++ This bug was initially created as a clone of Bug #616507 +++

Created an attachment (id=433207)
patch for /etc/init.d/cpuspeed

Description of problem:
When MIN_SPEED (resp. MAX_SPEED) is set in /etc/sysconfig/cpuspeed, and then removed, /etc/init.d/cpuspeed does not reset the value to the CPU minimum (resp. maximum) frequency.

Version-Release number of selected component (if applicable):
cpuspeed-1.5-13.fc13.x86_64

How reproducible:
Always

Steps to Reproduce:
0. check CPU frequency using cat /proc/cpuinfo
1. Set MIN_SPEED in /etc/sysconfig/cpuspeed to a suitable value superior to the CPU's minimum frequency
2. restart cpuspeed
3. Unset MIN_SPEED (restore configuration file)
4. restart cpuspeed
5. check CPU frequency using cat /proc/cpuinfo
  
Actual results:
CPU frequency in step 5 is equal to the MIN_SPEED set at step 1.

Expected results:
CPU frequency in steps 0 and 5 are identical.

Additional info:
This is because the cpuspeed script does not reset the values when the {MIN_SPEED,MAX_SPEED} variables are empty. A (crude) patch to do that is attached.

--- Additional comment from updates on 2010-07-21 08:11:29 EDT ---

cpuspeed-1.5-14.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/cpuspeed-1.5-14.fc13

--- Additional comment from psabata on 2010-07-21 08:18:13 EDT ---

Thank you for the patch.
This should now be fixed in 1:1.5-14 in both Fedora 13 and Rawhide.

Comment 1 François Cami 2010-07-21 20:58:56 UTC
Created attachment 433500 [details]
patch for /etc/init.d/cpuspeed

Comment 3 RHEL Program Management 2010-07-21 21:18:17 UTC
This issue has been proposed when we are only considering blocker
issues in the current Red Hat Enterprise Linux release.

** If you would still like this issue considered for the current
release, ask your support representative to file as a blocker on
your behalf. Otherwise ask that it be considered for the next
Red Hat Enterprise Linux release. **

Comment 4 RHEL Program Management 2011-01-07 15:35:42 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated
in the current release, Red Hat is unfortunately unable to
address this request at this time. 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. If you would like it considered as an
exception in the current release, please ask your support
representative.

Comment 13 John Brier 2012-10-02 19:00:41 UTC
fyi, reproduced only while using ondemand, could not reproduce with userspace governor:

[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# grep MHz /proc/cpuinfo 
cpu MHz		: 1400.000
cpu MHz		: 1400.000
cpu MHz		: 1400.000
cpu MHz		: 1400.000

[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_frequencies 
3700000 3300000 2900000 2400000 1900000 1400000 
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# vim /etc/sysconfig/cpuspeed 
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# service cpuspeed restart
Disabling ondemand cpu frequency scaling:                  [  OK  ]
Enabling ondemand cpu frequency scaling:                   [  OK  ]
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# tail /var/log/messages
<snip unrelated messages>
Oct  2 13:02:50 server cpuspeed: Enabling userspace cpu frequency scaling governor
Oct  2 13:03:20 server cpuspeed: Enabling userspace cpu frequency scaling governor
Oct  2 14:43:06 server cpuspeed: Enabling ondemand cpu frequency scaling governor
Oct  2 14:43:06 server kernel: CPUFREQ: Per core ondemand sysfs interface is deprecated - ignore_nice_load
Oct  2 14:49:21 server cpuspeed: Disabling ondemand cpu frequency scaling governor
Oct  2 14:49:21 server cpuspeed: Enabling ondemand cpu frequency scaling governor
Oct  2 14:49:21 server kernel: CPUFREQ: Per core ondemand sysfs interface is deprecated - ignore_nice_load


[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# grep MHz /proc/cpuinfo 
cpu MHz		: 1900.000
cpu MHz		: 1900.000
cpu MHz		: 1900.000
cpu MHz		: 1900.000
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# vim /etc/sysconfig/cpuspeed 
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# service cpuspeed restart
Disabling ondemand cpu frequency scaling:                  [  OK  ]
Enabling ondemand cpu frequency scaling:                   [  OK  ]
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# vim /etc/sysconfig/cpuspeed 
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# !grep
grep MHz /proc/cpuinfo 
cpu MHz		: 1900.000
cpu MHz		: 1900.000
cpu MHz		: 1900.000
cpu MHz		: 1900.000
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# rpm -q cpuspeed
cpuspeed-1.5-15.el6.x86_64
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# grep _SPEED /etc/sysconfig/cpuspeed 
MAX_SPEED=
MIN_SPEED=
[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# 

VERIFIED:

[root@server cpuspeed-1.5-17.el6.x86_64.rpm-dir]# cd
[root@server ~]# rpm -Uvh cpuspeed-1.5-17.el6.x86_64.rpm
Preparing...                ########################################### [100%]
   1:cpuspeed               ########################################### [100%]
[root@server ~]# vim /etc/sysconfig/cpuspeed 
[root@server ~]# !grep
grep _SPEED /etc/sysconfig/cpuspeed 
MAX_SPEED=
MIN_SPEED=
[root@server ~]# grep MHz /proc/cpuinfo 
cpu MHz		: 1900.000
cpu MHz		: 1900.000
cpu MHz		: 1900.000
cpu MHz		: 1900.000
[root@server ~]# service cpuspeed restart
Disabling ondemand cpu frequency scaling:                  [  OK  ]
Enabling ondemand cpu frequency scaling:                   [  OK  ]
[root@server ~]# grep MHz /proc/cpuinfo 
cpu MHz		: 1400.000
cpu MHz		: 1400.000
cpu MHz		: 1400.000
cpu MHz		: 1400.000
[root@server ~]#

Comment 16 errata-xmlrpc 2012-10-25 13:10:40 UTC
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-1404.html


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