name resolution problems
I have to change name resolution for RedHat 5 system so that the name will be resolved to "real" IP address ( assigned to eth0) vs. loopback. I have dns server from my provider, so in /etc/nsswitch.conf resolution via /etc/hosts is first, and via dns service second
hosts: files dns
and I changed "/etc/hosts":
#192.168.1.19 is assigned to eth0
192.168.1.19 myhost.mydomain.com myhost
"hostname -f" now returns "myhost.mydomain.com" but is it enough to assume that name resolution working?
The application software still fails due to name resolution problems... Is there anything else i should do ?
Also, how can i set /etc/hosts name assignment for dynamic ( DHCP assigned) address, vs. static?
What is the application software and what is the error message it gives?
on your RH5 system if you get eth0 IP from DHCP you only need to put your hostname in 127.0.0.1 entry along with the 'localhost'. like this,
127.0.0.1 localhost your-rh5-hostname
/etc/hostname sets your hostname at boot time.
/etc/resolv.conf domain entry sets the dnsdomainname at boot time.
the name-to-ip lookup of your system local application will use the 127.0.0.1 address, and for your remote application they need to relay on the DNS that is integrated with the DHCP where DHCP will dynamically update the DNS server on IP assignment and return.
|All times are GMT -5. The time now is 04:19 PM.|