设为首页 收藏本站 订阅本站

blogger

linux下关闭服务器的CPU(睿频)自动降频

cache 发布于 技术文档 2016-01-19 [ 106 ] 次浏览 [ 0 ] 条评论

标签: 自动降频

linux下关闭服务器的CPU(睿频)自动降频

因为在负载低的时候,CPU工作在较低的频率,为了节能,但在服务器突发访问时,CPU不断在高低频率上切换,所以需要关闭自动降频。

[email protected]:~# grep -E '^model name|^cpu MHz' /proc/cpuinfo
model name	: Intel(R) Xeon(R) CPU E3-1220 V2 @ 3.10GHz
cpu MHz		: 3101.000
model name	: Intel(R) Xeon(R) CPU E3-1220 V2 @ 3.10GHz
cpu MHz		: 1600.000
model name	: Intel(R) Xeon(R) CPU E3-1220 V2 @ 3.10GHz
cpu MHz		: 3101.000
model name	: Intel(R) Xeon(R) CPU E3-1220 V2 @ 3.10GHz
cpu MHz		: 1600.000
[email protected]:~# for CPUFREQ in /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor; do [ -f $CPUFREQ ] || continue; echo -n performance > $CPUFREQ; done
[email protected]:~# grep -E '^model name|^cpu MHz' /proc/cpuinfo
model name	: Intel(R) Xeon(R) CPU E3-1220 V2 @ 3.10GHz
cpu MHz		: 3101.000
model name	: Intel(R) Xeon(R) CPU E3-1220 V2 @ 3.10GHz
cpu MHz		: 3101.000
model name	: Intel(R) Xeon(R) CPU E3-1220 V2 @ 3.10GHz
cpu MHz		: 3101.000
model name	: Intel(R) Xeon(R) CPU E3-1220 V2 @ 3.10GHz
cpu MHz		: 3101.000

 

永久关闭:

 If you are running 'cpuspeed', 'cpufreqd', 'powerd' or other daemons, that can control CPU stepping, just stop them, if you really need to run your system on 100% of the CPU speed.
On CentOS:
# service cpuspeed stop
1:


 On Linux 2.6.32 (On RedHat 6, and Oracle Unbreakable Linux 6) remove CPU scaling kernel modules:
# lsmod | grep ondemand
cpufreq_ondemand        8764  0 
freq_table              3751  2 cpufreq_ondemand,acpi_cpufreq
# rmmod cpufreq_ondemand acpi_cpufreq freq_table

 

linux下关闭服务器的CPU(睿频)自动降频:等您坐沙发呢!

发表评论