February 2012
Intermediate to advanced
1184 pages
37h 17m
English
getgrnam NAMEThis function looks up a group file entry by group name. The return value in list context is:
# 0 1 2 3
($name, $passwd, $gid, $members) =
getgrnam("wheel");where $members contains a
space-separated list of login names that are members of the group. If
you want to do this repeatedly, consider caching the data in a hash
using getgrent.
In scalar context, getgrnam
returns only the numeric group ID. The User::grent module supports a by-name interface to this function. See
getgrnam(3).
Read now
Unlock full access