groupdel command in Linux with examples
groupdel command is used to delete a existing group. It will delete all entry that refers to the group, modifies the system account files, and it is handled by superuser or root user.
Syntax:
groupdel [options] GROUP
Files:
- /etc/group : It contains the account information of the Group.
- /etc/gshadow : It contains the secure group account information.
Exit values: This command exits with the following values.
- 0: Success
- 2: Invalid Command Syntax.
- 6: Specified group doesn’t exist.
- 8: Can’t remove users primary group.
- 10: Can’t update group file.
Options:
- -f –force: It used to delete a group even if it is the primary group of a user.
- -h –help: It displays the help message and exit.
- -R –root: It apply the changes in the CHROOT_DIR directory. Also, it uses the configuration files from the CHROOT_DIR directory.
- cvs command in Linux with Examples
- dir command in Linux with examples
- id command in Linux with examples
- ps command in Linux with Examples
- sum command in Linux with Examples
- man command in Linux with Examples
- cpp command in Linux with Examples
- mv command in Linux with examples
- help Command in Linux with examples
- Cat command in Linux with examples
- which command in Linux with examples
- apt command in linux with examples
- if command in linux with examples
- fc Command in Linux with Examples
- w command in Linux with Examples
Recommended Posts:
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.




