REVNETGROUP(8)
๐ REVNETGROUP โ the revnetgroup page, but make it make sense ๐
okay so bestie, you found the revnetgroup manual, and it's from the NIS Reference Manual, section 8 (that's the sysadmin-y section, the one with the big-girl tools ๐
). Buckle up, it's short but it's important, fr fr.
โจ NAME โจ
revnetgroup โ generate reverse netgroup data ๐
๐ธ SYNOPSIS ๐ธ
/usr/lib/yp/revnetgroup [-u | -h]
๐ฆ DESCRIPTION ๐ฆ
okay so revnetgroup is that girl who takes the standard input, reads it in netgroup(5) format, and flips it into what we call reverse netgroup form. and the way that works is so satisfying, let me explain ๐
- in the original file, you see netgroup memberships described as "which members live inside this particular group"
- in reverse netgroup format, it's the other way around: it says which groups are associated with a particular member
and why do we care? because this info is used to generate the netgroup.byuser and netgroup.byhosts NIS maps. those reverse netgroup maps are literally there to speed up netgroup lookups, especially for the innetgr() library function. no cap, that's the whole point ๐โโ๏ธ๐จ
revnetgroup prints its results on the standard output. and ngl, it's usually only called by /var/yp/Makefile when it's rebuilding the NIS netgroup maps โ so it's giving backstage crew energy, not main character energy. iconic either way ๐
๐ OPTIONS ๐
-uโ generatenetgroup.byuseroutput; only the username information in the original netgroup file gets processed โจ-hโ generatenetgroup.byhostoutput; only the hostname information in the original netgroup file gets processed ๐
heads up bestie: it's [-u | -h] โ the pipe means pick one, not both ๐ซถ
๐ FILES ๐
/var/yp/Makefileโ the Makefile to build the NIS databases. yes, that Makefile. the one doing all the summoning ๐ฎ/etc/netgroupโ the default netgroup database file. this file is most often found only on the NIS master server, so if you don't see it on your machineโฆ that's not you being messy, that's just how it's set up ๐
๐ SEE ALSO ๐
getnetgrent(3), netgroup(5), ๐ธ
๐ AUTHOR ๐
revnetgroup was written by Thorsten Kukuk <kukuk@linux-nis.org>. absolute legend, we stan ๐ซถโจ
and that's the whole page, bestie!! this beauty comes from the NIS Reference Manual and the page is dated 12/31/2020, filed under REVNETGROUP(8). go forth and reverse those netgroups, you've got this ๐๐๐ฆ
๐ฆ where this page comes from
- debian bookworm: ypserv 4.2-1+b2 ยท GPL-2.0-only
- debian trixie: ypserv 4.2-2+b2 ยท GPL-2.0-only
- ubuntu jammy: ypserv 4.1-2 ยท GPL-2.0-only
- ubuntu noble: ypserv 4.2-2build2 ยท GPL-2.0-only
- ubuntu questing: ypserv 4.2-2build2
- ubuntu resolute: ypserv 4.2-3 ยท GPL-2.0-only
- ubuntu stonking: ypserv 4.2-3build1 ยท GPL-2.0-only
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms