Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

by ignorance and error I renamed the user_name of the directory /home/, called frank_account (home/frank_account) to sixven(/home/sixven) (using gksudo nautilus). Restarting Ubuntu, I get 3 users: frank_account, sixven and guest. However, I can not access to any account with password, only the guest_account and is very limited. entering by tty (Ctrl+Alt+F1), I can log in with the user and pass sixven but I can not do sudo as it tells me sixven not in sudoers. And will not let me edit the etc/sudoers file. How I can fix this problem?

share|improve this question
have you tried rebooting in single user mode and change things back from there? – Anthon Mar 12 '14 at 19:38
@Anthon How i do that? I don't know how to do it. – franvergara66 Mar 12 '14 at 19:40
I am going to write up the answer with some screenshots, please bare with me. – Anthon Mar 12 '14 at 19:42
up vote 7 down vote accepted

You should restart your machine and replace init with bash:

  1. Reboot the computer and hold Shift, so that the grub menu appears:

    enter image description here

  2. Highlight the second entry and press e

    enter image description here

  3. Use to go to the line stating with linux, then use to go to ro and change it in rw, remove everything after that with init=/bin/bash

    enter image description here

  4. Following the instructions at the bottom press F10

After the message stop scrolling you should have a prompt:


which should allow you to roll-back the changes.

Afterwards reboot, by entering


and press reset

The changes to the grub menu are not saved.

share|improve this answer
And when i press enter. What Should i do ? – franvergara66 Mar 12 '14 at 20:00
When did you press Enter? Did you start before I made the changes? – Anthon Mar 12 '14 at 20:05
Great answer Anthon +1. – user55518 Mar 12 '14 at 22:15
This doesn't really put the user in Single user mode, it replaces Init with bash. Exit at the end causes a kernel panic and a hang, hence the OP question "And when I press enter, What do I do now ?" – X Tian Mar 13 '14 at 1:18
@XTian, ou are right about the single user mode. I was documenting that process for single user mode (adding single at point 3), but changed my mind without updating the start of the answer. – Anthon Mar 13 '14 at 5:16
  1. Download a live linux system (http://www.knoppix.org/, http://www.ubuntu.com, etc.)
  2. Burn ISO
  3. Start from CD-Rom
  4. Rename the home folder back to "frank_account"
share|improve this answer

Your Answer


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.