My friend did not use his (dual-boot) Linux Mint 20 in a long while, and forgot password to his system.
How can one change password offline, connecting his SSD to my Debian OS, I suppose likely via chroot, or any method really?
So, in my case, I have several directories in my /mnt, so I created directory /mnt/user
mkdir /mnt/user
Then, I mounted his ext4 partition with (note, I used this path as I am more used to it, of course, you can use e.g. /dev/sdXn, whichever you prefer:
mount /dev/disk/by-id/ata-<long_name>-part2 /mnt/user
It mounted ok, so I allowed myself to chroot into his system with:
chroot /mnt/user /bin/bash
Since the above step went ok too, I simply issued the change password commands, both for his username, and root:
passwd username
passwd root
I put his disk back into his machine and verified I can log in. Done.