Bug 11235
Summary: | ypbind won't find servers from /etc/hosts | ||
---|---|---|---|
Product: | [Retired] Red Hat Linux | Reporter: | mandrews |
Component: | ypbind | Assignee: | Preston Brown <pbrown> |
Status: | CLOSED NOTABUG | QA Contact: | |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | 6.2 | CC: | laroche |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2000-10-16 19:20:39 UTC | Type: | --- |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
mandrews
2000-05-05 01:37:51 UTC
assigned to laroche res_gethostbyname by definition only uses the resolver, not /etc/hosts, for name lookup, so there is no problem there. The question is why ypbind is using the res_ function instead of the regular glibc function. I have mailed the author for clarification. *** Bug 11316 has been marked as a duplicate of this bug. *** Answer from the program author: res_gethostbyname in ypbind-mt is only used if we don't have __nss_configure_lookup. The reason is simple: To avoid a deadlock. If we would use gethostbyname, we are not allowed to add "nis" to the hosts entry in /etc/nsswitch.conf. So we only allow IP numbers or use DNS (res_gethostbyname). But if we have __nss_configure_lookup, we can override the rule in /etc/nsswitch.conf to use only /etc/hosts and then DNS. With glibc 2.1 and 2.2 /etc/hosts and DNS should be allowed. Thorsten I.e., this is intentional behaviour. List the IP address of your NIS server if the machine is also a DNS server, or if there is no DNS entry. |