# US 2016/0261460 A1 · Method for Upgrading Version of Network Device and Network Device

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2016/0261460 A1
- Document ID: US20160261460A1
- Status: Published application
- Kind: A1
- Application number: 15/153,590
- Filed: 2016-05-12
- Published: 2016-09-08
- Earliest claimed: 2013-11-14
- Assignees: Huawei Technologies Co., Ltd.
- Applicants: Huawei Technologies Co., Ltd.
- Inventors: Wenjiang Shi; Fei Liu
- Web page: https://patentgrep.com/patent/US20160261460A1

## CPC

- H04L 41/082: the condition being updates or upgrades of network functionality
- H04L 47/12: Avoiding congestion; Recovering from congestion
- H04L 65/611: for multicast or broadcast (systems for broadcast or conference H04L12/18; arrangements for broadcast or distribution combined with broadcast H04H20/00; arrangements for broadcast applications with a direct linkage to broadcast information or to broadcast space-time H04H60/00; selective distribution of broadcast services, e.g. multimedia broadcast multicast service [MBMS], H04W4/06)
- H04L 69/324: in the data link layer [OSI layer 2], e.g. HDLC
- H04L 2101/622: Layer-2 addresses, e.g. medium access control [MAC] addresses
- H04L: TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION (arrangements common to telegraphic and telephonic communication H04M)

## Abstract

Embodiments of the present invention disclose a method for upgrading a version of a network device and a device. A specific solution is: configuring a forwarding plane of the network device to be a first forwarding plane and a second forwarding plane; performing, in the first forwarding plane, sampling on forwarded packets by using a preset sampling ratio, to obtain a sample packet; forwarding, by the second forwarding plane, the sample packet in a broadcast manner, to learn a MAC address; and when a quantity of MAC addresses learned by the second forwarding plane reaches a preset threshold, performing upgrade so that the second forwarding plane is used for packet forwarding of the network device. The technical solution can effectively avoid generation of a large quantity of broadcast packets during a version upgrade process, can help reduce network bandwidth that is excessively occupied, and avoid network congestion.

## Claims

### Claim 1

A method for upgrading a version of a network device, comprising:
configuring, by the network device, a forwarding plane of the network device to be a first forwarding plane and a second forwarding plane, wherein the first forwarding plane runs a first version, the second forwarding plane runs a second version, and before version upgrade of the network device, the first forwarding plane is used for packet forwarding of the network device;
performing, by the network device in the first forwarding plane, sampling on forwarded packets using a preset sampling ratio, to obtain a sample packet, and copying the sample packet to the second forwarding plane;
forwarding, by the network device, the sample packet in a broadcast manner in the second forwarding plane, to learn a Media Access Control (MAC) address, and generating a MAC address entry according to the learned MAC address; and
in response to a quantity of MAC addresses learned by the second forwarding plane reaching a preset threshold, performing an upgrade so that the second forwarding plane is used for packet forwarding of the network device, wherein the preset threshold is a nonzero positive integer.

### Claim 2 (depends on 1)

The method according to claim 1, wherein after the performing the upgrade so that the second forwarding plane is used for packet forwarding of the network device, the method further comprises:
in the second forwarding plane, for a packet whose matching MAC address entry is found, forwarding the packet in a unicast manner according to the found matching MAC address entry; and
forwarding, in a broadcast manner, a packet whose matching MAC address entry is not found.

### Claim 3 (depends on 1)

The method according to claim 1, wherein before performing sampling on forwarded packets using the preset sampling ratio, and copying the sample packet to the second forwarding plane, the method further comprises:
sending a Layer 2 forwarding entry generated by a control plane of the network device to the second forwarding plane.

### Claim 4 (depends on 1)

The method according to claim 1, wherein the preset threshold meets the following condition:
a bandwidth occupied by broadcast packets that are forwarded without using MAC addresses in the preset threshold range does not exceed a system bandwidth of the network device.

### Claim 5 (depends on 1)

The method according to claim 1, wherein performing the upgrade so that the second forwarding plane is used for packet forwarding of the network device comprises:
in the second forwarding plane, for a packet whose matching MAC address entry is found, forwarding the packet in a unicast manner according to the found matching MAC address, and forwarding, in a broadcast manner, a packet whose matching MAC address entry is not found.

### Claim 6

