Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Quts Hero 系统的一些优化项

本文环境:

型号: TS-h973AX
BIOS 版本: Q071AR07
固件版本: QuTS hero h5.2.9.3410 Build 20260214

网卡队列

function list_eth_irqs() {
    grep eth0-TxRx /proc/interrupts
    grep eth1-TxRx /proc/interrupts
    grep eth2      /proc/interrupts | head -n8
}

function set_eth_irq() {
    local idx=0
    exec 3< <( list_eth_irqs | cut -d: -f1 )
    while read -u3 id
    do
        echo ${idx} > /proc/irq/${id}/smp_affinity_list
        let idx+=1
        if [ "${idx}" -ge 8 ]; then
            idx=0
        fi
    done
}

set_eth_irq

分层Swap

Swap分区的定位参考 从系统阵列中移除HDD#查找阵列

if [ -e /dev/md322 ]; then
    swapoff /dev/md322
    mdadm --stop /dev/md322
fi

tmpfs

很多应用都是自带运行环境,并且需要解压的,运行一些大型应用的时候会塞爆/tmp

例如:

  • container station

    对! docker 命令也是自解压

  • yt-dlp
mount -o remount,size=262144k /tmp/

crontab

除Admin外的用户都无法使用 crontab,因为 busybox 没有设置 s flag

chmod u+s /bin/busybox

sudo 免密

和一般 linux 系统的操作一致

mkdir -p /usr/etc/sudoers.d
echo "${user} ALL=(ALL:ALL) NOPASSWD: ALL" > /usr/etc/sudoers.d/${user}
Last change: , commit: 6556421