QUIZ: Review of Data Link layer (L2)



Similar documents
Introduction to LAN/WAN. Network Layer

Introduction to IP v6

Computer Networks 1 (Mạng Máy Tính 1) Lectured by: Dr. Phạm Trần Vũ

Computer Networks. Main Functions

IP Addressing A Simplified Tutorial

8.2 The Internet Protocol

Computer Networks. Lecture 3: IP Protocol. Marcin Bieńkowski. Institute of Computer Science University of Wrocław

Chapter 5: Sample Questions, Problems and Solutions Bölüm 5: Örnek Sorular, Problemler ve Çözümleri Örnek Sorular (Sample Questions):

Future Internet Technologies

Course Overview: Learn the essential skills needed to set up, configure, support, and troubleshoot your TCP/IP-based network.

IP Addressing Introductory material.

Transport and Network Layer

Route Discovery Protocols

Internet Protocols Fall Lectures 7-8 Andreas Terzis

CSC458 Lecture 6. Homework #1 Grades. Inter-domain Routing IP Addressing. Administrivia. Midterm will Cover Following Topics

Lecture Computer Networks

The Internet. Internet Technologies and Applications

2. IP Networks, IP Hosts and IP Ports

Internetworking and IP Address

IP Addressing. IP Addresses. Introductory material.

IP - The Internet Protocol

College 5, Routing, Internet. Host A. Host B. The Network Layer: functions

Network layer" 1DT066! Distributed Information Systems!! Chapter 4" Network Layer!! goals: "

Internet Addresses (You should read Chapter 4 in Forouzan)

Internet Protocol: IP packet headers. vendredi 18 octobre 13

RARP: Reverse Address Resolution Protocol

Network layer: Overview. Network layer functions IP Routing and forwarding

Internet Protocols. Addressing & Services. Updated:

Internetworking. Problem: There is more than one network (heterogeneity & scale)

Internet Working 5 th lecture. Chair of Communication Systems Department of Applied Sciences University of Freiburg 2004

Introduction to TCP/IP

Technical Support Information Belkin internal use only

IP Networking. Overview. Networks Impact Daily Life. IP Networking - Part 1. How Networks Impact Daily Life. How Networks Impact Daily Life

Lecture 15. IP address space managed by Internet Assigned Numbers Authority (IANA)

Datagram-based network layer: forwarding; routing. Additional function of VCbased network layer: call setup.

IP addressing and forwarding Network layer

Module 2: Assigning IP Addresses in a Multiple Subnet Network

Internet Firewall CSIS Packet Filtering. Internet Firewall. Examples. Spring 2011 CSIS net15 1. Routers can implement packet filtering

Chapter 6. The Network Layer

Guide to Network Defense and Countermeasures Third Edition. Chapter 2 TCP/IP

Gary Hecht Computer Networking (IP Addressing, Subnet Masks, and Packets)

PART IV. Network Layer

Interconnection of Heterogeneous Networks. Internetworking. Service model. Addressing Address mapping Automatic host configuration

TCP/IP Fundamentals. OSI Seven Layer Model & Seminar Outline

Routing in packet-switching networks

Answers to Sample Questions on Network Layer

ICS 351: Today's plan

(Refer Slide Time: 02:17)

Internet Control Protocols Reading: Chapter 3

CS 43: Computer Networks IP. Kevin Webb Swarthmore College November 5, 2013

Guide to TCP/IP, Third Edition. Chapter 3: Data Link and Network Layer TCP/IP Protocols

Internet Protocol version 4 Part I

CS 348: Computer Networks. - IP addressing; 21 st Aug Instructor: Sridhar Iyer IIT Bombay

CS 457 Lecture 19 Global Internet - BGP. Fall 2011

IPv6 Fundamentals Ch t ap 1 er I : ntroducti ti t on I o P IPv6 Copyright Cisco Academy Yannis Xydas

Zarząd (7 osób) F inanse (13 osób) M arketing (7 osób) S przedaż (16 osób) K adry (15 osób)

Internet Protocol (IP) IP - Network Layer. IP Routing. Advantages of Connectionless. CSCE 515: Computer Network Programming IP routing

Savera Tanwir. Internet Protocol

CS 5480/6480: Computer Networks Spring 2012 Homework 4 Solutions Due by 1:25 PM on April 11 th 2012

Classful IP Addressing (cont.)

Internetworking and Internet-1. Global Addresses

Communication Systems Internetworking (Bridges & Co)

