Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
CPU Governor set to power save not performance Ubuntu studio 22.04
#1
Hi All
If I forget to change this after boot from power save MB has a hissy fit.

Is there a way to set performance as default? Looking at some old posts lots of editing config files
places I would rather not ry if possible.

I'm sure I could set this once in 20.04 and it stayed on performance.

Any ideas?
Cheers All
Linux for years!
Ubuntu studio 24.04 LTS  Mixbus 32C  V9
Dell Precision  T3600  8 core 64gb ram.
Reply
#2
(04-30-2022, 02:34 PM)wavesound Wrote: Hi All
If I forget to change this after boot from power save MB has a hissy fit.

Is there a way to set performance as default? Looking at some old posts lots of editing config files
places I would rather not ry if possible.

I'm sure I could set this once in 20.04 and it stayed on performance.

Any ideas?
Cheers All

Try
Code:
sudo systemctl disable ondemand
once.

If you don't like it to be full on all time anymore you simply re-enable it.

MMM
Linux throughout!
Main PC: XEON, 64GB DDR4, 1x SATA SSD, 1x NVME, MOTU UltraLite AVB
OS: Debian11 with KX atm

Mixbus 32C, Hydrogen, Jack... and Behringer synths
Reply
#3
(04-30-2022, 09:51 PM)madmaxmiller Wrote:
(04-30-2022, 02:34 PM)wavesound Wrote: Hi All
If I forget to change this after boot from power save MB has a hissy fit.

Is there a way to set performance as default? Looking at some old posts lots of editing config files
places I would rather not ry if possible.

I'm sure I could set this once in 20.04 and it stayed on performance.

Any ideas?
Cheers All

Try
Code:
sudo systemctl disable ondemand
once.

If you don't like it to be full on all time anymore you simply re-enable it.

MMM

Hi Thanks for the reply I got this:

[sudo] password for studio:  
Failed to disable unit: Unit file ondemand.service does not exist.



cheers
Linux for years!
Ubuntu studio 24.04 LTS  Mixbus 32C  V9
Dell Precision  T3600  8 core 64gb ram.
Reply
#4
(05-08-2022, 03:35 PM)wavesound Wrote:
(04-30-2022, 09:51 PM)madmaxmiller Wrote:
(04-30-2022, 02:34 PM)wavesound Wrote: Hi All
If I forget to change this after boot from power save MB has a hissy fit.

Is there a way to set performance as default? Looking at some old posts lots of editing config files
places I would rather not ry if possible.

I'm sure I could set this once in 20.04 and it stayed on performance.

Any ideas?
Cheers All

Try
Code:
sudo systemctl disable ondemand
once.

If you don't like it to be full on all time anymore you simply re-enable it.

MMM

Hi Thanks for the reply I got this:

[sudo] password for studio:  
Failed to disable unit: Unit file ondemand.service does not exist.



cheers

Fantastic! That means that that service which sets your CPU ondemand is not installed.
Here's a clunky but simple method with minimal scripting:
Code:
sudo su
nano /etc/rc.local

*** Add the lines: ***

echo "performance" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "performance" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
...
...

(adjust for your number of physical cores)
You can also make that into little scripts which you can run as root, one with "powersave" or "ondemand" and one with "performance"

HTH
MMM
Linux throughout!
Main PC: XEON, 64GB DDR4, 1x SATA SSD, 1x NVME, MOTU UltraLite AVB
OS: Debian11 with KX atm

Mixbus 32C, Hydrogen, Jack... and Behringer synths
Reply
#5
(05-09-2022, 05:59 AM)madmaxmiller Wrote:
(05-08-2022, 03:35 PM)wavesound Wrote:
(04-30-2022, 09:51 PM)madmaxmiller Wrote:
(04-30-2022, 02:34 PM)wavesound Wrote: Hi All
If I forget to change this after boot from power save MB has a hissy fit.

Is there a way to set performance as default? Looking at some old posts lots of editing config files
places I would rather not ry if possible.

I'm sure I could set this once in 20.04 and it stayed on performance.

Any ideas?
Cheers All

