Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

i got a used server and don't know the username and password to login.

Anyone know how i can reset the username and password without needing to wipe everything and starting from scrach?

share|improve this question

3 Answers 3

Hold shift at boot, select recovery mode then select root. You can now run:

passwd foo; reboot

Change foo for your username, E.g:

passwd andy; reboot

You can low log on as your username with your new password.

share|improve this answer

You could try using something like Kon-Boot to bypass the password (doesn't work on 3.0 or 64-bit kernels). Or, if you have a way to attach the HDD to another Linux machine you can chroot into the server and run passwd [user]

share|improve this answer

It's not difficult, but you probably should consider reinstalling. But if you don't want to, then you simply reboot and select "Recovery" from the Grub menu. You'll find an option to get a root shell. Then you'll do

adduser someusername
adduser someusername admin
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.