Chapter 19 Network Layer: Logical Addressing 19.1

Chapter 4 Network Layer

Network Layer: Network Layer and IP Protocol

This tutorial will help you in understanding IPv4 and its associated terminologies along with appropriate references and examples.

IP Network Layer. Datagram ID FLAG Fragment Offset. IP Datagrams. IP Addresses. IP Addresses. CSCE 515: Computer Network Programming TCP/IP

Lecture 8. IP Fundamentals

CSET 4750 Computer Networks and Data Communications (4 semester credit hours) CSET Required IT Required

Internet Protocol Address

Chapter 3. TCP/IP Networks. 3.1 Internet Protocol version 4 (IPv4)

CCNA Tutorial Series SUBNETTING

LAN Switching Computer Networking. Switched Network Advantages. Hubs (more) Hubs. Bridges/Switches, , PPP. Interconnecting LANs

Ethernet. Ethernet. Network Devices

Network Security TCP/IP Refresher

IP Address Classes (Some are Obsolete) Computer Networking. Important Concepts. Subnetting Lecture 8 IP Addressing & Packets

VLAN und MPLS, Firewall und NAT,

Address Resolution Protocol (ARP), Reverse ARP, Internet Protocol (IP)

Efficient Addressing. Outline. Addressing Subnetting Supernetting CS 640 1

Introduction to LAN/WAN. Network Layer (part II)

- IPv4 Addressing and Subnetting -

CS335 Sample Questions for Exam #2

VXLAN: Scaling Data Center Capacity. White Paper

IP address format: Dotted decimal notation:

Routing Protocols (RIP, OSPF, BGP)

Exhibit n.2: The layers of a hierarchical network

CHAPTER 3 STATIC ROUTING

Note! The problem set consists of two parts: Part I: The problem specifications pages Part II: The answer pages

Networking Test 4 Study Guide

Networking 4 Voice and Video over IP (VVoIP)

Telematics. 9th Tutorial - IP Model, IPv6, Routing

Unix System Administration

Internet Protocol Version 6 (IPv6)

Firewalls und IPv6 worauf Sie achten müssen!

SUPPORT DE COURS. Dr. Omari Mohammed Maître de Conférences Classe A Université d Adrar Courriel : omarinmt@gmail.com

Layer 3 Routing User s Manual

Mobile IP. Bheemarjuna Reddy Tamma IIT Hyderabad. Source: Slides of Charlie Perkins and Geert Heijenk on Mobile IP

Network Layer. Introduction Datagrams and Virtual Circuits Routing Traffic Control. Data delivery from source to destination.

Transcription:

QUIZ: Review of Data Link layer (L2) List four main problems that L2 is designed to solve in a network. For each of the four, name at least two algorithms we studied in Chs. 3 or 4.

solution Framing (length field, bit stuffing, byte stuffing) Flow control (feedback-based or rate based) Error control (detection: parity bits, checksum, CRC; correction: Hamming, convolutional) If only detection is performed, L2 can also implement retransmission: These also work for flow control! Stop-and-Wait, Go-back-N, Selective Repeat Medium access control = MAC (Aloha pure and slotted, CSMA, CSMA/CD, MACA, CSMA/CA )

QUIZ: Ethernet 36. A switch designed for use with Fast Ethernet has a backplane that can move 10 Gbps. How many frames/sec go through the switch during heaviest traffic conditions? Hint: In order to know which port to send the frame to, the switch has to examine its header!

QUIZ: Ethernet 36. A switch designed for use with Fast Ethernet has a backplane that can move 10 Gbps. How many frames/sec go through the switch during heaviest traffic conditions? Hint: What is the shortest FE frame?

solution 36. A switch designed for use with Fast Ethernet has a backplane that can move 10 Gbps. How many frames/sec go through the switch during heaviest traffic conditions? Solution:

QUIZ: Ehernet What is the promiscuous mode for an Ethernet interface? Why is it a security hazard? Is promiscuous mode a problem for stations connected to the same hub? Is promiscuous mode a problem for stations connected to the same switch? Hint: See p.290 of text.

Chapter 5 The Network Layer = L3 Segments Packets Frames Bits / Bytes

Why is L3 needed? L2 is concerned with moving data from one end of a wire to another, whereas L3 is concerned with moving data between source and destination, over many intermediate hops. The existence of bridges (section 4.7 not covered in this course, except for here) seems to contradict the above! A bridge is a L2 device! (a) (b) Two views of bridges: (a) The overall network topology (b) Role in host-to-host communication

