Home | Reports | Technical Documents | Tech-Blog | One-Shot Gallery | Korea ICT News | Korea Communication Market Data | List of Contributors | Become a Contributor |    
 
 
Section 5G 4G LTE C-RAN/Fronthaul Gigabit Internet IPTV/Video Streaming IoT SDN/NFV Wi-Fi KT SK Telecom LG U+ Network Protocol Samsung   Korean Vendors
 
Real World Private 5G Cases   4 Deployment Models On-Premise Cases 5G Core Control Plane Sharing Cases

5G Core Sharing Cases

   
 
Private 5G Deployment   • Private 5G Frequency Allocation Status in Korea  South Korean government's regulations on private 5G and KT's strategy for entering the market
Cases in Korea   Private 5G Operators |   SK Networks Service (SI) Sejong Telecom (Wire-line Carrier) KT MOS (Affiliate of KT) • Newgens (SI) • NAVER Cloud more >>  
    Enterprise DIY |   Korea Hydro & Nuclear Power (Power Plant) Korea Electric Power Corporation (Energy) • Republic of Korea Navy more >>
 
CHANNELS     HFR Private 5G Solution (my5G)       my5G Solution Components       my5G Key Features        my5G Resources        my5G News          
 
banner
banner
Switching and Routing - Part 4. IP Forwarding by L3 Switch
August 01, 2014 | By Chris Yoo (tech@netmanias.com)
Online viewer:
Comments (3)
19

 

  Switching and Routing

    1. Switching and Routing for Dummies - Ethernet Switching
    2. Switching and Routing for Dummies - IP Routing
    3. Switching and Routing - Part 1. Router Architecture
    4. Switching and Routing - Part 2. Packet Forwarding by IP Router
    5. Switching and Routing - Part 3. L2 (Ethernet) Switching by L3 Switch
    6. Switching and Routing - Part 4. IP Forwarding by L3 Switch

 

 

Let's talk about IP routing (IP forwarding) by L3 switch. Please follow us carefully as this process is the most complicated one.


Network Topology


Below is the same network topology we discussed in the previous post, except this time packet delivery is from SVR1 (1.1.1.10) to SVR4 (2.1.1.30).

 

 


1. Delivering a Packet from SVR1 to SVR4: R1, Flooding an ARP Request to the Ports that belong to the Destination VLAN, after Receiving an IP Packet

 

 

