In turn availability depends on which CPU frequency scaling driver you are using. It sleeps for 1 minutes and then changes the scaling governor to either interactive, ondemand or powersave, depending on availability. # CONFIG_CPU_FREQ_DEFAULT_GOV_SCHEDUTIL is not setīut also by default during boot up the ondemand service is executed. # CONFIG_CPU_FREQ_DEFAULT_GOV_CONSERVATIVE is not set # CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND is not set # CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE is not set # CONFIG_CPU_FREQ_DEFAULT_GOV_POWERSAVE is not set The relevant section of the kernel configuration file ( /boot/config-4.15.0-36-generic, in this example) is: #ĬONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE=y You may need to remove other programs that change CPU frequency if they override your Performance settings in /etc/rc.localĭefault Ubuntu kernel configurations are such that the performance CPU frequency scaling governor will be used during boot. Your machine will probably run 10 to 15 degrees C hotter. To setup /etc/rc.local in 18.04 see: How to Enable /etc/rc.local with Systemd If you insert the new lines after exit 0 it will never be executed. The simplest way to stay in Performance mode is to edit /etc/rc.local and insert these lines before the last line containing exit 0: sleep 120 # Give CPU startup routines time to settle. Sleep 120 seconds before setting Performance Mode Watch-gov.sh: Current governor: powersave Uptime: 17:51:09 up 1 min, 1 user, load average: 1.89, 0.62, 0.22Ĭonfirmation from this answer states this 1 minute force to powersave governor is controlled by /etc/init.d/ondemand. One minute after logging in look at the output: $ cat /tmp/watch-gov.log ![]() Last_gov=$(cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor)Įcho "watch-gov.sh: Set to performance at $Uptime " > /tmp/watch-gov.logĬall the script in /etc/rc.local before the exit 0 command (explained in detail below). # DESC: Set governnor to performance and watch for changeĮcho performance | tee /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor Program to monitor exact second Powersave invokedĬreate this script in /usr/local/bin/watch-gov.sh: #! /bin/bash When up time hits about 1 minute you see CPU MHz drop off. In the GIF below, the 3000+ MHz CPU speed at start up appears near the top. If you set the mode to Performance on startup it will be overridden around the 1 minute Up Time mark to Powersave mode. ![]() In /etc/rc.local put in these commands: sleep 120Ĭpupower frequency-set -governor performanceġ minute after boot automatic switch to Powersaveįor whatever reasons my Skylake Intel CPU always starts up in Performance mode and then switches to Powersave mode at the 1 minute mark automatically.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |