- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: command host returns value "reached"
Categories
Company
Local Language
Forums
Discussions
Knowledge Base
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Knowledge Base
Forums
Discussions
- Cloud Mentoring and Education
- Software - General
- HPE OneView
- HPE Ezmeral Software platform
- HPE OpsRamp
Knowledge Base
Discussions
Forums
Discussions
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
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
05-26-2009 12:18 AM
05-26-2009 12:18 AM
I try to determine ip address of the host, using command $host in HP-UX.
But it returns value "reached" instead of the ip address.
Does anybody clarify, where I am wrong?
DNS is not configured - I use /etc/hosts only.
So, file /etc/resolv.conf is absent.
File /etc/nsswitch.conf has the next order:
hosts files (ONLY!).
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-26-2009 12:34 AM
05-26-2009 12:34 AM
Solutionfrom the man pages
nslookup(1)
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.
host(1)
host is a simple utility for performing DNS lookups.
acording to hese informations, the host command cannot query files for resolution.
instead of using host, prefer using nslookup.
BR,
Cedrick Gaillard
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-26-2009 12:56 AM
05-26-2009 12:56 AM
Re: command host returns value "reached"
Is it possible to obtain ip address of the host without any other information, using command nslookup?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-26-2009 01:09 AM
05-26-2009 01:09 AM
Re: command host returns value "reached"
NS_RESULT="$(LANG=C nslookup
[ "$?" = "0" ] && {
IP="$(echo "$NS_RESULT" |grep "^Address:" |tail -1 |awk '{print $2}')"
}
BR,
Cedrick Gaillard
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-26-2009 01:33 AM
05-26-2009 01:33 AM
Re: command host returns value "reached"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-26-2009 01:35 AM
05-26-2009 01:35 AM
Re: command host returns value "reached"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-26-2009 01:51 AM
05-26-2009 01:51 AM
Re: command host returns value "reached"
don't forget do assign points when you have answers.
BR,
Cedrick Gaillard