List all the groups to which a user is a member

What is the command to list all the groups to which a user is a member?
tammyfAsked:
Who is Participating?
 
fridomConnect With a Mentor CEO/ProgrammerCommented:
groups user_name

Regards
Friedrich
0
 
biraCommented:
cat /etc/group |grep username
0
 
biraCommented:
or for better reading,

 cat /etc/group|grep bira|cut -f1 -d':'
0
 
biraCommented:
change bira by username in the last post
0
 
tammyfAuthor Commented:
This did not work.  I did not mention that this is for an Xserve and maybe I need different commands?
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.