Windows XP Windows 7 Windows 2003 Windows Vista Windows 綜合教學 Linux 系統教學
Windows 10 Windows 8 Windows 2008 Windows NT Windows Server 電腦軟體教學
您现在的位置: Windows教程網 >> Windows教程 >  >> Linux 系統教學 >> Linux 教學

Linux 關閉系統蜂鳴器報警聲與調整文字模式解析度

編輯:Linux 教學

關閉蜂鳴器(主板喇叭)

方法一:修改 /etc/inputrc

set bell-style none   # 或 visible(視覺閃爍替代聲音)

方法二:~/.bashrc 加入

echo "set bell-style none" >> ~/.bashrc

方法三:setterm 永久生效

setterm -blength 0
# 加入 /etc/bashrc 或 ~/.bashrc

方法四:禁用 pcspkr 核心模組(最徹底)

sudo modprobe -r pcspkr
echo "blacklist pcspkr" >> /etc/modprobe.d/blacklist

GDM 登入畫面關閉聲音

# /etc/gdm/custom.conf
[greeter]
SoundOnLogin=false

或終端執行 rmmod pcspkr; xset b off。

文字模式(Grub/LILO)設定解析度

GRUB(/boot/grub/grub.conf 或 menu.lst)

在 kernel 行尾加 vga=XXX,常用對照表:

色深\解析度640x480800x6001024x7681280x1024
8bit769771773775
16bit785788791794
24bit786789792795

範例:kernel /boot/vmlinuz-... ro root=LABEL=/ vga=791 rhgb quiet(1024x768 16bit)。

LILO(/etc/lilo.conf)

加入 vga=0x317(1024x768)、0x31A(1280x1024)等十六進制值,重跑 lilo 生效。

Copyright © Windows教程網 All Rights Reserved