How to create and delete groups in Linux || groupadd || groupdel

preview_player
Показать описание
#groupadd #groupdel #linux #linuxessentials

How to create a group using groupadd command in Linux?
to create a new user use the groupadd command. The syntax is:
#groupadd groupname
The groupadd command can be executed only with admin permissions. The details of all users are available in /etc/group file
The options available with groupadd are
-g: to assign user to an existing group
-0: to assign same GID to multiple groups

The command to delete a user is groupdel. Syntax:
#groupdel groupname
Again this command can be executed only by the admin

Рекомендации по теме
Комментарии
Автор

We would force the removal by using the -f option.

nacirarmando
Автор

usermod cars -g 3030, what i use is groupdel -f G1,

ponnuponnu
Автор

groupdel -f G1
groupdel G1 -f
it doesn't matter if the option comes first or last

HussainAlsami
Автор

sudo groupdel G1, if it is wrong say the correct answer sir

rrajeswari