LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices



Reply
 
Search this Thread
Old 04-10-2006, 03:55 AM   #1
p_test
Member
 
Registered: Aug 2004
Location: Jaipur(Rajasthan), INDIA
Posts: 35

Rep: Reputation: 15
primary & secondary groups ???


Hi

What is the difference between Primary & Secondary groups of users regarding file access permissions. ???

Regards
 
Old 04-10-2006, 04:47 AM   #2
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,123

Rep: Reputation: 162Reputation: 162
Your primary group is the group that gets used when you create files/directories. Any file/directory with a group id that you are a member of (primary or otherwise) you will have access to according to the group permissions.

You can modify the behaviour by setting the group id bit on directories, but that's the simple overview
 
Old 09-12-2012, 03:09 PM   #3
hermes_ilk
LQ Newbie
 
Registered: Mar 2009
Posts: 1

Rep: Reputation: 0
Smile primary and secondary group

Your Primary Group is the default group your account is associated when you login, this is the group with the Group ID that is the 4th field in your account /etc/passwd file. Directories and files you create have this Group ID.
Your Seconday Group is any Group(s) you are a member of other than your Primary Group.
All Group(s) are found in the /etc/group file and are created with the 'groupadd' command or any text editor, such as vi/vim.
Users are added to a Group with the 'usermod -G groupname uname' command. You can see the members of a Group by viewing the /etc/group file.
Users can change the current Group they are in with the command 'newgrp' and can check their current group with the 'id' command.
Access to directory/files is controlled by the permission bits of the directory/file and the Group that "owns" the directory/file.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
primary - secondary DNS jsheffie Solaris / OpenSolaris 2 08-01-2005 07:55 AM
redundant qmail servers (primary & secondary) littleking Linux - Networking 3 08-15-2004 11:18 PM
Primary and secondary group trophy Linux - Newbie 2 04-03-2004 01:30 AM
setting up primary HD and secondary HD dataport Linux - General 8 01-23-2004 11:18 PM
Primary and Secondary DNS dilberim82 Linux - Networking 3 07-13-2001 11:50 AM


All times are GMT -5. The time now is 08:18 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration