I did a stupid mistake on my Ubuntu virtual server (Amazon). I was messing around with /etc/passwd & /etc/group files and i am about to lock my self out of the server for good. I have a copy of the original passwd+group files but i cannot copy them back because every time i try to sudo i get :
sudo: unknown uid 1000: who are you?
I am still logged in. Is there anything i can try? I am afraid that after i log out there is no way to bring it back.
Thanks in advance.