Auxiliary Group Membership
Theory
If VOV_USE_INITGROUPS is set, the subtasker calls initgroups(). This is an OS call that sets all (or max 16) auxiliary groups. The resulting list of groups is not cached. Another job will call initgroups() again.
The default is to not call initgroups because it may load the name services too much.
By default, the vovtasker calls the external utility vovgetgroups, which uses the value of VOV_ALARM to decide how long to wait for a reply (default 10 seconds). The VOV_USE_VOVGETGROUPS environment variable can be used to control this behavior:
Set to 0 to disable the call to the external utility and use the getgrent() POSIX API function to find all groups that are valid for a user. If there are more than 16, the list is truncated to the first 16. The list is cached by vovtasker, so only the first job for a user causes traffic with the name services. This is only recommended in small environments, as this method can create significant delays, and even blocking conditions, in complex environments (e.g. Linux with LDAP).
Set to 2 to continue to use the external utility, but instruct the utility to call the getgrent() POSIX API function instead of the default call to getgrouplist(). This is mainly for debugging purposes, since this mode of operation results in slower processing of group information.
History
- Prior to 2016.09 & 2015.09u8
- If VOV_USE_VOVGETGROUPS was set to any value, when a tasker needs to get group data it will use the
vovgetgroups
external utility (a separate executable). This utility is robust to LDAP errors or timeouts which would otherwise cause thegetgrent
library call to hang indefinitely (and block the tasker from issuing further jobs). - 2016.09 & 2015.09u8 and Later Versions
- If VOV_USE_VOVGETGROUPS was set to any value other than 1, it would
behave like pre 2016.09 code and use
getgrent()
. If VOV_USE_VOVGETGROUPS was set to 1, it would usegetgrouplist()
, which is a newer utility (but still old) to get group information with higher performance.