LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Red Hat (https://www.linuxquestions.org/questions/red-hat-31/)
-   -   how to remove a user from secondary group using command line (https://www.linuxquestions.org/questions/red-hat-31/how-to-remove-a-user-from-secondary-group-using-command-line-739095/)

iamjayanth 07-10-2009 01:49 AM

how to remove a user from secondary group using command line
 
Sir ,

I have a user 'jai' and his primary group is 'jai'. This user is also a member of group 'student'. I want to remove this user from student group. Can i do this from command line.

colucix 07-10-2009 02:17 AM

Code:

gpasswd -d jai student
or just edit the file /etc/group and remove jai from the list of users in the student group.

iamjayanth 07-10-2009 11:12 PM

Thanks colucix...It worked wonderfully...


All times are GMT -5. The time now is 11:18 PM.