Why is L3 needed? Since bridges can already deal with multiple hops in L2 (using forwarding tables, flooding, spanning trees etc.), why not extend the L2 architecture to the entire Internet? This would save a lot of complexity, cost and overhead We would not need L3 addresses (MAC addresses are unique anyway, so why not use only them?!)

Why is L3 needed? Short answer: Because the algorithms for L2 switching do not scale. Examples: Think about flooding the entire Internet for every packet. This would generate a huge superfluous load talk about overhead! Unlike L3 (IP) addresses, MAC addresses are hard-wired in the NICs, and there is no correlation between geography and MAC address space. In order to do universal addressing in L2, each routing table would have to contain all L2 addresses in the world (More than 1 billion hosts see https://www.isc.org/solutions/survey/history) Another reason: There are many different technologies in L2 (e.g. Ethernet, Token bus, token ring, wireless Ethernet, ATM, wireless MAN, HDLC, PPP), and they cannot all directly interoperate. We d have to build a different bridge for each pair of L2 protocols - the n 2 problem again!

5.1 L3 Design Issues Store-and-Forward Packet Switching Services Provided to the Transport Layer Connectionless? Connection-oriented? Implementation of Connectionless Service Implementation of Connection-Oriented Service Comparison of Virtual-Circuit and Datagram Subnets

Store-and-Forward Packet Switching fig 5-1 The environment of the network layer (L3) protocols.

Store-and-Forward vs. Cut-Through fig 5-1 Although used in some L2 switches, Cut-Through is never implemented in L3 routers, b/c of the potential of letting corrupted packets go through.

Services provided by L3 to L4 These services have been designed according to the following principles: 1. Services should be independent of router technology and implementation 2. L4 should be shielded from the number, type and topology of the routers in the subnet 3. Addresses should be uniform, independent of the underlying LAN or WAN technology

Should L3 be connectionless or connection-oriented? a) The Internet community says connectionless Remember: the Internet started as a DoD project, w/explicit goal of survivability! b)the telephone companies say connection-oriented Remember: They installed millions of miles of Tn and OCn lines! They want good QoS for voice traffic.

Implementation of Connectionless Service a.k.a. Datagram The L4 segment is split into 4 L3 packets, which are routed independently. Routing algorithm is responsible for managing routing tables and making routing decisions.

Implementation of Connection-Oriented Service a.k.a. Virtual Circuit (VC) Label switching Route is chosen once and for all (?!) during connection setup. Individual pkts are routed based on their connection identifier (label).

VC vs. Datagram 5-4

VC vs. Datagram Tradeoffs Router memory space vs. bandwidth VC numbers are shorter than full Internet addresses, but maintaining per-vc state consumes memory One routing table vs. two There are fewer VCs going through a router than Internet addresses but connection setup pkts need to be routed, too full Internet addresses are needed in either case! Setup time vs. address parsing time

5.2 Routing Algorithms SKIP The Optimality Principle Shortest Path Routing (Dijkstra) Flooding Distance Vector Routing Hierarchical Routing Link State Routing Broadcast Routing Multicast Routing Routing for Mobile Hosts Routing in Ad Hoc Networks

Routing is the main function of L3. Other functions: congestion ctrl, QoS, fragmentation. Def: Routing algorithm/process = the part of L3 responsible for building and maintaining routing information. creates and updates the routing table Def: Forwarding algorithm/process = the part that actually handles the data pkts, deciding which output line an incoming pkt. is to be transmitted on. creates and updates the fwding table

Routing Algorithms wish-list correctness simplicity robustness don t reboot the entire Nw every time a router or a link crashes stability fast convergence to a state of equilibrium after any perturbation fairness all users must have equal access to Nw resources optimality What do we want to optimize? There are many possible optimization goals, many contradictory. E.g. average delay vs. total throughput. Conflict between fairness and optimality.

Types of Routing Algorithms Non-adaptive RA = static routing All routes computed off-line in advance, then downloaded in the Nw. Simplest form: manual config. of static routes, used on Hosts (Windows, Unix route add) Routers, if the Nw is small (a handful of routes) or there is only one way in/out Advanced forms: various central optimization algorithms (e.g. AT&T had one in the 70s for optimizing load in their long-distance telephone Nw) Adaptive RA = dynamic routing Routing tables change in real time, reflecting changes in topology and/or traffic. Design questions: How to obtain the information? When to operate changes? What metric to use for optimization?

The Optimality Principle If J is on the optimal path from M to B, then the optimal path from J B follows the same route. Sink tree associated with every destination (no loops!) = spanning tree. The goal of any routing algorithm is to discover and use sink trees for all routers in the network.

If J is on the optimal path from M to B, then the optimal path from J B follows the same route. How could the Optimality Principle not hold in a network??

If J is on the optimal path from M to B, then the optimal path from J B follows the same route. How could the Optimality Principle not hold in a network?? A: Optimality can be measured in many ways, and network policies can be selective Example: Packets originated at M are given high priority at C, but those originated at J are not.

handout

Shortest Path Routing Dijkstra (static) Computing the shortest path from A to D: The set of processed nodes is denoted by the circle/ellipse. The set of boundary nodes is denoted by a square. The arrow indicates the node that has just been added to the set of processed nodes.

Dijkstra s algorithm

Dijkstra s algorithm The algorithm stops when the target node D has been included in the set of processed nodes, not in the boundary!

Dijkstra s algorithm Finish the algorithm! EoL1

QUIZ: L3 a) What is the name of L3? b) What is the main function of L3? c) What is the unit of data that L3 is concerned with? d) What are L3 devices called in a network? e) Do L3 devices use store-and-forward or cutthrough transmission? Why? f) What are static and dynamic routing algorithms?

QUIZ: L3 a) State the optimality principle (O.P.). b) Give an example network scenario in which O.P. is not true. c) Name the 3 sets of nodes used in Dijkstra s algorithm. d) Would Dijkstra s algorithm work if O.P. did not hold? Explain why or give a counterexample! e) Do you remember the Big Oh complexity of Dijkstra s algorithm?

Shortest Path Routing Dijkstra (static) Computing the shortest path from A to D: The set of processed nodes is denoted by the circle/ellipse. The set of boundary nodes is denoted by a square. The arrow indicates the node that has just been added to the set of processed nodes.

Flooding Send the pkt. out on all links, except the one it came on. Problem: If loops are present in the topology (and in general they are!), an infinite # duplicate pkts. will be generated. Improvement 1: Source and destination do not fwd. the pkts. Improvement 2: Hop counter in the header of each pkt. (called TTL in IP): Start at a value larger than the diameter of the network Each node decrements it. Discard pkt. when it reaches zero. Nr. of hops between the two most distant nodes

QUIZ: TTL What is the diameter of this network?

Answer: 6 What is the diameter of this network?

handout After 1 st hop After 2 nd hop After 3 rd hop

Flooding Send out copies of pkt. on every outgoing link, except the one the pkt. came in on. Source and destination do not fwd. pkt. Each pkt. carries hop-count information Problem 7 / 475: A sends a pkt. to D with a max. hop count of 3. How many copies does D get? Show the positions of the copies after each hop. Hint: What info. needs to be carried in a pkt.?

Problem 7 / 475: A sends a pkt. to D with a max. hop count of 3. How many copies does D get? Show the positions of the copies after each hop. Individual work for next time: Solve the same problem for max hop count of 4.

QUIZ Is flooding a static or dynamic algorithm? Explain.

Comparison Dijkstra vs. flooding They are two extremes in terms of information needed by the network routers: For Dijkstra alg., each router needs to know all the costs in the network How is this information collected and made available to the nodes? For flooding alg., the router doesn t need to know anything about the network

Distance Vector Routing Distance vector is a distributed routing algorithm Shortest path computation is split across nodes How it works: Each node knows only the distances of the links connecting it to its immediate neighbors Each node advertises the vector of lowest known distances to all neighbors Each node uses received vectors to update its own Repeat periodically

Distance Vector Routing Network Vectors received at J from Neighbors A, I, H and K

Distance Vector Routing What is the Big-Oh complexity of calculation in each router?

Distance Vector Routing What is the Big-Oh complexity of calculation in each router? A: O(k N) = O(N) Compare to Dijkstra O(N 2 ) k is the # of neighbors, usually small

Distance Vector Routing What is the Big-Oh complexity of calculation in each router? A: O(N) However, the local nature that makes this improvement in complexity possible also incurs a cost: In some cases, the DV algorithm can be fooled.

The Count-to-Infinity Problem Failures can cause DV to count to infinity while seeking a path to an unreachable node X Good news of a path to A spreads quickly Bad news of no path to A is learned slowly

The Count-to-Infinity Problem Failures can cause DV to count to infinity while seeking a path to an unreachable node X Good news of a path to A spreads quickly Bad news of no path to A is learned slowly

