Easy Tutorial
❮ Linux Comm Fgrep Linux Comm Mcopy ❯

Linux groupmod Command

Linux Command Manual

The Linux groupmod command is used to change the group ID or name.

When you need to modify the group ID or name, you can use the groupmod command to accomplish this task.

Syntax

groupmod [-g &lt;group ID> <-o>][-n &lt;new group name>][group name]

Parameters:

Example

Modifying the group name

[[email protected] ~]# groupadd linuxso 
[[email protected] ~]# tail -1 /etc/group 
linuxso:x:500: 
[[email protected] ~]# tail -1 /etc/group 
linuxso:x:500: 
[[email protected] ~]# groupmod -n linux linuxso 
[[email protected] ~]# tail -1 /etc/group 
linux:x:500:

Linux Command Manual

❮ Linux Comm Fgrep Linux Comm Mcopy ❯