Delete Group in Linux

Delete Group in Linux

In Linux system, a group is a collection of users which have the same permissions on files and directories. When working as system administrator, might need to delete a group. This tutorial shows how to do that in Linux.

The groupdel command allows to delete a group. For example, run the following command to delete a group named test-group:

sudo groupdel test-group

On success, the command does not print any output. If the group doesn't exist, command prints error.

Verify that group is deleted:

cat /etc/group | grep -w test-group

Leave a Comment

Cancel reply

Your email address will not be published.