dns.rst
changeset 1862 f4e844aa1217
child 1863 1532554ca0b4
equal deleted inserted replaced
1861:c28dba308db9 1862:f4e844aa1217
       
     1 .. -*- coding: utf-8; -*-
       
     2 .. include:: HEADER.rst
       
     3 
       
     4 ======
       
     5  DNS.
       
     6 ======
       
     7 
       
     8 About DNS resolving protocol.
       
     9 =============================
       
    10 
       
    11 Default port for name resolving is ``53``::
       
    12 
       
    13   $ nslookup -port=53 microsoft.com
       
    14 
       
    15 Debugging name resolution.
       
    16 ==========================
       
    17 ::
       
    18 
       
    19   $ nslookup -debug microsoft.com
       
    20 
       
    21 Dumping all available resords::
       
    22 
       
    23   $ nslookup -type=any microsoft.com
       
    24 
       
    25 IP from host name.
       
    26 ==================
       
    27 
       
    28 This request is for the ``A`` record and default for ``nslookup`` command::
       
    29 
       
    30   $ nslookup defun.work
       
    31   $ nslookup -type=a defun.work
       
    32 
       
    33 Host name from IP.
       
    34 ==================
       
    35 
       
    36 If that information available::
       
    37 
       
    38   $ nslookup -type=ptr 8.8.8.8
       
    39 
       
    40 
       
    41 List authoritative NS for domain.
       
    42 =================================
       
    43 ::
       
    44 
       
    45   $ dig ns defun.work
       
    46   $ nslookup -type=ns defun.work
       
    47 
       
    48 List MX records for domain.
       
    49 ===========================
       
    50 ::
       
    51 
       
    52   $ dig mx mail.google.com
       
    53   $ nslookup -type=mx mail.google.com
       
    54 
       
    55 List SOA records for domain.
       
    56 ============================
       
    57 
       
    58 SOA ("Start Of Authority") Record for a domain provides technical information
       
    59 about the domain::
       
    60 
       
    61   $ dig soa defun.work
       
    62 
       
    63 Human readable format can be viewed via::
       
    64 
       
    65   $ nslookup -type=mx defun.work
       
    66 
       
    67     origin = ns1.mindsandmachines.com
       
    68     mail addr = admin.mindsandmachines.com
       
    69     serial = 2011091101
       
    70     refresh = 10800
       
    71     retry = 7200
       
    72     expire = 604800
       
    73     minimum = 86400
       
    74 
       
    75 Email adress for domain administrator is ``admin@mindsandmachines.com`` for
       
    76 above output.
       
    77 
       
    78 List domain names.
       
    79 ==================
       
    80 ::
       
    81 
       
    82   $ dig ns dp.gov.ua
       
    83   ...
       
    84   ;; ANSWER SECTION:
       
    85   dp.gov.ua.              3600    IN      NS      ns.giknpc.com.ua.
       
    86   ...
       
    87 
       
    88   $ dig @ns.giknpc.com.ua dp.gov.ua AXFR
       
    89   ...
       
    90   dp.gov.ua.              3600    IN      MX      200 relay2.giknpc.com.ua.
       
    91   dp.gov.ua.              3600    IN      A       195.64.190.1
       
    92   adm.dp.gov.ua.          3600    IN      A       195.64.190.1
       
    93 
       
    94 How reread config file?
       
    95 =======================
       
    96 
       
    97 FreeBSD::
       
    98 
       
    99   $ named.reload