2

after I created a group, and put the root account in it, I lost control of it and now it's not root anymore. Also I can't login with "root". How can I revert this? Now there is no way I can use sudo commands. And I don't know what account the control has!

/etc/group looks like this:

root:x:0
...
developers:x:1004:thomas,website
tversteeg
  • 195

1 Answers1

0

Not being able to login as root (other than by using sudo) is normal; Ubuntu doesn't set a password for root by default.

The empty /etc/sudoers means you can't use sudo, of course. But creating a new group shouldn't affect /etc/sudoers. You must have done something else.

The way to recover from this (short of reinstalling) is to boot into a single-user root shell. From there, you can fix /etc/sudoers, and whatever else needs fixing. Be careful while you're doing this; it's very easy to break the system by manually editing system files like this and frankly you've already done so.

To get a single-user root shell, see this question. Quick summary: Hold down the left shift key while booting and follow the prompts to get a root shell.