- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- name resolution ?
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 02:56 AM
12-07-2001 02:56 AM
name resolution ?
When I do an nslookup of host y (which has an entry in the hosts file), I get this message.
$ nslookup y
*** Can't find server name for address z.z.z.z: Timed out
Using /etc/hosts on: hostname
looking up FILES
Name: y.xx.xx.com
Address: x.x.x.x
Aliases: y
$
Why does the system first try to find the server name of z.z.z.z ?
This z.z.z.z. is the first nameserver entry in the resolv.conf file .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 03:05 AM
12-07-2001 03:05 AM
Re: name resolution ?
Check /etc/nsswitch.conf to see in what order your system will try to resolve names.
If DNS is in there, look at /etc/resolv.conf for the DNS server (probably z.z.z.z)
The easiest way to modify this nsswitch file is with SAM->Networking and Communications->Name Service Switch.
Remove DNS from that switch if you don't need DNS.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 03:09 AM
12-07-2001 03:09 AM
Re: name resolution ?
hosts: files [NOTFOUND=continue] dns
See the nsswitch.conf(4) man page for more details.
The timeout on z.z.z.z means that name server is not responding to your request. Is this IP address in /etc/resolv.conf the correct address of your name server? If you don't need DNS, move the resolv.conf file aside.
Regards,
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 03:14 AM
12-07-2001 03:14 AM
Re: name resolution ?
Edit /etc/nsswitch.conf. Modify the hosts line like:
hosts: files [NOTFOUND=continue] dns
or (eventually) nis.
Make sure you have connection to your primary nameserver.
E.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 05:00 AM
12-07-2001 05:00 AM
Re: name resolution ?
hosts: files [NOTFOUND=continue] dns
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 05:04 AM
12-07-2001 05:04 AM
Re: name resolution ?
nslookup follows the hosts entry defined in the nsswitch.conf file for discovering the address or hostname of a host. That's why nslookup first tries to contact the nameserver on execution. As others have pointed out,if you swap the host entry to put "files" first, it will look for /etc/hosts file (and if it cannot find the entry , it will try contacting the name server).
If you are not using namesever, then you can remove the nameserver entry. OR if you have a secondary nameserver, you can add that entry too in the resolv.conf file. That way, it will try contacting the secondary name server.
HTH
raj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 05:07 AM
12-07-2001 05:07 AM
Re: name resolution ?
Cheers,
Steve
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 05:16 AM
12-07-2001 05:16 AM
Re: name resolution ?
The nsswith.conf is set to check the hosts file. In the hosts file the entry for host Y is present.
When doing an nslookup on y, one should expect that the system would immediately lookup the hostname in the hosts file ... but no it tries to resolve first an IP address. This doesn't seem normal.
As the last participant points out : maybe the permissions on nsswitch.conf are set wrong. I will check this asap but right now, due to network problems I cannot connect to the system.
Keep you further informed.
Franky
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 05:45 AM
12-07-2001 05:45 AM
Re: name resolution ?
Try this entry in your /etc/nsswitch.conf file,
hosts: files [NOTFOUND=continue, TRYAGAIN=continue] DNS
Hope this helps.
Regds
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-07-2001 06:07 AM
12-07-2001 06:07 AM
Re: name resolution ?
I don't like that behaviour either but the man page says:
"nslookup is a program to query Internet domain name servers. nslookup has been extended to follow the configured name resolution algorithm of the host and to query NIS, as well as, DNS and host tables."
Seems nslookup was designed for DNS and retro-fitted for files and nis, etc. So I guess it is normal for it to connect to a DNS server even if resolving with files first.
You z.z.z.z nameserver was unavailable but nslookup had to wait to timeout before continuing.
It could be worse. I had a co-worker who was a sysadmin (I think in name only) who listed every nameserver known to him in his resolv.conf files without regard to whether or not they were behind firewalls, taken out of service, or whatever. It was amazing the things we found after he took a managerial position with another company!
Darrell
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-10-2001 02:58 AM
12-10-2001 02:58 AM
Re: name resolution ?
nslookup always looks first at the DNS even when the nsswitch.conf tells the system to look at the hosts file first.
Answering another question : the nsswitch.conf had read and write permissions for everybody.
This issue can be closed.
Thanks to all.
Franky