1. 程式人生 > >ubantu 18.02 root密碼忘記,密碼重置方法

ubantu 18.02 root密碼忘記,密碼重置方法

  1. 開機按Esc,進入GRUB
  2. 選擇*Advanced options for Ubuntu
  3. 選擇*Ubuntu,with Linux 4.15.0-20-generic(recovery mode)
  4. 選擇root drop to root shell promt
  5. mount -o remount,rw /ect
  6. chattr -i ect/passwd
  7. lasttr -v erc/passwd
  8. passwd
  9. 輸入新密碼
  10. 再次輸入新密碼
  11. passwd: password updated successfully