/etc/init.d/ondemand unconditionally overrules /etc/init.d/cpufrequtils

Bug #911206 reported by Daniel on 2012-01-03
74
This bug affects 14 people
Affects Status Importance Assigned to Milestone
cpufrequtils (Ubuntu)
Undecided
Unassigned
sysvinit (Ubuntu)
High
Unassigned

Bug Description

/etc/init.d/ondemand *always* sets the cpu scaling governor to ondemand, and is executed after /etc/init.d/cpufrequtils.

This causes two problems:
1. Confusion, because it seems as if /etc/init.d/cpufrequtils is being run, but has no effect
2. Possible problems down the road, because /etc/init.d/ondemand has no /etc/default/ondemand, so either editing or deleting
  /etc/init.d/ondemand. I just discovered that updating initscripts will fail if /etc/init.d/ondemand has been deleted (dpkg complains about this file missing and aborts)

Suggested fixes:

a) Remove /etc/init.d/ondemand, make the ondemand governor the default for /etc/init.d/cpufrequtils, install package cpufrequtils by default.

b) If this is not desired, make absolutely sure that /etc/init.d/ondemand is executed *before* /etc/init.d/cpufrequtils, maybe by making /etc/init.d/cpufrequtils depend on /etc/init.d/ondemand.

I'm looking forward to your responses,
Daniel

ProblemType: Bug
DistroRelease: Ubuntu 11.10
Package: initscripts 2.88dsf-13.10ubuntu4.1
ProcVersionSignature: Ubuntu 3.0.0-14.23-generic 3.0.9
Uname: Linux 3.0.0-14-generic x86_64
NonfreeKernelModules: nvidia
ApportVersion: 1.23-0ubuntu4
Architecture: amd64
Date: Tue Jan 3 13:13:59 2012
InstallationMedia: Ubuntu 11.10 "Oneiric Ocelot" - Release amd64 (20111012)
ProcEnviron:
 PATH=(custom, user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: sysvinit
UpgradeStatus: Upgraded to oneiric on 2011-12-10 (23 days ago)
modified.conffile..etc.init.d.ondemand: [modified]
mtime.conffile..etc.init.d.ondemand: 2012-01-03T13:13:33.783902

Daniel (skorka-b) wrote :
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in sysvinit (Ubuntu):
status: New → Confirmed
Daniel Hahler (blueyed) on 2015-09-18
Changed in sysvinit (Ubuntu):
status: Confirmed → Triaged
importance: Undecided → High
Changed in cpufrequtils (Ubuntu):
status: New → Confirmed
Sergio Callegari (callegar) wrote :

There is another issue:

/etc/init.d/ondemand tries to set the governor to ondemand unconditionally, even on intel systems with p-state.

Systems with the p-state frequency scaling do not have an ondemand governor at all. This means that the /etc/init.d/ondemand falls back to the powersave governor, hindering performance.

Alltogether, the /etc/init.d/ondemand looks hackish. Its operation relies on assumptions on the system setup that are just plain wrong:

1) That one does not install the cpufreq utils
since, as mentioned in the original bug report, it destroys the work of /etc/init.d/cpufrequtils

2) That one is on the acpi cpu frequency driver
since it is hardwired with the governors provided by such driver.

I strongly recommend getting rid of /etc/init.d/ondemand

Sergio Callegari (callegar) wrote :

I am just realizing that this other problem is already listed as bug 1480320

Greg Mason (gmason) wrote :

This also led to the problem in bug 1579278

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers