/etc/resolv.conf vs _CS_RESOLVE

I understand that the TCP/IP resolver is supposed to use the
confstr() _CS_RESOLVE to locate a nameserver. This seems to work
fine with some applications, but oddly enough it doesn’t work
for nslookup. When I copy the _CS_RESOLVE data into /etc/resolv.conf,
nslookup starts behaving normally. Is there a reason for this?
Are there other applications that are thusly afflicted?

-Norton Allen

Norton Allen <allen@huarp.harvard.edu> wrote:

I understand that the TCP/IP resolver is supposed to use the
confstr() _CS_RESOLVE to locate a nameserver. This seems to work
fine with some applications, but oddly enough it doesn’t work
for nslookup. When I copy the _CS_RESOLVE data into /etc/resolv.conf,
nslookup starts behaving normally. Is there a reason for this?
Are there other applications that are thusly afflicted?

Yes, this is confusing. “nslookup” using it’s own resolver
code then others, which only check /etc/resolv.conf.

In general, all utils from bind package have their own
resolver (well, same resolver as nslookup used). However,
I don’t think we release any utils from bind package
other then nslookup.

This will be merged into same resolver in a feature release.

-xtang

Thanks. That makes sense.