The Count-to-Infinity Problem The problem can be mitigated with additional strategies: Split horizon: Do not advertise a destination to the next hop to that destination Poisoned reverse: Send infinity to the next hop to that destination However, these strategies are not fool-proof; they fail in more complex network scenarios (involving loops).

Hierarchical Routing Best choice to reach nodes in 5 except for 5C Hierarchical routing reduces the work of route computation but may result in slightly longer paths than flat routing

Hierarchical Routing For larger networks, 3 or more levels may be necessary. Optimal # of levels for an N-node network is ln(n). Each router s table has only e ln(n) entries The increase in mean path length is usually negligible

QUIZ Hierarchical Routing The Internet had an estimated 1 billion hosts in 2014. If optimal h. routing was used, how many levels would be required, and how many entries in each routing table? For larger networks, 3 or more levels may be necessary. Optimal # of levels for an N-node network is ln(n). Each router s table has only e ln(n) entries The increase in mean path length is usually negligible

A 2 handout 6 B 3 C D E 7 8

QUIZ: Distance-Vector Routing A 2 6 B 3 C D E 7 8 a) At step 0, each router in the network detects the distances to its immediate neighbors (all links are duplex and symmetrical). Show the vectors advertised by each node.

solution The vectors first advertised by each node.

b) Show: the calculations performed at each node in step 1 (start with A) each node s routing table at the end of step 1 the vectors advertised by each node at the end of step 1.

partial solution (node A) A knows its own vector and the ones from its neighbors B and C. A s routing table at the end of step 1. The vector advertised by A at the end of step 1.

c) Show the vectors advertised by each node at steps 2, 3, d) When (after how many steps) does the algorithm converge?

e) If link CD goes down, do we have the count-to-infinity problem? Explain, either way. f) Same question if link AC goes down instead.

SKIP all other routing algorithms in section 5.2: --Link state --Broadcast --Multicast --Anycast --Mobile hosts --Ad hoc networks SKIP sections 5.3, 5.4, 5.5 EOL2

5.6 L3 in the Internet SKIP 5.6.1 The IP Protocol (IP v.4) 5.6.2 IP Addresses 5.6.3 IP v.6 Term paper! 5.6.4 Internet Control Protocols OSPF The Interior Gateway Routing Protocol BGP The Exterior Gateway Routing Protocol Internet Multicasting Mobile IP

Internet = Collection of many (sub)networks A pkt. going from 1 to 2 traverses 6 networks (source and destination networks included).

IP (Internet Protocol) was designed to provide a best-effort way (i.e. datagram, i.e. connectionless) to transport pkts. from source to destination, irrespective of how many networks are in between.

Architectural Principles for Internet RFC 1958 http://tools.ietf.org/html/rfc1958 1. Make sure it works. 2. Keep it simple. (KISS! ) 3. Make clear choices. 4. Exploit modularity. 5. Expect heterogeneity. 6. Avoid static options and parameters. 7. Look for a good design; it need not be perfect (a.k.a. satisficing in A.I.) 8. Be strict when sending and tolerant when receiving. 9. Ensure scalability. 10. Consider performance and cost.

9. Scalability Make the core dumb and the edge smart CE = Customer Edge Router, PE = Provider Edge Router, P = Provider Core Router Image source: http://www.ipjforum.org

IP v.4 The header of an IPv.4 pkt. (a.k.a. datagram)

In 32-bit words max 60 byte for entire header max 40 byte for Options. In Bytes max 65535 for entire datagram. IP v.4 or IP v.6 IP v.5? Don t Fragment Congestion? More Fragments Which datagram a fragment belongs to. Initially 3 bits Precedence + 3DTR (Delay, Throughput, Reliability) Today 6 DSCP (DiffServ Code Points) In multiples of 8 bytes. All fragments except the last must be such multiples.

Q: Why not specify the Total length in multiples of 4 Bytes (32 bits)? In Bytes max 65535 for entire datagram. A: B/c the pkt. payload that follows this header is not necessarily a multiple of 4 Bytes!

Extra-credit

Originally designed to count time (sec.) Today counts only hops. Important examples: ICMP=1, IP=4, TCP=6, UDP=17 Go to http://www.iana.org/assignments/protocol-numbers for the complete list of protocols Must be recomputed at each hop, since at least TTL changes Padded to the next multiple of 4 Bytes

