Linux Comm Groupadd
# Linux groupadd Command
[ Linux Command Manual](#)
The groupadd command is used to create a new group. The information of the new group will be added to the system files.
Related files:
* /etc/group: Group account information.
* /etc/gshadow: Secure group account information.
* /etc/login.defs: Shadow password suite configuration.
### Syntax
The syntax format for the groupadd command is as follows:
groupadd [-g gid ] group
**Parameter Description:**
* -g: Specify the **id** for the new group;
* -r: Create a system group, with a group ID less than 500;
* -K: Override the configuration file **/etc/login.defs**;
* -o: Allow adding a group with a non-unique group ID.
* -f, --force: If the specified group already exists, this option will cause the command to exit with a success status. When used with -g, and the specified GID_MIN already exists, another unique GID is selected (i.e., -g is disabled).
### Example
Create a new group and add a group ID.
#groupadd -g 344
At this time, an entry with group ID (GID) 344 is created in the /etc/group file.
[ Linux Command Manual](#)
YouTip