wbinfo fails when called from idmap tdb2 script

Volker Lendecke Volker.Lendecke at SerNet.DE
Tue Mar 29 19:51:25 UTC 2016

On Tue, Mar 29, 2016 at 12:44:02PM -0700, Joachim Achtzehnter wrote:
> With the unset in the script it is working. Thanks!
> Would it make sense to do this inside the script module instead of requiring
> script authors to discover this obscure work-around?
> I tried adding winbind_on() and winbind_off() calls before/after the call to
> file_lines_pload() in "idmap_script.c", but this doesn't seem to help. The
> script sill sees the _NO_WINBINDD variable set to the value "1". I'm not
> sure how this can be?

Not sure either. But I would argue that this is more a documentation than
a code problem. Calling wbinfo -s from within an idmap script should be
a very conscious decision, as careless use of nsswitch functions like
getpwnam (even ls -l would do that) can very easily lead to recursive
calls. So we need to protect winbind from itself. Agreed, this could be
better documented. Feel free to send in a wording and/or a patch.


SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
phone: +49-551-370000-0, fax: +49-551-370000-9
AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen
http://www.sernet.de, mailto:kontakt at sernet.de

More information about the samba-technical mailing list