Archive | April, 2015

Neighbor Discovery

25 Apr

Address Resolution:
———————–
-> Nodes exchange Neighbor Solicitation & Neighbor Advertisement messages to resolve the link-layer address of the on-link next-hop address for a given destination.
-> The multicast address of the Neighbor Solicitation message is the solicited-node multicast address derived from the target IP address.
(specified a prefix length of “104” bit prefixed with least 24 bits of destination IP address.)
Dest IP:   2001:DB2::1F5C:7A92
Prefix:    FF02::1:FF
So Solicitated Multicast Address:   FF02::1:FF + 5C:7A92  = FF02::1:FF5C:7A92
– R1 and R2 are brought up in the same link.
– Initially no neighbor entries exists.
– From R1, ping to R2. i.e ping6 2001:DB2::1F5C:7A92
– R1 sends NS to R2(multicast). R2 responds with NA to R1 (unicast).

-> Sender host sends NS message to multicast address. since no other host has that IP address, it is the only host that will receive these frames. so that not every
device on the segment needs to process the packet.
-> When the target host receives the Neighbor Solicitation message, it updates its own neighbor cache based on the source address of the Neighbor Solicitation
message and the link-layer address in the source Link-Layer Address option.
-> Next, the target host sends a (unicast) Neighbor Advertisement to the Neighbor Solicitation sender. The Neighbor Advertisement includes the Target Link-Layer Address
option.
-> After receiving the Neighbor Advertisement from the target host, the sending host updates its neighbor cache with an entry for the target host based on the
information in the Target Link-Layer Address option. At this point, the sending host and the target host can send unicast IPv6 traffic to each other.

-> destination Ethernet address will be prefixed with multicast 33:33:FF.

NS_packet

Neighbor Solicitation

 

NA_packet

Neighbor Advertisement

Duplicate Address Detection:
———————————-
-> IPv4 nodes use ARP Request messages and a method called gratuitous ARP to detect duplicate IP addresses on their local links.
Similarly, IPv6 nodes use the Neighbor Solicitation message to detect duplicate address use on their local links.
-> With gratuitous ARP, the Source Protocol Address and Target Protocol Address fields in the ARP Request message header are set to the IPv4 address for which
duplication is being detected.
Similarly, in IPv6 duplicate address detection, the Target Address field in the Neighbor Solicitation message is set to the IPv6 address for which duplication
is being detected.
-> Duplicate address detection differs from address resolution in these ways:
– In a Neighbor Solicitation message for duplicate address detection, the Source Address field in the IPv6 header is set to the unspecified address (::).
The address being queried for duplication cannot be used until it is determined that the address is not already in use.
– In the Neighbor Advertisement reply to a Neighbor Solicitation message for duplicate address detection, the Destination Address in the IPv6 header is set to the
link-local scope all-nodes multicast address (FF02::1). Because the sender of the Neighbor Solicitation message for duplicate address detection is not using the
desired address, it cannot receive unicast Neighbor Advertisement messages. Therefore, the Neighbor Advertisement message is multicast.
-> Upon receipt of the multicast Neighbor Advertisement message sent in response to the Neighbor Solicitation message, the node disables the use of the duplicate
address on the interface. If the node does not receive a Neighbor Advertisement message that defends the use of the IPv6 address, it initializes the address on the
interface.

Neighbor_Solicitation_for_Duplicate_Address_Detection

Neighbor Solicitation for Duplicate Address Detection

Neighbor_Advertisement_for_Duplicate_Address_Detection

Neighbor Advertisement for Duplicate Address Detection

 

Path MTU Discovery:
————————-
-> The maximum transmission unit (MTU) for a path is the minimum link MTU of all links on a path between a source and a destination.
-> To discover the path MTU, the sending host uses the receipt of ICMPv6 Packet Too Big messages.

Sending hosts discover the path MTU through the following process:
1.The sending host assumes that the path MTU is the link MTU of the interface on which the traffic is being forwarded.
2.The sending host sends IPv6 datagrams at the path MTU size.
3.If a router on the path is unable to forward the packet over a link because the packet is larger than the link MTU, the router sends an ICMPv6 Packet Too Big
message back to the sending host and discards the packet. The Packet Too Big message contains the MTU of the link on which the forwarding failed.
4.The sending host sets the path MTU for packets being sent to the destination to the value of the MTU field in the Packet Too Big message.

-> The sending host starts again at step 2 and repeats steps 2 through 4 as many times as necessary to discover the path MTU.
-> The sending host determines the path MTU when the node receives either an acknowledgement from the destination or no more Packet Too Big messages.

IPv6_ICMPv6_Path_MTU

PATH MTU