0

I am running Fedora 17.

My user was created during the live cd install and has root/admin privileges. Hence, I use the sudo command to perform root actions. E.g

sudo iftop

I enter my password and it works.

However, when I access

sudo visudo

My username is not listed.

Can someone explain this?

Thanks

2
  • An ordinary user doesn't have "root" access in linux other than via sudo (or su). However, your user could be part of a group that has sudo access. If you do id, can you see adm, sudo or any other admin-like groups - check this in visudo too.
    – Paul
    Commented Oct 17, 2013 at 2:11
  • Also check /etc/sudoers.d serverfault.com/questions/574953/… Commented Dec 9, 2019 at 21:00

2 Answers 2

2

Assuming you don't mean you're already acting as the root user, you'll likely find an entry in the sudoers file for the wheel group, a line that starts with %wheel, and you'll be in that group (which is stored in the /etc/groups file)

1
  • I believe this is the correct answer. By running the command "groups" I can see that I am in the "wheel" group.
    – Pete
    Commented Oct 18, 2013 at 1:58
0

To adding to Sirex's response above, here's a link with more information about the wheel group.

Also, check the man pages for sudo and sudoers for more information.

2
  • Isn't that just referring to the user called "root"? I tried running sudo with a user that is in the "root" group but not in wheel or listed as an explicit entry in the sudoers list and this user was not able to execute commands using sudo.
    – Pete
    Commented Oct 18, 2013 at 2:00
  • I actually tried testing this by removing the root user from the sudoers list. When it was removed I could still access the sudo list using the command "visudo". But then I tried accessing visudo using the command "sudo visudo" it didn't work. But I when I added root ALL=(ALL) ALL back to visudo I could use the command "sudo visudo" as root.
    – Pete
    Commented Oct 18, 2013 at 2:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .