PVE(proxmox) 开启省电模式
首先修改启动项
root@pve:~# vi /etc/default/grub找到quiet那个位置,后面加空格,再加
intel_pstate=disable加上参数后保存,并更新grub
root@pve:~# update-grub保存完后重启生效。
安装cpufrequtils
root@pve:~# apt-get install cpufrequtils配置
先查看一下信息
root@pve:~# cpufreq-info
cpufrequtils 008: cpufreq-info (C) Dominik Brodowski 2004-2009
Report errors and bugs to [email protected], please.
analyzing CPU 0:
driver: acpi-cpufreq
CPUs which run at the same hardware frequency: 0
CPUs which need to have their frequency coordinated by software: 0
maximum transition latency: 10.0 us.
hardware limits: 1.60 GHz - 2.30 GHz
available frequency steps: 2.30 GHz, 2.20 GHz, 2.10 GHz, 2.00 GHz, 1.90 GHz, 1.80 GHz, 1.70 GHz, 1.60 GHz
available cpufreq governors: conservative, ondemand, userspace, powersave, performance, schedutil
current policy: frequency should be within 1.60 GHz and 1.60 GHz.
The governor "performance" may decide which speed to use
within this range.
current CPU frequency is 2.30 GHz (asserted by call to hardware).
cpufreq stats: 2.30 GHz:12.35%, 2.20 GHz:0.00%, 2.10 GHz:0.00%, 2.00 GHz:5.16%, 1.90 GHz:0.00%, 1.80 GHz:0.00%, 1.70 GHz:0.00%, 1.60 GHz:82.49% (4)
analyzing CPU 1:
driver: acpi-cpufreq
CPUs which run at the same hardware frequency: 1
CPUs which need to have their frequency coordinated by software: 1
maximum transition latency: 10.0 us.
hardware limits: 1.60 GHz - 2.30 GHz
available frequency steps: 2.30 GHz, 2.20 GHz, 2.10 GHz, 2.00 GHz, 1.90 GHz, 1.80 GHz, 1.70 GHz, 1.60 GHz
available cpufreq governors: conservative, ondemand, userspace, powersave, performance, schedutil
current policy: frequency should be within 1.60 GHz and 1.60 GHz.
The governor "performance" may decide which speed to use
within this range.
current CPU frequency is 2.30 GHz (asserted by call to hardware).
cpufreq stats: 2.30 GHz:12.35%, 2.20 GHz:0.00%, 2.10 GHz:0.00%, 2.00 GHz:2.45%, 1.90 GHz:0.00%, 1.80 GHz:0.00%, 1.70 GHz:0.00%, 1.60 GHz:85.21%修改
可以看到目前是performance模式,主频是2.30 GHz ,下面就配置一下,改成省电模式(powersave) 以最低允许的主频运行
root@pve:~# vi /etc/init.d/cpufrequtils找到如下:
ENABLE="true"
GOVERNOR="performance"
MAX_SPEED="2300000"
MIN_SPEED="1600000"改成:
ENABLE="true"
GOVERNOR="powersave"
MAX_SPEED="1600000"
MIN_SPEED="1600000"保存后,重启服务:
root@pve:~# systemctl daemon-reload
root@pve:~# /etc/init.d/cpufrequtils restart如果不生效,查看一下是否有/etc/default/cpufrequtils文件,如果有,在这里修改就可以了。
检查
root@pve:~# cpufreq-info
cpufrequtils 008: cpufreq-info (C) Dominik Brodowski 2004-2009
Report errors and bugs to [email protected], please.
analyzing CPU 0:
driver: acpi-cpufreq
CPUs which run at the same hardware frequency: 0
CPUs which need to have their frequency coordinated by software: 0
maximum transition latency: 10.0 us.
hardware limits: 1.60 GHz - 2.30 GHz
available frequency steps: 2.30 GHz, 2.20 GHz, 2.10 GHz, 2.00 GHz, 1.90 GHz, 1.80 GHz, 1.70 GHz, 1.60 GHz
available cpufreq governors: conservative, ondemand, userspace, powersave, performance, schedutil
current policy: frequency should be within 1.60 GHz and 1.60 GHz.
The governor "powersave" may decide which speed to use
within this range.
current CPU frequency is 1.60 GHz (asserted by call to hardware).
cpufreq stats: 2.30 GHz:12.35%, 2.20 GHz:0.00%, 2.10 GHz:0.00%, 2.00 GHz:5.16%, 1.90 GHz:0.00%, 1.80 GHz:0.00%, 1.70 GHz:0.00%, 1.60 GHz:82.49% (4)
analyzing CPU 1:
driver: acpi-cpufreq
CPUs which run at the same hardware frequency: 1
CPUs which need to have their frequency coordinated by software: 1
maximum transition latency: 10.0 us.
hardware limits: 1.60 GHz - 2.30 GHz
available frequency steps: 2.30 GHz, 2.20 GHz, 2.10 GHz, 2.00 GHz, 1.90 GHz, 1.80 GHz, 1.70 GHz, 1.60 GHz
available cpufreq governors: conservative, ondemand, userspace, powersave, performance, schedutil
current policy: frequency should be within 1.60 GHz and 1.60 GHz.
The governor "powersave" may decide which speed to use
within this range.
current CPU frequency is 1.60 GHz (asserted by call to hardware).
cpufreq stats: 2.30 GHz:12.35%, 2.20 GHz:0.00%, 2.10 GHz:0.00%, 2.00 GHz:2.45%, 1.90 GHz:0.00%, 1.80 GHz:0.00%, 1.70 GHz:0.00%, 1.60 GHz:85.21%完成
经过测试,省电模式下,待机会保持在最低功耗,温度也最低。
本作品采用 知识共享署名-相同方式共享 4.0 国际许可协议 进行许可。
小菜鸡
评论已关闭