Is there a way to disable Intel SpeedStep steppings on an Ubuntu Server using a command line application?
The Ubuntu kernel is shipped with CPU controlling governors, normally set to ondemand
they will regulate the performance of your CPU in your Ubuntu system.
You can change the CPU performance setting in Ubuntu per logical CPU.
Start by reading the current available settings for your system:
sudo cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
this will return a list of available settings you can use to regulate each core of your CPU, if you can you should then set them to max performance by selecting the performance
option. This will make your CPU cores run always at max frequency.
Knowing what options you have and if the performance
option is available, you can then set each core to performance
mode with the command:
sudo echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
this will make cpu0 (first core) run all the time at max performance. Do it for all the logical cores in your CPU.
You can then check if the option was successfully changed with the command:
sudo cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
this will check the current set option for cpu0 (first core). Check if the change was successful for all cores and if everything was set correctly you are good to go: Intel SpeedStep will be on but all your cores will be running at max frequency speed all the time.
You can then check and get information about the actual frequency using cpufreq-info
from the package cpufrequtils
in the universe repository, it will report per core the actual speed and a lot of other information including the set governor, but you need to install it first using the command sudo apt-get install cpufrequtils
.
cpufreq-info
cpufrequtils 007: cpufreq-info (C) Dominik Brodowski 2004-2009
Report errors and bugs to [email protected], please.
analyzing CPU 0:
driver: powernow-k8
CPUs which run at the same hardware frequency: 0
CPUs which need to have their frequency coordinated by software: 0
maximum transition latency: 8.0 us.
hardware limits: 800 MHz - 3.00 GHz
available frequency steps: 3.00 GHz, 2.30 GHz, 1.80 GHz, 800 MHz
available cpufreq governors: conservative, ondemand, userspace, powersave, performance
current policy: frequency should be within 800 MHz and 3.00 GHz.
The governor "ondemand" may decide which speed to use
within this range.
current CPU frequency is 800 MHz.
cpufreq stats: 3.00 GHz:10.45%, 2.30 GHz:0.29%, 1.80 GHz:1.72%, 800 MHz:87.55% (28605)
Related videos on Youtube
Michael Goldshteyn
I compute, therefore I am. If this does not compute, you are ∅ inside. Any programming code, guidance, or explanation that I personally contributed to StackOverflow is covered by the least restrictive license of them all - the WTFPL. For a TL;DR explanation, see this humorous comic strip.
Updated on September 18, 2022Comments
-
Michael Goldshteyn over 1 year
We cannot disable it using the BIOS, because Turbo gets turned off as well as a side effect (what a crappy BIOS!). I am looking for a simple command line tool for Ubuntu 12.04 LTS Server that can do this.
I know on Windows, if you set the Power Options to High Performance, SpeedStep is disabled, but how can I do this on Ubuntu Linux using a command line application?
-
inckka over 2 years
sudo sh -c "echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor"
worked for me as otherwise it was giving a permission error.