Intro to Networks This lecture will consist Internet























- Slides: 23
Intro. to Networks This lecture will consist • • • Internet and Ethernet short history Layer model (ISO and IP) Routing and routers Linux routing table PPP short history and purpose PPP and Linux
Internet & Ethernet Brief history Internet (http: //www. isoc. org/internet/history/) • 1969 – ARPANET (The Internet origin) • 1969 – UNIX • 1972 – Ethernet • 1989 – WWW • 1991 – Linux • 1992 –Mosaic
Internet organization • • • ISOC – http: //www. isoc. org IETF – http: //www. ietf. org IETF RFCs – http: //www. ietf. org/rfc IANA – http: //www. iana. org IAB – http: //www. iab. org W 3 C – http: //www. w 3 c. org
Other org. involve in Networks • ISO – http: //www. iso. ch • ITU – http: //www. itu. int • IEEE – http: //www. ieee. org
OSI layers via Internet layers OSI • Physical • Data link • Network • Transport • Session • Presentation • Application IP • Ethernet hardware • Ethernet • IP stack • TCP/UDP stack • IP applications
LAN MAC Addresses • • • Registration through the IEEE. XX-XX-XX-XX Vendor register leading XX-XX-XX. Example: 3 Com register 00 -05 -1 A Example: a NIC made by 3 Com 00 -05 -1 A-0 C-01 -93
Making LAN We need 4 component to make LAN • Cables • NICs in the PCs or other (e. g. Printers) • Hubs (Repeaters) • Switches
Configure NIC • • Use hotplug. lspci , lspci -n PCI Vendor ID. (on the Internet) /lib/modules/<kid>/kernel/drivers/net/ USB Cable, USB ADSL => USB NIC. lsmod ifconfig -a
IP v 4 Address • • • Class A 1. 0. 0. 0 -126. 0. 0. 0 7/24 Class B 128. 1. 0. 0 -191. 254. 0. 0 14/16 Class C 192. 0. 1. 0 -223. 255. 254. 0 22/8 Class D 224. 0. 0. 0 -239. 255 Class E 240. 0 -254. 255
IP Network and subnets • • • A name for IP based LAN. IP Network – mask according to class. IP sub network have a smaller mask. Example: 10. 1. 0. 0, 255. 0. 0 is subnet class A.
Address Resolution Protocol • • • RFC 826 Map LAN MAC into the IP address. Dynamic ARP. Manual ARP Static ARP.
Linux LAN • • • ifconfig -a – See your interfaces arp -n – See the ARP table arp -s ip mac – Set ARP route -n ip - iproute 2 tool
IP routing. Server 10. 101. 15. 73 Router 10. 101. 15. 1 10. 1. 14. 124 00 -02 -BA-13 -BC-11 00 -02 -BA-13 -BC-13 00 -02 -B 3 -1 D-5 E-87 00 -05 -1 B-1 A-3 C-B 4 Dst 10. 101. 15. 73 Src 10. 1. 14. 124 Dst MAC 00 -02 -BA-13 -BC-11 Src MAC 00 -05 -1 B-1 A-3 C-B 4
IP routing. Server Router 10. 101. 15. 1 10. 101. 15. 73 10. 1. 14. 124 00 -02 -BA-13 -BC-11 00 -02 -BA-13 -BC-13 00 -02 -B 3 -1 D-5 E-87 Dst 10. 101. 15. 73 Src 10. 1. 14. 124 Dst MAC 00 -02 -B 3 -1 D-5 E-87 Src MAC 00 -02 -BA-13 -BC-13 00 -05 -1 B-1 A-3 C-B 4
Routing table • Default Gateway. • Simple example: • Destination Gateway Genmask Flags Metric Ref Use Iface • 10. 1. 0. 0 255. 0. 0 U 0 0 0 eth 0 • 0. 0 10. 1 0. 0 UG 0 0 0 eth 0
A real route • • RIP – RFC 1058, 1388, 1723 OSPF - RFC 2178 (v 2) BGP - RFC 1771 (BGP-4) PIM – RFC 2362, 3973 OSI IS-IS IGRP, EIGRP – Cisco. Real routers are not just routers!
PPP • Point to Point Protocol • IP protocol for connecting PC over phone line. • Use tty char device for transferring IP packets. • RFC 1661, RFC 1662 (STD 51) • HDLC ISO 3309
Why PPP? • • Phone lines. Authentication. Bandwidth and Qo. S control Dynamic client to ISP mapping. Easy configuration VPN. Compression option. Packets concatenating.
PPP structure • LCP – Create the PPP link. • PAP or CHAP authentication. • HDLC – Octet/Bit stuffed framing
PPP over link layer • PPPo. E - RFC 2516 • PPPo. A – RFC 2364 • MAC address or VP instead of phone line.
PPP over IP • • • L 2 TP – RFC 2661, RFC 3931 (v 3) PPTP – RFC 2637 Server IP instead of phone number. Two IP networks with one IP stack Need a more complicated routing. Possible to work L 2 TP over PPPo. E.
PPP over IP routing • Simple example: • Destination Gateway Genmask • 132. 64. 140. 2 0. 0 255 UH 0 0 0 ppp 0 • 10. 1. 0. 0 255. 0. 0 U 0 0 0 eth 0 • 0. 0 132. 64. 140. 2 0. 0 UG 0 0 0 ppp 0 Flags Metric Ref Use Iface
Linux PPP tools • • • The PPP daemon PPTP client – works with the pppd. L 2 TP – status unknown. PPPo. E PPPo. A – kernel patch with ATM driver. Kernel 2. 6 - PPP, PPPo. E, PPPo. A