SVR1 needs to send a packet to the destination, SVR4 with IP address of 2.1.1.30.
Through routing table lookup, SVR1 finds out the destination is matched to the default route (0.0.0.0/0), and thus the gateway address is 1.1.1.1 (R1) and the OIF is lan1.
Then through ARP table lookup, it also finds out the MAC address of the gateway address 1.1.1.1 is a1 (For easier explanation, we assume a1 is listed as the MAC address in SVR1's ARP table)
SVR1 sends a packet consisting of the following information to the destination address 2.1.1.30:

 

[Ethernet Header] Destination MAC address = a1 (R1's MAC address), Source MAC address = m1 (SVR1's MAC address)
[IP Header] Destination IP address = 2.1.1.30 (SVR4's IP address), Source IP address = 1.1.1.10 (SVR1's IP address)

 

The line card #1 at R1 keeps the packet received through ge1/1 port in the ingress packet buffer for a while.


Source MAC Learning
The packet processor at the line card #1 checks its MAC table to see if there is an entry that matches m1, the source MAC address of the received packet, or not. In this example, there is no matching entry.
So, the processor informs the control module of the event that "m1, the source MAC address, belonging to VLAN 10 is mapped to ge1/1 port".
The control module records the received information in its MAC table (source MAC learning).
Now, the control module has to send the learned MAC address information to the line cards. Note that not all the line cards, but only those with the same VLAN need the learned MAC information. So, the control module refers to the VLAN table, and finds out that ge1/1, ge1/2 and ge2/1 ports belong to VLAN 10, and that the line cards #1 and #2 support the VLAN. Note that entries in the VLAN table are created when VLAN values are assigned through CLI.
The control module forwards the MAC information (VLAN=10, source MAC=m1, port=ge1/1) to the line cards #1 and #2 so that the same information can be copied into their MAC tables (allowing for source MAC learning).


IP Routing or Ethernet Switching
The packet processor has to decide whether to perform IP routing (delivering packet through FIB lookup) or Ethernet switching (delivering through MAC table lookup). So, it checks the destination MAC address of the received packet.

  • If it is a1, the MAC address of L3 switch R1, then IP routing is performed.
  • If not, Ethernet switching is performed.

In this example, IP routing is performed because the destination MAC address is a1.


IP Routing based on Destination IP address
Through FIB lookup (LPM: Longest Prefix Match) for the destination IP address 2.1.1.30, the packet processor finds out the destination of the packet is directly connected to R1, and the OIF is VLAN 20.
Then through ARP table lookup, it checks if there is an entry that matches the MAC address of the destination 2.1.1.30.
No matching entry in the ARP table. So, the processor informs the control module of ARP miss event (no MAC address for 2.1.1.30).
The control module hence checks the VLAN table to identify line cards that belong to VLAN 20. Here the line cards #1 and #2 have the ports that belong to VLAN 20.
The control module now sends an ARP request (Who has 2.1.1.30? Tell 2.1.1.1) packet to the two line cards.
Upon receiving the ARP request packet, the two cards refer to their VLAN tables and identify the ports that belong to VLAN 20.
The ARP Request packet is sent (flooded) to ge1/3 port in the line card #1, and ge2/2 and ge2/3 in the line card #2.

 

 

2. Delivering a Packet from SVR1 to SVR4: R1, Receiving an ARP Reply from SVR4

 

 

The ARP request packet is received by SVR4, SVR5 and SVR6. SVR4, of which IP address is 2.1.1.30, responds to the request by sending an ARP reply (2.1.1.30 is at m3) packet to R1.
Again, the received packet is kept in the ingress packet buffer for a while.
③④⑤⑥⑦ The same source MAC learning explained in the previous section above is performed. As a result, R1 now knows m3, the source MAC address that belongs to VLAN 20, is mapped to ge1/3 port.
The packet processor notices the destination MAC address of the received packet is a1, R1's MAC address, and thus IP routing should be performed.
Then, it notices the packet type (EtherType in Ethernet Header) is marked as ARP packet (EtherType = 0x0806). All ARP packets are sent to the control module, instead of being routed, if their destination MAC addresses are matched to the MAC address of the router (i.e. a1 here).
The control module, upon receiving the ARP reply, records m3, the MAC address of 2.1.1.30, in its ARP table.
It sends the learned information to the line card #1 that has forwarded the ARP packet, so that the same information can be recorded in the ARP table there as well.

 


3. Delivering a Packet from SVR1 to SVR4: IP Routing (Forwarding)

 

 

R1 is ready to send a packet (routing) to the destination 2.1.1.30.

SVR1 sends a packet destined for the destination 2.1.1.30 to R1.
R1 keeps it in the ingress packet buffer for a while.
The source MAC address of the received packet is m1, a learned MAC address. So, source MAC learning is skipped.
R1 notices the destination MAC address is set a1, which is its own MAC address. So, the packet should be routed.
The FIB lookup for the destination IP address of the received packet (2.1.1.30) finds the OIF is VLAN 20.
And the ARP table lookup finds the MAC address for 2.1.1.30 is m3.
Finally, R1 performs MAC table lookup with m3, and finds out m3 is mapped to port ge1/3.
Now it moves the packet kept in the ingress packet buffer to the egress packet buffer to deliver.
The packet is now delivered to ge1/3.

 

 

Summary

 
   

 

Through this and three previous posts, we have looked into packet delivery by router/L3 switch. 
The three most fundamental functions of L3 switch can be summarized as follows: 
 
First, L3 switch always performs source MAC learning first whether it is planning Ethernet switching or IP routing.
Second, it performs IP routing if the destination MAC address of a received packet is the MAC address of L3 switch. If not, it performs Ethernet switching.
Third, during IP routing, L3 switch refers to the MAC table when actually deciding to which OIF to send a packet. This is because, the OIFs listed in RIB/FIB may be VLAN ID information, not physical ports. 

That is,


1) It finds out the next hop address (e.g. 20.1.1.1) and OIF (e.g. VLAN = 30) through FIB lookup.
2) Then, through ARP table lookup, it determines the MAC address of the next hop address (e.g. c1). If no next hop (if connected directly to L3 switch), it searches through the table for the MAC address corresponding to the destination IP address (e.g. 100.1.1.) instead.

