NOTE: THIS FUNCTIONALITY IS NOW BUILT-IN TO UBUNTU STUDIO CONTROLS. THIS GUIDE IS SCHEDULED FOR DELETION AFTER THE END-OF-LIFE OF UBUNTU STUDIO 16.04 IN APRIL 2019.

For some uses, the standard CPU governor Ondemand or Powersave will cause problems. For example low latency audio below about 10ms (which is required to use effects live or live softsynths) requires the CPU speed to remain constant.

Ubuntu comes with a startup script that sets the CPU governor to Ondemand or Powersave if Ondemand is not available. But it does so 60 seconds after startup. This makes merely setting the governor to Performance at boot time seem to not work. So the first thing to do is to turn that action off. This is done from a terminal command line with:

sudo /usr/sbin/update-rc.d ondemand disable

Next we have to actually set the CPU governor to Performance. First make sure the package cpufrequtils is installed:

sudo apt install cpufrequtils

Then we create a file in /etc/default/

echo 'GOVERNOR="performance"' | sudo tee /etc/default/cpufrequtils

Done, now the next time the machine is booted, the machine will be in performance mode. If you wish to switch to performance mode without rebooting use:

sudo /etc/init.d/cpufrequtils restart

Notes:

  • Running in Performance mode will possibly use more power and reduce time between charges on a laptop.
  • A later Intel CPU with "Boost" turned on will still change CPU speed. Most BIOS allow turning Boost off.
  • Ondemand/Powersave can be turned back on at boot with

sudo /usr/sbin/update-rc.d ondemand enable
  • Ondemand/Powersave can be turned back on while running (with a 60 second delay) with

sudo /etc/init.d/ondemand start

UbuntuStudio/Setting_CPU_Governor (last edited 2019-03-15 21:19:37 by eeickmeyer)