NSS and buffer length
Carlos O'Donell
carlos@redhat.com
Tue Jul 7 20:54:08 GMT 2020
On 7/7/20 4:11 PM, Ivan Stana wrote:
> But in the enumeration of groups - the group is not present in the
> output and the buffer size was not increased:
>
>> $ getent group
>>
>> second buffer out of range, buflen: 1024
If the NSS plugin returns NSS_STATUS_TRYAGAIN and ERANGE then
getent should double the buffer size and retry the NSS call.
> The question is what can I do to see the group with many users? Thank
> you for your answers.
It should work. Other plugins make this work successfully.
I would suggest debugging getent directly setting breakpoints at
__nss_getent() and __nss_getent_r() and inside your plugin and
debug the API calls to see why the caller (getent in this case)
doesn't increase the buffer size.
--
Cheers,
Carlos.
More information about the Libc-help
mailing list