Network Layer – Part 2

24
Network Layer – Part Network Layer – Part 2 2 염염염

description

Network Layer – Part 2. 염익준. ICMP Features. Internet Control Message Protocol ICMP: Used by IP to send error and control messages ICMP uses IP to send its messages ICMP does not report errors on ICMP messages. ICMP Message Format. ICMP: Message Types. Type description - PowerPoint PPT Presentation

Transcript of Network Layer – Part 2

Page 1: Network Layer – Part 2

Network Layer – PartNetwork Layer – Part 22

염익준

Page 2: Network Layer – Part 2

2

ICMP FeaturesICMP Features

• Internet Control Message Protocol• ICMP: Used by IP to send error and control

messages • ICMP uses IP to send its messages • ICMP does not report errors on ICMP messages.

Page 3: Network Layer – Part 2

3

ICMP Message FormatICMP Message Format

8-bit type of message

8-bit error code 16-bit checksum

(contents depends on type and code)

Page 4: Network Layer – Part 2

4

ICMP: Message TypesICMP: Message Types

Type description0 echo reply (ping)3 destination unreachable4 source quench 5 redirect8 echo request (ping)9 route advertisement10 router discovery11 TTL expired12 bad IP header13 timestamp request14 timestamp reply15 information request16 information reply17 address mask request18 address mask reply

Page 5: Network Layer – Part 2

5

Destination UnreachableDestination Unreachable

code Meaning

0123456789

101112

network unreachablehost unreachableprotocol unreachableport unreachablefragmentation needed but don’t fragment bit setsource route faileddestination network unknowndestination host unknownsource host isolateddestination network administratively prohibiteddestination host administratively prohibitednetwork unreachable for TOShost unreachable for TOS

Page 6: Network Layer – Part 2

IP version 6IP version 6- IP Next Generation (IPng)- IP Next Generation (IPng)

Page 7: Network Layer – Part 2

7

Related RFCsRelated RFCsRFC Title Date

1752 The recommendation for the IP Next Generation Protocol Jan 1995

1809 Using the flow label in IPv6 Jun 1995

1881 IPv6 address allocation management Dec 1995

1883 IPv6 specification Dec 1995

1884 IPv6 addressing architecture Dec 1995

1885 ICMPv6 for the IPv6 specification Dec 1995

1886 DNS extensions to support IPv6 Dec 1995

1887 An architecture for IPv6 unicast address allocation Dec 1995

1897 IPv6 testing address allocation Jan 1996

1924 A compact representation of Ipv6 addresses Apr 1996

1933 Transition mechanisms for IPv6 hosts and routers Apr 1996

Page 8: Network Layer – Part 2

8

IPng Considerations IPng Considerations

• Addressing– the two level structure of the IP address is convenient but wasteful of

address spaces.– it is general practice to assign a unique network number to an IP

network whether or not it is actually connected to the Internet.– networks are proliferating rapidly.– growth of TCP/IP usage in new areas will result in a rapid growth in the

demand for unique IP addresses.• Performance

– reduced number of fields in the IPv6 packet header– fixed length of header – extension header– disabling fragmentation

Page 9: Network Layer – Part 2

9

IPng ConsiderationsIPng Considerations

• Network service– should be possible to associate packets with particular services

classes – flow label

• Addressing flexibility– anycast – delivered to just one of a set of nodes– multicast – improved scalability by a scope filed

• Security capabilities– providing authentication and privacy

Page 10: Network Layer – Part 2

10

IPv6 Packet HeaderIPv6 Packet Header

Version TrafficClass FlowLabel

PayloadLen NextHeader HopLimit

SourceAddress

DestinationAddress

0 4 12 16 24 31

Next header/data

Page 11: Network Layer – Part 2

11

Traffic ClassTraffic Class

• One bit for two classes – congestion controlled traffic– non-congestion controlled traffic

• Three bits for eight priorities in each class

Page 12: Network Layer – Part 2

12

Flow LabelFlow Label

• a flow is a sequence of packets that– are generated from a single application instance from the source’s

point of view– share attributes which affect how they are handled from the router’s

point of view• Rules for flow label

– hosts or routers that do not support the flow label field must • set the field to zero when originating a packet• pass the field unchanged when forwarding a packet• ignore the field when receiving a packet

– all the packets with the same non-zero flow label must have the same destination address, source address, priority, hop-by-hop options header contents and routing header contents.

– the source assigns a flow label to a flow.

Page 13: Network Layer – Part 2

13

• 128 bit address space• Address notation: 47cd:1234:4422:ac02:0022:1234:a456:0123

AddressingAddressing

125– m– n– o– pponm3

SubscriberIDProviderIDRegistryID010 InterfaceIDSubnetID

Page 14: Network Layer – Part 2

14

Address Prefix AssignmentAddress Prefix Assignment

Prefix Use Prefix Use

0000 0000 Reserved 101 Unassigned

0000 0001 Unassigned 110 Unassigned

0000 001 Reserved for NSAP 1110 Unassigned

0000 010 Reserved for IPX 11110 Unassigned

0000 011 Unassigned 1111 0 Unassigned

0000 1 Unassigned 1111 10 Unassigned

0001 Unassigned 1111 110 Unassigned

001 Unassigned 1111 1110 0 Unassigned

010 Unicast address 1111 1110 10 Link local use

011 Unassigned 1111 1110 11 Site local use

100 Unassigned 1111 1111 Multicast

Page 15: Network Layer – Part 2

15

AnycastAnycast

• Delivery method:– unicast: one-to-one– multicast: one-to-many– broadcast: one-to-all– anycast: one-to-one-of-many

• Anycast address: an address assigned to multiple hosts

Page 16: Network Layer – Part 2

16

Multicast TechnologyMulticast Technology

• Requires group communication– one-to-many or many-to-many– dynamic mgmt of group subscription

• Big problem with unicast technology: bandwidth waste with multiple data flows

Page 17: Network Layer – Part 2

17

Why Multicast?Why Multicast?

• Typical applications – Multimedia conference (video, audio, digital whiteboard) – Resource discovery (e.g., auto-topology) – War simulation – Commercial apps (e.g., transactions, news distribution) – Routing protocols (e.g., both EIGRP and OSPF use multicast to

send updates to neighbors) – Games (e.g., distributed arcades) – Physics apps

Page 18: Network Layer – Part 2

18

Principles of MulticastingPrinciples of Multicasting

• Special IP addresses are used to identify multicast groups

• Hosts notify multicast routers about the multicast groups to which they (want to) belong

• Multicast groups are managed by the routers using multicast routing protocols

Page 19: Network Layer – Part 2

19

Multicast AddressesMulticast Addresses

• Multicast packets are identified by Class D IP addresses

• Global range from 224.0.0.0 to 239.255.255.255 – Reserved: 224.0.0.0-224.0.0.255 – Internet-wide addresses: 224.0.1.0-238.255.255.255 – Local addresses: 239.0.0.0-239.255.255.255

• Some special addresses – 224.0.0.1: all multicast systems on a subnet – 224.0.0.2: all multicast routers on a subnet

Page 20: Network Layer – Part 2

20

Multicast GroupsMulticast Groups

• IGMP - Internet Group Management Protocol (RFC 1112) – defines how hosts tell routers which groups they are part of;

available on Unix, PCs, Mac – routers query directly connected hosts sending an IGMP query

to 224.0.0.1 (i.e., all multicast systems) • when there is more than one multicast router on a LAN,

only one has to send the query • access lists can be applied to restrict the multicast groups

hosts can receive – hosts send a single reply per group per LAN

Page 21: Network Layer – Part 2

21

Multicast Routing ProtocolsMulticast Routing Protocols

• Forwarding decisions: different from unicast protocols – multicast protocols use the source address instead of the destination

address to make their forwarding decisions • Two main protocols

– DVMRP (Distance Vector Multicast Routing Protocol) • Distance vector (RIP-like) algorithm • Static configuration based on tunnels between DVMRP routers

(often Sun workstations) • Not easily scalable (e.g., max hops < 32)

– PIM (Protocol Independent Multicast) • Typically installed on routers • Independent from the unicast routing protocols used by the router • Scalable (Dense-mode & Sparse-mode)

Page 22: Network Layer – Part 2

22

FloodingFlooding

• When a router receives a packet that is addressed to a multicast

group, it determines whether this is the first time the router has

seen this particular packet. • If so, it forwards the packet on all the interfaces except the one

on which it arrived.• Simple to implement.• Does not scale well because of the large number of duplicate

messages.

Page 23: Network Layer – Part 2

23

RPFRPF

• Reverse Path Forwarding (RPF) – A router accepts a multicast packet from a source if and only if the

packet has been received over the interface used to send unicast packets to the source

– If the RPF test succeeds, the packet is forwarded to all the interfaces included in the router’s OIF (Outgoing Interface List)

– If the RPF test fails, the multicast packet is discarded – A packet should never be re-sent over the RPF interface (to avoid

loops)

Page 24: Network Layer – Part 2

24

DVMRP constructs source-rooted multicast delivery trees using RPF algorithm.

Basic operations follow:. The first datagram for any (source, group) pair is forwarded across

the entire internetwork. The leaf routers transmit prune messages back toward the source if

there are no group members on their directly attached leaf subnetworks.

Periodically the prune state times out, and the next datagram for the (source, group) pair is forwarded across the entire internetworks.

Implements a “graft” operation for quickly establishing a new branch. if a router that previously sent a prune message for a (source,

group) pair discovers new group members on a leaf network, it sends a “graft message” to the group’s previous-hop router.

When an upstream router receives a “graft” message, it cancels the previously received prune message. Graft messages may cascade back towards the source to establish the branch to the multicast tree.

DVMRPDVMRP