LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Do I always should add my user to some system groups? (https://www.linuxquestions.org/questions/linux-newbie-8/do-i-always-should-add-my-user-to-some-system-groups-824886/)

Mr. Alex 08-08-2010 04:17 AM

Do I always should add my user to some system groups?
 
For example I create new user in the system. Do I always should add it to groups like
Code:

adm, dialout, cdrom, plugdev, lpadmin, admin, audio
?

Or this is not required on modern distros?

Demerzel 08-08-2010 05:19 AM

I can give you an example, Debian Lenny. If I create new user and won't add him to audio group he wont be able to hear anything from sound card.
When you create new user you also create new group with the same name. Adding to other groups is a matter of need.

Mr. Alex 08-08-2010 05:24 AM

What if I add all permissions to "others" for audio device in "/dev" ? Will this make unneed to add user to audio group?

And what about other groups like I mentiond in the topic?

Demerzel 08-08-2010 05:52 AM

Something tells me that solution for you is editing basic settings for new user. I read about that long time a go. When you create new user they already will get all groups.

I am not sure but I think that setting even chmod -R 777 on /dev will not be enougth. In fact I started to be courious my self.

tredegar 08-08-2010 01:08 PM

Quote:

For example I create new user in the system. Do I always should add it to groups like
If you want sensible advice, you are going to have to tell us a bit more:

For example, are you talking about a server with hundreds, or thousands users (we do get these on LQ sometimes) or is this just your "Family PC"?
Who uses it?
How (one at a time, or all at once)?
What for (Email, watching videos, WP)?

Mr. Alex 08-09-2010 12:59 PM

tredegar, it's my computer and noone uses it except me. Purposes - Web, E-mail, OpenOffice and printing, text keeping, listening to MP3s...

tredegar 08-09-2010 01:11 PM

If it is only you, then the solution is easy.

Login as the "install" user (the first one you created).

Find out what groups you are in with the groups command.
Now (as root) add your newly created user to all the same groups: Then, everything will work as you are used to, with your second username. You can use the GUI [System - Administration - Users & Groups] or the command line to do this. The GUI is "easier", but the command line is handy if you get yourself into a muddle.

It is best not to change permissions on devices ( /dev/whatever ), but to manage access rights with the groups as set up by your distro (ubuntu).

If you were creating a user account for one of your children, I'd advise against granting them membership of administration groups, because they could then break your OS [let's face it - as the "Family Sysadms" we don't really care what they do in their home dirs, we do care about the system booting and running properly for everyone else].

Hope this helps.

Mr. Alex 08-10-2010 02:17 AM

Yeah it helps a lot, thanks!
So system groups that user is in depend on a distro? Different distros - different system groups for first non-root user?

tredegar 08-10-2010 03:49 AM

With ubuntu, the default is that the first user is granted administrative rights (they can use sudo), other users cannot, unless the first user grants them this.

See here

Different distros do things differently.


All times are GMT -5. The time now is 03:20 PM.