GROUPMEMS(8)
๐ GROUPMEMS(8) โ like, the manual page for groupmems bestie ๐
okay so you wanna know about groupmems? it lives in the System Management Commands corner of the manual, section 8, and it's genuinely one of the cutest little tools in the shadow suite. let's get into it ๐ซถ
โจ NAME โจ
groupmems โ administer members of a user's primary group ๐
๐ธ SYNOPSIS ๐ธ
groupmems -a user_name | -d user_name | [-g group_name] | -l | -p
๐ฆ DESCRIPTION ๐ฆ
so groupmems is that girl who lets a user administer their own group membership list WITHOUT needing superuser privileges. no sudo, no root, no drama. she's for systems that set users up so they live in their own name-sake primary group โ think guest / guest, that kinda setup. iconic honestly ๐
but bestie listen โ only the superuser, as administrator, can use groupmems to alter the memberships of other groups. your own group? fine. someone else's? not your business, respectfully ๐
๐ OPTIONS ๐
the options that apply to the groupmems command are, in order, no skips, no cuts:
-a,--adduser_name โ add a user to the group membership list โจ- if the
/etc/gshadowfile exist, and the group has no entry in the/etc/gshadowfile, a new entry will be created.
- if the
-d,--deleteuser_name โ delete a user from the group membership list ๐๏ธ- if the
/etc/gshadowfile exist, the user will be removed from the list of members and administrators of the group. - if the
/etc/gshadowfile exist, and the group has no entry in the/etc/gshadowfile, a new entry will be created.
- if the
-g,--groupgroup_name โ the superuser can specify which group membership list to modify ๐-h,--helpโ display help message and exit ๐-l,--listโ list the group membership list ๐-p,--purgeโ purge all users from the group membership list ๐งน- if the
/etc/gshadowfile exist, and the group has no entry in the/etc/gshadowfile, a new entry will be created.
- if the
-R,--rootCHROOT_DIR โ apply changes in the CHROOT_DIR directory and use the configuration files from the CHROOT_DIR directory. only absolute paths are supported. no SELINUX support. ๐ซ
๐ SETUP ๐
okay so on this operating system, the groupmems executable is not setuid, and regular users cannot use it to manipulate the membership of their own group. that's just how it is here, bestie ๐ญ
๐ CONFIGURATION ๐
these are the config variables in /etc/login.defs that change how this tool behaves:
MAX_MEMBERS_PER_GROUP (number) โญ
maximum members per group entry. when the max is reached, a new group entry (line) is started in /etc/group โ with the same name, same password, and same GID. same girl, new line ๐
the default value is 0, meaning that there are no limits in the number of members in a group.
this feature (split group) permits to limit the length of lines in the group file. this is useful to make sure that lines for NIS groups are not larger than 1024 characters. lowkey a niche need but okay ๐
if you need to enforce such limit, you can use 25.
Note: split groups may not be supported by all tools (even in the Shadow toolsuite). you should not use this variable unless you really need it. fr fr, don't touch it for fun ๐ซฃ
๐ FILES ๐
/etc/groupโ group account information ๐/etc/gshadowโ secure group account information ๐
๐ SEE ALSO ๐
chfn(1), chsh(1), passwd(1), groupadd(8), groupdel(8), useradd(8), userdel(8), usermod(8).
that's the whole page, bestie, no cap ๐ง
this little love letter to groupmems ships with shadow-utils 4.19.0, dated 04/29/2026 โ so if you're reading this, hi from the future, hope your group membership is exactly how you want it ๐๐
โจ
๐ฆ where this page comes from
- fedora 44: shadow-utils 2:4.19.0-7.fc44 ยท BSD-3-Clause AND GPL-2.0-or-later
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms