PVE 配置

1. UPS 配置

nut-scanner -qNU

[nutdev1]
        driver = "usbhid-ups"
        port = "auto"
        vendorid = "051D"
        productid = "0002"
        product = "Back-UPS BK650M2-CH FW:294803G -292804G"
        serial = "9B2123A10779"
        vendor = "American Power Conversion"
        bus = "003"

编辑 /etc/nut/ups.conf 文件,在文件最后增加:

参考:https://www.cnblogs.com/LandWind/articles/pve-nut-config.html

CPU 降频,编辑 /etc/default/cpufrequtils 文件,修改为如下:

ENABLE="true"
GOVERNOR="powersave"
MAX_SPEED="1.2"
MIN_SPEED="1.2GHz"

/etc/network/interfaces

# network interface settings; autogenerated
# Please do NOT modify this file directly, unless you know what
# you're doing.
#
# If you want to manage parts of the network configuration manually,
# please utilize the 'source' or 'source-directory' directives to do
# so.
# PVE will preserve these directives, but will NOT read its network
# configuration from sourced files, so do not attempt to move any of
# the PVE managed interfaces into external files!

auto lo
iface lo inet loopback

auto eno1
iface eno1 inet manual

auto vmbr0
iface vmbr0 inet static
        address 192.168.199.111/24
        gateway 192.168.199.252
        bridge-ports eno1
        bridge-stp off
        bridge-fd 0
        bridge-vlan-aware yes
        bridge-vids 2-4094

auto vmbr0.43
iface vmbr0.43 inet manual

auto vmbr1
iface vmbr1 inet manual
        bridge-ports vmbr0.43
        bridge-stp off
        bridge-fd 0

2. dns

新增文件:/lib/systemd/system/ ,内容如下:

[Unit]
Description=Tencent DNS Service
After=network.target
StartLimitIntervalSec=500
StartLimitBurst=5

[Service]
Type=simple
# User=nobody
# Group=nobody
LimitNOFILE=32768
ExecStart=/usr/local/bin/tencent-dns
# PIDFile=/run/tencent-dns.pid
StandardOutput=syslog
StandardError=syslog
SyslogIdentifier=tencent-dns
Restart=on-failure
RestartSec=5s

[Install]
WantedBy=multi-user.target

将 tencent-dns 文件放至指定目录:

mv tencent-dns /usr/local/bin/tencent-dns

3. 更新源

4. 风扇配置

如果风扇不降速,声音非常响,常人是无法忍受的,因此需要通过 IPMI 将风扇降速。使用 crontab -e 新增如下项目:

@reboot echo "powersave" | tee /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor >/dev/null 2>&1
@reboot /usr/bin/ipmitool raw 0x30 0x70 0x66 0x01 0x00 0x3c

etc/apt/sources.list.d

/etc/apt/sources.list

apt update

apt update && apt dist-upgrade -y

apt-get -y install apcupsd

apt install -y ipmitool

邮箱配置:

https://fcying.com/proxmox-use-qqmail-sendmail-14589/