To prevent entering U 12.04 I set my log in password to none (blank) Since then I can not authenticate as administrator as all possible passwords I tried are rejected. Besides, I can not enter recovery mode as the shift key does not work when rebooting. Any other way to enter Recovery M.?


If you installed the system yourself, your user will be member of sudo and admin. In this case your password, not the root password will ba asked.

Try (in a terminal):

sudo su -

and give your own password.

If none of that works, boot into Ubuntu using a rescue CD (or USB key)

  1. On the boot prompt choose "Advanced options" and/or "Rescue a broken system"
  2. Answer the prompts about language and keyboard settings, hostname and network (if needed)
  3. Wait for the system to give you the rescue options
  4. Choose the root device of your system to rescue, or assemble the RAID and then choose
  5. Assuming the device was /dev/sda1 choose the menu item "Execute a shell in /dev/sda1"

From there execute:

passwd <you-username>
passwd root

to reset passwords. Since the rescue shell runs as superuser, this won't ask the old password and simply set a new one. You should be done. This whole principle also works in general for many unixoid systems, not just Ubuntu or Linux in general.

Side-note concerning sudo. In /etc/sudoers you have the following line:

%sudo ALL=(ALL) ALL

by default. If you change that into:


all members of the group sudo will be able to execute anything as anybody else without being asked a password. This may or may not be desirable depending on the system. Also sudoers allows for much more fine-grained control over what users or groups can execute and as who. It's my favorite method of allowing limited privileged operations to unprivileged users instead of setuid :)

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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