gateways . , , , RIP gated. 3.5. The Internet Control Message Protocol ( ) IP -, - 43 - . (ICMP) , . . . , erdos telnet 12345 quark, . TCP , ICMP . ICMP , - . , (Redirect message). , gateway, . , sophus : , FDDI , gateway Groucho (gcc1). , quark gcc1, niels (gateway ). , gcc1 -- , niels, ICMP sophus, . , . , , RIP ICMP , . ICMP RIP , , - . 3.6. (Domain Name System) 3.6.1 (Hostname Resolution) < > , TCP/IP 32 . , - 44 - . , "", gauss strange. IP Hostname resolution. , IP , , , , gethostbyname (3) gethostbyaddr (3). , resolver; Linux, libc. , Ethernet, , , IP . /etc/hosts. , , -- hosts . , . -- NIS, Sun Microsystems, YP, . NIS hosts ( ) , . , , , . Internet, HOSTS.TXT. NIC, . , . HOSTS.TXT , , . ( ) . , 1984 , -- DNS, Paul Mockapetris . - 45 - 3.6.2. DNS DNS (domain). -- - , ( , BITNET), ( ), . , edu , , , . Groucho Marx groucho.edu , -- maths.groucho.edu. Internet erdos erdos.maths.groucho.edu. 3.6.2 . , , , . , , . , . , top-level, second-level, third-level (, , ). . , : edu ( ) , ... com , . org . UUCP . net Gateways . - 46 - mil . gov . uucp , UUCP , . , Internet, . net . , mil gov . , , ISO-3166. , , fi , fr , de , au ... , NIC . , , , com.au, edu.au, . , , , , . , ftp.informatik.uni-erlangen.de. , ; NIC . , se . , ; DNS, , . DNS : . , Groucho ; - 47 - . , , , physics.groucho.edu . , IP . , , . : groucho.edu Groucho Marx , groucho.edu , . , physics.groucho.edu. 3.6.2, . 3.6.3 DNS , . , , - ?! DNS. IP erdos, , DNS , , , . , DNS - . (name server), . , . IP erdos, -- groucho.edu, . , , . Groucho Marx ? - 48 - address-resolving oracle, DNS . erdos, , . , erdos.maths.groucho.edu. , , edu . , edu , edu . , a.isi.edu. , a.isi.edu groucho.edu , . , , , IP . , IP . , HOSTS.TXT. . , . , groucho.edu , , groucho.edu. , , . time to live( ), TTL. TTL . 3.6.4 (Domain Name Servers) , master name servers. . - 49 - , . , , . o , , -- . , . , , DNS, . , , . . caching-only . 3.6.5 DNS , DNS IP , . DNS . DNS resource record ( ), RR. , , , , . , IP (IN ), Hesiod ( MIT), . , IP . , . , , , . , , CNAME, - 50 - . , , , . 3.6.5 physics.groucho.edu. A CNAME , , , . - SOA , Start of Authority ( ), , . , , . , groucho.edu . "@", SOA . , groucho.edu - , . : NS FQDN, , IP . , . -- , . physics.groucho.edu 3.6.5. ; ; Authoritative Information on physics.groucho.edu @ IN SOA { niels.physics.groucho.edu. hostmaster.niels.physics.groucho.edu. 1034 ; serial no 360000 ; refresh 3600 ; retry 3600000 ; expire 3600 ; default ttl - 51 - } ; ; Name servers IN NS niels IN NS gauss.maths.groucho.edu. gauss.maths.groucho.edu. IN A 149.76.4.23 ; ; Theoretical Physics (subnet 12) niels IN A 149.76.12.1 IN A 149.76.1.12 nameserver IN CNAME niels otto IN A 149.76.12.2 quark IN A 149.76.12.4 down IN A 149.76.12.5 strange IN A 149.76.12.6 ... ; Collider Lab. (subnet 14) boson IN A 149.76.14.1 muon IN A 149.76.14.7 bogon IN A 149.76.14.12 ... 5. amed.hosts . 3.6.6. . IP , , , . reverse mapping( ) , . hosts , . DNS, . , , inaddr.arpa, IP . dotted-quad , IP 149.76.12.4 4.12.76.149.in-addr.arpa. , , PTR. - 52 - ; ; Zone data for the groucho.edu zone. @ IN SOA { vax12.gcc.groucho.edu. hostmaster.vax12.gcc.groucho.edu. 233 ; serial no 360000 ; refresh 3600 ; retry 3600000 ; expire 3600 ; default ttl } .... ; ; Glue records for the physics.groucho.edu zone physics IN NS niels.physics.groucho.edu. IN NS gauss.maths.groucho.edu. niels.physics IN A 149.76.12.1 gauss.maths IN A 149.76.4.23 ... 6. named.hosts GMU. . IP , DNS IP . , , 149.76.8.0, 149.76.12.0, 149.76.14.0. , in-addr.arpa : 8.76.149.in-addr.arpa, 12.76.149.in-addr.arpa, 14.76.149.in-addr.arpa. , Collider in-addr.arpa . 12 3.6.6. 3.6.6. ; - 53 - ; the 12.76.149.in-addr.arpa domain. @ IN SOA { niels.physics.groucho.edu. hostmaster.niels.physics.groucho.edu. 233 360000 3600 3600000 3600 } 2 IN PTR otto.physics.groucho.edu. 4 IN PTR quark.physics.groucho.edu. 5 IN PTR down.physics.groucho.edu. 6 IN PTR strange.physics.groucho.edu. 7. named.rev 12. ; ; the 76.149.in-addr.arpa domain. @ IN SOA { vax12.gcc.groucho.edu. hostmaster.vax12.gcc.groucho.edu. 233 360000 3600 3600000 3600 } ... ; subnet 4: Mathematics Dept. 1.4 IN PTR sophus.maths.groucho.edu. 17.4 IN PTR erdos.maths.groucho.edu. 23.4 IN PTR gauss.maths.groucho.edu. ... ; subnet 12: Physics Dept, separate zone 12 IN NS niels.physics.groucho.edu. IN NS gauss.maths.groucho.edu. niels.physics.groucho.edu. IN A 149.76.12.1 gauss.maths.groucho.edu. IN A 149.76.4.23 ... 8. named.rev , IP , , , netmasks 8. Groucho Marx - 54 - netmask 255.255.255.0, in-addr.arpa . , netmask 255.255.255.128, 149.76.12.128 , DNS, 12.76.149.in-addr.arpa , 1 127, 128 255, . . - 55 - 4. . 4.1. , , , TCP/IP, , , " " . , . -, , , Ethernet : , , PC. - . Ethernet , , Linux, . . , Linux Ethernet . "Becker Series Drivers" , , Donald Becker. - D-link , D-link , . , , "" ? Ethernet , . : , . PC, - .. . - ( ) - 56 - Ethernet 0x300, 0x360. , , , . autoprobing( ), , , Ethernet. , Ethernet , ; Ethernet . , , Ethernet . , . , -- interrupt request channel ( ). , , . PC, 15 (0, 1, 3 15). interrupt request channel IRQ. 3., . , , . . , /dev. Ethernet. - eth0, eth1, .. , ; Ethernet eth0, -- eth1, . - SLIP , ; , SLIP , - 57 - , . , , . : This processor honours the WP bit even when in supervisor mode. Good. Floppy drive(s): fd0 is 1.44M Swansea University Computer Society NET3.010 IP Protocols: ICMP, UDP, TCP PPP: version 0.2.1 (4 channels) OPTIMIZE FLAGS TCP compression code copyright 1989 Regents of the University of California PPP line discipline registered. SLIP: version 0.7.5 (4 channels) CSLIP: code copyright 1989 Regents of the University of California dl0: D-Link DE-600 pocket adapter, Ethernet Address: 00:80:C8:71:76:95 Checking 386/387 coupling... Ok, fpu using exception 16 error reporting. Linux version 1.1.11 (okir@monad) #3 Sat May 7 14:57:18 MET DST 1994 TCP/IP, SLIP, CSLIP, PPP. c , d-link, dl0. Ethernet , , eth0, . Ethernet , , . . 4.2. Linux , PC. , , . , , . - 58 - Linux , . "Installation and Getting Started" Matt Welsh, Linux . , Linux, . make config, , , ... -- TCP/IP . y, . 4.2.1. Linux 1.0 , , SCSI , ... . , - . ( 1.0 1.1) ( italics ): * * Network device support * Network device support? (CONFIG ETHERCARDS) [y] , y, , Ethernet, SLIP, PPP. y, Ethernet- . : SLIP (serial line) support? (CONFIG SLIP) [y] SLIP compressed headers (SL COMPRESSED) [y] PPP (point-to-point) support (CONFIG PPP) [y] - 59 - PLIP (parallel port) support (CONFIG PLIP) [n] Linux. SLIP IP . CSLIP, TCP/IP . CSLIP , . PPP - . SLIP, IP, IPX. PPP , . PLIP IP . PC DOS. Ethernet . , . , . NE2000/NE1000 support (CONFIG NE2000) [y] WD80*3 support (CONFIG WD80x3) [n] SMC Ultra support (CONFIG ULTRA) [n] 3c501 support (CONFIG EL1) [n] 3c503 support (CONFIG EL2) [n] 3c509/3c579 support (CONFIG EL3) [n] HP PCLAN support (CONFIG HPLAN) [n] AT1500 and NE2100 (LANCE and PCnet-ISA) support (CONFIG LANCE) [n] AT1700 support (CONFIG AT1700) [n] DEPCA support (CONFIG DEPCA) [n] D-Link DE600 pocket adaptor support (CONFIG DE600) [y] AT-LAN-TEC/RealTek pocket adaptor support (CONFIG ATP) [n] * * CD-ROM drivers * - 60 - ... , , NFS. NFS , . NFS filesystem support (CONFIG NFS FS) [y] 4.2.2. Linux 1.1.14 Linux 1.1.14, IPX, . . . * * Networking options * TCP/IP networking (CONFIG INET) [y] TCP/IP , y. n, IPX. IP forwarding/gatewaying (CONFIG IP FORWARD) [n] Y, gateway Ethernet, Ethernet SLIP, ... , firewall, . Firewalls -- , . Internet . firewall Internet, , firewall. * - 61 - * (it is safe to leave these untouched) * PC/TCP compatibility mode (CONFIG INET PCTCP) [n] PC/TCP, TCP/IP DOS. , Unix , . Reverse ARP (CONFIG INET RARP) [n] RARP. RARP X- IP . RARP . (net-0.32d) rarp RARP . Assume subnets are local (CONFIG INET SNARL) [y] TCP , IP, . Ethernet, , - . SNARL, , . , B Groucho Marx , . SNARL, . ( , , SLIP ), c mtu , . Disable NAGLE algorithm (normally enabled) (CONFIG TCP NAGLE OFF) [n] Nagle IP - 62 - , tinygrams. Tinygrams , , telnet rsh. Tinygrams . Nagle TCP . Nalge , . The IPX protocol (CONFIG IPX) [n] IPX, Novell . . -- IPX DOS novell PPP . Novell , . 1.1.16, Linux , dummy driver ( ). . Dummy net driver support (CONFIG DUMMY) [y] , SLIP . loopback . , SLIP Ethernet, , IP . 6.7.7 6 .. 4.3. Linux Linux . , , . Linux , . , - 63 - eth0, eth1, ... lo loopback. , . , , , . loopback , . ethn n- Ethernet . Ethernet . dln D-Link DE-600 ( Ethernet ). , DE-600 . sln n- SLIP . SLIP sl0, ... SLIP . pppn n- PPP . SLIP , PPP , PPP. . plipn n- PLIP . PLIP IP . PLIP . PLIP , . , , ISDN AX.25, . , . 4.4. Ethernet - 64 - Linux Ethernet . Donald Becker (becker@super.org). National Semiconductor 8390 ; Becker . D-Link, D-Link , Ethernet . Bjrn Ekwall (bj0rn@blox.se). DEPCA David C. Davies (davies@wanton.lkg.dec.com). 4.4.1. Ethernet . Ethernet , . Ethernet - . 50 . T- BNC , . ,