The core is dumb, so it shouldn t pay attention to them! IP options (rarely used, most routers ignore them) 5-54 A total of 25 (2 obsolete) are defined at http://www.iana.org/assignments/ip-parameters Internet Assigned Numbers Authority More reading here: http://www.eecs.berkeley.edu/pubs/techrpts/2005/eecs-2005-24.pdf (link on our webpage)

Example IP pkt. (datagram) Source: RFC 791

Error control in IP? Source: RFC 791

IPv.4 Addresses have 32 bits Dotted-decimal notation: Each Byte is represented in its decimal value, with dots in between, e.g. 00101010 10000000 11000000 00000111 (binary) = = 0x2A 80 C0 07 (hex) = = 42.128.192.3 (dotted-decimal)

Your turn! Convert between hex and dotted-decimal: a) 0xAB CD EF 23 = b) 100.32.85.20 = c) 50.100.200.300 =

IP Addresses - until 1981 First (most significant) Byte = network field Last 3 bytes = rest field (identifies host inside network) This was possible because

IP Addresses 1982 Source: http://en.wikipedia.org/wiki/classful_network

IP Addresses 1982 What are the only two companies that had multiple networks at that time? What is each one s claim to fame (in the field of comp. nws.)? Source: http://en.wikipedia.org/wiki/classful_network

solution BBN: J.C.R.Licklider was the earliest originator of the concept of packet-switched nw., then director at ARPA. BBN was awarded by ARPA the contract to build the first incarnation of ARPANET. SRI: The first ARPANET message ( lo(gin) ) was sent from UCLA to SRI. Image source: http://en.wikipedia.org/wiki/classful_network

IP Addresses RFC 791 Internet Protocol (Sept.1981) Initial IP address formats (classful addressing). Dotted decimal notation

QUIZ: How many hosts can there be in a class A, B, and C network? Initial IP address formats (classful addressing).

CIDR = Classless Inter-Domain Routing RFC 1518 + 1519 (1993) later updated by RFC 4632 The three bears problem : a class B network should be just right but in reality it is too large for most organizations wasted address space. Fact: Half of all class B networks have < 50 hosts. QUIZ: assuming the other half are all full (!) what percentage of the class B address space is lost?

CIDR prefixes This is the new CIDR notation. Read: slash 24 See next slide!

Ambiguity: the two meanings of subnet A campus network consisting of subnets (LANs) for various departments. From Ch.1: The subnet is the routing infrastructure of the Internet, a.k.a. the core.

QUIZ: CIDR prefixes What is the dotted-decimal notation for a /26 subnet mask?

solution What is the dotted-decimal notation for a /26 subnet mask? 1111 1111. 1111 1111. 1111 1111. 1100 0000 = = 255.255.255.192

The subnetting idea is extended to the entire Internet, by using masks explicitly in the routing process Each router table entry contains a network address and a subnet mask, e.g. 128.42.43.44/24 The packets themselves do not carry masks, only SA and DA

Example: /26 network prefixes Here the subnet mask consists of 26 bits, leaving 6 bits for the host identifier. This allows for 64 combinations (2 6 ), however the all zeros value and all ones value are reserved for the network ID and broadcast address respectively, leaving 62 addresses. In general the number of available hosts on a subnet is 2 n 2. RFC 3021 specifies an exception to this rule when dealing with 31-bit subnet masks (i.e. 1-bit host identifiers). In such networks, usually point-to-point links, only two hosts (the end points) may be connected and a specification of network and broadcast addresses is not necessary. Source: Wikipedia

Only used in certain ICMP pkts. Special IP Addresses

QUIZ How many hosts can a /17 network have? What is the broadcast address of the network 172.29.96.0/20? What valid host range is the IP address 192.168.149.58/30 a part of?

QUIZ How many hosts can a /17 network have? A: 2 32-17 2 = 32,766 What is the broadcast address of the network 172.29.96.0/20? A: 172.29.111.255 What valid host range is the IP address 192.168.149.58/30 a part of? A: 192.168.149.57 through to 192.168.149.58 http://www.subnettingquestions.com/

Read and understand sections 5.6.1 and 5.6.2, and all the examples we gave today IP addressing practice questions (and answers): http://www.subnettingquestions.com/

Homework for Ch.5 1, 2, 6, 7, 16, 24, 26, 27, 28, 30 Due Thu, April 21 EOL3

QUIZ What is the last valid host on the subnetwork 192.168.185.128 / 26? http://www.subnettingquestions.com/

