Mailing List
Home
Forum Home
Linux - General Red Hat Linux discussion list
Installation - Getting started with Red Hat Linux
Enterprise Linux 3 - Discussion of Red Hat Enterprise Linux 3 (Taroon)
Red Hat Linux 9 - Discussion of Red Hat Linux 9 (Shrike)
Red Hat Linux 7.2 - Discussion of Red Hat Linux 7.2 (Enigma)
Red Hat Linux 7.3 - Discussion of Red Hat Linux 7.3 (Valhalla)
Apache Web Server
Oracle database, Microsoft SQL server ...
Subjects
application/x mplayer2 plugin
RPM error: db4 error(16) from dbenv >remove: Device or resource
   busy
Command stream end of file while reading
X Windows problem (xauth)
Upgrading openoffice 1 1 rpm
FTP: connection refused
FTP: connection refused
mount: /dev/cdrom: is not a valid block device
Dell Precision 650, RedHat 9, no sound
how to trace the cause resulting in the crash of bind server
Virus on the list
UNINSTALL RPM MYSQL
usb pen drives: mounting as a user
broadcom network interface
make mrproper
sendmail configuration on redhat
Couldn 't open PID file /var/run/named/named pid Permission denied
Promise 378 controller
kernel 2 6 and /dev/sound/mixer not found
Problem using up2date
mrtg step by step howto/configuration for a newbie?
Compiling and Installing Kernel 2 6
Can 't locate module ppp0, can 't locate module ppp compress 21
HOW I CAN MAKE BOOTABLE FLOPPY DISKET
Lotus Notes under Wine
/etc/security/limits conf question
Intel E/1000 driver
Command stream end of file while reading
rpm database corrupt
qla2300 modules
 
Groupd and User 's Group Changing

Groupd and User 's Group Changing

2003-03-15       - By Cameron Simpson

 Back
Reply:     1     2     3  

On 11:26 14 Mar 2003, Nestor Waldyd <nwaldyd@(protected)> wrote:
| I really don't have a good definition of what a group is in Linux... Would
you please give me one? What i know
| is that a group is a set of users, but how can i change an user's group?

A group is a set of users, but the sets need not be disjoint.  A user may
be a member of several groups for access to various things.

The mapping is mostly in the file /etc/group, whihc is a list of group
names, group ids (the internal numeric values used to represent each
group) and the users in each.

At any given time a process has
  - a user id (uid)
  - a primary group id
  - a list of secondary groups ids

The uid and primary gid come from the /etc/passwd file.
The secondary gids come from the /etc/group file.

There's nothing special about the primary versus secondary gids; the
primary gid dates from an early revision of UNIX where there was only the
primary gid and no secondaries; the eatra groups were a BSD innovation,
now universal.

When accessing a file exactly _one_ of the three permission groups on the
file are considered:

  - if the user id of the file matches the user id of file
   then the first (user) set of permissions are used

  - otherwise, if the gid of the file matches one of the gids of the
   process, the second set is used

  - otherwise, the third ("other") set is used

Cheers,
--
Cameron Simpson, DoD#743        cs@(protected)    http://www.zip.com.au/~cs/

Success in software development depends on making a carefully planned
series of small mistakes in order to avoid making unplanned large
mistakes.   - Steve McConnell, _Software Project Survival Guide_