1GROUPDEL(8)               System Management Commands               GROUPDEL(8)
2
3
4

NAME

6       groupdel - delete a group
7

SYNOPSIS

9       groupdel [options] GROUP
10

DESCRIPTION

12       The groupdel command modifies the system account files, deleting all
13       entries that refer to GROUP. The named group must exist.
14

OPTIONS

16       The options which apply to the groupdel command are:
17
18       -f, --force
19           This option forces the removal of the group, even if there's some
20           user having the group as the primary one.
21
22       -h, --help
23           Display help message and exit.
24
25       -R, --root CHROOT_DIR
26           Apply changes in the CHROOT_DIR directory and use the configuration
27           files from the CHROOT_DIR directory.
28
29       -P, --prefix PREFIX_DIR
30           Apply changes in the PREFIX_DIR directory and use the configuration
31           files from the PREFIX_DIR directory. This option does not chroot
32           and is intended for preparing a cross-compilation target. Some
33           limitations: NIS and LDAP users/groups are not verified. PAM
34           authentication is using the host files. No SELINUX support.
35

CAVEATS

37       You may not remove the primary group of any existing user. You must
38       remove the user before you remove the group.
39
40       You should manually check all file systems to ensure that no files
41       remain owned by this group.
42

CONFIGURATION

44       The following configuration variables in /etc/login.defs change the
45       behavior of this tool:
46
47       MAX_MEMBERS_PER_GROUP (number)
48           Maximum members per group entry. When the maximum is reached, a new
49           group entry (line) is started in /etc/group (with the same name,
50           same password, and same GID).
51
52           The default value is 0, meaning that there are no limits in the
53           number of members in a group.
54
55           This feature (split group) permits to limit the length of lines in
56           the group file. This is useful to make sure that lines for NIS
57           groups are not larger than 1024 characters.
58
59           If you need to enforce such limit, you can use 25.
60
61           Note: split groups may not be supported by all tools (even in the
62           Shadow toolsuite). You should not use this variable unless you
63           really need it.
64

FILES

66       /etc/group
67           Group account information.
68
69       /etc/gshadow
70           Secure group account information.
71

EXIT VALUES

73       The groupdel command exits with the following values:
74
75       0
76           success
77
78       2
79           invalid command syntax
80
81       6
82           specified group doesn't exist
83
84       8
85           can't remove user's primary group
86
87       10
88           can't update group file
89

SEE ALSO

91       chfn(1), chsh(1), passwd(1), gpasswd(8), groupadd(8), groupmod(8),
92       useradd(8), userdel(8), usermod(8).
93
94
95
96shadow-utils 4.9                  11/19/2021                       GROUPDEL(8)
Impressum