QUIZ What is the last valid host on the subnetwork 192.168.185.128/26? A: 192.168.185.190 What is the last valid host on the subnetwork 172.29.241.96 255.255.255.224? http://www.subnettingquestions.com/

QUIZ What is the last valid host on the subnetwork 192.168.185.128/26? A: 192.168.185.190 What is the last valid host on the subnetwork 172.29.241.96 255.255.255.224? A: 172.29.241.126 http://www.subnettingquestions.com/

Example: Viewing the routing table in Windows

Subnetting Split up the IP prefix of a network into subnet(work)s to help with management: Looks like a single prefix outside the network ISP gives network a single Class B prefix Network divides it into subnets internally

QUIZ How many subnets and hosts per subnet can you get from the network 172.22.0.0 255.255.254.0? Hint: What class of network is 172.22.0.0 (A, B, C)? http://www.subnettingquestions.com/

QUIZ How many subnets and hosts per subnet can you get from the network 172.22.0.0 255.255.254.0? A: 128 subnets and 510 hosts How many subnets and hosts per subnet can you get from the network 172.31.0.0 255.255.255.128? http://www.subnettingquestions.com/

QUIZ How many subnets and hosts per subnet can you get from the network 172.22.0.0 255.255.254.0? A: 128 subnets and 510 hosts How many subnets and hosts per subnet can you get from the network 172.31.0.0 255.255.255.128? A: 512 subnets and 126 hosts http://www.subnettingquestions.com/

In a router, the masks in the routing table are AND-ed with the DA of the packet, then matched against the corresponding network address Scaling: a router has in its routing table only its local (i.e. LAN) hosts and all other network prefixes

The opposite of subnetting: Aggregation Aggregation joins multiple IP prefixes into a single larger prefix to reduce routing table size ISP advertises a single prefix ISP customers have different prefixes

Aggregation example (Destination) Address Mask 11000010 00011000 00000000 00000000 11111111 11111111 11111000 00000000 11000010 00011000 00001000 00000000 11111111 11111111 11111100 00000000 11000010 00011000 00001100 00000000 11111111 11111111 11111100 00000000 11000010 00011000 00010000 00000000 11111111 11111111 11110000 00000000 aggregation point = right-most point to the left of which all addresses are the same

Longest Matching Prefix Packets are forwarded to the entry with the longest matching prefix or smallest address block Complicates forwarding but adds flexibility Routing tables often contain a default route, which has the shortest possible prefix match, to fall back on in case matches with all other entries fail. Except for this part! Main prefix goes this way

QUIZ: Longest Matching Prefix Send out on interface B Send out on interface A Which interface will the pkt. go to?

Special IP Addresses continued: private addresses One Class A Network: 10.0.0.0 16 Class B Networks: 172.16.0.0-172.31.0.0 256 Class C Networks: 192.168.0.0-192.168.255.0 These are reserved for networks not connected to the Internet (at least not directly connected see NAT later in this section FYI)

QUIZ: private addresses One Class A Network: 10.0.0.0 16 Class B Networks: 172.16.0.0-172.31.0.0 256 Class C Networks: 192.168.0.0-192.168.255.0 What is the total # of private addresses?

SKIP NAT (Network Address Translation) 1999 RFC 2663

How IP addresses are were allocated The Internet Assigned Numbers Authority (IANA) distributes top-level blocks to the 5 regional Internet registries (RIR), which then assign subblocks to end users and local Internet registries, such as Internet service providers, universities and businesses. Source: http://en.wikipedia.org/wiki/ipv4_address_exhaustion

Exhaustion of IPv4 address space On 31 January 2011, the last two unreserved IANA /8 address blocks were allocated to APNIC according to RIR request procedures. Asia-Pacific Network Information Centre This left five reserved but unallocated /8 blocks. In accord with ICANN policies, IANA proceeded to allocate one of those five /8s to each RIR, exhausting the IANA pool, at a ceremony and press conference on 3 February 2011. APNIC was the first regional Internet Registry to run out of freely allocated IPv4 addresses, on 15 April 2011. Source: http://en.wikipedia.org/wiki/ipv4_address_exhaustion

Exhaustion of IPv4 address space What countermeasures have been tried: Classes (1981) CIDR (1993) NAT (1999) and

IP Version 6 Dec.1998, RFC 2460 Major upgrade due mainly to the impending address exhaustion, but also w/various other goals: Support billions of hosts Reduce routing table size Simplify protocol Better security Attention to type of service Aid multicasting Roaming host without changing address Allow future protocol evolution Permit coexistence of old and new protocols

