Tips & Tricks
ProcessorScheduler tunables for multi-socket systemsMulti-core, multi-threaded power-saving tunables for the process scheduler:
echo 1 > /sys/devices/system/cpu/sched_mc_power_savings
These power savings options may impact the performance of some applications. For some, there will be negligible impact on the performance. These tunables are provided in the hope that the administrators can use these tunables during off-hours (where they can tolerate some impact on performance) or turn on some of these options by default, if the corresponding power-savings policy has no impact on performance for a specific target workload that the administrator is interested in.
P-states: Frequency control and ondemand-governorProcessor performance states (P-states) are a predefined set of frequency and voltage combinations at which the processor operates. With higher frequencies, you get higher performance, but to achieve that the voltage needs to be higher as well, which makes the processor consume more power. With P-states, the operating system can dynamically change the tradeoff between power and performance all the time.
# cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors ondemand userspace performanceIn the example above, there are three governers available. In addition to the ondemand governer, there are the userspace and performance governers.
# cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor ondemandYou can also change the currently running governor by echoing one of the available governors to the scaling_governor file node: # echo ondemand > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governorFor most distributions, the proper P-state governor is loaded automatically from the init script /etc/init.d/powernow or /etc/init.d/cpuspeed initialization scripts. But its worth checking to be sure just the same.
CONFIG_CPU_FREQ=y CONFIG_CPU_FREQ_GOV_ONDEMAND=m CONFIG_X86_ACPI_CPUFREQ=mThere are related governor and processor options that are ok to have enabled as well, but for current systems, the options above are the important ones to set.
Power aware interrupt balancingUse the interrupt (IRQ) balancing technique to distribute the various interrupts, from the devices on the system, over the cores/processors in the system.
|