0

Unfortunatelly I made mistake somewhere but can't get where. I had issues with ssh and github, tried different things and they didn't work. Later I decided .. i think.. moved file i balieve it was home/username/known.hosts or smth like that. Additonally I deleted everything from folder, where id_25519 and id_25519.pub files (maybe they are related to github, i don't know). And somewhere in between or afteer all. I could not provide my password in terminal. I 200% sure it's correct, no caps/num/ other things used. and now i can't log in to my linux mint cinamon 20. I will really appreciate any help how can I recover my laptop. It starts, but requires pass. And I can't understad how coudl it change ......

1 Answers1

2

It's unlikely modifying anything in your home directory will have reset your password. On most distributions it's stored in /etc/shadow by default.

To get to a recovery console, the most easy thing to try is to change the init kernel parameter on boot.

Assuming you are booting with grub:

  • switch on your computer
  • At the boot menu press e to edit the boot entry
  • You might be asked for your grub password if you have one set
  • Modify the line starting linux to add init=/bin/bash at the end
  • Press f10 to boot

This should give you a root command line with / mounted readonly. To make it read-write remount it:

mount -o remount,rw /

You should be able to reset your password with:

passwd <username>

And finally reboot with:

 reboot
Philip Couling
  • 17,591
  • 5
  • 42
  • 82