Through “Scaling Governor”, you can choose the optimal CPU frequency control scheme, which affects power consumption and performance.
On highly loaded access servers, acquaintances had cases of server hangup during “ondemand”, although I did not have such cases, but still I recommend changing it to “performance”.
On laptops and lightly loaded servers, you can leave “ondemand” to save energy.
Let’s see the current value of all processor cores:
cat /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor ls /sys/devices/system/cpu/
In my case, the default value for all eight cores is “ondemand”.
Let’s look at possible schemes:
Switch to root user:
And we indicate for all kernels “performance”:
echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor echo performance > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor echo performance > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor echo performance > /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor echo performance > /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor echo performance > /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor echo performance > /sys/devices/system/cpu/cpu6/cpufreq/scaling_governor echo performance > /sys/devices/system/cpu/cpu7/cpufreq/scaling_governor
cat /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor egrep '(MHz)' /proc/cpuinfo
See also my article:
Changing the processor core frequency in Linux