TRANSPORT and NETWORK LAYERS - Part 1 Dr. V.T. Raja Oregon State University
Transport and Network Layers - TCP/IP (Part 1) Chapter Objectives: • Understand primary functions of transport and network layers • Understand the “big picture” • Five-layer network model
Examples of Transport/Network Layer Protocols • Examples: • Two popular transport/network layer protocols • Another example of protocol in a WAN environment that is not popular in North America • Protocol for IBM compatible hardware/software and mainframe environments
Examples of Transport/Network Layer Protocols • Examples: • Two popular transport/network layer protocols • TCP/IP • IPX/SPX • Another example of protocol in a WAN environment that is not popular in North America • X.25 • Protocol for IBM compatible hardware/software and mainframe environments • SNA • APPN
TCP/IP • Why TCP/IP? • What is the expansion of TCP/IP? • What are the major functions of TCP/IP?
TCP/IP • Why TCP/IP? • Most widely used protocol on Internet • Estimated about 70-80% of LAN, MAN, and backbone networks use TCP/IP • Reliable protocol • TCP/IP performs some error detection/error correction functions, although this is not a primary function of the network layer protocol • Compatible with many data link protocols • What is the expansion of TCP/IP? • Transmission Control Protocol/Internet Protocol • What are the major functions of TCP/IP? • Packetizing, Addressing and Routing
TCP • Main functions of TCP: Packetizing • What is Packetizing? • At sender • At final destination • Thought Questions (with regard to the “big picture”): • With what layer(s) does TCP interface in the 5-layer model? • If more than two computers are involved in message transmission, then is TCP involved in all the computers? In how many computers is TCP involved?
Transmission Control Protocol (TCP) • Main function of TCP: • Packetizing – What is packetizing? • At sender • Break messages into packets • Assign packet numbers • At final destination • Check if all packets have arrived • Reassemble packets • Interfacing with two other layers • Thought Questions (with regard to the “big picture”): • With what layer(s) does TCP interface in the 5-layer model? • If more than two computers are involved in message transmission, then is TCP involved in all the computers? In how many computers is TCP involved?
TCP (Continued) • Some details on TCP header: • TCP header containing 24 bytes (192-bit header) of overhead information is enclosed along with user’s data: • Examples of overhead information added: • Source and destination address • Packet sequence number • Thought Question (with regard to the “big picture”): • Didn’t the data link layer already have the source and destination address specified in the DLH? Is TCP duplicating this function of DL?
Token Ring and Ethernet Frames Token Ring format Start Frame Destination Source Message End delimiter control address address variable delimiter Access Frame control check sequence1 byte 4 bytes Ethernet format Destination Source Length Message CRC-32 address address 2 bytes variable 4 bytes 6 bytes 6 bytes
Port Identifiers • Source Port IDs refer to software used at application layer of source computer • Destination Port IDs refer to software to be used at application layer of final destination computer • With TCP/IP, each application layer software has a unique port address/identifier. • Every standard application layer software on the Internet has a predefined (default) port number. • Thought Questions: • Could network managers choose not to use the default port numbers? • Why would a network manager not want to use a default port number?
Internet Protocol (IP) • What are IP’s main functions? • Main functions: • Thought Question: • Is IP involved only at sender’s or final destination computers? Or is it involved in all interim computers that take part in the message routing as well?
Internet Protocol (IP) • What are IP’s main functions? • Main functions: • Addressing • Routing • Thought Question: • Is IP protocol involved only at sender’s or final destination computers? Or is it involved in all interim computers that take part in the message routing as well? • IP is involved not only at source and final destination, but also involved at each of the intervening computers involved in the message transmission.
IP (Continued) • Different versions of IP • IPv4 and IPv6 • IP creates a IP header • IP header contains (among other overhead information) source and destination address! • Network layer (IP) address • Examples? • Thought Question (with regard to the “big picture”): • In what order are the different headers from different layers combined with the user data packet? • If DL protocol is Ethernet, and NL protocol is TCP/IP, then what is the maximum packet size for user data? Assume DLH and DLT sizes sum to 26 bytes, TCP header size is 24 bytes, and IP header size is 24 bytes as well. • Sample content in each header?
IPv4 AddressingICANN • Every computer participating on the Internet should use approved network layer (IP) addresses. • IP Addresses are approved by ICANN or one of several private companies authorized by ICANN • Internet Corporation for Assigned Names and Numbers • http://www.icann.org/ • FAQ on registration of IP addresses • http://www.internic.net/faqs/
IPv4 AddressingDotted Decimal Notation • Dotted Decimal Notation • Four bytes (8 bits = 1 byte) per address • Each byte separated by a dot • Each byte expressed in decimal notation • Example: • Dotted Decimal Notation: 18.104.22.168 • Binary Notation?: • What is the minimum decimal value any byte can be assigned? • What is the maximum decimal value any byte can be assigned?
IPv4 AddressingClass Based Address Structure • IP Addresses were grouped into classes: • Classes A, B, C, D and E • Classes A, B and C - used for commercial purposes • The class of the address - determined by examining the first byte of the address and mapping it to a range of values as follows: • Class A: first byte is in the range 1 – 127 • Class B: first byte is in the range 128 - 191 • Class C: first byte is in the range 192 - 223
IPv4 AddressingNetwork and Host Addresses • Each IP address has two parts: • Network Address (assigned/approved by ICANN) • Host Address (assigned by host organization) • For a Class A IP address, the first byte is assigned/approved by ICANN • Class A: Network.Host.Host.Host • For a Class B IP address, the first two bytes are assigned/approved by ICANN • Class B: Network.Network.Host.Host • For a Class C IP address, the first three bytes are assigned/approved by ICANN • Class C: Network.Network.Network.Host • Restrictions for Host address: IP address cannot end in 0 or 255
IPv4 AddressingClass Participation Exercise # 1 • Class Participation Exercise: • If OSU has an IP address whose first byte is 128, what class does this IP address belong to? • To which of the four bytes of the IP address can OSU assign values, assuming the first byte has the value 128? • a) Assume that ICANN has assigned OSU a group of IP addresses, and that the first two bytes (of each assigned IP address) are 130.192. In this case, how many IP addresses are available for OSU? b) How many IP addresses are available to OSU, if ICANN assigned OSU a class A IP address? c) How many IP addresses are available to OSU, if ICANN assigned OSU a class C IP address?
IPv4 Addressing (Continued)Subnets • Subnets • Part of a network that is logically grouped by IP addresses • Example: • Suppose ICANN assigned OSU a set of IP addresses as follows: 128.193.x.x • OSU assigns the host part of the IP address • 128.193.75.x; (CS subnet) • 128.193.76.x; (BSG subnet) • 128.193.76.x; (COB subnets) • Can have one subnet for faculty: 128.193.76.____ (faculty subnet) • Can have one subnet for IS staff: 128.193.76.____ (IS staff subnet) • Every computer in a TCP/IP network is assigned a subnet mask by the host organization – Why?
IPv4 AddressingSubnet Masks • Subnet Mask Applications: • Helps determine if sender and receiver are on same subnet. • Why is this important? • Helps determine maximum number of computers per subnet • Helps determine maximum number of subnets possible
Subnet mask applicationDetermining if sender and receiver are on same subnet • How to determine if sender and receiver are on the same subnet? • Refer to algorithm provided on separate handout • Examples: • Are computer A (IP address: 22.214.171.124) and computer B (IP address: 126.96.36.199) on the same subnet? • Do you have sufficient information to answer the above mentioned question? • Class Participation Exercise # 2 (Question # 1)
Subnets (Continued)Partial Subnetting • Subnet mask default values • Example: Class Participation Exercise # 2 (Question # 2) • Partial Subnetting • Subnet masks can also take values other than 0 or 255 • Example 1: • Subnet mask: 255.255.255.224 • Sender’s IP: 188.8.131.52 • Receiver’s IP: 184.108.40.206 • Example 2: Class Participation Exercise # 2 (Question # 3)
Subnet Mask Applications • Subnet mask helps: • Determine if sender and receiver are on same subnet • Determine maximum number of computers per subnet • Determine maximum number of subnets possible • Example 1: • Background: Assume OSU is assigned a Class C address, and assume that the network manager at OSU has selected the subnet mask value as: 255.255.255.248 • Question: Find (a) maximum # of computers per subnet and (b) maximum # of subnets possible
Class Participation Exercise # 2 – Question # 5 • Background Info: A firm has been assigned a class B address by ICANN. Based on an estimation of future network growth in the firm, the administration plans to have 30 different subnets, and about 2040 computers in each subnet. • Question:What subnet mask value should the network manager use in order to satisfy the planning needs (of the administration) as specified above?