1752771 Members
5044 Online
108789 Solutions
New Discussion юеВ

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 6
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.