Try
Code:
sudo systemctl disable ondemand
once.

If you don't like it to be full on all time anymore you simply re-enable it.

MMM

Hi Thanks for the reply I got this:

[sudo] password for studio:  
Failed to disable unit: Unit file ondemand.service does not exist.



cheers

Fantastic! That means that that service which sets your CPU ondemand is not installed.
Here's a clunky but simple method with minimal scripting:
Code:
sudo su
nano /etc/rc.local

*** Add the lines: ***

echo "performance" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "performance" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
...
...

(adjust for your number of physical cores)
You can also make that into little scripts which you can run as root, one with "powersave" or "ondemand" and one with "performance"

HTH
MMM

Yup, something simple as making an executable script along this example:


Code:
cat /usr/local/bin/SCALE_GOV
echo "$1" | tee /sys/devices/system/cpu/cpu*//cpufreq/scaling_governor &>/dev/null
 and then calling it with:
SCALE_GOV powersave
or
SCALE_GOV performance
Mixbus/32C 5.3.22, 6.2.407, 7.2.0, 8.2.184, 9.2.105, 10.0.0 on Manjaro midtower i5-6600K 3.5GHz and Lenovo X250 i5
Mixbus 5.3.22, 6.2.407 on Win10x64/Lenovo T40 i7 and X250 i5
audiocards: Scarlett 2i4, Tascam US4x4HR
Reply
#6
There's a neat utility called cpupower-gui if you want a graphical way to change scaling governor. I prefer to change it back to ondemand when not doing audio production, to save power and run cooler.
Mixbus 32C, Debian Bookworm/KDE, EVE SC205 + ADAM Sub 8 monitors, Soundcraft Compact 4, M-Audio 2496, i5 6500, 16GB RAM, WD Blue SSD 1TB, 48" LG OLED, other stuff.
Work as house engineer at a popular venue in Melbourne AU. On a quest for the holy grail, the perfect amount of cowbell.

Reply
#7
i have installed the indicator-cpufreq on xubuntu from the ubuntu repos and with 2 clicks it sets the governor for all the cores. i think you need cpufreq package installed but it works as a graphical front end and works great.
Reply
#8
(05-10-2022, 07:49 AM)sunrat Wrote: There's a neat utility called cpupower-gui if you want a graphical way to change scaling governor. I prefer to change it back to ondemand when not doing audio production, to save power and run cooler.

I even don't switch to "performance" every time I do audio. It keeps the fans off. Although, it must be said that my "powersave" is someone else's "performance" Big Grin
Maybe that's a good reason for having a beefy CPU? (I have that XEON machine only through some lucky coincidence)

MMM
Linux throughout!
Main PC: XEON, 64GB DDR4, 1x SATA SSD, 1x NVME, MOTU UltraLite AVB
OS: Debian11 with KX atm

Mixbus 32C, Hydrogen, Jack... and Behringer synths
Reply
#9
(05-10-2022, 06:54 PM)madmaxmiller Wrote: I even don't switch to "performance" every time I do audio.

Same. With a few minor tweaks, mainly a good kernel, rt-irq and threadirqs, ondemand governor setting can well handle most except the heaviest tasks. It is also mentioned in the recently revised wiki guide -
https://wiki.linuxaudio.org/wiki/system_configuration
Mixbus 32C, Debian Bookworm/KDE, EVE SC205 + ADAM Sub 8 monitors, Soundcraft Compact 4, M-Audio 2496, i5 6500, 16GB RAM, WD Blue SSD 1TB, 48" LG OLED, other stuff.
Work as house engineer at a popular venue in Melbourne AU. On a quest for the holy grail, the perfect amount of cowbell.

Reply
#10
Hi All
Just done a quick test on this this system and in power save mode MB shows
many xruns when sitting idle, plus DSP is at 90%.
Setting performance, restarting Jack and all is as it should be.

So we need a way to enable performance from boot.

Any ideas on Ubuntu 22.04 Studio?

Cheers all.

Smile
Linux for years!
Ubuntu studio 24.04 LTS  Mixbus 32C  V9
Dell Precision  T3600  8 core 64gb ram.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)