透過 GRUB 進入單人模式(Single User Mode)重置 root 密碼,各發行版細節略有不同:
single 或 Smount -t proc proc /procmount -o remount,rw /passwdsync; rebootro single 改為 rw single init=/bin/bashmount -apasswd rootrebootmount -afsck -ypasswd rootinit 6/a 選 ypasswd → init 6boot -smount -a; fsck -y; passwd; exit 進入多用戶模式init=/bin/bashmount -n / -o remount,rwpasswdmount -n / -o remount,rorebootgrub2-mkpasswd-pbkdf2)