You are not logged in.

#1 2013-04-02 14:05:06

logos88
Member
From: Valencia
Registered: 2013-04-02
Posts: 28

[Solved] User groups and sudo

Hello. I have read that with systemd it's not more necesary to put the user in the diferent groups (sys, disk, lp, network, video, audio, optical, storage, scanner, power, etc.).

But, if I don't add the user to wheel, how do I have to configure sudo? Is there any problem adding the user to wheel?

Last edited by logos88 (2013-04-05 09:11:34)

Offline

#2 2013-04-02 14:12:35

parazyd
Member
From: Amsterdam
Registered: 2012-10-14
Posts: 259
Website

Re: [Solved] User groups and sudo

You can add yourself to wheel.
It's also possible to edit yhe sudoers to allow your username, just the same way root is allowed.

Offline

#3 2013-04-02 14:12:58

Awebb
Member
Registered: 2010-05-06
Posts: 4,541

Re: [Solved] User groups and sudo

Look at: Wiki article about sudo
/etc/sudoers (it is all explained in the file).
man sudoers

In the past, it was recommended to edit the sudoers file only through visudo, because it performs a syntax check, but you should not worry too much, as long as you have a root account.

EDIT: Never mind. I got it the wrong way. You asked about systemd and the wheel group. Sudo only works with groups and users, so if you have to use sudo, then it is safe to do so by adding your user to the wheel account. It does not bother systemd.

Last edited by Awebb (2013-04-02 14:16:15)

Offline

#4 2013-04-02 14:15:54

parazyd
Member
From: Amsterdam
Registered: 2012-10-14
Posts: 259
Website

Re: [Solved] User groups and sudo

I still edit it with

# visudo

Offline

#5 2013-04-02 14:20:55

skanky
Member
From: WAIS
Registered: 2009-10-23
Posts: 1,841

Re: [Solved] User groups and sudo

parazyd wrote:

I still edit it with

# visudo

Yeah, same here. It's worth noting that you can change the editor visudo uses (see the man page) - though this is not especially relevant to the original question.

Just a general point, it is worth at least a skim of the sudoers and sudo man pages, and the sudoers comments.


"...one cannot be angry when one looks at a penguin."  - John Ruskin
"Life in general is a bit shit, and so too is the internet. And that's all there is." - scepticisle

Offline

#6 2013-04-02 15:25:17

drcouzelis
Member
From: Connecticut, USA
Registered: 2009-11-09
Posts: 3,523
Website

Re: [Solved] User groups and sudo

logos88 wrote:

Hello. I have read that with systemd it's not more necesary to put the user in the diferent groups (sys, disk, lp, network, video, audio, optical, storage, scanner, power, etc.).

Oh, I hate that section. It never works for me! I always read it and then I remove myself from all of those groups and then everything stops working correctly. yikes

Offline

#7 2013-04-05 08:50:17

logos88
Member
From: Valencia
Registered: 2013-04-02
Posts: 28

Re: [Solved] User groups and sudo

Finally I included the user only in the groups wheel and systemd-journal.

In the Users and Groups page (https://wiki.archlinux.org/index.php/Users_and_Groups) says that wheel will be used in the future by systemd to allow starting/stopping services as non-root, and that systemd-journal provides access to the complete systemd logs. Otherwise, only user generated messages are displayed.

Then I made a visudo and uncomented:
#%wheel  ALL=(ALL)  ALL

Now sudo works good, and I don't have any problems with audio or media devices despite not being in any other groups.

Offline

#8 2013-04-05 08:53:57

HalosGhost
Member
From: Twin Cities, MN
Registered: 2012-06-22
Posts: 1,486
Website

Re: [Solved] User groups and sudo

I'm glad you got it worked out. Please add [Solved] to your thread title.

All the best,

-HG


"All errors are ᴘᴇʙᴋᴀᴄ errors—It's just a matter of narrowing down which keyboard and chair." -Trilby
\ldots

Offline

Board footer

Powered by FluxBB