DNS HOWTO
 Nicolai Langfeldt [email protected], ������� Alex Ott
 [email protected]
 v2.0.8, 25 ������ 1998

 �� ���� � �������� ����� �������������� DNS.
 ______________________________________________________________________

 Table of Contents


 1. �������

    1.1 ��������� ����
    1.2 �������������� � ����� � ������
    1.3 ����������

 2. ��������

 3. ������� ���������� ������ ����.

    3.1 ������ named

 4. (EM

    4.1 �� ���� ��������� ���������� ����� ������
    4.2 �� ����������� �����
    4.3 ������ (reverse) ���

 5. ������ �������� �����

    5.1 /etc/named.conf (��� /var/named/named.conf)
    5.2 /var/named/root.hints
    5.3 /var/named/zone/127.0.0
    5.4 /var/named/zone/land-5.com
    5.5 /var/named/zone/206.6.177

 6. �������������

 7. ������������ ������� named �� ������ 4 � ����� 8

 8. ������� � ������

 9. �� ���� ����� ������ �������������� DNS.



 ______________________________________________________________________

 ������������������� ���������������������:: ����� ��� ���� ���������� � �������, ���
 ���������.

 11..  ����������������

 ������� ����: DNS, bind, bind-4, bind-8, named, dialup, ppp, slip,
 isdn, Internet, ����� (domain), ��� (name), ������ (hosts),
 ��������� ���� (resolving)

 11..11..  �������������������� ���������

 ��������� ��� (c) Nicolai Langfeldt, 1995. �� ��������� ���
 ��������� ��������� ���, �������������� �������� ��� ���������
 ����������� �� ��������� ����.



 11..22..  ����������������������������� �� ����������� �� ������������

 � ���� ����������� Arnt Gulbrandsen, ������� ��������� �����
 ��������� ����� �������� � ��� ����� ������� � �����������. � ����
 ���� ����������� ����, ������� ������� ��� ���� ����������� �
 �������.

 ���� �������� ������ �� ����� �������, �������� �������� ���
 ��������� � ���� ������ � ������ -- ��� ������ ����� ��������
 �����. ���� �������� ������, ���������� �/��� ������� � �����
 [email protected]. ���� �� �������� ��������� � ������ �������� �����,
 �� �������� �������� ���������� � _�_�_�_�_�_�_�_�_�, ��� ������� �����
 �������� ��������� � ������. ���� ������������������ ��������� �����
 ``������� � ������'' �� ���� �� ������� ���������.

 ���� �� ������ ��������� ���� ��������, �� �������� �������� ��� ��
 ����, ��� �� � ��� ���������� � ���� ����� � ��� ����������, �
 ���� ����� � ��� ��������� ��, ���� ���� �������� ����� ��������.

 11..33..  ��������������������

 ���� �������� �������� Anne Line Norheim Langfeldt. ���� �� ��������
 ������ ��� �� ��������, ��������� �� �� ��������� � ����� �������,
 ���������� ����� ���������.

 22..  ����������������

 ������ ������ ���������,, �� ������ �������� ���������������� ���� ����������������

 ��� ��������, DNS -- ��� ������� ������ ���� (Domain Name System).
 DNS ���������� ���� ���� � IP-�����, ������� ������� �������
 ����, �� ���������� �� ���� � ����� � �� ������� � ����. ����
 �������� �������� �� ���������� ���� ������������, ���������
 ������� � ��� Linux. ������������ -- ��� ������ �������
 ��������� ����� ����� �����, � ���� ����� ����� ������ �����,
 ���� �� ftp.linux.org, � ������� IP ���� �����, �������
 199.249.150.4.

 DNS ��������, ��� ������������� (��� �� ;-), ����� �� ����
 ����������� ������� �������� ����������������. ���� ��������
 ��������� ������ ��������� ���� ��������. ����� ���������� ��
 �������� _�_�_�_�_�_�_� ������ DNS. ��� � �������� ���������� ������,
 �� �������� � �������� ��������� ������ DNS ��� �����. ��� �����
 ������� ������� �� ������ ���������� ����� ``������� � ������''
 ����� ��������.  ���� �� �� ��������, �� ��� �� �����, �� ��
 ���������� _�_�_�_�_�_�_�_�_� ����� ����������. � ��������� � ���� �� ����
 ������� �� ����� ����������� � ``��������� ����''.

 �� ��� ����� �������, �� ������  �������� ��� ����� ��, �����
 �� ����� ��������� ������ telnet � ���/� ���, � ����������� ����
 ������� ����������, � �� ���������� ���������� ����� �����������
 ��������� ������ telnet 127.0.0.1 � ������� � ��� ����������
 ����� (������������� ��� �����!). ��� ���� ���������� �����
 �������� ���������� ���� /etc/nsswitch.conf (��� /etc/host.conf),
 /etc/resolv.conf � /etc/hosts, ��������� � �� ���� ��������� ��
 ������� � ���� ���������. ���� ���� ���� � �� ��� �� �������, ��
 � _N_E_T_-_3_-_H_O_W_T_O �/��� _P_P_P_-_H_O_W_T_O �� �������� �� ��� ������. ���������
 ��.

 ���� � ����� `�� ����' � ���������� �� �����, � ������� ��
 �������� �������� DNS. � �� ��� ����� ����, ������ �� �����
 ������� � ��� ������� ������������.

 � ���������, ��� �� �� ��������� � firewall ����� ���, �������
 ��������� ����� ����. ���� �� ���-��� ��������� � firewall, �� ��
 ��������� ��������� �������, �������� ����� ``������� �
 ������''.

 � Unix ��� ��������� ���� ����������� ���������, ��������
 named. �� �������� ���� ���� bbiinndd, ������� ������������� Paul
 Vixie ��� Internet Software Consortium. Named ������ � �����������
 ������������� Linux, � ������ ������������ �� /usr/sbin/named.
 ���� � �� ���� named, �� �� �������� ������� ����������� ���; ���� �
 �� ��� ���, �� �� ������ �������� ����������� ���� � �������� ftp
 �������� Linux, ��� ����� �������� � ������� ����� ��������
 ������� � ftp.isc.org:/isc/bind/src/cur/bind-8/. ���� ��������
 �������� bind ������ 8. ����� ������ ����� ��������, ����������
 bind ������ 4, ��� �������� �� ������
 http://www.math.uio.no/~janl/DNS/, � ��� �����, ���� �� �����������
 bind 4. ���� �������� ������ named �������� � ��� named.conf,
 �� � �� ����� bind 8, ���� �� �������� � named.boot, �� � �� bind
 4. ���� � �� ��������� bind ������ 4 � �� ��������� �������������
 ��������� �����������, �� �� ������������� ������ �������� ���
 ����� �� ������ 8.

 DNS �������� ���� ����� �� ��������� ����. ������� ��������� � ���,
 ��� �� �������� � ���. ���� �� ������ ������� � ��� ������ ���, ��
 � �� � ������ ��� ���� ������ ������ ���. ������ ��� ��� DNS �
 ����������� � �� �������� ������� ����������� � �� �������. �������
 �� ����������� ��, ��������������� � ��������, � �� ������ ���
 ����� ������� ��������������, ������� ���� �� ����� � ���������
 ��������� ���������.

 � ���� ��������� � ��������� ���� �����, ������� � ���� ���� ��
 ������� �������� ���������� (��� ������� �� ������ ����
 ��������� ����������). ��� ��� ������ � ����� ���������. ��� ����
 (�������� ;-) ����� ������, ���� �� ��������, ���� ��� � ����.

 ����������:: ������� ��������� ����� ���� �����, ������� � ���� ���������
 ��������, ���� � �� ��� ��� ����, �� ��� ���� ������ �� �����
 ������, �� �� ������ ��������� ��� � ������ �����������.

 33..  ���������������� ��������������������� ������������� ��������..

 ������ ������������ ����� �� ����������������� DDNNSS,, ���������� ���������������� ������ ddiiaalluupp
 �������������������������

 ��������� ������ ����� ����� � ����� �� ����� ����� � �������
 ���, ����� ��������, ���� �� �������� ��� �� �������� � ��������
 ��. ��� ���������� �������� ����� ������� ����� ��� ��������
 ������, �������� ���� � �� ��������� ����������.

 ��� ��� �� ����� ���, ������� /etc/named.conf. �� ���� named
 ����� �������� ��� �����. ����� �� ������ ������ ��������
 �������� ������:

















 ______________________________________________________________________
 // ��� ������� ��� ������ ���������� ������

 options {
         directory "/var/named";

         // ��������������� ������� ������, ���� ��
         // ������� ����� firewall � ������ �� ������:

         // query-source address * port 53;
 };

 zone "." {
         type hint;
         file "root.hints";
 };

 zone "0.0.127.in-addr.arpa" {
         type master;
         file "pz/127.0.0";
 };
 ______________________________________________________________________



 ����� `directory' ���� ��� ����� ����. ��� ���� ������������
 ������������, ����� ���������� ������������ ���� ����������. ����
 ������ pz -- ��� ���������� � ���������� /var/named, �.�.,
 /var/named/pz. /var/named -- ��� �������� ���������� ������� _L_i_n_u_x
 _F_i_l_e _s_y_s_t_e_m _S_t_a_n_d_a_r_d _(_�_�_�_�_�_�_�_�_� _�_�_�_�_�_�_�_� _�_�_�_�_�_�_� _L_i_n_u_x_).

 ��� ������� /var/named/root.hints ������ �������� � �������
 ����������. �� ������ �������� ������� ��������:


 ______________________________________________________________________
 .                     6D IN NS        G.ROOT-SERVERS.NET.
 .                     6D IN NS        J.ROOT-SERVERS.NET.
 .                     6D IN NS        K.ROOT-SERVERS.NET.
 .                     6D IN NS        L.ROOT-SERVERS.NET.
 .                     6D IN NS        M.ROOT-SERVERS.NET.
 .                     6D IN NS        A.ROOT-SERVERS.NET.
 .                     6D IN NS        H.ROOT-SERVERS.NET.
 .                     6D IN NS        B.ROOT-SERVERS.NET.
 .                     6D IN NS        C.ROOT-SERVERS.NET.
 .                     6D IN NS        D.ROOT-SERVERS.NET.
 .                     6D IN NS        E.ROOT-SERVERS.NET.
 .                     6D IN NS        I.ROOT-SERVERS.NET.
 .                     6D IN NS        F.ROOT-SERVERS.NET.

 G.ROOT-SERVERS.NET.     5w6d16h IN A    192.112.36.4
 J.ROOT-SERVERS.NET.     5w6d16h IN A    198.41.0.10
 K.ROOT-SERVERS.NET.     5w6d16h IN A    193.0.14.129
 L.ROOT-SERVERS.NET.     5w6d16h IN A    198.32.64.12
 M.ROOT-SERVERS.NET.     5w6d16h IN A    202.12.27.33
 A.ROOT-SERVERS.NET.     5w6d16h IN A    198.41.0.4
 H.ROOT-SERVERS.NET.     5w6d16h IN A    128.63.2.53
 B.ROOT-SERVERS.NET.     5w6d16h IN A    128.9.0.107
 C.ROOT-SERVERS.NET.     5w6d16h IN A    192.33.4.12
 D.ROOT-SERVERS.NET.     5w6d16h IN A    128.8.10.90
 E.ROOT-SERVERS.NET.     5w6d16h IN A    192.203.230.10
 I.ROOT-SERVERS.NET.     5w6d16h IN A    192.36.148.17
 F.ROOT-SERVERS.NET.     5w6d16h IN A    192.5.5.241
 ______________________________________________________________________


 ���� ��� �������� ���� �������� �������� ���� �� ����� ����. ��
 ������ ���������� ����� �� ������� � �� ���� � ��������� _�_�_�_�_�_�
 �������������. �������� ``����� �� ������������'' ��� ����, �����
 ����� �� ������ ��� �������� ������������� ����������������.

 �������� ����� � named.conf -- ��� ��������� ���. � ������ �� ��
 ������������ � �������� ������, ����� ������ ������� ���,
 ������� 127.0.0 � ������������� pz:


 ______________________________________________________________________
 @               IN      SOA     ns.linux.bogus. hostmaster.linux.bogus. (
                                 1       ; Serial
                                 8H      ; Refresh
                                 2H      ; Retry
                                 1W      ; Expire
                                 1D)     ; Minimum TTL
                         NS      ns.linux.bogus.
 1                       PTR     localhost.
 ______________________________________________________________________



 ���� �� ����������, ����� �� ��� /etc/resolv.conf ��������
 �������� ��:


 ______________________________________________________________________
 search subdomain.your-domain.edu your-domain.edu
 nameserver 127.0.0.1
 ______________________________________________________________________



 ����� `search' ���� � ���� ������ ������ ���� ����� ���� �
 ��������� �� ������ �����������. ����� `nameserver' ������� �����
 ����� ������ ����, � ���� ����� ��� �� ���������� ����,
 ��������� � ��� ������ named (127.0.0.1 ��� ��������� �����, ����
 ������ �������, ���� �� ���� ����� ������ �����). ���� �� ������
 ����������� ��������� �������� ����, �� ��������� �� �� ������ �
 ������ �� ������ `nameserver' ��� ������. (��������: Named ������
 �� ����� ���� ���, ��� ����� ������� resolver, ������ ����������
 named).

 �������������� �� ��� ������: ���� ������ ������� ���� ����� �
 ������ foo, �� ���� ������� ������� ���� ����� � ������ ������
 foo.subdomain.your-domain.edu, ���� � ������ foo.your-fomain.edu, � �
 ����� ������ foo. ���� ������ ������� ���� sunsite.unc.edu, ��
 ���� ��������� sunsite.unc.edu.subdomain.your-domain.edu (� ���
 �����, �� ��� �� ��� ������), ���� sunsite.unc.edu.your-
 domain.edu, � � ����� ������ sunsite.unc.edu. �� ������ �� �������
 ������� ����� ������� � ������ �����, ��������� ����� � ��� �����
 ������� ����� �������.

 ������ ����������, ��� �� ��������� � ������ subdomain.your-
 domain.edu, � �� ���� �������� �������� your-
 machine.subdomain.your-domain.edu. ����� ����� �� ����� ��������
 �� TLD (Top Level Domain (����� �������� ������), `edu' � ����
 �����). ���� �� ���������� ���� ����������� � ������ � ������
 ������, �� �� ������ ������� ���� ����� � ������ �����, �������� ���
 ��:





 ______________________________________________________________________
 search subdomain.your-domain.edu your-domain.edu other-domain.com
 ______________________________________________________________________



 � �� ����. ��������, ��� �� ���������� ��������� � ��� ������ ����
 �������� �������, ������ ���������������. �������� �������
 ���������� ����� � ����� ����� �����.

 ���� � ���������� �� ���� ������ libc �� ���������� �������
 ���������� ���� � ��� /etc/nsswitch.conf, ���� � ���
 /etc/host.conf. ���� � �� ��� ���� ��� nsswitch.conf, �� ����� ��
 ����� ������� ���������� � ����, ���� �� ��� ���, �� �� ����� �������
 ��������� � ��� host.conf.

 //eettcc//nnsssswwiittcchh..ccoonnff

 ��� ������� ��� ���������� �� �������� ����� ���� �����, ��
 ����� ��� ��� ��� �����. � ���� �� ������ �������� ��������
 ����������, ������� �� ������ ������ ��� ������ ����� ���. �����
 ����, �� �� ������ ������ ��������� � `hosts:', �� ������
 �������:


 ______________________________________________________________________
 hosts:      files dns
 ______________________________________________________________________



 ���� � ���� ���� ��� ������ ���������� � `hosts:', �� ���������
 �������������� ������ � ���. �� ����� ������� �������� ����
 ��������� ����� � ���� /etc/hosts, � ���� ����������� DNS �
 ������������ � �������� ������ � ���� resolv.conf.

 //eettcc//hhoosstt..ccoonnff

 ���� ��� �������� �������� ����� �����, ��� �� ����� �����
 �������� �� ���� order � ��������� �������� ��:


 ______________________________________________________________________
 order hosts,bind
 ______________________________________________________________________



 ���� ������ � `order' ���, �� �� ������ �� �������. �� ��������
 ����������� ��������� ���� ���� ���������� � ���� /etc/hosts, �
 ���� ������ ����� � ������� ���� (������� � resolv.conf ���� ��
 ���� � ������� 127.0.0.1). ��� �� ��������� ��� ������ � ������
 (8) ��������� ������� (��������� ������ `man 8 resolv') �
 ����������� ������������� Linux. �� ����� ����� ��� ������ ������
 �������� ������, � ����� �������, �������� ������������� DNS,
 ������ �������� �� ���� �� ��. ������� ��� �����! ���� �� ������
 ���� "� ����� ��� �����", �� �� ������ ��� �� �������.

 33..11..  ������������ nnaammeedd

 ����� ���� ������������� ������ ����� ����� named. ���� ��
 ����������� dialup ����������, �� ���� ����������� ����������.
 ������� `ndc start' ��� �����, � ������ ������ return. ����
 ������� �������� ���, �� ���������� ������� ������
 `/usr/sbin/ndc start'.  ���� ����� ������ �� �����, �� ��������
 ����� ``������� � ������''. ������ �� ����� ������������� ���
 ��������. ���� �� ���������� � ��� ��������� syslog (������
 ������� /var/adm/messages, �� ����� ���� ����� ���������� /var/log
 � ������ ��� syslog � ������� ���������� ����������) �� ����� �����
 named (��������� ������ tail -f /var/log/messages), �� �� ������
 ������� ���-�� �������� ���������:

 (������ ������������ � \ ����������� � �������� ������)



      Feb 15 01:26:17 roke named[6091]: starting.  named 8.1.1 Sat Feb 14 \
        00:18:20 MET 1998 ^[email protected]:/var/tmp/bind-8.1.1/src/bin/named
      Feb 15 01:26:17 roke named[6091]: cache zone "" (IN) loaded (serial 0)
      Feb 15 01:26:17 roke named[6091]: master zone "0.0.127.in-addr.arpa" \
        (IN) loaded (serial 1)
      Feb 15 01:26:17 roke named[6091]: listening [127.0.0.1].53 (lo)
      Feb 15 01:26:17 roke named[6091]: listening [129.240.230.92].53 (ippp0)
      Feb 15 01:26:17 roke named[6091]: Forwarding source address is [0.0.0.0].1040
      Feb 15 01:26:17 roke named[6092]: Ready to answer queries.





 ���� ���� ����-������ ��������� �� ������, �� ����� �� ���-��
 ������ ����������. Named ����� � ���� ���� ����� (� �����, ���
 ��� ���� �� ����� named.conf � root.hints :-). ��������� ����������
 named � ��������� ���� �����������.

 ������ ��� �������� nslookup � ��������� ��������� ���� �����.



      $ nslookup
      Default Server:  localhost
      Address:  127.0.0.1

      >





 ���� ��� �������� ��, �� ����� �� ������� ������� ������. �� ��
 �������. ���� ���-�� ������, �� ��������� ��� � ��� ���������.
 ����� �� ���� �� ��������� ��� named.conf, �� ����������
 ������������ named, ��������� ������ ndc restart.

 ������ �� ����� ������ ����� � ����� ���������. ���������� ����
 ����� ������ � ��. pat.uio.no �������� ������ �� ����, �
 ������������ ����:



      > pat.uio.no
      Server:  localhost
      Address:  127.0.0.1

      Name:    pat.uio.no
      Address:  129.240.130.16






 ����� nslookup �������� �� named ���������� �������� � �����
 pat.uio.no. ����� �� ���������� � ����� �� �������� ����,
 ������������� � ���� ���� root.hints, � ������� � ���� ���� �
 ����� �����. ��� ����� ����� ����-�� �����, �� ���� �� ��
 �������� ���������, ��������� ������ ���� ���� ����� ����� ��
 ���� ������ ������������� � ���� ���� /etc/resolv.conf.

 ���� �� �������� �� �� ����, �� �� �������� ���� �����:



      > pat.uio.no
      Server:  localhost
      Address:  127.0.0.1

      Non-authoritative answer:
      Name:    pat.uio.no
      Address:  129.240.2.50





 �������, ��� �� � ��� �� �������� ��������� `Non-authoritative
 answer:'. ��� ������, ��� named � ���� �� �� ���� ����� � �������
 ������� ����, � ������ ����� �������� ����� � ����� ���� � ���� ��
 �����. �� ���������� ��������� ����� ���� ���������. �� ��� ��
 �� ���������� �� ���� (����� �������������) �������� ����������
 `Non-authorative answer:'. nslookup ����� ��� ���������, ���� ��
 ������ �� ��������� �� ����� � ��� �� ����� -- ��� ��� ����, ���
 named �������� �������� � ��� �����, ��� �� ������ ��������. ��
 ������ �������� ����� nslookup �� ������ `exit'.

 ������ �� ����� �� ��������� ��������� ������ ����. �������� ���,
 ����� ��� ����, ��� �� ������������ � ����������� ���.

 44..  ��������������  ����������..

 ����� ������������������� �������� ���������������������� ����������

 44..11..  ���� ����������� ������������������ �������������������� ���������� ������������

 �� ���� �� �� � _�_�_�_�_�_�_�_�_�_�_�_�_�_�_�_� ����� ���� �����, � ���� ��� ��
 ��������� ������������� �������� � ��� �� ������ DNS. � �� ������
 ����� �����, ������ ��� ��� ������� ��� ��. ���� �� �� `������'
 ����� ���, �� �� �� ������ ���� ������ ������ ����������� ���.
 �����������, ���� �� ������� ������ � ���, ��� �� ������ ����� �
 ���� ����� named.conf.

 DNS -- ��� ����������� ������. ������ ���������� �� `.'  �
 ������������ �� `root (������)'.  � . ���������� ��������� ����������
 ������� �������� ������ (Top Level Domains, TLDs), ������� ����������
 �� ������� ������� ORG, COM, EDU � NET, �� � ���� ���� �� ������
 ������.

 ��� ������ �����, ����� ����������� ����������, ����� � �����.
 ���� �� ������ ���� ����� ����� prep.ai.mit.edu, �� �� ������ ����
 ������ ���� ������ ����, ������� ���������� edu. �� ��������
 �������� ������ (.) (�� ��� ���� �������� .  ������ -- ���
 ����������� � ���� root.hints), �������� ������ . ��� ������
 �������� edu:





 $ nslookup
 Default Server:  localhost
 Address:  127.0.0.1





 ��������� �������� ������:



      > server c.root-servers.net.
      Default Server:  c.root-servers.net
      Address:  192.33.4.12





 ��������� ��� ����� (Query type) � NS (����� � ������� ����):



      > set q=ns





 ��������� ��� � edu:



      > edu.





 ������������ ���� . ����� ���, �� ������� �������, ��� ��
 �������� � edu ���������� ����� ��� �������� �������� . (���
 ���������� �����).



      edu     nameserver = A.ROOT-SERVERS.NET
      edu     nameserver = H.ROOT-SERVERS.NET
      edu     nameserver = B.ROOT-SERVERS.NET
      edu     nameserver = C.ROOT-SERVERS.NET
      edu     nameserver = D.ROOT-SERVERS.NET
      edu     nameserver = E.ROOT-SERVERS.NET
      edu     nameserver = I.ROOT-SERVERS.NET
      edu     nameserver = F.ROOT-SERVERS.NET
      edu     nameserver = G.ROOT-SERVERS.NET
      A.ROOT-SERVERS.NET      internet address = 198.41.0.4
      H.ROOT-SERVERS.NET      internet address = 128.63.2.53
      B.ROOT-SERVERS.NET      internet address = 128.9.0.107
      C.ROOT-SERVERS.NET      internet address = 192.33.4.12
      D.ROOT-SERVERS.NET      internet address = 128.8.10.90
      E.ROOT-SERVERS.NET      internet address = 192.203.230.10
      I.ROOT-SERVERS.NET      internet address = 192.36.148.17
      F.ROOT-SERVERS.NET      internet address = 192.5.5.241
      G.ROOT-SERVERS.NET      internet address = 192.112.36.4


 ��� ��� �� �������� � ���, ��� *.root-servers.net ����������
 edu., �� ��� �� ����� ��������� �������� ������ c. ������ �� �����
 ���� ��� ���������� �������� ������� ����� �����: mit.edu.:



      > mit.edu.
      Server:  c.root-servers.net
      Address:  192.33.4.12

      Non-authoritative answer:
      mit.edu nameserver = W20NS.mit.edu
      mit.edu nameserver = BITSY.mit.edu
      mit.edu nameserver = STRAWB.mit.edu

      Authoritative answers can be found from:
      W20NS.mit.edu   internet address = 18.70.0.160
      BITSY.mit.edu   internet address = 18.72.0.3
      STRAWB.mit.edu  internet address = 18.71.0.151





 ������ steawb, w20ns � bitsy ���������� mit, �������� ���� �� ��� �
 �������� � ���� �������� � ai.mit.edu:



      > server W20NS.mit.edu.





 ���� ���� �� ������ �� �������, �� � ������ �������� ���� ���
 �������� � ������ �����, �� ��� � ������ �� ����� ��, �� ���
 ������ � �����.




























 Server:  W20NS.mit.edu
 Address:  18.70.0.160

 > ai.mit.edu.
 Server:  W20NS.mit.edu
 Address:  18.70.0.160

 Non-authoritative answer:
 ai.mit.edu      nameserver = ALPHA-BITS.AI.MIT.EDU
 ai.mit.edu      nameserver = GRAPE-NUTS.AI.MIT.EDU
 ai.mit.edu      nameserver = TRIX.AI.MIT.EDU
 ai.mit.edu      nameserver = MUESLI.AI.MIT.EDU
 ai.mit.edu      nameserver = LIFE.AI.MIT.EDU
 ai.mit.edu      nameserver = BEET-CHEX.AI.MIT.EDU
 ai.mit.edu      nameserver = MINI-WHEATS.AI.MIT.EDU
 ai.mit.edu      nameserver = COUNT-CHOCULA.AI.MIT.EDU
 ai.mit.edu      nameserver = MINTAKA.LCS.MIT.EDU

 Authoritative answers can be found from:
 AI.MIT.EDU      nameserver = ALPHA-BITS.AI.MIT.EDU
 AI.MIT.EDU      nameserver = GRAPE-NUTS.AI.MIT.EDU
 AI.MIT.EDU      nameserver = TRIX.AI.MIT.EDU
 AI.MIT.EDU      nameserver = MUESLI.AI.MIT.EDU
 AI.MIT.EDU      nameserver = LIFE.AI.MIT.EDU
 AI.MIT.EDU      nameserver = BEET-CHEX.AI.MIT.EDU
 AI.MIT.EDU      nameserver = MINI-WHEATS.AI.MIT.EDU
 AI.MIT.EDU      nameserver = COUNT-CHOCULA.AI.MIT.EDU
 AI.MIT.EDU      nameserver = MINTAKA.LCS.MIT.EDU
 ALPHA-BITS.AI.MIT.EDU   internet address = 128.52.32.5
 GRAPE-NUTS.AI.MIT.EDU   internet address = 128.52.36.4
 TRIX.AI.MIT.EDU internet address = 128.52.37.6
 MUESLI.AI.MIT.EDU       internet address = 128.52.39.7
 LIFE.AI.MIT.EDU internet address = 128.52.32.80
 BEET-CHEX.AI.MIT.EDU    internet address = 128.52.32.22
 MINI-WHEATS.AI.MIT.EDU  internet address = 128.52.54.11
 COUNT-CHOCULA.AI.MIT.EDU        internet address = 128.52.38.22
 MINTAKA.LCS.MIT.EDU     internet address = 18.26.0.36





 �� ��� museli.ai.mit.edu �������� �������� ���� ��� ai.mit.edu:



      > server MUESLI.AI.MIT.EDU
      Default Server:  MUESLI.AI.MIT.EDU
      Address:  128.52.39.7





 ������ � ������� ��� �����, ��������� �� ���� ������ ���� � �����
 �������� ��� ���, ��� �� ����� ���� � prep.ai.mit.edu.










 > set q=any
 > prep.ai.mit.edu.
 Server:  MUESLI.AI.MIT.EDU
 Address:  128.52.39.7

 prep.ai.mit.edu CPU = dec/decstation-5000.25    OS = unix
 prep.ai.mit.edu
         inet address = 18.159.0.42, protocol = tcp
           ftp  telnet  smtp  finger
 prep.ai.mit.edu preference = 1, mail exchanger = gnu-life.ai.mit.edu
 prep.ai.mit.edu internet address = 18.159.0.42
 ai.mit.edu      nameserver = beet-chex.ai.mit.edu
 ai.mit.edu      nameserver = alpha-bits.ai.mit.edu
 ai.mit.edu      nameserver = mini-wheats.ai.mit.edu
 ai.mit.edu      nameserver = trix.ai.mit.edu
 ai.mit.edu      nameserver = muesli.ai.mit.edu
 ai.mit.edu      nameserver = count-chocula.ai.mit.edu
 ai.mit.edu      nameserver = mintaka.lcs.mit.edu
 ai.mit.edu      nameserver = life.ai.mit.edu
 gnu-life.ai.mit.edu     internet address = 128.52.32.60
 beet-chex.ai.mit.edu    internet address = 128.52.32.22
 alpha-bits.ai.mit.edu   internet address = 128.52.32.5
 mini-wheats.ai.mit.edu  internet address = 128.52.54.11
 trix.ai.mit.edu internet address = 128.52.37.6
 muesli.ai.mit.edu       internet address = 128.52.39.7
 count-chocula.ai.mit.edu        internet address = 128.52.38.22
 mintaka.lcs.mit.edu     internet address = 18.26.0.36
 life.ai.mit.edu internet address = 128.52.32.80





 �� ����� �� ����� ., �� ���� ������ ������ ���� ��� ������
 ������, ������� � ����� �����. ���� �� �� ����������� ��
 ����������� ������ DNS ������ ������������ ���� �������������
 ��������, �� �� ������ ������� �� �������� �� �� ��������,
 ������ �� ������ �� ����� ����������� ����� ����, � ���� �� ��
 ������ �� ������� ��� �������� ��� ��������� ��������.

 ����� ����������, �� ��� ���� ����� �������� ����� in-addr.arpa. ��
 ���� ����� ����������� ���������, ������� `�������' ������. in-
 addr.arpa ��������� �� �������� ��� �����, �� �� ������. ����������
 �������, �� ��� ip-����� � ������ in-addr.arpa ������ � �������
 �������. �������, ���� � �� ���� ���� � �������: 192.128.52.43, ��
 named ��������� �� ����� ���� �� � ������� ��� prep.ai.mit.edu:
 ������ ������ arpa.. ������ ������ ��� ����� in-addr.arpa.,
 ������ ������ 192.in-addr.arpa., ������ ������ ��� 128.192.in-
 addr.arpa., ������ ��� 52.128.192.in-addr.arpa.. � ����� ��� ������
 ����������� ����� � 43.52.128.192.in-addr.arpa. �����? (������
 '�'). ���� ������� ������� ����� ������, �� ��� ������ ������ ��
 ���.

 � �� �����. DNS �� ������ ����� ��, �� � ��� �����. ��
 ��������� ������ � ��������� ��������.

 44..22..  ����� ���������������������� ����������

 ������ ��������� �� ����������� �����. �� ����� ����� �����
 _l_i_n_u_x_._b_o_g_u_s � ��������� ����� � ���. � �������� �������� ����������
 ��� �����, ��� ���� ����� ���� ���������, ��� �� �� �����������
 ������ �� ������� ����.

 ���� ����� ������� �� ���� �� �� �����: �� ��� ������� ��������
 ����������� � ����� ����. �� ���������� �������� �����������
 ������: a-z, ������: 0-9 � �������� '-' (����). ��������������
 ������������ ���� ��������. ��������� � �������� ������� ��
 ��������� DNS, �� ��� pat.uio.no �������� ����� Pat.UiO.No.

 �� ��� ���� ��� ���� ������� � named.conf:


 ______________________________________________________________________
 zone "0.0.127.in-addr.arpa" {
         type master;
         file "pz/127.0.0";
 };
 ______________________________________________________________________



 �������� ���������� `.' � ����� ���� ������� � ���� ����. ���
 �������, ��� �� ����� ����� ���������� ���� 0.0.127.in-addr.arpa, �
 ��� �� ����� �������� �������� ��� ���, � ���� ��, ��� �� ������� �
 ����, ������� pz/127.0.0. �� ��� ������ ���� ���, � ��� ������:


 ______________________________________________________________________
 @               IN      SOA     ns.linux.bogus. hostmaster.linux.bogus. (
                                 1       ; Serial
                                 8H      ; Refresh
                                 2H      ; Retry
                                 1W      ; Expire
                                 1D)     ; Minimum TTL
                         NS      ns.linux.bogus.
 1                       PTR     localhost.
 ______________________________________________________________________



 �������� ������ ������ `.' � ����� ������ ���� ������� � ���� ����,
 � ����������������� ���������������� ���� named.conf. ��������� ���
 ���� ������ ����� ��� ��� � ��������� $ORIGIN, �� ��� ��������
 ��������. ����������� (origin) (����� ���� � ������� DNS) ��� ����
 ��������� � ������ ��� � ���� named.conf, � ����� ����� ���
 0.0.127.in-addr.arpa.

 ���� `��� ����' �������� 3 `����� �������� (resource records)'
 (RRs): A SOA RR, A NS RR � PTR RR.  SOA ��� ��������� ��� ���
 ���������� (Start Of Authority). ������ `@' ��� ���������� ������
 ���������� �����������, � ��������� � ������� `����� (domain)' ���
 ����� ��� ������ 0.0.127.in-addr.arpa, �� ����� ����� � ����
 ���� �����



      0.0.127.in-addr.arpa.   IN      SOA ...





 NS ��� RR ��� ������ ���� (Name Server). � ���� ������ ������ '@'
 �� ���������, ��� _�_�_�_�_�_�_�_�_�_�_�_�_�_�_�, ��������� ��������� �����
 ������� � ������ '@'. ��� ���������� �� ��������� ����� �
 ������. �� ��� ����� NS � ���������������� ������� ��



      0.0.127.in-addr.arpa.   IN      NS      ns.linux.bogus


 �� ����� ������� DNS, ��� ���� �������� �������� ���� �����
 0.0.127.in-addr.arpa, ��� ns.linux.bogus.  'ns' ����������� ��� ���
 �������� ����, �� �� � ��� web-��������, ���� ����������� ������
 �������� www._�_�_�_-_�_�_�_�_�_�, ����� ��� ����� ���� ����.

 � � � �������� - ����� PTR �����, ��� ���� � ������� 1 � �������
 0.0.127.in-addr.arpa, �������, 127.0.0.1 �������� localhost.

 ������ SOA �������� � �������� ������ �� ����� ���, � �� �����
 ������ ����� � ����. �� �������� ���� -- ����� �� ����������
 (����, ������ ns.linux.bogus), ��� ������� � ���������� ����
 ([email protected]), ��� ������ ��� ���� ������ (serial: 1),
 � ������ ����, ������� ��� ������ ��� ��������� � ���������
 �������� DNS. ��� ����� refresh, retry, expire � minimum �����������
 ���� ����������� � ���� ��������� � �� ������ ���� � �����������,
 ��������� ��.

 ����� ������������ ��  named (����� ndc restart) � �����������
 �������� nslookup ��� �������� ����, ��� ������:



      $ nslookup

      Default Server:  localhost
      Address:  127.0.0.1

      > 127.0.0.1
      Server:  localhost
      Address:  127.0.0.1

      Name:    localhost
      Address:  127.0.0.1





 �� �����, ��� named ������ � ����� �������� ����� � localhost ��
 ����� 127.0.0.1, ��� ����� ������. ������ ��������� � ���� ��������
 ����, ������ linux.bogus, ������ ����� ����� '(zone)' � ���
 named.conf:


 ______________________________________________________________________
 zone "linux.bogus" {
         notify no;
         type master;
         file "pz/linux.bogus";
 };
 ______________________________________________________________________



 �������, ��� �� ����� �� ������ ��������� ������ `.' � �����
 ����� � ���� named.conf.

 � ���� ���� linux.bogus �� �������� ��������� ���������� �����:








 ______________________________________________________________________
 ;
 ; ��� ���� ��� linux.bogus
 ;
 ; ������ ��� ����
 ;
 @       IN      SOA     ns.linux.bogus. hostmaster.linux.bogus. (
                         199802151       ; serial, todays date + todays serial #
                         8H              ; refresh, seconds
                         2H              ; retry, seconds
                         1W              ; expire, seconds
                         1D )            ; minimum, seconds
 ;
                 NS      ns              ; Internet ����� ������ ����
                 MX      10 mail.linux.bogus     ; �������� �������� ������
                 MX      20 mail.friend.bogus.   ; �������������� �������� ������
 ;
 localhost       A       127.0.0.1
 ns              A       192.168.196.2
 mail            A       192.168.196.4
 ______________________________________________________________________



 ���������� ��������� ��� ���� � ����� SOA.  ns.linux.bogus _�_�_�_�_�_�
 ���� �������� ������ � ����� A. �� ��������� ������� ����� �
 ����� CNAME � ����� SOA.  ��� ��� �� ���������� ������ ���� `ns',
 ��� ����� ���� ���� ��������� ������ �����. ����,
 hostmaster.linux.bogus ������ ������� �� [email protected], ���
 ������ ���� �������� ��������� ��� �������� ���� ��� �������
 �������������� DNS � �������� ����� ��������� ����. ��� ����,
 ������������ ����� ����� ��������� � ����� ������ �����. ��� ��
 ���������� ������ ��� `hostmaster', ��� ����� ���� ���� ���������
 ����� ����������� �����, �� ����� � ������ `hostmaster' �� ��������
 ����� ������.

 � ���� ���� �������� ��� ���� ����� ��� ����� � ������� (RR) -- MX,
 ��� ����� ������ �������� ������ (Mail eXchanger). �� �������
 �������� ������� ��� ������� ����� ���������� [email protected],
 � ������ ������� mail.linux.bogus ��� mail.friend.bogus. ����� �����
 ����� ������ ����� -- ��� ��������� ����� MX RR. ������ ������ �
 ��������� ������� (10) -- ��� ����� ��� ���� ����� ��������� �
 ����� �������. ���� ���������� �����, �� ���� ����� ���� ����� �
 ����� � ������� �������, ���������� ��������� �������, �������,
 mail.friend.bogus ��� �������� ��������� ��������� ����� 20.

 ������������ named � ������ ������ ndc restart. ���������
 ��������� ����� ��������� ������ nslookup:


















 $ nslookup
 > set q=any
 > linux.bogus
 Server:  localhost
 Address:  127.0.0.1

 linux.bogus
         origin = ns.linux.bogus
         mail addr = hostmaster.linux.bogus
         serial = 199802151
         refresh = 28800 (8 hours)
         retry   = 7200 (2 hours)
         expire  = 604800 (7 days)
         minimum ttl = 86400 (1 day)
 linux.bogus     nameserver = ns.linux.bogus
 linux.bogus     preference = 10, mail exchanger = mail.linux.bogus.linux.bogus
 linux.bogus     preference = 20, mail exchanger = mail.friend.bogus
 linux.bogus     nameserver = ns.linux.bogus
 ns.linux.bogus  internet address = 192.168.196.2
 mail.linux.bogus        internet address = 192.168.196.4





 ��� ����������� ����������� �� ��������� ������. �����



      linux.bogus     preference = 10, mail exchanger = mail.linux.bogus.linux.bogus





 �������� �������� �����������. �� ����� ��������� ��������
 ������



      linux.bogus     preference = 10, mail exchanger = mail.linux.bogus





 � ���������� ����� ������, ����� �� ������ �������� ���������
 ���� --:-) ����� � ��� ���� �� ��������, ��� � ������



                      MX      10 mail.linux.bogus     ; �������� �������� ������





 ����������� ����. ��� ������ �� ������ 'linux.bogus'. ���� ���
 ����� �� ���������� � ������ ����� � ���� ����, �� � ����� �����
 ����� ���������� ������� ����������� (origin), ������ � �����
 ����������� ����� linux.bogus.linux.bogus. �� �����





 ______________________________________________________________________
                 MX      10 mail.linux.bogus.    ; �������� �������� ������
 ______________________________________________________________________



 ���


 ______________________________________________________________________
                 MX      10 mail                 ; �������� �������� ������
 ______________________________________________________________________



 �������� ���������. � ���������� �������� �����, ��������� ���
 ������ ������ � ��������. ��������� ����������� bind, �������
 �� ������� � ���� ��������, �� ���� � ��, ������� ������� � ����. �
 ���� ���� ��� ����� ������ ���� ������ � ��������� � ������
 `.' ��� ����� �� ������ ���� ����, � ���� ����� �� �������
 ������� ����� ������� ����������� (origin) �����.

 � ������ �����������, ��� � ���� named.conf _�_� _�_�_�_�_�_� ���� ������
 `.' ����� ���� �������. � �� ����� �� ���� ������� ��� ������ `.' --
 ��� ������� ���� ��� ������� ������� ����� �������� ����� ���� �
 ������ ����� ����.

 �� ��� ������� � �� ����� ������ �� ������ ����� ��� ����, �
 ��������� �������������� ����������.





































 ______________________________________________________________________
 ;
 ; ��� ���� ��� linux.bogus
 ;
 ; ������ ��� ����
 ;
 @       IN      SOA     ns.linux.bogus. hostmaster.linux.bogus. (
                         199802151       ; serial, todays date + todays serial #
                         8H              ; refresh, seconds
                         2H              ; retry, seconds
                         1W              ; expire, seconds
                         1D )            ; minimum, seconds
 ;
                 TXT     "Linux.Bogus, your DNS consultants"
                 NS      ns              ; Internet ����� ������ ����
                 NS      ns.friend.bogus.
                 MX      10 mail.linux.bogus     ; �������� �������� ������
                 MX      20 mail.friend.bogus.   ; �������������� �������� ������

 localhost       A       127.0.0.1

 gw              A       192.168.196.1
                 HINFO   "Cisco" "IOS"
                 TXT     "The router"

 ns              A       192.168.196.2
                 MX      10 mail
                 MX      20 mail.friend.bogus.
                 HINFO   "Pentium" "Linux 2.0"
 www             CNAME   ns

 donald          A       192.168.196.3
                 MX      10 mail
                 MX      20 mail.friend.bogus.
                 HINFO   "i486"      "Linux 2.0"
                 TXT     "DEK"

 mail            A       192.168.196.4
                 MX      10 mail
                 MX      20 mail.friend.bogus.
                 HINFO   "386sx" "Linux 1.2"

 ftp             A       192.168.196.5
                 MX      10 mail
                 MX      20 mail.friend.bogus.
                 HINFO   "P6" "Linux 2.1.86"
 ______________________________________________________________________



 ����� ������������ ��������� ����� ������ � ������� (RR): �����
 HINFO (��������� � �����, Host INFOrmation) ����� ��� ����, �������
 ��������� �������� �������� ����� �� ���� ����� � ������. �����
 ���� -- ��� ��������� �� ����������� �����, � ����� ����
 �������� ���������� ����������� � ���������� ������� �����
 �����. ����, ������ 'ns', ����� ��������� Pentium � ������ ���
 ���������� Linux 2.0. CNAME (����������� ���, Canonical NAME) -- ���
 ������ ��������� ����� ����� ��������� ����. ��, ��� www ��������
 ������ ��� ns.

 ������������ ����� CNAME �������� ������� ������������. ��
 ��������� �������� ����� �������� ������, ��� ����� MX, CNAME ���
 SOA _�_�_�_�_�_�_� �� ������ �������� � ���, ������� �� ����� CNAME,
 ��� ������ �������� � ��� ������������ ����� A, �� ��� �����
 ���������� ������

 ______________________________________________________________________
 foobar          CNAME   www                     ; NO!
 ______________________________________________________________________



 �� ������ ����� ���������� ������


 ______________________________________________________________________
 foobar          CNAME   ns                      ; Yes!
 ______________________________________________________________________



 ���� ����� ������, ��� ����� CNAME �� �������� �������� ������
 ����� ��� ������������ � ������ ����������� �����: �����
 [email protected] �������� ����������� ������� �����������
 �����. �� ������ ������, ��� ��������� ������������� �����������
 ����� �� ������� ���� ������ � ���������� ����� �����, ��� ���� �
 �� ��� ������ ��������. ��� ����, ����� ������� ����� �����������
 ����� A (� �������� ���� ��������� ������ �����, ���� �� MX)
 ������:


 ______________________________________________________________________
 www             A       192.168.196.2
 ______________________________________________________________________



 ��������� �� ����������� ����������� bind (arch-bind-wizards),
 ���������� _�_� ����������� ����� CNAME. ��, ��� �� ������������
 ��� ���������� ��������.

 �� �� �� ������, ���� �������� ���� �� � ��������� ������ ��������
 �� ������ ����� ������.

 ��������� ���� ��� ����� �������� ������ ndc reload, ��� ������
 named ��������� ���� ��� �����.



      $ nslookup
      Default Server:  localhost
      Address:  127.0.0.1

      > ls -d linux.bogus





 ��� ������, ��� ������ ���� ����������� ��� ����� � ����� ������.
 � ��������� ��������� ��������:











 [localhost]
 $ORIGIN linux.bogus.
 @                       1D IN SOA       ns hostmaster (
                                         199802151       ; serial
                                         8H              ; refresh
                                         2H              ; retry
                                         1W              ; expiry
                                         1D )            ; minimum

                         1D IN NS        ns
                         1D IN NS        ns.friend.bogus.
                         1D IN TXT       "Linux.Bogus, your DNS consultants"
                         1D IN MX        10 mail
                         1D IN MX        20 mail.friend.bogus.
 gw                      1D IN A         192.168.196.1
                         1D IN HINFO     "Cisco" "IOS"
                         1D IN TXT       "The router"
 mail                    1D IN A         192.168.196.4
                         1D IN MX        10 mail
                         1D IN MX        20 mail.friend.bogus.
                         1D IN HINFO     "386sx" "Linux 1.0.9"
 localhost               1D IN A         127.0.0.1
 www                     1D IN CNAME     ns
 donald                  1D IN A         192.168.196.3
                         1D IN MX        10 mail
                         1D IN MX        20 mail.friend.bogus.
                         1D IN HINFO     "i486" "Linux 1.2"
                         1D IN TXT       "DEK"
 ftp                     1D IN A         192.168.196.5
                         1D IN MX        10 mail
                         1D IN MX        20 mail.friend.bogus.
                         1D IN HINFO     "P6" "Linux 1.3.59"
 ns                      1D IN A         192.168.196.2
                         1D IN MX        10 mail
                         1D IN MX        20 mail.friend.bogus.
                         1D IN HINFO     "Pentium" "Linux 1.2"
 @                       1D IN SOA       ns hostmaster (
                                         199802151       ; serial
                                         8H              ; refresh
                                         2H              ; retry
                                         1W              ; expiry
                                         1D )            ; minimum





 ��� ������. �� �� ������, ��� �������� ����� �� �� ��� ����.
 ������ �������� ���� ����� ����� ������ ��� ����� � ������ www:



      > set q=any
      > www.linux.bogus.
      Server:  localhost
      Address:  127.0.0.1

      www.linux.bogus canonical name = ns.linux.bogus
      linux.bogus     nameserver = ns.linux.bogus
      linux.bogus     nameserver = ns.friend.bogus
      ns.linux.bogus  internet address = 192.168.196.2





 ������� ������, �������� ������ ��� www.linux.bogus ��������
 ns.linux.bogus, � �� ���� ����� �������� ������������� ��������
 � ����� ns, ���������, ����� ����������� � ���.

 ������ �� �������� � �������� ����.

 44..33..  �������������� ((rreevveerrssee)) �������

 ������ �������� ����� ������������� ���� ���� � ������
 linux.bogus � �����, �� ������� ��� ����� �������� � ����� ������.
 �� ����, ����� �����, ��������� ������ ���, ������ ���
 ����������� DNS ������������� ����� � ���� ����. ��� ����
 ����������� ���������� ����������� �������� ��������� ��� (FTP,
 IRC, WWW � �������) ��� ����, ����� ������, ����� �� ��� � ���
 ������� ��� ���, � ��� ����� ��� ����� ������������ ��� ����,
 ����� ������ ���� ��������� �� ���. ������ ��� ��������� ���
 ������� ������ � �������� ������� � Internet.

 ��������� �������� ������ � ��� named.conf:


 ______________________________________________________________________
 zone "196.168.192.in-addr.arpa" {
         notify no;
         type master;
         file "pz/192.168.196";
 };
 ______________________________________________________________________



 ��� ������ ������ � ������� ���� 0.0.127.in-addr.arpa, � ��� ����
 ���� ����� ������� ���������:


 ______________________________________________________________________
 @       IN      SOA     ns.linux.bogus. hostmaster.linux.bogus. (
                         199802151 ; Serial, todays date + todays serial
                         8H      ; Refresh
                         2H      ; Retry
                         1W      ; Expire
                         1D)     ; Minimum TTL
                 NS      ns.linux.bogus.

 1               PTR     gw.linux.bogus.
 2               PTR     ns.linux.bogus.
 3               PTR     donald.linux.bogus.
 4               PTR     mail.linux.bogus.
 5               PTR     ftp.linux.bogus.
 ______________________________________________________________________



 ������ ������������ �� named (ndc restart) � ���� ��������� ���
 ����� � ������ �������� nslookup:


 ______________________________________________________________________
 > 192.168.196.4
 Server:  localhost
 Address:  127.0.0.1

 Name:    mail.linux.bogus
 Address:  192.168.196.4
 ______________________________________________________________________

 ��, ��� �������� ��������, ������ ������ ������ ������ ���� �
 ������, ��� ���� ����� ��������� ����������� ���������:


 ______________________________________________________________________
 > ls -d 196.168.192.in-addr.arpa
 [localhost]
 $ORIGIN 196.168.192.in-addr.arpa.
 @                       1D IN SOA       ns.linux.bogus. hostmaster.linux.bogus. (
                                         199802151       ; serial
                                         8H              ; refresh
                                         2H              ; retry
                                         1W              ; expiry
                                         1D )            ; minimum

                         1D IN NS        ns.linux.bogus.
 1                       1D IN PTR       gw.linux.bogus.
 2                       1D IN PTR       ns.linux.bogus.
 3                       1D IN PTR       donald.linux.bogus.
 4                       1D IN PTR       mail.linux.bogus.
 5                       1D IN PTR       ftp.linux.bogus.
 @                       1D IN SOA       ns.linux.bogus. hostmaster.linux.bogus. (
                                         199802151       ; serial
                                         8H              ; refresh
                                         2H              ; retry
                                         1W              ; expiry
                                         1D )            ; minimum
 ______________________________________________________________________



 �������� ������!

 ���������� ��������� �����, ������� � ������ ������� �����. �������
 �����, ������������ ����� ����� �� ������ �� ������ '������ (private)
 �����', �� �� ��������� �������� ����������� � internet. ��, ���
 �� ����� �������� ����������� �� ������ � ���� ���������. �����
 ���� ��� ����� notify no;. �� �������� named �� ������� ���������
 (�������) ������, ���� �� ���������� ���� �� ����� ���. � bind-8,
 named ����� ���������� ������ ������, ������������� � ������ NS �
 ���� ���, ���� ��������� ��� �����������. ��� �������� �������
 ��� �������� ������������, �� ��� ������ ������������� � ����� ��
 ����������� ����� ���� �������, �� �� �� �����, ����� ��
 ����������� �������� internet?

 � �������, ���� ����� �������� ���������, ���� �� � ��� ����� �
 ���. ��� ��������� ������ ����������� ����� �������� ��������
 �����.

 55..  ������������ ����������������� �����������

 ���� ���������� �������������������� ������������������ _�_�_�_�_�_�_�_�_� ����������� ������

 ����������� ����������, ����� � ������ ������ ������� �����������
 ����� �� ������� �������.

 � �������� ���� ������ � ��������� David Bullock �� LAND-5. ���
 ���� ������� ��������, ������ ������� ������� � 24 ��������
 1996 ���, � ���� ������������� ��� ��� ������������ ������
 �������� bind-8 � ����������� ��������� ��� ���������. �� ���, ��
 ��� �� ������� ����� ����� ��������� �� ����, ��� �� ������� �����
 ����� � �������� ������ ���� LAND-5.




 55..11..  //eettcc//nnaammeedd..ccoonnff ((������ //vvaarr//nnaammeedd//nnaammeedd..ccoonnff))

 ����� �� �������� �� ����� �������� ��� ��� ���� �����������
 ������� ���: ��� ���� 127.0.0, � ���� ��� ����� LAND-5 � �������
 206.6.177. � �����  ��� �������� ���� ����� land-5.com. ����
 ������, ��� ������ ��������� ����� � ���������� ������� pz, �� �
 ���� ����� �� �����, ������������ �������� ��� ���� � ���������
 ������ zone.


 ______________________________________________________________________
 // ����������� ��� ��� ������ ���� LAND-5

 options {
         directory "/var/named";
 };

 zone "." {
         type hint;
         file "root.hints";
 };

 zone "0.0.127.in-addr.arpa" {
         type master;
         file "zone/127.0.0";
 };

 zone "land-5.com" {
         type master;
         file "zone/land-5.com";
 };

 zone "177.6.206.in-addr.arpa" {
         type master;
         file "zone/206.6.177";
 };
 ______________________________________________________________________



 ���� �� ��������� ��� ����� � �� ��� named.conf ��� ����, �����
 ������������������� � ����, �� _�_�_�_�_�_�_�_�_�_� ��������� ������ notify no;
 � ����� ���, ����������� land-5, ��� ���� ����� �������
 ����������.

 55..22..  //vvaarr//nnaammeedd//rroooott..hhiinnttss

 ���������, ��� ��� ��� �� �������� ����������, � ����� ����� ��
 ������������� ����� �������� ������� ����������. ��� �����
 ����������� ������ ������������ ���, ���  �������� ����� ����
 ������ �������� dig, �� ��� ����������� ����.















 ______________________________________________________________________
 ; <<>> DiG 8.1 <<>> @A.ROOT-SERVERS.NET.
 ; (1 server found)
 ;; res options: init recurs defnam dnsrch
 ;; got answer:
 ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 10
 ;; flags: qr aa rd; QUERY: 1, ANSWER: 13, AUTHORITY: 0, ADDITIONAL: 13
 ;; QUERY SECTION:
 ;;      ., type = NS, class = IN

 ;; ANSWER SECTION:
 .                     6D IN NS        G.ROOT-SERVERS.NET.
 .                     6D IN NS        J.ROOT-SERVERS.NET.
 .                     6D IN NS        K.ROOT-SERVERS.NET.
 .                     6D IN NS        L.ROOT-SERVERS.NET.
 .                     6D IN NS        M.ROOT-SERVERS.NET.
 .                     6D IN NS        A.ROOT-SERVERS.NET.
 .                     6D IN NS        H.ROOT-SERVERS.NET.
 .                     6D IN NS        B.ROOT-SERVERS.NET.
 .                     6D IN NS        C.ROOT-SERVERS.NET.
 .                     6D IN NS        D.ROOT-SERVERS.NET.
 .                     6D IN NS        E.ROOT-SERVERS.NET.
 .                     6D IN NS        I.ROOT-SERVERS.NET.
 .                     6D IN NS        F.ROOT-SERVERS.NET.

 ;; ADDITIONAL SECTION:
 G.ROOT-SERVERS.NET.     5w6d16h IN A    192.112.36.4
 J.ROOT-SERVERS.NET.     5w6d16h IN A    198.41.0.10
 K.ROOT-SERVERS.NET.     5w6d16h IN A    193.0.14.129
 L.ROOT-SERVERS.NET.     5w6d16h IN A    198.32.64.12
 M.ROOT-SERVERS.NET.     5w6d16h IN A    202.12.27.33
 A.ROOT-SERVERS.NET.     5w6d16h IN A    198.41.0.4
 H.ROOT-SERVERS.NET.     5w6d16h IN A    128.63.2.53
 B.ROOT-SERVERS.NET.     5w6d16h IN A    128.9.0.107
 C.ROOT-SERVERS.NET.     5w6d16h IN A    192.33.4.12
 D.ROOT-SERVERS.NET.     5w6d16h IN A    128.8.10.90
 E.ROOT-SERVERS.NET.     5w6d16h IN A    192.203.230.10
 I.ROOT-SERVERS.NET.     5w6d16h IN A    192.36.148.17
 F.ROOT-SERVERS.NET.     5w6d16h IN A    192.5.5.241

 ;; Total query time: 215 msec
 ;; FROM: roke.uio.no to SERVER: A.ROOT-SERVERS.NET.  198.41.0.4
 ;; WHEN: Sun Feb 15 01:22:51 1998
 ;; MSG SIZE  sent: 17  rcvd: 436
 ______________________________________________________________________



 55..33..  //vvaarr//nnaammeedd//zzoonnee//112277..00..00

 �� ����� ��� ������������ ������� ������� ����� SOA, � �����,
 ������ ��������� 127.0.0.1 �� localhost. ��������� ����� ��� ���
 �����. ������ ������ �� ������ ���� � ���� ����. ��� ������ �����
 ������ �� ��� ����� ���������, �� ��� ��� ��� �� ��������� �����
 ������ ���� ��� �������������� � ����� (hostmaster).











 ______________________________________________________________________
 @               IN      SOA     land-5.com. root.land-5.com. (
                                 199609203       ; Serial
                                 28800   ; Refresh
                                 7200    ; Retry
                                 604800  ; Expire
                                 86400)  ; Minimum TTL
                         NS      land-5.com.

 1                       PTR     localhost.
 ______________________________________________________________________



 55..44..  //vvaarr//nnaammeedd//zzoonnee//llaanndd--55..ccoomm

 ����� �� ������ ���������� ����� SOA, � ����������� ����� NS. ��
 ����� ������, ��� ������� �������������� ������ ���� ������������ ��
 ������ ns2.psi.net. _�_�_�_�_�_� ���������� ����� �������������� ������ ����
 � �������� ����� � ������� ������. �� ���� ����� ������, ���
 ���� ����� ����� �������� ������, ������� land-5, ������� ��������
 � ��������� ����� �������� Internet, ��� ������ ��������� �����
 CNAME (�� ���������� ����������� ������ A).

 �� �� ������ �� ����� SOA, ��� ���� ��������� � ������ land-5.com,
 ������������� ����� �������� [email protected]. hostmaster -- ��� ������
 ���� ������������ ����� ��� ������������� � ��� ����� �������.
 �������� ����� ����� � ��������� ������ yyyymmdd � ��������
 �������� ������� ��� �������� ���; ��� �������� 6-� ������ ��� ����
 � 20 �������� 1996. �������, ��� �������� ����� _�_�_�_�_�_� ������������
 ���������, ����� ������ _�_�_�_� ���� ��� ��������� ����� �������� ���,
 �� ��� ����� 9 ������� �� ������ ���� ��������� ���, ��� ����
 ����� ����� ���������� ����������� ���. ���������� �����������
 ������������ ���� ���� ��� ����� ������ �����.
































 ______________________________________________________________________
 @       IN      SOA     land-5.com. root.land-5.com. (
                         199609206       ; serial, todays date + todays serial #
                         8H              ; refresh, seconds
                         2H              ; retry, seconds
                         1W              ; expire, seconds
                         1D )            ; minimum, seconds
                 NS      land-5.com.
                 NS      ns2.psi.net.
                 MX      10 land-5.com.  ; �������� �������� ������

 localhost       A       127.0.0.1

 router          A       206.6.177.1

 land-5.com.     A       206.6.177.2
 ns              A       206.6.177.3
 www             A       207.159.141.192

 ftp             CNAME   land-5.com.
 mail            CNAME   land-5.com.
 news            CNAME   land-5.com.

 funn            A       206.6.177.2
 @               TXT     "LAND-5 Corporation"

 ;
 ;       ������ ������
 ;
 ws-177200       A       206.6.177.200
                 MX      10 land-5.com.   ; ������� ������� ����
 ws-177201       A       206.6.177.201
                 MX      10 land-5.com.   ; ������� ������� ����
 ws-177202       A       206.6.177.202
                 MX      10 land-5.com.   ; ������� ������� ����
 ws-177203       A       206.6.177.203
                 MX      10 land-5.com.   ; ������� ������� ����
 ws-177204       A       206.6.177.204
                 MX      10 land-5.com.   ; ������� ������� ����
 ws-177205       A       206.6.177.205
                 MX      10 land-5.com.   ; ������� ������� ����
 ; {����� ������������ ����������� ������}
 ws-177250       A       206.6.177.250
                 MX      10 land-5.com.   ; ������� ������� ����
 ws-177251       A       206.6.177.251
                 MX      10 land-5.com.   ; ������� ������� ����
 ws-177252       A       206.6.177.252
                 MX      10 land-5.com.   ; ������� ������� ����
 ws-177253       A       206.6.177.253
                 MX      10 land-5.com.   ; ������� ������� ����
 ws-177254       A       206.6.177.254
                 MX      10 land-5.com.   ; ������� ������� ����
 ______________________________________________________________________



 ���� �� ��������� � �������� ���� ����� land-5, �� �� ���������,
 ��� ���� ���� ���� ����� ws__�_�_�_�_�. � ��������� ������ bind 4 named
 ��� ���������� ��, ���� ������� ����� ���� ����������� � �����
 ����. ��, ��� ��� ����  ������ ���� ����������� � bind-8, � �
 �������� ������ '-' (����) ������ ������ '_' (������������).

 ����� ����, ������ ���������� �������, ��� ��, ��� ��� ������
 ������ �� ���� ������������� ����, � ������ ����� ������� ��
 ������� � ������� ������� 2 ��������� ���� �� IP-�����. ���������
 ���� ��������� �� ������ ���������� ��������� ����� ��
 ������������, �� ��� ����� ���� ��������� �������� � �
 ���������������� ����� ���� ���������� ����������� �� ������� ����
 ��������.

 �� ���� �����, ��� ��� funn.land-5.com ��� ���� ��� land-5.com, ��
 ������������ ����� A, � �� ����� CNAME.

 55..55..  //vvaarr//nnaammeedd//zzoonnee//220066..66..117777

 � ������������� ��� ��� ����� ����� �������.


 ______________________________________________________________________
 @               IN      SOA     land-5.com. root.land-5.com. (
                                 199609206       ; Serial
                                 28800   ; Refresh
                                 7200    ; Retry
                                 604800  ; Expire
                                 86400)  ; Minimum TTL
                         NS      land-5.com.
                         NS      ns2.psi.net.
 ;
 ;       Servers
 ;
 1       PTR     router.land-5.com.
 2       PTR     land-5.com.
 2       PTR     funn.land-5.com.
 ;
 ;       ������ ������
 ;
 200     PTR     ws-177200.land-5.com.
 201     PTR     ws-177201.land-5.com.
 202     PTR     ws-177202.land-5.com.
 203     PTR     ws-177203.land-5.com.
 204     PTR     ws-177204.land-5.com.
 205     PTR     ws-177205.land-5.com.
 ; {����� ������������ ����������� ������}
 250     PTR     ws-177250.land-5.com.
 251     PTR     ws-177251.land-5.com.
 252     PTR     ws-177252.land-5.com.
 253     PTR     ws-177253.land-5.com.
 254     PTR     ws-177254.land-5.com.
 ______________________________________________________________________



 ������ ��� �������� ��� ���� ��������, ������ ������ ���������
 ������ ������� ���� (�����, grief). �� ������������ ��� ����, �����
 ���� ��� ����� �� �� IP-������. ������: � �� ���� IRC-������ � ��
 �������� ���������� �� IRC-��������. ����� �� �������� � �������� �
 ����� �������� ���������� ������ �� �������� �� �������� � ������
 ����������� ����. ���� �� ������������ � ��������, �� � ������
 ���������� ���� � �� ������ ����� ����� ������������ � ��������
 �����, ��������� ���� ����� ���������� �� ���� �����, ����������
 �� ����. ������ ������ ����� ������ ������ ������ gethostbyaddr,
 ������ ���� ��� ����� �� ������� IP-������. Gethostbyaddr �������
 ������ DNS, ������� �������� ����� ������ ����� � DNS. ��������
 ������ ����������� � ����� ws-177200.land-5.com. IP-�����, �������
 ��������� C ������� IRC-�������, ���� 206.6.177.200. ��� ����,
 ����� ���� ��� ����� �� ���������� ���� ����� 200.177.6.206.in-
 addr.arpa. DNS-������ ���� ����� ������ ����� arpa., ����
 ����� ������ in-addr.arpa., ������ ����� ����� ������ ������ 206,
 ���� 6 � � ����� ������ ����� ������ ��� ���� 177.6.206.in-addr.arpa
 � ������ land-5. �� �������� �� � ����� ������ ����� ������� �����,
 ��� ��� 200.177.6.206.in-addr.arpa � �� ���� ����� 'PTR
 ws-177200.land-5.com', ������� ��� ��� ����� � �������
 206.6.177.200 ���� ws-177200.land-5.com. �� � ���������� ����, ��
 �� ����� prep.ai.mit.edu, ���� ������ ��������.

 �������� � ����� ������� � IRC-��������. IRC-������ ��������
 ���������� ������ �� ����������� ����, �������, *.no, *.se, *.dk,
 ��� ws-177200.land-5.com ���� �� ������������� ����� ������ � ������
 ������� ����������. ���� �� _�_� ���� �������� ��������� �����
 206.2.177.200 � ������ ���� in-addr.arpa, �� ������  �� ���� ��
 ������ ���� ��� ����� � ������ ��� �� �������� ����� 206.2.177.200
 � ������� ����� --*.no, *.se � *.dk, ������� ���� ����� ���� ��
 �������������.

 ��������� ��� �����, ��� ������� ������������ ������� ����
 ������ ��� ��������, � �� ���� ��� �������� �����. ��� �� ��:
 ������ ftp, news, IRC � ��� ��������� http (WWW) ������ _�_� ��������
 ���������� �� ���� ��� ������� ��� �� ����� ���� ����. �� ��� �
 ���������������� ������� ������������ ��� ���� ��������
 _�_�_�_�_�_�_�_�_�_�_�_�.

 66..  ��������������������������

 ������������������� �� ������������� ������������������.

 ���������� ������ ��� ��� �� ������������ named, ����� ���������
 ��� ��������� � �����. ��� ���������� ���������� ��� root.hints.
 ������� ������ ���� -- ��� ������������ �������� dig. ����
 �������� dig ��� ���������� � �� �������� ��� root.hints,
 �������������� ���� �����.  ����� �������� ���� �� �������������
 �������� ��������, �������� ������ dig @rootserver. �� �������, ���
 ����� ���� ������ �������� ����� ������ � ��� root.hints.
 �������� ��������� ����� � ��� (� ������ ������ dig @e.root-
 servers.net . ns >root.hints.new) � ������� ���� ����� ����� ���
 root.hints.

 �������, ��� ���������� ������������ named ����� ����� ���.

 Al Longyear ����� ��� ���� ������, ������� ����� ���� ������������
 ������ ��� ����, ����� ��������� ��� root.hints, ������� ����� �
 crontab ��� ����� ��� �� � ����� � ������� ��� ����. � �������
 ������������, ��� ������� ������ ������ � ��� ��������� ��������
 ���� `hostmaster'. �� ������ ��������� ���� ������ ��� ������������
 ���� ��������.
























 ______________________________________________________________________
 #!/bin/sh
 #
 # ��������� �������� ��� ������ ���� �� � �����.
 # �� ������������ ��������� �� � ����� � ������ cron.
 #
 (
  echo "To: hostmaster <hostmaster>"
  echo "From: system <root>"
  echo "Subject: Automatic update of the named.conf file"
  echo

  export PATH=/sbin:/usr/sbin:/bin:/usr/bin:
  cd /var/named

  dig @rs.internic.net . ns >root.hints.new

  echo "The named.conf file has been updated to contain the following
 information:"
  echo
  cat root.hints.new

  chown root.root root.hints.new
  chmod 444 root.hints.new
  rm -f root.hints.old
  mv root.hints root.hints.old
  mv root.hints.new root.hints
  ndc restart
  echo
  echo "The nameserver has been restarted to ensure that the update is complete."
  echo "The previous root.hints file is now called
 /var/named/root.hints.old."
 ) 2>&1 | /usr/lib/sendmail -t
 exit 0
 ______________________________________________________________________



 ��������� �� �� �������, ��� ��� root.hints ���� �������� �� ftp �
 ������ Internic. �������� _�_� ����������� ftp ��� ���������� ���
 root.hints, ��������������� ����� ����� ��������� �� �������� �
 ����.

 77..  �������������������������� ��������������� nnaammeedd ���� ������������ 44 �� ����������� 88

 ����� ��� ��� ����� �� ������������ bind 8, �������� David E.
 Smith ([email protected]). � ������� ������� ��� ��� ����, �����
 �������������� ����� �����.

 � ��� ������ �������. �� ���������� ������������ ��� named.conf
 ������ named.boot, ��� �������� ���� ����. � bind8 ����������� ��
 �������� � perl, ������� ���������� ���� ������� �� �����
 ���������� � ��� � ����� ����������. ������ ��� named.boot
 (����� �����) ��� ���������� ������ ����:


 ______________________________________________________________________
 directory /var/named
 cache   .                                     root.hints
 primary 0.0.127.IN-ADDR.ARPA                    127.0.0.zone
 primary localhost                               localhost.zone
 ______________________________________________________________________



 � �������� ������, ������� � ���������� bind8/src/bin/named (_�_�_�_�
 _�_�_�_�_�_� _�_�_�_�_�_�_�_�_�_�_�_�_, _�_�_� _� _�_�_� _�_�_�_�_�_�_� _�_�_�_�_�_�_�_� _�_�_� _�_�_�_�_�_� _b_i_n_d_8_. _�_�_�_�
 _� _�_�_� _�_�_�_�_�_�_�_� _�_�_�_�_�_, _�_� _�_�_�_�_�_� _�_�_�_�_�_�_�_� _�_�_�_�_�_� _�_�_�_� _�_�_�_-_�_� _�_�_�_�_�_,
 _�_�_�_� _� _�_� _�_�_�_�_�_�_, _� _�_�_� _�_�_� _�_�_�_�_� _�_� _�_�_�_�_�_�_�_�_�_�_�_�_�_�), �������:


 ______________________________________________________________________
 ./named-bootconf.pl < named.boot > named.conf
 ______________________________________________________________________



 �� ����� ������ �������������� ��� named.conf:


 ______________________________________________________________________
 // generated by named-bootconf.pl

 options {
         directory "/var/named";
 };

 zone "." {
         type hint;
         file "root.hints";
 };

 zone "0.0.127.IN-ADDR.ARPA" {
         type master;
         file "127.0.0.zone";
 };

 zone "localhost" {
         type master;
         file "localhost.zone";
 };
 ______________________________________________________________________



 ���� ������ ������ ��� �����, ��� ����� ���� ������ � ����
 named.boot, ���� �� �� �������� ��� ����� ��������� � �����
 ��������, ������� �������� ����������� � bind8. ����� � �������
 ����� ������ ��� named.conf, ������� ����� �� �� ���� ����, ��
 ������� ����� ����������.






















 ______________________________________________________________________
 // ��� ��� ����������� ��� named (��� BIND 8.1 ��� ����� �������).
 // �� ������ ������������ �� /etc/named.conf.
 // ������� �� `���������' ��� named.conf (����� ����� ���������� :)
 // � ���, ��� ����� <tt/directory/ ��������������, ���������
 // � ���� ��� ���� ���� ��� � ���������� /var/named.

 options {
         directory "/var/named";
         check-names master warn;                /* �� ������� */
         datasize 20M;
 };

 zone "localhost" IN {
         type master;
         file "localhost.zone";
         check-names fail;
         allow-update { none; };
         allow-transfer { any; };
 };

 zone "0.0.127.in-addr.arpa" IN {
         type master;
         file "127.0.0.zone";
         check-names fail;
         allow-update { none; };
         allow-transfer { any; };
 };

 zone "." IN {
         type hint;
         file "root.hints";
 };
 ______________________________________________________________________



 bind8/src/bin/named/test �������� ���� ���, � ���� ����� ����� ���,
 ������� ������ ��� ����� ����������� � ����������� ��� ��������
 ���� � ����.

 ������ ����� ��� � ����� root.hints ��������, ���� �� � ������
 ��� �� ����������.

 88..  �������������� �� ������������

 �������� ��������� ���� ����� �� ����, �� ���������� ����� ��� �
 ��� ����.


 1. ��� named ������� ������ ��� named.boot


    �� �������� ����������� HOWTO. �������� ���������� ����
    ����� ����� ��������, ������ �������� bind 4. �� ����� ���� ��
    ������ http://www.math.uio.no/~janl/DNS/

 2. �� ����������� DNS ������� ����, ��������� firewall?


    ���� ������� ����: `forwarders', `slave', � ���� ����������
    ������ ��������� � ����� ����� ��������.

 3. �� ���� ������ ���������� DNS ��� ������������� ������, �������
    www.busy.site, ����� ��������� ��� ���� �������, ��� ����, �����
    �������� ������ ���� �������, ��� ����-�� ���������.
    ������� ��������� ����� ������ AA ��� www.busy.site � �����������
    bind ������ 4.9.3 ��� �����.  ��� ���� bind ��� ������ �����
    �������� �� ����� ����� ������� �������. ���� ����� _�_� �����
    ������ � ����� ������ �������� bind.

 4. � ���� ��������� DNS � ������� ������������ ���� (intranet). ���
    ��� ��� ������?


    ��� ���������� ����� ��� root.hints � ������ ����������� ����
    ���. ��� ���� ������, ��� �� ������ �� ����� ����� ���������
    ���.

 5. �� � ���� ��������� �������������� (�������) ������ ����?


    ���� ��������/������� ������ ���� ����� ����� 127.0.0.1, �� ��
    ���������� ��������� �������� ��� ������ � ��� named.conf
    ��������������� ������ ����:


    ___________________________________________________________________
      zone "linux.bogus" {
            type slave;
            file "sz/linux.bogus";
            masters { 127.0.0.1; };
      };

    ___________________________________________________________________



 �� ������ ����������� ��������� ������������� �������� �������� ���
 ����, ������� ����� �����������, ������ ����� masters, �����������
 ����� ';' (���� � ������).

 6. � ���� ����� �������� bind, � �� �����, ���� � �� �������� �
    ����.


    ���� �� ������ � ������ ���� ��������:


 �  � ������� ��� ������ �� Ian Clark <[email protected]>, ��� ��
    �������� ���� ������ ������� ����� ��������:





















 � ���� ������ named � ���� ����� � 'Masquerading'. � ���� ���� �� ���
 root.hints -- ����, ������� root.hints.real, ������� �������� ��������
 ������ ���� �������� �������� � ������, ������� root.hints.fake, �������
 ��������...

 ----
 ; root.hints.fake
 ; ���� ��� �� �������� ���������
 ----

 ���� � �������� �� ��������, � ������ ��� root.hints.fake � ���
 root.hints � ���������� named.

 ���� � ���� ��������� � ���������, �� � ������ ��� root.hints.real �
 root.hints � ����� ���������� named.

 ��� ������� �� �������� ip-down � ip-up ��������������.

 ���� � ���� ����� �� ����� �����, � ������� named �� �����
 ���������, � �� ������� �������� ��� ������ � ���  messages..

 Jan 28 20:10:11 hazchem named[10147]: No root nameserver for class IN

 ������ ��� ������ � ���� �����. � ���� ����������� ������ ���� ���
 �������� ���� � �� �����, ���� � ������� �� ����,
 ��� ���� ���� ������� �� ���-���� ���
 ������� �������, � ������ ���� ������ �������� � �������� �������,
 � �� � ����, ���� � �������� � ����.





 �  � ���� ������� �������� �� Karl-Max Wanger � ���, �� bind
    �������������� � NFS � portmapper � ����������� �����������
    ����, �� ������ ������ � ������� ����.




      � ���� ������ named � ���� �����, ������� ������ ����� �� �������
      ��������� � Internet � ������ �����. ������ ���� ������ ��������
      ��������, �� �� ���������� ����� �������� � �������� ��� ����
      ������ ������������� � ���� root.cache. �� ������ � Slackware, ��
      ��������� �� nfsd � mountd.

      � ����� �� ���� ���� (���������� �������� Libretto 30) � ���� ���
      ������� � ���, ��� ����� � ��� ������������� �� ���� � ������
      �����, ����������� � ���� �������� ����, �� � �������� ����� �� ������� ��
      �������. � ���� ��� ���� � ��� �� ������, ��� ���������� ��
      ������������ PLIP, PCMCIA ethernet ���� ��� PPP �� ����������������
      ����������.

      ����� ���������� �������, ������������ � �������������� � ������������, �
      ����, ��� named ���������� ������ ���������� � ������� ���������� nfsd �
      mountd, ��� ����������� � ������ portmapper ��� ������ (� �� ������
      ������ ��� ������ �� ����� �������). ������ named ����� nfsd � mountd
      �������� ������� ��� ��������.

      ��������� �� ��������  ������� ����� �� ���� ����������
      ����������������� �������, �� � ��������� ���� ������ ���� ��
      ����� �, ���
      ������������� ������������ ����������.



 7. ��� ��������� ������ ���� ����� ���� ���? ���� �� ������
    ������������� ����� ���.


    ��� �������� ������� � �����, �� _�_�_�_�_�_�_� ���������� � � ����.
    ����� ��, ���� �� ��������� ���������� named ���������� ���
    ��������. ��� �� �������������� �� ����� �� ��������. named
    ���������� ���, ������� ����������� ������� ������. �� ��
    ������ ������������� ��� ��� ��� ����� �� ���� �������. ���� ��
    ������, �� �� ������ ``��������'' ���, �������� named. ����� ���
    �� �������������.

 8. �������� �� named ���� ��� ����� �����������? �� � ����
    ������� named �������� ���?


    ���, named _�_� ��������� ��� ��� ���������. ��� ������, ��� ���
    ������ ���� �������� ����� ����� �� ��� ���������� named. _�_�_�
    ������, ������� ������ �� named �������� ��� � ����. ���� ��
    ������, �� �� ������ ``��������'' ���, �������� named. ����� ���
    �� �������������.



 99..  ����� ��������� ���������� ������������� ����������������������������� DDNNSS..

 ����������������������� �� ��������������..

 ���������� ������� �����������. �������� � ����������� � �
 ������� �����. ������ ��������� �� ���� ���������� ��������� ���
 ����, ����� ������ �� �� �������� ������������ DNS � ��������
 �������������. � ������� ���� ��������� ������ �������� _D_N_S _a_n_d
 _B_I_N_D ������� C. Liu � P. Albitz, ��������� O'Reilly & Associates,
 Sebastopol, CA, ISBN 0-937175-82-X. � ���� ��, �� ����������. ����
 ���������� ����� � DNS � ����� _T_C_P_/_I_P _N_e_t_w_o_r_k _A_d_m_i_n_i_s_t_r_a_t_i_o_n,
 �������� Craig Hunt � ������� O'Reilly..., ISBN 0-937175-82-X.
 ���� ��� ���������������� DNS (��� �����, ������������ � �����)
 ����� ���� ������� ���� _Z_e_n _a_n_d _t_h_e _A_r_t _o_f _M_o_t_o_r_c_y_c_l_e _M_a_i_n_t_e_n_a_n_c_e
 ����� Robert M. Prisig :-) ������� �� ISBN 0688052304, � ����
 ������ �����.

 � ����������� ����� �� ������ ���� ������� �
 <http://www.dns.net/dnsrd/>,  <http://www.isc.org/bind.html>; FAQ,
 ��������� ������� (BOG; Bind Operations Guide), � ���� ����� �
 ����������� ���������� � ���������� (hacks) � DNS (���, � �����������,
 ���� �� ���, rfc, ���������� ����, ��� ���� ���� � ������� bind).
 ��� �� ����� ����������� �� ���, �� � �� ������ ������� DNS
 ��������������. Arnt Gulbrandsen  ���� BOG � �������� � ������ ��
 ��� :-). � ������ �������� comp.protocols.tcp-ip.domains ����������
 ��������� � DNS. � ��������� � �����, ����� ����������� ��������� RFC
 � DNS, ����� ������ �� ������� �������� ������� ��������:


    RRFFCC 22005522
       A. Gulbrandsen, P. Vixie, _A _D_N_S _R_R _f_o_r _s_p_e_c_i_f_y_i_n_g _t_h_e _l_o_c_a_t_i_o_n
       _o_f _s_e_r_v_i_c_e_s _(_D_N_S _S_R_V_), October 1996

    RRFFCC 11991188
       Y. Rekhter, R. Moskowitz, D. Karrenberg, G. de Groot, E. Lear,
       _A_d_d_r_e_s_s _A_l_l_o_c_a_t_i_o_n _f_o_r _P_r_i_v_a_t_e _I_n_t_e_r_n_e_t_s, 02/29/1996.

    RRFFCC 11991122
       D. Barr, _C_o_m_m_o_n _D_N_S _O_p_e_r_a_t_i_o_n_a_l _a_n_d _C_o_n_f_i_g_u_r_a_t_i_o_n _E_r_r_o_r_s,
       02/28/1996.


    RRFFCC 11991122 EErrrroorrss
       B. Barr _E_r_r_o_r_s _i_n _R_F_C _1_9_1_2, this is available at
       <http://www.cis.ohio-state.edu/~barr/rfc1912-errors.html>

    RRFFCC 11771133
       A. Romao, _T_o_o_l_s _f_o_r _D_N_S _d_e_b_u_g_g_i_n_g, 11/03/1994.

    RRFFCC 11771122
       C. Farrell, M. Schulze, S. Pleitner, D. Baldoni, _D_N_S _E_n_c_o_d_i_n_g _o_f
       _G_e_o_g_r_a_p_h_i_c_a_l _L_o_c_a_t_i_o_n, 11/01/1994.

    RRFFCC 11118833
       R. Ullmann, P. Mockapetris, L. Mamakos, C. Everhart, _N_e_w _D_N_S _R_R
       _D_e_f_i_n_i_t_i_o_n_s, 10/08/1990.

    RRFFCC 11003355
       P. Mockapetris, _D_o_m_a_i_n _n_a_m_e_s _- _i_m_p_l_e_m_e_n_t_a_t_i_o_n _a_n_d _s_p_e_c_i_f_i_c_a_t_i_o_n,
       11/01/1987.

    RRFFCC 11003344
       P. Mockapetris, _D_o_m_a_i_n _n_a_m_e_s _- _c_o_n_c_e_p_t_s _a_n_d _f_a_c_i_l_i_t_i_e_s,
       11/01/1987.

    RRFFCC 11003333
       M. Lottor, _D_o_m_a_i_n _a_d_m_i_n_i_s_t_r_a_t_o_r_s _o_p_e_r_a_t_i_o_n_s _g_u_i_d_e, 11/01/1987.

    RRFFCC 11003322
       M. Stahl, _D_o_m_a_i_n _a_d_m_i_n_i_s_t_r_a_t_o_r_s _g_u_i_d_e, 11/01/1987.

    RRFFCC 997744
       C. Partridge, _M_a_i_l _r_o_u_t_i_n_g _a_n_d _t_h_e _d_o_m_a_i_n _s_y_s_t_e_m, 01/01/1986.