Each user has a user group, the system can be centrally managed for all users in a user group. Different Linux systems have different requirements for user groups,
As Linux users under the user group belongs to its namesake, the user groups are created at the same time when creating a user.
Management user group involves adding user groups, delete and modify. Increase the group, delete and modify actually on the / etc / group update files.
groupadd Add Group
1. The basic syntax
groupadd group name
2. Case practical operation
( 1 ) Add a xitianqujing group
[root@hadoop101 opt]#groupadd xitianqujing
groupdel delete group
1. The basic syntax
groupdel group name
2. Case practical operation
( 1 ) Delete xitianqujing group
[root@hadoop101 opt]# groupdel xitianqujing
groupmod Modify Group
1. The basic syntax
groupmod -n new group name of the old group name
2. Option Description
Table 1-25
Options |
Functional Description |
-n < new group name > |
The new group name is specified workgroup |
3. Case practical operation
( 1 ) Modify atguigu group name atguigu1
[Root @ hadoop101 ~] #groupadd xitianqujing
[Root @ hadoop101 ~] # groupmod -n xitian xitianqujing
cat / etc / group to see which group created
1 . Basic operations
[root@hadoop101 atguigu]# cat /etc/group