CSUF LogoCSUF Site Navigation
optics.csufresno.edu

F14 Laptop & General Settings cpuspeed

Department of Electrical and Computer Engineering
Associate Professor Gregory R. Kriehn
Forums
Wiki
F14 cpuspeed

cpuspeed enables you to dynamically change the CPU speed of a processor through the ACPI daemon. I find it useful only for my laptop, and only when I do not have AC power. The default configuration is very annoying, which monitors the system's idle percentage and reduces or raises the CPU's clock speed and voltage accordingly to minimize power consumption when idle (theoretically). The configuration file is now located in /etc/sysconfig/cpuspeed. Edit the file using sudo:
~> sudo nano /etc/sysconfig/cpuspeed
Perform a search for the "GOVERNOR=" line. Add the following:
GOVERNOR=performance
Next scroll down to the "# Add your favorite options here" line and make sure that the line just below it is commented out. This will remove the "-r" option (restores previous speed on program exit), which will allow the system to be governed by load, AC power, and temperature management only. To do this, add the following:
OPTS="$OPTS -i 2 -C"
The "-i 2" option changes the default response time to 2/10's of a second from 2 seconds and the "-C" option will ensure that the CPU runs at maximum speed when AC power is connected and only at lower speeds if on battery power or if the temperature of the processor is too high. Finally, uncomment the last two "OPTS" lines to allow cpuspeed to actually check the state of the AC adapter and system temperature:
OPTS="$OPTS -a /proc/acpi/ac_adapter/*/state"
OPTS="$OPTS -t /proc/acpi/thermal_zone/*/temperature 75"
Save and exit. Now restart the daemon:
~> sudo service cpuspeed restart
You should see cpuspeed stop and restart:
Disabling performance cpu frequency scaling:               [  OK  ]
Enabling performance cpu frequency scaling:                [  OK  ]
As a final note, cpuspeed finally has a man page. Use it to determine the different options for the daemon.