cancel
Showing results for 
Search instead for 
Did you mean: 

changing group

 
madhudeepan
Frequent Advisor

changing group

i created a user in a group named oper, i need to change the user to group named manage,, how can i do it....
6 REPLIES
Nido
Trusted Contributor

Re: changing group

Hi,

from the man page of `chown`
chown [-h] [-R] owner[:group] file

Read the man page and you'll get a lot more info.

Cheers!!
" Let Villagers Be Happy!! "
Michal Kapalka (mikap)
Honored Contributor

Re: changing group

hi,

check this tutorial :

http://www.bga.org/~lessem/psyc5112/usail/tasks/users-groups/users-groups.html

- chapter -> Making changes

see the manpages :

man groupmod

man usermod


mikap
sujit kumar singh
Honored Contributor

Re: changing group

Hi

usermod -g group1 -G group2,group3 username

that shall add the user the group membership of group2 and group3 and primary group as group1.

but these groups haave to exist on the system.

see more usermod manpages for additional things.
regards
sujit
Suraj K Sankari
Honored Contributor

Re: changing group

hi,
See the example below
Change a userâ s primary and secondary group membership
# usermod â g users user1
# usermod â G class,training user1
or
# groupmod -n accounts accts # change accounts to orauser if accts group not exist
# groupmod -g 111 -o dbuser # change group id into 111, if the grp ID 111 is already in use

Suraj
Tarun Kumra
Esteemed Contributor

Re: changing group

Hi,

To change the group of a user run:
usermod -g

To add user in different groups run:
usermod -G


Regards
Tarun
Ganesan R
Honored Contributor

Re: changing group

Hi,

#usermod -g manage
Best wishes,

Ganesh.