A network device, comprising:
a configuration unit, configured to configure a forwarding plane of the network device to be a first forwarding plane and a second forwarding plane, wherein the first forwarding plane runs a first version, the second forwarding plane runs a second version, and before version upgrade of the network device, the first forwarding plane is used for packet forwarding of the network device;
a sampling unit, configured to perform, in the first forwarding plane that is configured by the configuration unit, sampling on forwarded packets by using a preset sampling ratio, to obtain a sample packet, and copy the sample packet to the second forwarding plane;
a generation unit, configured to forward the sample packet in a broadcast manner in the second forwarding plane that is configured by the configuration unit, to learn a media access control (MAC) address, and generate a MAC address entry according to the learned MAC address; and
an upgrade unit, configured to, in response to a quantity of MAC addresses learned by the second forwarding plane reaching a preset threshold, perform an upgrade so that the second forwarding plane is used for packet forwarding of the network device, wherein the preset threshold is a nonzero positive integer.

### Claim 7 (depends on 6)

The network device according to claim 6, further comprising a forwarding unit, wherein the forwarding unit is configured to:
after the upgrade unit performs the upgrade so that the second forwarding plane is used for packet forwarding of the network device, in the second forwarding plane, for a packet whose matching MAC address entry is found, forward the packet in a unicast manner according to the found matching MAC address entry; and forward, in a broadcast manner, a packet whose matching MAC address entry is not found.

### Claim 8 (depends on 6)

The network device according to claim 6, wherein the network device further comprises a receiving unit, wherein the receiving unit is configured to:
before sampling is performed on the forwarded packets in the first forwarding plane that is configured by the configuration unit by using the preset sampling ratio, to obtain the sample packet, and the sample packet is copied to the second forwarding plane, send a Layer 2 forwarding entry generated by a control plane of the network device to the second forwarding plane.

### Claim 9 (depends on 6)

The network device according to claim 6, wherein the preset threshold meets the following condition:
a bandwidth occupied by broadcast packets that are forwarded without using MAC addresses in the preset threshold range does not exceed a system bandwidth of the network device.

### Claim 10 (depends on 6)

The network device according to claim 6, wherein performing the upgrade so that the second forwarding plane is used for packet forwarding of the network device comprises:
in the second forwarding plane, for a packet whose matching MAC address entry is found, forwarding the packet in a unicast manner according to the found matching MAC address, and forwarding, in a broadcast manner, a packet whose matching MAC address entry is not found.

### Claim 11

A network device, comprising a processor, a transmitter, a memory and a bus, wherein:
the processor, the transmitter and the memory are connected by using the bus; the memory is configured to store data processed by the processor; and
the processor is configured to:
configure a forwarding plane of the network device to be a first forwarding plane and a second forwarding plane, wherein the first forwarding plane runs a first version, the second forwarding plane runs a second version, and before version upgrade of the network device, the first forwarding plane is used for packet forwarding of the network device;
perform, in the first forwarding plane, sampling on forwarded packets using a preset sampling ratio, to obtain a sample packet, and copy the sample packet to the second forwarding plane;
forward, by using the transmitter, the sample packet in a broadcast manner in the second forwarding plane, to learn a media access control (MAC) address, and generate a MAC address entry according to the learned MAC address; and
in response to a quantity of MAC addresses learned by the second forwarding plane reaching a preset threshold, perform an upgrade so that the second forwarding plane is used for packet forwarding of the network device, wherein the preset threshold is a nonzero positive integer.

### Claim 12 (depends on 11)

The network device according to claim 11, wherein the processor is further configured to:
after performing the upgrade so that the second forwarding plane is used for packet forwarding of the network device, in the second forwarding plane, for a packet whose matching MAC address entry is found, forward the packet in a unicast manner according to the found matching MAC address entry; and forward, in a broadcast manner, a packet whose matching MAC address entry is not found.

### Claim 13 (depends on 11)

The network device according to claim 11, wherein the processor is further configured to:
before performing, in the first forwarding plane, sampling on the forwarded packets using the preset sampling ratio, to obtain the sample packet, and copying the sample packet to the second forwarding plane, send a Layer 2 forwarding entry generated by a control plane to the second forwarding plane.

### Claim 14 (depends on 11)

The network device according to claim 11, wherein the preset threshold meets the following condition:
a bandwidth occupied by broadcast packets that are forwarded without using MAC addresses in the preset threshold range does not exceed a system bandwidth of the network device.

### Claim 15 (depends on 11)

The network device according to claim 11, wherein performing the upgrade so that the second forwarding plane is used for packet forwarding of the network device comprises:
in the second forwarding plane, for a packet whose matching MAC address entry is found, forwarding the packet in a unicast manner according to the found matching MAC address, and forwarding, in a broadcast manner, a packet whose matching MAC address entry is not found.