3) Through MAC table lookup, it knows which physical port (e.g. ge3/1) is mapped to the MAC address (e.g. c1). Here, the physical port refers to the one that belongs to the VLAN listed as the OIF in FIB (e.g. VLAN 30).

4) If no matching entry is found in the MAC table during IP routing, L3 switch floods the packet to all physical ports that belong to the OIF (VLAN =30) by referring to the VLAN table.

 

 

 

 

 

learncisco.net 2014-12-27 21:32:00

Very good writing I must say . in the forwarding side I got some ambiguities but get with them when I tried them more than once. Worthy post !

John 2015-08-29 04:25:11

Nice presentation, lots of info

Ruddhi 2016-06-24 12:04:15

When does a router broadcast a packet or an ARP request? In last post, when receiving an unknown destination MAC packet, the router broadcasts the packet? Why does it broadcast an ARP request in this post? Thanks!

Thank you for visiting Netmanias! Please leave your comment if you have a question or suggestion.
 
 
 
 

[HFR Private 5G: my5G]

 

Details >>

 

 

 

     
         
     

 

     
     

Subscribe FREE >>

Currently, 55,000+ subscribed to Netmanias.

  • You can get Netmanias Newsletter

  • You can view all netmanias' contents

  • You can download all netmanias'

    contents in pdf file

     
     

 

     
         
     

 

 

 

View All (858)
4.5G (1) 5G (102) AI (8) AR (1) ARP (3) AT&T (1) Akamai (1) Authentication (5) BSS (1) Big Data (2) Billing (1) Blockchain (3) C-RAN/Fronthaul (18) CDN (4) CPRI (4) Carrier Ethernet (3) Charging (1) China (1) China Mobile (2) Cisco (1) Cloud (5) CoMP (6) Connected Car (4) DHCP (5) EDGE (1) Edge Computing (1) Ericsson (2) FTTH (6) GSLB (1) GiGAtopia (2) Gigabit Internet (19) Google (7) Google Global Cache (3) HLS (5) HSDPA (2) HTTP Adaptive Streaming (5) Handover (1) Huawei (1) IEEE 802.1 (1) IP Routing (7) IPTV (21) IoST (3) IoT (56) KT (43) Korea (20) Korea ICT Market (1) Korea ICT Service (13) Korea ICT Vendor (1) LG U+ (18) LSC (1) LTE (78) LTE-A (16) LTE-B (1) LTE-H (2) LTE-M (3) LTE-U (4) LoRa (7) MEC (4) MPLS (2) MPTCP (3) MWC 2015 (8) NB-IoT (6) Netflix (2) Network Protocol (21) Network Slice (1) Network Slicing (4) New Radio (9) Nokia (1) OSPF (2) OTT (3) PCRF (1) Platform (2) Private 5G (11) QoS (3) RCS (4) Railway (1) Roaming (1) SD-WAN (17) SDN/NFV (71) SIM (1) SK Broadband (2) SK Telecom (35) Samsung (5) Security (16) Self-Driving (1) Small Cell (2) Spectrum Sharing (2) Switching (6) TAU (2) UHD (5) VR (2) Video Streaming (12) VoLTE (8) VoWiFi (2) Wi-Fi (31) YouTube (6) blockchain (1) eICIC (1) eMBMS (1) iBeacon (1) security (1) telecoin (1) uCPE (2)
Password confirmation
Please enter your registered comment password.
Password