解决ubuntu忘记密码记录

2016-04-08  本文已影响216人  mrwrong1988

忘记普通用户密码:

  1. 重启Ubuntu,随即长按shift进入recover mode菜单(或F10);
  2. 选择recovery mode,回车确认;
  3. 在Recovery Menu中,选择“Root Drop to root shell prompt”,回车确认;
  4. 进入shell界面,使用passwd命令重新设定密码:passwd wangyu,回车确认;看到密码设定成功提示:passwd: password updated successfully;重启系统:sudo reboot;

如果出现Authentication token manipulation error错误原因是The problem was that the system was started as read only, 运行"mount -rw -o remount /"

忘记root密码:

  1. 开机按F10进入grub时,按e(不是回车
  2. 看到一行linux /boot/vm.......ro *****,(类似)
  3. 删除*****, 在这行的最后添加 quiet splash rw init=/bin/bash
  4. 按F10, 启动
  5. passwd, 系统会提示你输入新的密码,结束。
上一篇 下一篇

猜你喜欢

热点阅读