IPv6 The header and is simpler, and it can use optional extension headers (EH): main header 40 Bytes Zero or more extension headers follow the main header All EHs are a multiple of 8 octets in size (may have to use padding!) EHs should appear at most once, except for the Destination Options header, which may appear twice. There are 8 EHs currently defined.

QUIZ Compare the Minimum size Maximum size of the IPv4 and IPv6 headers

IPv6 Implements Virtual Circuits (see p.358) QoS Header excluded, but extension headers included! 256 possible extension headers (in the last header it means L4 protocol like in IPv4) Identical to TTL from IPv4 CN5E by Tanenbaum & Wetherall, Pearson Education-Prentice Hall and D. Wetherall, 2011 No header checksum!

QUIZ Compare the Minimum size Maximum size of the IPv4 and IPv6 packets.

IPv6 The header has much longer addresses (128 vs. 32 bits) 40 Bytes Compare the number of possible IPv6 addresses with the number of bacteria living on earth, which is estimated to be 5,000,000,000,000,000,000,000,000,000,000. = 5 10 30 Source: http://www.ehow.com/about_4674401_how-many-bacteria-live-earth.html

IPv6 and the Internet of things The catch: Individual bulbs run in the $20 to $30 range! http://www.greentechmedia.com/articles/read/the-ipv6-addressable-light-bulb-goes-on-sale

IPv6 Extension Headers All routers along the path must examine it! E.g.: hop-by-hop header has an option for jumbogram # of Bytes is specified on 32 bits. Excludes main hdr., but includes all extension hdrs.

QUIZ What is the maximum size of an IPv6 packet if the jumbogram header is used?

Conclusion IPv6 improvements over IPv4 Longer addresses (128 bits vs. 32) Simpler header (7 fields vs. 13) Better support for options (extension headers) Native support for security: Authentication Privacy QOS (Quality of Service) The Diff.Serv. field defines traffic class. The Flow Label field supports VCs.

IPv6 vs. IPv4 IPv6 does not specify interoperability features with IPv4, but essentially creates a parallel, independent network. Exchanging traffic between the two networks requires translator gateways employing NAT64; or other transition technologies, such as tunneling protocols However, IPv6 is compatible with the auxiliary Internet protocols (see next Sec. 5.6.4) Deployment of IPv6 has been slow & painful, but is picking up pace now that IPv.4 addresses are exhausted. As of September 2013, about 4% of domain names and 16.2% of the networks on the internet have IPv6 protocol support. http://en.wikipedia.org/wiki/ipv6#deployment

IPv6 deployment IPv6 has been implemented on all major operating systems in use in commercial, business, and home consumer environments. Since 2008, DNS (domain name system) can be used in IPv6. IPv6 was first used in a major world event during the 2008 Summer Olympic Games, the largest showcase of IPv6 technology to date. Some governments (incl. U.S. and China) are starting to require IPv6 capability on their equipment. In 2009, Verizon mandated IPv6 operation and deprecated IPv4 as an optional capability for cellular (LTE) hardware. T-Mobile USA followed suit: as of June 2012, they support external IPv6 access. http://en.wikipedia.org/wiki/ipv6#deployment

5.6.4 Internet Control Protocols IP works with the help of several control protocols: ICMP is a companion to IP that returns error info Required, and used in many ways, e.g., for traceroute ARP finds Ethernet address of a local IP address Glue that is needed to send any IP packets Host queries an address and the owner replies DHCP assigns a local IP address to a host Gets host started by automatically configuring it Host sends request to server, which grants a lease

ICMP Main ICMP (Internet Control Message Protocol) types:

ARP: Address Resolution Prot.

ARP RFC 826 Routers do not forward Ethernet broadcasts (why?) but they can be configured for proxy ARP

QUIZ ARP Problem 35: You have just explained ARP to a friend, and (s)he says: ARP provides a service to the Network layer, so it s part of the data link layer. What do you reply?

DHCP RFC 2131, 2132 Host w/o IP address broadcasts DHCP DISCOVER pkt. DHCP server replies with DHCP OFFER pkt. Leasing is used to avoid inactive host hogging up addresses.

Read and understand sections 5.6.1 through 5.6.4, and all the examples we gave today SKIP the remainder of Ch.5, starting with MPLS

Don t forget the homework is due next time! Homework for Ch.5 1, 2, 6, 7, 16, 24, 26, 27, 28, 30 Due Thu, April 21