1
2dnsget(1)                   General Commands Manual                  dnsget(1)
3
4
5

NAME

7       dnsget - DNS lookup utility
8
9

SYNOPSYS

11       dnsget [-v|-q] [-c class] [-t type] [-o opt,opt,...]  name...
12
13

DESCRIPTION

15       dnsget  is  a  simple  command-line  to perform DNS lookups, similar to
16       host(1) and dig(1).  It is useable for both interactive/debugging  sce‐
17       narious  and  in  scripts.   The  program  is implemented using udns(3)
18       library.
19
20
21       By default, dnsget produces a human-readable output, similar to
22              alias.example.com. CNAME www.example.com.
23              www.example.com. A 192.168.1.1
24              www.example.com. MX 10 mx.example.com.
25       which is just sufficient to see how a given name resolves.  Output for‐
26       mat is controllable with -v and -q options -- the former increases ver‐
27       bosity level up to printing the whole DNS contents of all packets  sent
28       and  received,  which is suitable for debugging DNS problems, while the
29       latter reduces the level, making output more quiet, up to  bare  result
30       with no error messages, which is good for scripts.
31
32

OPTIONS

34       The following options are recognized by dnsget:
35
36
37       -v     produce more detailed output.  More -v's means more details will
38              be produced.  With single -v,dnsget will print contents  of  all
39              received  DNS packets (in a readable format), while with -vv, it
40              will output all outgoing DNS packets too.
41
42
43       -q     the opposite for -v -- produce less detailed output.  With  sin‐
44              gle  -q,dnsget  will  only  show  (decoded)  data from final DNS
45              resource records (RR), while -qq also suppresses error messages.
46
47
48       -t type
49              request record(s) of the given type type.   By  default,  dnsget
50              will  ask  for IPv4 address (A) record, or for PTR record if the
51              argument in question is an IPv4  or  IPv6  address.   Recognized
52              types  include  A,  AAAA,  MX, TXT, CNAME, PTR, NS, SOA, ANY and
53              others.
54
55
56       -c class
57              request DNS record(s) of the given class class.  By default dns‐
58              get uses IN class.  Valid classes include IN, CH, HS, ANY.
59
60
61       -a     (compatibility option).  Equivalent to setting query type to ANY
62              and increasing verbosity level (-v).
63
64
65       -C     (planned)
66
67
68       -x     (planned)
69
70
71       -o opt,opt,...
72              (may be specified several times).  Set resolver  options  (in  a
73              form  option:value) as if they were set in $RES_OPTIONS environ‐
74              ment variable, or set query flags:
75
76              timeout:sec
77                     Set initial query timeout to sec.
78
79              attempts:num
80                     (re)try every query num times before failing.
81
82              udpbuf:bytes
83                     set DNS UDP buffer size to bytes bytes.  Valid values are
84                     from  512 to 65535.  If bytes is greather than 512, EDNS0
85                     (RFC 2671) extensions will be used.
86
87              port:num
88                     Use given UDP port number num instead of the default port
89                     53 (domain).
90
91              aa     set AA (auth only) query bit.
92
93              nord   do  not  set  RD  (recursion  desired)  query bit (set by
94                     default).
95
96              dnssec or do
97                     set DNSSEC OK (DO) query flag  (dnsget  does  not  verify
98                     DNSSEC  signatures,  only  displays  them; this is set in
99                     EDNS RR).
100
101              cd     set CD (checking disabled) query bit.
102
103
104       -n nameserver
105              Use the given nameserver(s) (may be specified  more  than  once)
106              instead  of  the  default.   Using this option has the same same
107              effect as $NSCACHEIP or $NAMESERVERS environment variables, with
108              the  only difference that only IPv4 addresses are recognized for
109              now, and it is possible to specify names (which will be resolved
110              using default settings) instead of IP addresses.
111
112
113       -h     print short help and exit.
114
115

RETURN VALUE

117       When  all  names  where  resovled successefully, dnsget exits with zero
118       exit status.  If at least one name was not found, dnsget will exit with
119       return  code  100.  If some other error occured during name resolution,
120       it will exit with code 99.  In case of usage or  initialization  error,
121       dnsget will return 1.
122
123

SEE ALSO

125       host(1) dig(1) resolv.conf(5) udns(3).
126
127
128
129User Utilities                     Jan 2014                          dnsget(1)
Impressum