IP Library Granted Patent US 9,525,631
Granted Patent B2
US 9,525,631 · App. 14/289,055 · Granted Dec 20, 2016

Packet forwarding method, apparatus, and system

Inventor: Youquan Luo (Shenzhen, CN)
Assignee: HUAWEI TECHNOLOGIES CO., LTD.
H04L45/745H04L12/56H04L45/74H04L61/103
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 9,525,631
App. No.
14/289,055
Granted
Dec 20, 2016
Kind
B2
Abstract

A packet forwarding method, includes: receiving an IP packet, and obtaining a destination IP address carried in the IP packet; obtaining an IP address of a next-hop device on a link from a routing table according to the destination IP address; obtaining a MAC address of the next-hop device and a corresponding port number according to the IP address of the next-hop device; and if failing to obtain the MAC address of the next-hop device and the corresponding port number, obtaining a corresponding interface on the routing device from the routing table according to the destination IP address, and obtaining the MAC address of the next-hop device and the corresponding port number from a fuzzy ARP table according to the interface; and forwarding the IP packet to the next-hop device according to the MAC address of the next-hop device and the port number.

Claims (26)

1. A packet forwarding method, comprising:

receiving, by a routing device, an Internet protocol (IP) packet, and obtaining a destination IP address carried in the IP packet;

obtaining, by the routing device, an IP address of a next-hop device on a link from a routing table according to the destination IP address;

obtaining, by the routing device, a media access control (MAC) address of the next-hop device and a corresponding port number on the routing device from a first address resolution protocol (ARP) table according to the IP address of the next-hop device; and if failing to obtain the MAC address of the next-hop device and the corresponding port number on the routing device, obtaining a corresponding interface on the routing device from the routing table according to the destination IP address, and obtaining the MAC address of the next-hop device and the corresponding port number on the routing device from a second ARP table according to the interface; and

forwarding, by the routing device, the IP packet to the next-hop device according to the MAC address of the next-hop device and the port number;

wherein the first ARP table records a mapping relationship between the IP address of the next-hop device, the port number, the interface, and the MAC address; the second ARP table records a mapping relationship between the interface, the port number, and the MAC address.

2. The method according to claim 1 , before the receiving an IP packet, further comprising:

sending, by the routing device, a free ARP packet through the interface, wherein the free ARP packet carries a MAC address and an IP address of the routing device.

3. The method according to claim 1 , before the receiving an IP packet, further comprising:

receiving a free ARP packet, wherein the free ARP packet carries a MAC address; and

storing a mapping relationship between a number of a port and an interface receiving the free ARP packet and the MAC address carried in the free ARP packet into the second ARP table.

4. The method according to claim 3 , wherein when the interface enters an inactive state from an active state, an entry corresponding to the interface is deleted from the second ARP table.

5. A routing device, comprising:

a receiver, configured to receive an Internet protocol (IP) packet, and obtain a destination IP address carried in the IP packet;

a processor coupled to the receiver, configured to obtain an IP address of a next-hop device on a link from a routing table according to the destination IP address; obtain a media access control (MAC) address of the next-hop device and a corresponding port number on the routing device from a first address resolution protocol (ARP) table according to the IP address of the next-hop device; and if failing to obtain the MAC address of the next-hop device and the corresponding port number on the routing device, obtain a corresponding interface on the routing device from the routing table according to the destination IP address, and obtain the MAC address of the next-hop device and the corresponding port number from a second ARP table according to the interface; and

a transmitter coupled to the processor, configured to forward the IP packet to the next-hop device according to the MAC address of the next-hop device and the port number;

wherein the first ARP table records a mapping relationship between the IP address of the next-hop device, the port number, the interface, and the MAC address; the second ARP table records a mapping relationship between the interface, the port number, and the MAC address.

6. The routing device according to claim 5 , wherein:

the receiver is further configured to receive a free ARP packet, wherein the free ARP packet carries an IP address and a MAC address of another device on the link; and

the processor is further configured to obtain a number of a port receiving the free ARP packet, and record a mapping relationship between the obtained port number, the corresponding interface, and the MAC address carried in the free ARP packet into the second ARP table.

7. The routing device according to claim 5 , wherein the processor is further configured to delete an entry corresponding to the interface from the second ARP table when the interface enters an inactive state from an active state.

8. A packet forwarding system, comprising:

a routing device, configured to: receive an Internet protocol (IP) packet, and obtain a destination IP address carried in the IP packet; obtain an IP address of a next-hop device on a link from a routing table according to the destination IP address; obtain a media access control (MAC) address of the next-hop device and a corresponding port number on the routing device from a first address resolution protocol (ARP) table according to the IP address of the next-hop device; and if failing to obtain the MAC address of the next-hop device and the corresponding port number on the routing device, obtain a corresponding interface on the routing device from the routing table according to the destination IP address, and obtain the MAC address of the next-hop device and the corresponding port number from a second address resolution protocol ARP table according to the interface; and forward the IP packet to the next-hop device according to the MAC address of the next-hop device and the port number;

the next-hop device linked to the routing device, configured to receive the IP packet from the routing device;

wherein the first ARP table records a mapping relationship between the IP address, the port number, the interface, and the MAC address; the second ARP table records a mapping relationship between the interface, the port number, and the MAC address.

9. The system according to claim 8 , wherein the routing device is further configured to receive a free ARP packet, wherein the free ARP packet carries an IP address and a MAC address of another device, obtain a number of a port receiving the free ARP packet, and record a mapping relationship between the obtained port number, the corresponding interface, and the MAC address carried in the free ARP packet into the second ARP table.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 29, 2014
From: LUO, YOUQUAN
To: HUAWEI TECHNOLOGIES CO., LTD.
Reel/Frame 032986/0992 →
Priority Claims (1)
CN 2011 1 0386699 · Nov 29, 2011 · national
Continuity (2)
Continuation PCTCN2012079705 · Aug 6, 2012
Related Publication 20140269729A1 · Sep 18, 2014