I used rsync -aiiP to copy the /etc from my old laptop to the /etc of my new laptop. After locking the screen and trying to log back in, my password no longer works. I rebooted but it gets stuck on the loading screen and my new user account never appears, instead I am entered into emergency mode where I can use root on the command line to navigate the filesystem.
I think the problem could be that I replaced /etc/shadow and /etc/passwd on the new system with the ones from the old system. The user account on my old system and new system are different.
How do I get access to my user account again and what caused this problem?
I'm thinking of freshly installing fedora 37 on a different laptop and then copying /etc to the broken laptop using root in emergency mode, but I don't know if there's a better way.