Erlang reads /etc/host.conf on linux systems, gentoo doesn't have a /etc/host.conf dile to control the behaviiour of the resolver. It only has /etc/nsswitch.conf (which by the way makes sence) Having the old BSD file /etc/host.conf as well as nsswitch.conf is strange. redhat and suse has both .... Reproducible: Always Steps to Reproduce: 1.to inet:gethostbyname("www.yahoo.com"). in the shell 2. 3. Actual Results: since erl only reads /etc/host.conf (and never nsswitch.conf) it only uses files as resolv method and doesn't even invoke the resolver client. Erlang reads /etc/host.conf on linux systems, gentoo doesn't have a /etc/host.conf dile to control the behaviiour of the resolver. It only has /etc/nsswitch.conf (which by the way makes sence) Having the old BSD file /etc/host.conf as well as nsswitch.conf is strange. redhat and suse has both ....
Created attachment 13277 [details, diff] make erlang read nsswitch.conf
Hi Claes. Thanks for the update! >gentoo doesn't have a /etc/host.conf dile to control the behaviiour of the >resolver. It only has /etc/nsswitch.conf (which by the way makes sence) Yes :), IIRC /etc/host.conf is considered deprecated with newer kernels. Of course distributios trying to be automatic install everything "just in case", so thius might explain Red Hat having it.. However I am a bit confused: you say that your patch is supposed to make erlang read nsswitch.conf (which should cause it obey whatever resolution order is defined on system), but I see it actually deleting nsswitch support. Are you sure you included the intended and not a reverse patch? George
Created attachment 13743 [details, diff] better (non rversed) patch I'm an idiot, the patch was reversed. Sorry.
Hi Claes. Thanks for the update! Unfortunately looks like bugzilla did not send notification email (yet again), just noticed your resubmission. I incorporated the patch and issued a new revision - 9c-r1. The ebuild is committed and keymasked. Please test. George
Reclosing the bug