[CentOS] Shell script to list group members
Tim Alberts
talberts at msiscales.comTue Sep 23 23:11:42 UTC 2008
- Previous message: [CentOS] Shell script to list group members
- Next message: [CentOS] Shell script to list group members
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Barry Brimer wrote: > With spaces separating groups: > > egrep -e '^groupname:' /etc/group | awk -F : '{ print $4 }' | sed -e 's/,/ /g' > > With commas separating groups: > > egrep -e '^groupname:' /etc/group | awk -F : '{ print $4 }' I'm sorry, I didn't specify, I'm using LDAP for user/group management. Ideally a command like 'groups' would be nice, except it would be the inverse, it would print the users in a group, not the groups a user belongs to. -------------- next part -------------- A non-text attachment was scrubbed... Name: talberts.vcf Type: text/x-vcard Size: 337 bytes Desc: not available URL: <http://lists.centos.org/pipermail/centos/attachments/20080923/56d19211/attachment-0001.vcf>
- Previous message: [CentOS] Shell script to list group members
- Next message: [CentOS] Shell script to list group members
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the CentOS mailing list