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?
- have you tried rebooting in single user mode and change things back from there?Anthon– Anthon2014-03-12 19:38:06 +00:00Commented Mar 12, 2014 at 19:38
- @Anthon How i do that? I don't know how to do it.franvergara66– franvergara662014-03-12 19:40:47 +00:00Commented Mar 12, 2014 at 19:40
- I am going to write up the answer with some screenshots, please bare with me.Anthon– Anthon2014-03-12 19:42:27 +00:00Commented Mar 12, 2014 at 19:42
2 Answers
You should restart your machine and replace init with bash:
Reboot the computer and hold Shift, so that the grub menu appears:

Highlight the second entry and press e

Use ↓ to go to the line stating with
linux, then use → to go toroand change it inrw, remove everything after that withinit=/bin/bash
Following the instructions at the bottom press F10
After the message stop scrolling you should have a prompt:
root(none):/# which should allow you to roll-back the changes.
Afterwards reboot, by entering
sync sync exit and press reset
The changes to the grub menu are not saved.
- And when i press enter. What Should i do ?franvergara66– franvergara662014-03-12 20:00:05 +00:00Commented Mar 12, 2014 at 20:00
- 1When did you press Enter? Did you start before I made the changes?Anthon– Anthon2014-03-12 20:05:26 +00:00Commented Mar 12, 2014 at 20:05
- 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– X Tian2014-03-13 01:18:01 +00:00Commented Mar 13, 2014 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– Anthon2014-03-13 05:16:58 +00:00Commented Mar 13, 2014 at 5:16
- Download a live linux system (http://www.knoppix.org/, http://www.ubuntu.com, etc.)
- Burn ISO
- Start from CD-Rom
- Rename the home folder back to "frank_account"