You embed the username in the format string in printf. The ${mygroup#*:} strips everything to the left of the ":". Printf will keep repeating until all items in mygroup have been printed.
I need to find all the files that have group Read or Write permission or files that have user write permission.
This is what I have so far:
find . -exec ls -l {} \; | awk '/-...rw..w./ {print $1 " " $3 " " $4 " " $9}'
It shows me all files where group read = true, group write = true... (5 Replies)
Experts,
I know when I use id it shows only the primary group information for the given user, and that info comes from passwd file. When I use groups it shows all groups user are member of, however from where come information given by groups command?
grep fmtt3990 /etc/passwd... (6 Replies)
Gurus
I am trying to capture all the data in /etc/group file in a CSV ,thru a fingerprinting engine.
For hosts having ,unique group names and Ids ,following code works fine.
Trouble starts when on a host,there are multiple groups defined with same name and id.
e.g One of my hosts has 8... (10 Replies)
Hi I need help..........
I have an Sun One Directory server LDIF file with 5000 user entries, I need to change the data to match Test ID's, so I can run a perf test.
I'm way out of my league as I have not done any scripting for 10 years.
There are four entries for each user in the file... (3 Replies)
Hi,
Anyone can help me on how to duplicate privileges and group for useroradb01 to userrootdb01. I have currently using "useroradb01" and create a newly user "userrootdb01".
I want both in the sames privileges and group. Please see the existing users list below;
drwxr-xr-x 53 useroradb01... (0 Replies)
Hi,
We now have a Samba or Winbind issue. The Linux client under RHEL6 can not get Windows' AD sub-domain info. See the following output please. The main domain 'Global' is shown online, but the sub-domain 'Europe' and 'Asia' are shown offline although they are online.
Commands 'wbinfo -u' and... (0 Replies)
Hi,
In the following output you can see the the user "richard" is a member on the team/group "developers":
# id richard
uid=10247(richard) gid=100361(developers) groups=100361(developers),10053(testers)
but in the following details of the said group (developers), the said user... (3 Replies)
Hi,
I am trying to find files that are more than a gig with this command
find . -size +1073741823c and it just gives me the names of the files. How do i get it to give me the actual size of the files too?
---------- Post updated at 09:41 AM ---------- Previous update was at 09:37 AM... (2 Replies)
Discussion started by: LilyClaro
2 Replies
LEARN ABOUT MOJAVE
group
GROUP(5) BSD File Formats Manual GROUP(5)NAME
group -- format of the group permissions file
DESCRIPTION
The file </etc/group> consists of newline separated ASCII records, one per group, containing four colon ':' separated fields. These fields
are as follows:
group Name of the group.
passwd Group's encrypted password.
gid The group's decimal ID.
member Group members.
The group field is the group name used for granting file access to users who are members of the group. The gid field is the number associ-
ated with the group name. They should both be unique across the system (and often across a group of systems) since they control file access.
The passwd field is an optional encrypted password. This field is rarely used and an asterisk is normally placed in it rather than leaving
it blank. The member field contains the names of users granted the privileges of group. The member names are separated by commas without
spaces or newlines. A user is automatically in a group if that group was specified in their /etc/passwd entry and does not need to be added
to that group in the /etc/group file.
INTERACTION WITH DIRECTORY SERVICES
Processes generally find group records using one of the getgrent(3) family of functions. On Mac OS X, these functions interact with the
DirectoryService(8) daemon, which reads the /etc/group file as well as searching other directory information services to determine groups and
group membership.
FILES
/etc/group
SEE ALSO passwd(1), setgroups(2), crypt(3), getgrent(3), initgroups(3), passwd(5), DirectoryService(8)BUGS
The passwd(1) command does not change the group passwords.
HISTORY
A group file format appeared in Version 6 AT&T UNIX.
Mac OS X July 18, 1995 Mac OS X