Name
host
Synopsis
host [options
]host
[server
] host [options
]domain
[server
]
Prints information about specified hosts or zones in DNS. Hosts may
be IP addresses or hostnames; host
converts IP
addresses to hostnames by default and appends the local domain to
hosts without a trailing dot. Default servers are determined in
/etc/resolv.conf
. For more information about
hosts and zones, refer to Chapter 1
and Chapter 2 of DNS
and
BIND
(O’Reilly).
Options
-
-a
All, same as
-t
ANY
.-
-c
class
Search for specified resource record class (
in
[ternet],cs
[net],ch
[aos],hs
/hesiod, orany
). Default isin
. Thechaos
andcsnet
classes, although defined in RFC1035, are rejected as invalid classes by thehost
command.-
-C
Print the SOA (start of authority) records for the host.
-
-d
Debugging mode.
-dd
is a more verbose version.-
-l
domain
List all machines in
domain
.-
-r
No recursion. Don’t ask contacted server to query other servers but require only the information that it has cached.
-
-s
Chase signatures back to parent key (
DNSSEC
).-
-t
type
Look for
type
entries in the resource record. Acceptable values fortype
are:a
,ns
,md
,mf
,cnames
,soa
,mb
,mg
,mr
,null
,wks
,ptr
,hinfo
,minfo
,mx
,any
, and*
(careful, the shell loves those asterisks; be sure to escape them).-
-v
Verbose. Include all fields from the resource record, even time-to-live and class, as well as “additional information” and “authoritative nameservers” (provided by the remote nameserver).
-
-w
Wait forever for a response from a queried server. ...
Get Mac OS X Panther in a Nutshell, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.