- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: nslookup
Operating System - HP-UX
1748165
Members
3834
Online
108758
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
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
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- 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
тАО11-16-2010 12:12 PM
тАО11-16-2010 12:12 PM
How can nslookup function (access DNS) if there is no /etc/nsswitch.conf file?
I have multiple HP-UX servers (11i and 11iv2)
Some with nsswitch.conf, some without.
Presense of nsswitch.conf seems to change nothing.
Some have the DNS server in their /etc/hosts,
some do not.
Adding or removing DNS server from /etc/hosts seems to change nothing.
One server has no nsswitch.conf, no DNS entry in /etc/hosts, but for "sys" group users, nslookup works fine.
Not for anyone else.
ftp doesn't resolve the same as nslookup
traceroute resolves fine for everyone.
ping resolves fine for everyone.
I have multiple HP-UX servers (11i and 11iv2)
Some with nsswitch.conf, some without.
Presense of nsswitch.conf seems to change nothing.
Some have the DNS server in their /etc/hosts,
some do not.
Adding or removing DNS server from /etc/hosts seems to change nothing.
One server has no nsswitch.conf, no DNS entry in /etc/hosts, but for "sys" group users, nslookup works fine.
Not for anyone else.
ftp doesn't resolve the same as nslookup
traceroute resolves fine for everyone.
ping resolves fine for everyone.
Solved! Go to Solution.
- Tags:
- nslookup
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-16-2010 12:24 PM
тАО11-16-2010 12:24 PM
Re: nslookup
/etc/nsswitch.conf defines the policy for nslookup. Whether the command to be looked up files or dns or nis etc.
Alternatively, you can specify all these info in .nslookuprc file in user's home directory using set command.
Read man pages.
man nslookup.
Alternatively, you can specify all these info in .nslookuprc file in user's home directory using set command.
Read man pages.
man nslookup.
Regards
Shibin
Shibin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-16-2010 12:57 PM
тАО11-16-2010 12:57 PM
Solution
If no /etc/nsswitch.conf is present on the system, then there are default policies that are used by the system. According to the nslookup man page:
The library functions contain compiled-in default entries that are used if the appropriate entry in nsswitch.conf is absent or
syntactically incorrect. The entries are as follows:
[...]
hosts: dns [NOTFOUND=return] nis [NOTFOUND=return] files
[...]
So, that explains part of the behavior.
The other part of the equation is the /etc/resolv.conf file. The DNS servers that are used to look up host info are specified there.
The DNS server being in the /etc/hosts file will not accomplish much.
>>One server has no nsswitch.conf, no DNS
>>entry in /etc/hosts, but for "sys" group
>>users, nslookup works fine.
I suspect in this case that you have an /etc/resolv.conf file and that the permissions allow reading of the file by the owner and group, which are probably root and sys respectively (the defaults).
To resolv this, you need to make the file world READable (you don't need world write or world execute).
chmod o+r /etc/resolv.conf
The library functions contain compiled-in default entries that are used if the appropriate entry in nsswitch.conf is absent or
syntactically incorrect. The entries are as follows:
[...]
hosts: dns [NOTFOUND=return] nis [NOTFOUND=return] files
[...]
So, that explains part of the behavior.
The other part of the equation is the /etc/resolv.conf file. The DNS servers that are used to look up host info are specified there.
The DNS server being in the /etc/hosts file will not accomplish much.
>>One server has no nsswitch.conf, no DNS
>>entry in /etc/hosts, but for "sys" group
>>users, nslookup works fine.
I suspect in this case that you have an /etc/resolv.conf file and that the permissions allow reading of the file by the owner and group, which are probably root and sys respectively (the defaults).
To resolv this, you need to make the file world READable (you don't need world write or world execute).
chmod o+r /etc/resolv.conf
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-16-2010 01:04 PM
тАО11-16-2010 01:04 PM
Re: nslookup
I'll give you a 9 for effort, but you were too slow.
We discovered the permission error on /etc/resolv.conf just moments before you responded
We discovered the permission error on /etc/resolv.conf just moments before you responded
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP