Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 11-29-2010, 09:54 AM   #1
LQ Newbie
Registered: Jun 2007
Posts: 1

Rep: Reputation: 0
how to view user admins assigned in a group

Hello Linux Gurus,

Once you add a user(s) to be an administrator on the group you've created using gpasswd command (for example, i've added joe (username) as administrator for payroll (groupname) group using gpasswd); is there any way for me to view the list of users that I've assigned as administrators for a particular group? if so, what is the command line that i need to run?

Thanks =)
Old 11-29-2010, 09:59 AM   #2
LQ Guru
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Hi -

man 1 groups
GROUPS(1)                        User Commands                       GROUPS(1)

       groups - print the groups a user is in

       groups [OPTION]... [USERNAME]...

       --help display this help and exit

              output version information and exit

       Same as id -Gn.  If no USERNAME, use current process.

       Written by David MacKenzie.

       Report bugs to <>.

       Copyright © 2004 Free Software Foundation, Inc.
       This is free software; see the source for copying conditions.  There is
       NO warranty; not even for MERCHANTABILITY or FITNESS FOR  A  PARTICULAR

       The  full  documentation  for groups is maintained as a Texinfo manual.
       If the info and groups programs are properly installed  at  your  site,
       the command

              info groups

       should give you access to the complete manual.

groups 5.97                      February 2010                       GROUPS(1)

Last edited by paulsm4; 11-29-2010 at 10:00 AM.
Old 11-29-2010, 10:20 PM   #3
LQ Guru
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.10, Centos 7.3
Posts: 17,548

Rep: Reputation: 2423Reputation: 2423Reputation: 2423Reputation: 2423Reputation: 2423Reputation: 2423Reputation: 2423Reputation: 2423Reputation: 2423Reputation: 2423Reputation: 2423
If you want the list of users in a group

grep <groupname> /etc/group

Another way to tell what groups a user is in is the 'id' cmd.

Last edited by chrism01; 11-29-2010 at 10:23 PM.


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 Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Looking for a group of Admins auximini General 2 10-02-2009 04:56 PM
What group is my user ID assigned to? runnerpaul Solaris / OpenSolaris 2 09-26-2008 06:47 AM
permissions not recognizing group or assigned users to group blckspder Linux - Server 1 07-28-2008 10:32 AM
ID created with assigned group is not display in /etc/group file dwarf007 Linux - Security 2 08-21-2007 10:39 PM
Unable to view user/group console? bottomsup6 Linux - Software 1 07-28-2004 11:59 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:47 AM.

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