1 / 149

TCP/IP Introduction

TCP/IP Introduction. George Macri <gmacri@homemail.com> ROMTELECOM S.A. Romania 5 th Network Technologies Workshop. Technological Prerequisites. Internetworks Internet Protocols Internet Addresses Routing Subneting CIDR. What internetworks are. Start with lots of little networks

amity-ramos
Download Presentation

TCP/IP Introduction

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. TCP/IP Introduction George Macri <gmacri@homemail.com> ROMTELECOM S.A. Romania 5th Network Technologies Workshop . CEENET Workshop Budapest 16-26 August 1999

  2. Technological Prerequisites • Internetworks • Internet Protocols • Internet Addresses • Routing • Subneting • CIDR CEENET Workshop Budapest 16-26 August 1999

  3. What internetworks are • Start with lots of little networks • Many different types • ethernet, dedicated leased lines, dialup, ATM, Frame Relay, FDDI • Each type has its own idea of addressing and protocols • Want to connect them all together and provide a unified view of the whole lot CEENET Workshop Budapest 16-26 August 1999

  4. The unifying effect of the network layer • Define a protocol that works in the same way with any underlying network • Call it the network layer • routers operate at the network layer • There are defined ways of using: • protocol over ethernet, ATM, FDDI • protocol over serial lines (PPP) • protocol over almost anything CEENET Workshop Budapest 16-26 August 1999

  5. The 7 Layer OSI Model CEENET Workshop Budapest 16-26 August 1999

  6. Protocol Stacks • Layers: Applications TCP / UDP Transport layer IP Network layer atm x.25 hdlc ethernet token ring dialup frame relay CEENET Workshop Budapest 16-26 August 1999

  7. Layer Functions Mail, Web etc. Application Presentation Session Transport TCP End to end reliability Forwarding best-effort IP Network Data Link Packet delivery Physical Raw signal CEENET Workshop Budapest 16-26 August 1999

  8. ISO seven layer model • 1: Physical layer • moves bits using voltage, current, light, etc. • 2: Data Link layer • bundles bits into frames and moves frames between hosts on the same link CEENET Workshop Budapest 16-26 August 1999

  9. ISO seven layer model • 3: Network layer (e.g. IP) • Makes routing decisions • uses destination address in packet • Forwards packet hop by hop • encapsulates network layer packet inside data link layer frame • different framing on different underlying network types • Unreliable • Single address space for the entire internetwork CEENET Workshop Budapest 16-26 August 1999

  10. ISO seven layer model • 4: Transport layer (e.g. TCP) • end to end transport of datagrams • encapsulates datagrams in network layer packets • adds reliability by detecting and retransmitting lost packets • uses acknowledgements and sequence numbers to keep track CEENET Workshop Budapest 16-26 August 1999

  11. ISO seven layer model • 5: Session layer • not used in the TCP/IP network model • 6: Presentation layer • not used in the TCP/IP network model • 7: Application layer • Uses the underlying layers to carry out work CEENET Workshop Budapest 16-26 August 1999

  12. Layer interaction Application Application Presentation Presentation Session Session Transport Transport Network Network Network Network Link Link Link Link Physical Physical Physical CEENET Workshop Budapest 16-26 August 1999

  13. INTERNET PROTOCOLS • Internet protocols • can be used for communications between heterogeneous systems; • can be used for communications between systems connected in a LAN; • can be used for communications between systems connected in a WAN; • can be used for communications between a set of interconnected networks; • Documents called RFCs (Requests For Comments), which are reviewed and analyzed by the IETF community; improvements, additions and refinements of protocols are published in new RFCs (see ftp://ftp.rs.internic.net., ftp://ftp.ripe.net/). • Looking at all RFCs, you can see the history of the development of Internet protocols, people and companies that have contributed to this • TCP and IP are the best known of the Internet protocols and very often the term TCP/IP refers to the whole family of protocols. CEENET Workshop Budapest 16-26 August 1999

  14. TCP/IP Model Message Segment Datagram Frame Bit 5 4 3 2 1

  15. TCP/IP is a 5 Layered model • Layers 1 and 2 are not actually defined by TCP/IP , as TCP/IP was defined to be independent of physical media . CEENET Workshop Budapest 16-26 August 1999

  16. Layer 3 is the Internet Protocol (IP) layerThis provides a basic datagram service • ICMP (Internet Control Message Protocol) is normally provided in this layerICMP reports problems in transmission of datagrams • ARP (Adress Resolution Protocol) • RARP (Reverse Address Resolution Protocol)

  17. In layer 4 are 2 possible protocols : TCP (Transport Control Protocol) and UDP (User Datagram Protocol) . • TCP provides a reliable service with error correction and flow control .The cost of providing a reliable service is more overhead in connection setup and closedown, processing power for correcting errors and data transmission, but some applications need reliability irrespective of cost. • UDP just extends IP’s connectionless datagram service to applications that do not require reliability .UDP datagrams can be sent to a network without the overhead of creating and maintaining a connection

  18. Layer 5 is the Application layerThis layer provides services suitable for the different types of application that might wish to use the network .It does not provide the application itself .For example : SMTP , FTP , Telnet ... CEENET Workshop Budapest 16-26 August 1999

  19. TCP/IP CEENET Workshop Budapest 16-26 August 1999

  20. Internet Protocols NFS RPC FTP RFC 959 SNMP RIP RFC 1058 Routing protocols BGP OSPF IGRP EIGRP Telnet RFC 854 SMTP RFC 821 DNS RFC 1035 ICMP RFC 792 TCP RFC 793 UDP RFC 768 IP RFC 791 ARP RFC 826 X.25 PPP HDLC SLIP LAPB Ethernet/IEEE 802.3 LAN Public telephone network CEENET Workshop Budapest 16-26 August 1999

  21. SMTP mail exchange as an example • There is a protocol for mail that defines a set of commands and messages that one machine sends to the other, for example, a conversation between machines linkguide.ici.ro and mail.iob.ro: Linkguide: HELO linkguide.ici.ro Mail.iob.ro: 250 mail.iob.ro - HELO Linkguide.ici.ro Linkguide: MAIL From:<gmacri@linkguide.ici.ro> Mail.iob.ro: 250 MAIL accepted Linkguide: RCPT To:<mihai@mail.iob.ro> Mail.iob.ro: 250 Recipient accepted Linkguide: DATA Mail.iob.ro: 354 Start mail input; end with <CTRL>,<CRLF> Linkguide: Date: Sat, 26 Jul 96 14:23:34 +02 Linkguide: From: gmacri@linkguide.ici.ro Linkguide: To: mihai@mail.iob.ro Linkguide: Subject: helo Linkguide: text of the message Linkguide: . Mail.iob.ro: 250 OK Linkguide: QUIT Mail.iob.ro: 221 mail.iob.ro Service closing transmission channel • The protocol assumes that we have a reliable way of command and message communication CEENET Workshop Budapest 16-26 August 1999

  22. Host A FTP client FTP server TCP TCP IP IP Token Ring Driver TCP/IP Architecture Terms Host B router IP eth drv t.r. drv Ethernet Driver CEENET Workshop Budapest 16-26 August 1999

  23. Encapsulation • Lower layers add headers (and sometimes trailers) to data from higher layers Application Data Transport Header Data Internet Header Header Data Network Access Header Header Header Data CEENET Workshop Budapest 16-26 August 1999

  24. IP Addresses • Purpose • Basic Structure • Network mask • Special addresses CEENET Workshop Budapest 16-26 August 1999

  25. Purpose of an IP address • Unique Identification of • SourceSometimes used for security or policy-based filtering of data • DestinationSo the networks know where to send the data • Network Independent Format • IP over anything CEENET Workshop Budapest 16-26 August 1999

  26. Basic Structure of an IP Address • 32 bit / 4 byte number:(e.g. 204.152.8.1) • Decimal Representation: • Binary Representation: 204 152 8 1 11001100 10011000 00001000 00000001 CEENET Workshop Budapest 16-26 August 1999

  27. Address Structure Revisited • Hierarchical Division in IP Address: • Network Part (Prefix) • describes which physical network • Host Part (Host Address) • describes which host on that network • Boundary can be anywhere • not necessarily at a multiple of 8 bits 1 205 . 154 . 8 11001101 10011010 00001000 00000001 Network Host CEENET Workshop Budapest 16-26 August 1999

  28. Network Masks • Define which bits are used to describe the Network Part • Different Representations: • decimal dot notation: 255.255.248.0 • number of network bits: /19 • Binary AND of 32 bit IP address with 32 bit netmask yields network part of address CEENET Workshop Budapest 16-26 August 1999

  29. Subnetting • One class address (either B or C) space could be too large for a given organization, or for a certain site of the organization. • Subnetting divides a single network address into many subnet addresses, so that each subnetwork can have its own unique address. • A subnet is defined by applying a bit mask (the subnet mask) to the IP address. • If a bit is 1 in the mask, the equivalent bit in the address is interpreted as a network bit. • If a bit in the mask is 0, the bit belongs to the host part of the address. • Ex: mask to divide the 193.226.2.0 address into 4 subnets: • 11111111 11111111 11111111 11000000 CEENET Workshop Budapest 16-26 August 1999

  30. Example Prefixes • 137.158.128.0/17 (netmask 255.255.128.0) • 198.134.0.0/16 (netmask 255.255.0.0) • 205.37.193.128/26 (netmask 255.255.255.192) 11111111 11111111 1 0000000 00000000 10001001 10011110 1 0000000 00000000 11111111 11111111 00000000 00000000 11000110 10000110 00000000 00000000 11111111 11111111 11111111 11 000000 11001101 00100101 11000111 10 000000 CEENET Workshop Budapest 16-26 August 1999

  31. Old-Style Classes of Address • Different classes used to represent different sizes of network (small, medium, large) • Class A networks: x.0.0.0 - 16.777.215 host addresses • 8 bits network, 24 bits host (/8, 255.0.0.0) • First byte in range x=1-127 • Class B networks: x.y.0.0 - 65.536 host addresses • 16 bits network, 16 bits host (/16 ,255.255.0.0) • First byte in range x=128-191 y=0-254 • Class C networks: x.y.z.0 - 256 host address • 24 bits network, 8 bits host (/24, 255.255.255.0) • First byte in range x=192-223 y,z=0-254 CEENET Workshop Budapest 16-26 August 1999

  32. IP Address Structure - Class-full Address format 32 bits Network address Host address Class A network=8 bits 0 Class B network=16 bits 1 0 Class C network=24 bits 1 1 0 Class D (multicast) 1 1 1 0 Class E (reserved) 1 1 1 1 CEENET Workshop Budapest 16-26 August 1999

  33. Special Addresses • All 0’s in host part: Represents Network • e.g. 193.0.0.0/24 • e.g. 138.37.128.0/17 • All 1’s in host part: Broadcast • e.g. 137.156.255.255 (137.156.0.0/16) • e.g. 134.132.100.255 (134.132.100.0/24) • e.g. 190.0.127.255 (190.0.0.0/17) • 127.0.0.0/8: Loopback address (127.0.0.1) • 0.0.0.0: Various special purposes CEENET Workshop Budapest 16-26 August 1999

  34. TCP/IP Basics: Physical & Datalink CEENET Workshop Budapest 16-26 August 1999

  35. The Physical and Datalink layer • Ethernet • IEEE and ISO • Token Ring • FDDI • SLIP • PPP • ISDN CEENET Workshop Budapest 16-26 August 1999

  36. Ehernet • Network access protocol • The medium for communication between two machines directly connected can be: coax, twisted cable, telephone link, radio link, satellite link, etc. The lowest layer of protocols provides functions that manage the data transmission specific to a certain physical medium. • Classes of links • Point to point • Broadcast • Non-broadcast multi-access • Ethernet/IEEE 802.3 is a coaxial based bus cabling system developed by Digital Equipment Corporation, Intel, Xerox (DIX) • Ethernet was the technological basis for the IEEE 802.3 specification • Both of them specify the CSMA/CD (Carrier Sense Multiple Access with Collision Detection), also referred as “listen while talk” (LWT) • Both are broadcast networks CEENET Workshop Budapest 16-26 August 1999

  37. Transceivers on boards in computers Transceivers 10 Base 5 Thick Wire 10 Base 2 Thin Wire Twisted Pair concentrator 10/100/1000 Base T On Board Transceivers Ethernet Topologies Fiber concentrator 10/100/1000 Base F Transceivers

  38. The Ethernet frame • This Ethernet frame encapsulates the TCP/IP protocol and is responsible for transporting it across the cabling system to layer 2 of the destination device , whether it’s a Router , Gateway or end node . CEENET Workshop Budapest 16-26 August 1999

  39. MAC addressing • The ethernet frame uses addresses referred to as MAC (Medium Access Control) • MAC addresses identify the specific network cards • These are 48 bits long • Each network card has a unique address configured by its manufacturer CEENET Workshop Budapest 16-26 August 1999

  40. The LAN card will accept only 3 types of MAC address . • Unicast - Frames with destination to the exact MAC address . • Broadcast - Has all 48 bits set to binary 1 (or Hex FF FF FF FF FF FF) .This type of frame is used when the sender does not know the destination MAC address it tries to communicate , so we broadcast to all . • Multicast - Addressing to groups of LAN cards that are related in some way .The LAN cards have to be configured to know they are part of a multicast group .

  41. The type field • The Type field identifies different protocols . • A computer running multiple protocols can easily differentiate between them , and path the contents to the relevant layer . • TCP/IP Generally uses 3 Ethernet types registered in IEEE . CEENET Workshop Budapest 16-26 August 1999

  42. At the end of the frame is a CRC . This is a 32 bit value that is calculated from all the bits of the Ethernet frame and its contents , but ignoring the preamble and the CRC itself . The remote node does the same calculation and compares the CRC .If the value is different , the LAN card will not pass the Frame to the network layer . CRC - Cyclic Redundancy Check CEENET Workshop Budapest 16-26 August 1999

  43. The service provided by Ethernet • The medium access mechanism used by Ethernet is CSMA/CD (Carrier Sense Multiple Access with Collision Detection) . • This allows nodes on the network to manage shared access to the cable , but it restricts the length of the cabling , and the number of nodes that use it . • They are not specific to Protocol , therefore for TCP/IP . CEENET Workshop Budapest 16-26 August 1999

  44. Ethernet Packet size • Minimum packet size - 64 octets • Maximum packet size - 1518 octets • The sizes above include all the frame apart from the preamble . • Because of the frame header fields , the CRC and the overhead of the IP and TCP or UDP higher layer protocols , the amount left for useful application data is less then 1518 . CEENET Workshop Budapest 16-26 August 1999

  45. To give an example :The Ethernet frame overhead consists of 18 octets and the higher layer protocols often need 40 octets .That leaves 1460 (1518-40-18=1460) octets for application data .

  46. IEEE and ISO systems • IEEE 802.3 uses CSMA/CD . • IEEE 802.4 uses a token mechanism on a bus . • IEEE 802.5 and FDDI (IS9314) use a token passing mechanism on a ring . CEENET Workshop Budapest 16-26 August 1999

  47. LLC (Logical Link Layer) • For LAN’s , layer 2 is split to 2 sublayers . • The lower is MAC and above we have the LLC , which has the standard number IEEE 802.2 . • One of the major functions of LLC is to differentiate between the different types of network layer protocols , in a similar way to the type field of Ethernet . CEENET Workshop Budapest 16-26 August 1999

  48. Ethernet CEENET Workshop Budapest 16-26 August 1999

  49. Token Ring CEENET Workshop Budapest 16-26 August 1999

  50. FDDI CEENET Workshop Budapest 16-26 August 1999

More Related