Skip to content

重制密码

重启电脑 Ctrl + Alt + Delete

GNU GRUB 选择 Proxmox VE GNU/Linux 按 e 进入编辑模式

sh
# 在 后面添加 init=/bin/bash
linux /boot/vmlinuz-xxx root=

# 例如:
# linux /boot/vmlinuz-6.x root=ZFS=... ro quiet init=/bin/bash

Ctrl + X 或 F10 启动(好像可以没有这一步)

开始重制密码

sh
# 挂载根目录为可写
mount -o remount,rw /

# 重置密码
passwd root

# 重启
reboot -f