In-band network remote measuring method and equipment

文档序号:22709 发布日期:2021-09-21 浏览:11次 中文

阅读说明:本技术 一种带内网络遥测方法及设备 (In-band network remote measuring method and equipment ) 是由 黄振 闫波 于 2021-06-18 设计创作,主要内容包括:本申请提供了一种带内网络遥测方法及设备。该方法在转发带内遥测报文时,将获取的元数据信息以及待转发带内遥测报文的出端口标识对应的出端口带宽利用率和出端口丢包字节数写入该待转发带内网络遥测报文的元数据字段,并将待转发带内网络遥测报文发往下一跳设备。这样,带内网络遥测报文被写入的元数据信息与当前网络的实际情况相符,使得上层设备能借助带内网络遥测报文被写入的元数据信息对当前网络的运行状况进行更加全面的分析,以降低网络设备在转发报文时出现拥堵或出错的概率。(The application provides an in-band network telemetering method and equipment. When the method is used for forwarding the in-band telemetering message, the obtained metadata information, the output port bandwidth utilization rate and the output port packet loss byte number corresponding to the output port identification of the in-band telemetering message to be forwarded are written into a metadata field of the in-band network telemetering message to be forwarded, and the in-band network telemetering message to be forwarded is sent to next hop equipment. Therefore, the written metadata information of the in-band network telemetry message conforms to the actual condition of the current network, so that the upper-layer equipment can analyze the operation condition of the current network more comprehensively by means of the written metadata information of the in-band network telemetry message, and the probability of congestion or errors when the network equipment forwards the message is reduced.)

1. An in-band network telemetry method, characterized in that,

writing the port identification of each port and the corresponding bandwidth utilization rate of the output port and the number of bytes of packet loss of the output port into a multiplexing register of a plurality of metadata registers;

acquiring metadata information from the metadata registers and reading the bandwidth utilization rate of an output port and the number of bytes of an output port packet loss corresponding to the output port identification of the in-band telemetry message to be forwarded from the multiplexing register;

writing the obtained metadata information, the bandwidth utilization rate of the output port and the number of bytes of packet loss of the output port into a metadata field of the in-band network telemetry message to be forwarded;

and sending the in-band network telemetry message to be forwarded to next hop equipment.

2. The method of claim 1, wherein before writing each port identifier and the corresponding egress port bandwidth utilization and egress port packet loss byte number into a multiplexing register of the plurality of metadata registers, the method further comprises:

setting an output port information register for each port;

and writing the output port sending message number and the output port packet loss number into an output port information register of each port.

3. The method of claim 2, wherein writing the port identifier of each port and the corresponding egress port bandwidth utilization and egress port packet loss byte number into a multiplexing register of the plurality of metadata registers comprises:

reading out port sending message number and output port packet loss number from output port information register of each port;

calculating the bandwidth utilization rate of the output port of each port according to the read number of messages sent by the output port of each port;

calculating the number of output port packet loss bytes of each port according to the read output port packet loss number of each port;

and writing the port identification of each port and the calculated output port bandwidth utilization rate and output port packet loss byte number into the multiplexing register.

4. The method of claim 1, wherein the port identifier of each port is a port ID of each port or a chip ID and a port ID of each port.

5. The method of claim 1, wherein the multiplexing register is a programmable register.

6. The utility model provides an in-band network remote equipment, its characterized in that, equipment includes:

the write-in module is used for writing the port identification of each port, the corresponding bandwidth utilization rate of the output port and the number of bytes of packet loss of the output port into one multiplexing register of the plurality of metadata registers;

the forwarding module is used for acquiring metadata information from the metadata registers and reading the bandwidth utilization rate of an output port and the number of bytes of an output port packet loss corresponding to the output port identification of the in-band telemetry message to be forwarded from the multiplexing register; writing the obtained metadata information, the bandwidth utilization rate of the output port and the number of bytes of packet loss of the output port into a metadata field of the in-band network telemetry message to be forwarded; and sending the in-band network telemetry message to be forwarded to next hop equipment.

7. The apparatus of claim 6, further comprising a setup module;

the setting module is used for setting an output port information register for each port;

the write-in module is further configured to write in the output port information register of each port the output port sending message number and the output port packet loss number.

8. The apparatus of claim 6, wherein the writing module writes the port identifier of each port and the corresponding egress port bandwidth utilization and egress port packet loss byte number into a multiplexing register of the plurality of metadata registers, and includes: reading out port sending message number and output port packet loss number from output port information register of each port; calculating the bandwidth utilization rate of the output port of each port according to the read number of the messages sent by the output port; calculating the number of output port packet loss bytes of each port according to the read output port packet loss number of each port; and writing the port identification of each port and the calculated output port bandwidth utilization rate and output port packet loss byte number into the multiplexing register.

9. The apparatus of claim 6, wherein the port identifier of each port is a port ID of each port or a chip ID and a port ID of each port.

10. The apparatus of claim 9, wherein the multiplexing register is a programmable register.

Technical Field

The present application relates to network communication technologies, and in particular, to a method and device for in-band network telemetry.

Background

The NT (Network Telemetry) Telemetry technology realizes the capability of Network devices to actively push status information, and can transmit a short-distance measurement value of a target object to a long-distance measurement station to realize long-distance measurement, so the Telemetry technology is widely used to solve the problem that the conventional Network monitoring means cannot solve the "invisible" problem, such as time delay, forwarding path, cache and packet loss.

INT (In-band Network Telemetry) is a Telemetry technology used for solving the problem that a forwarding path and forwarding delay are invisible. The message reaches INT equipment as a head node, the INT head is inserted into the head node after the four-layer head, the metadata information reads the metadata information of each metadata memory and packages the metadata information into MD (Meta Data), and the MD is inserted into the head of the INT; after an INT device serving as an intermediate node is matched with an INT head, inserting a layer of MD behind the INT head; the message is forwarded to the last INT (INT) jump device as a tail node, the tail node is inserted into a layer of MD after being matched with the INT head, an IP (ERSPAN) head is packaged outside the message, and the outer IP is the address of the monitoring server, so that the INT message is forwarded to the monitoring server.

Fig. 1 is a schematic diagram illustrating a conventional manner in which an INT Device reads metadata information, where the INT Device reads the metadata information from a timestamp register, a Device identification (Device ID) register, an ingress/egress port register, and a lifetime register, and then packages the metadata information into a metadata write INT message. At that time, the number of chip registers read by the switching chip of the INT device is limited by the inherent capability of the chip, so that the switching chip takes out metadata MD information from several fixed chip registers at present, most INT devices do not use the output port information as MD information to be written in the INT message MD because the number of chip registers read is limited, and when the monitoring server analyzes the network operation status, the monitoring information lacks the output port information of the INT devices at all levels, so that the acquired network data does not conform to the actual situation, which makes the upper layer device unable to comprehensively analyze the current network operation status with the help of the monitoring information, thereby causing the technical problem of network congestion or errors.

Disclosure of Invention

The application provides an in-band network telemetering method and equipment, which are used for reducing the probability of network congestion or errors.

The technical scheme provided by the application comprises the following steps:

in a first aspect, an embodiment of the present application provides an in-band network telemetry method, including:

writing the port identification of each port and the corresponding bandwidth utilization rate of the output port and the number of bytes of packet loss of the output port into a multiplexing register of a plurality of metadata registers;

acquiring metadata information from the metadata registers and reading the bandwidth utilization rate of an output port and the number of bytes of an output port packet loss corresponding to the output port identification of the in-band telemetry message to be forwarded from the multiplexing register;

writing the obtained metadata information, the bandwidth utilization rate of the output port and the number of bytes of packet loss of the output port into a metadata field of the in-band network telemetry message to be forwarded;

and sending the in-band network telemetry message to be forwarded to next hop equipment.

In a second aspect, an embodiment of the present application provides an in-band network remote control device, which includes:

the write-in module is used for writing the port identification of each port, the corresponding bandwidth utilization rate of the output port and the number of bytes of packet loss of the output port into one multiplexing register of the plurality of metadata registers;

the forwarding module is used for acquiring metadata information from the metadata registers and reading the bandwidth utilization rate of an output port and the number of bytes of an output port packet loss corresponding to the output port identification of the in-band telemetry message to be forwarded from the multiplexing register; writing the obtained metadata information, the bandwidth utilization rate of the output port and the number of bytes of packet loss of the output port into a metadata field of the in-band network telemetry message to be forwarded; and sending the in-band network telemetry message to be forwarded to next hop equipment.

According to the technical scheme, when the INT message is forwarded, the obtained metadata information, the output port bandwidth utilization rate and the output port packet loss byte number corresponding to the output port identification of the INT to be forwarded are written into the metadata field of the INT message to be forwarded, and the INT message to be forwarded is sent to the next hop device. Therefore, the written metadata information of the INT message conforms to the actual condition of the current network, so that the upper-layer equipment can carry out more comprehensive analysis on the operation condition of the current network by means of the written metadata information of the INT message, and the probability of congestion or errors when the network equipment forwards the message is reduced.

Drawings

The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure.

FIG. 1 is a diagram illustrating a prior art approach to read metadata accesses by an INT device;

fig. 2 is a flowchart of an in-band network telemetry message forwarding method provided in the present application;

FIG. 3 is a schematic diagram of an INT device reading metadata accesses provided herein;

fig. 4 is a schematic structural diagram of an INT device provided in the present application.

Detailed Description

In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in detail with reference to the accompanying drawings and specific embodiments.

Referring to fig. 2, fig. 2 is a flowchart of an in-band network telemetry packet forwarding method provided by the present application, where the method may be applied to a head node, an intermediate node, or a tail node in an in-band network telemetry packet forwarding path, where the head node, the intermediate node, or the tail node is a network device, and the method may be applied to a switch chip of the network device.

As shown in fig. 2, the flow implemented by the method may include the following steps:

step 101, writing the port identifier of each port, the corresponding bandwidth utilization rate of the output port and the number of bytes of packet lost of the output port into a multiplexing register of a plurality of metadata registers.

In this embodiment, for the port identifier of each port, the determination of the port identifier of the port is related to the number of switch chips, and when the number of switch chips in the present device is greater than 1, the chip ID of the switch chip where the port is located and the port ID of the port are determined as the port identifiers used for storing the port bandwidth utilization rate and the port packet loss byte number of the port in the multiplexing register, which correspond to the port bandwidth utilization rate and the port packet loss byte number of the port. When the number of switching chips in the device is 1, the port ID of the port is determined as the port identifier for storing the port bandwidth utilization rate and the port packet loss byte number of the port in the multiplexing register. Therefore, the switching chip can accurately and quickly obtain the port bandwidth utilization rate and the port packet loss byte number of the port from the multiplexing register according to the port label corresponding to the port. Based on this, as an embodiment, the port identifier of each port may be a port ID of each port or a chip ID and a port ID of each port. The port bandwidth utilization rate and the port packet loss byte number of the port are accurately and quickly obtained from the multiplexing register according to the port label corresponding to the port.

The plurality of metadata registers may include a metadata register dedicated to storing time-related data, a metadata register dedicated to storing port numbers, and a metadata register dedicated to storing PACKET PACKETs. The multiplexing register may be understood as a metadata register that is specially used for storing the port identifier of each port, and the bandwidth utilization rate of the output port and the number of bytes lost by the output port corresponding to each port identifier. For one embodiment, the multiplexing register may be a programmable register.

And step 102, acquiring metadata information from a plurality of metadata registers, and reading an output port bandwidth utilization rate and an output port packet loss byte number corresponding to an output port identifier of the in-band telemetry message to be forwarded from a multiplexing register.

The metadata information may include a timestamp of each port on the switching chip obtained from a metadata register for storing Time-related data, an access port number obtained from a metadata register for storing a port number, a TTL (Time To Live) obtained from a metadata register for storing a PACKET, and a Device ID obtained from a metadata register for storing a Device identification Device ID of the network Device.

It should be noted that, if the multiplexing register is a programmable controller, in view of the fact that the programmable controller is a register for storing a Device ID, based on this, the Device ID, the egress port bandwidth utilization rate corresponding to the egress port identifier of the INT message to be forwarded, and the number of bytes of egress port packet loss can be obtained from the programmable controller.

And 103, writing the obtained metadata information, the bandwidth utilization rate of the output port and the number of bytes of the output port packet loss into a metadata field of the in-band network telemetry message to be forwarded.

And writing the acquired metadata information into a metadata field corresponding to each metadata information in an INT header of the INT message to be forwarded.

Writing the obtained output Port bandwidth Utilization rate into a metadata field used for identifying an output Port bandwidth Utilization rate aggregate Port Utilization field in an MD (message header) of an INT (INT) message to be forwarded, and writing the obtained output Port packet loss Byte number into a metadata field used for identifying an output Port packet loss Byte number aggregate Port Pkt Cnt field in an MD in an INT header of the INT message to be forwarded.

And 104, sending the in-band network telemetry message to be forwarded to next hop equipment.

If the network equipment is the first node, the next hop equipment to which the INT message to be forwarded is sent is the intermediate node; if the network equipment is an intermediate node, the next hop equipment to which the INT message to be forwarded is the tail node; if the network device is a tail node, the next hop device to which the INT message to be forwarded is sent is the monitoring device.

So far, the description shown in fig. 2 is completed.

Therefore, in the technical scheme of the embodiment of the application, when the INT message is forwarded, the obtained metadata information, the output port bandwidth utilization rate and the output port packet loss byte number corresponding to the output port identifier of the INT to be forwarded are written into the metadata field of the INT message to be forwarded, and the INT message to be forwarded is sent to the next hop device. Therefore, the written metadata information of the INT message conforms to the actual condition of the current network, so that the upper-layer equipment can carry out more comprehensive analysis on the operation condition of the current network by means of the written metadata information of the INT message, and the probability of congestion or errors when the network equipment forwards the message is reduced.

In an embodiment provided by the present application, before step 101, the method may further include steps a to B:

and step A, respectively setting an output port information register for each port.

Each port can be used as an input port and a port, in order to store the port as the output port sending message number and the output port lost packet number corresponding to the output port, a register meeting the requirement of storage space for containing the output port sending message number and the output port lost packet number is selected from registers, and when the number of registers meeting the requirement of storage space for containing the output port sending message number and the output port lost packet number is more than or equal to 1, one register is selected from the memories meeting the requirement as an output port information register.

And step B, writing the bandwidth utilization rate of the output port and the packet loss number of the output port into the output port information register of each port.

After the output port information register is selected, correspondingly writing the output port sending message number and the output port packet loss number of the output port into the output port information register.

In this embodiment, the number of messages sent by the output port and the number of packet lost by the output port may be written in real time or at regular time, which is not limited in this embodiment.

Therefore, by applying the technical scheme provided by this embodiment, the output port sending message number and the output port packet loss number of each port as the output port of the output port can be written into the output port information register set by each port in advance, so as to obtain the output port sending message number and the output port packet loss number of each port from the output port information register of each port at any time in the future.

In an embodiment provided by the present application, the implementation manner of step 101 in the flowchart shown in fig. 2 may include the following steps C to F:

and step C, reading out port sending message number and output port packet loss number from output port information registers of all ports.

Based on the above description, for the egress port information register of each port, the egress port information register of the port stores the number of egress port transmission messages and the number of egress port lost packets of the port.

And D, calculating the bandwidth utilization rate of the output port of each port according to the read number of the messages sent by the output port of each port.

As an embodiment, for each port, calculating the current flow rate of the output port according to the number of messages sent by the output port of the port; and calculating the bandwidth utilization rate of the outlet port of the port according to the calculated current flow rate and the total bandwidth of the port. The total bandwidth of a port in this embodiment refers to the maximum bandwidth of the port.

In some embodiments, the port bandwidth utilization may be calculated according to the following expression.

The expression is: l is s/k;

wherein s is the current traffic rate of the port, k is the total bandwidth of the port, and l is the bandwidth utilization rate of the output port of the port.

Therefore, by applying the technical scheme provided by the embodiment, the bandwidth utilization rate of the output port of the port can be determined quickly and accurately.

And E, calculating the number of bytes of the output port packet loss of each port according to the read output port packet loss number of each port.

In this step, for each port, the number of bytes of packet lost by the output port of the port is calculated according to the number of packet lost by the output port of the port.

As an embodiment, a Central Processing Unit (CPU) in the network device may be used to specifically calculate the port bandwidth utilization rate and the number of bytes of the output port packet loss, where the network device includes a main CPU and two or more sub-CPUs, the sub-CPU is a sub-CPU selected from all the sub-CPUs in the network device, and an originally allocated task of the sub-CPU is re-allocated to at least one other sub-CPU, based on which, the switching chip instructs the sub-CPU on the switching chip to execute steps C to E, and sends the calculated bandwidth utilization rate of the output port and the number of bytes of the output port packet loss to the switching chip so that the switching chip executes step F.

And F, writing the port identification of each port, the calculated output port bandwidth utilization rate and output port packet loss byte number into a multiplexing register.

In this step, the multiplexing register stores the port identifier of each port, and the bandwidth utilization rate of the output port and the number of bytes of packet lost by the output port corresponding to each port identifier.

The port identifier may be stored in the multiplexing register as an index in a mapping relationship between the output port bandwidth utilization rate and the output port packet loss byte number of the port corresponding to the port identifier. Therefore, the bandwidth utilization rate of the output port and the number of bytes of output port packet loss corresponding to the port identification can be read according to the port identification as the index.

Therefore, by applying the technical scheme provided by this embodiment, when the port bandwidth utilization rate and the number of bytes of output port packet loss are read, the output port bandwidth utilization rate and the number of bytes of output port packet loss corresponding to the port identifier can be quickly and accurately read from the multiplexing register according to the label identifier.

The flow shown in fig. 2 is described below based on an embodiment:

in practical application, a forwarding path of the INT packet to be forwarded includes a head node, a middle node, or a tail node, where the head node, the middle node, or the tail node is a switching device. As shown in fig. 3, the method for implementing in-band network telemetry by the switching chip of the switching device may include:

the switching chip sets output port information registers for n ports RORT 1-RORTn in the switching device respectively, output port information of RORT1, namely an RORT1 register in fig. 3, is used for storing the number of lost packets of output port 1 and the number of messages sent by output port 1 corresponding to port RORT1, … …, an output port information register of RORT, namely an RORT register in fig. 3, is used for storing the number of lost packets of output port n and the number of messages sent by output port n, the switching chip can redistribute tasks originally distributed by one auxiliary CPU (marked as RCPU) to at least one other auxiliary CPU, the RCPU determines the current flow rate of the output port 1 by using the number of messages sent by output port 1 of the output port 1, and the bandwidth utilization rate of the output port 1 is calculated according to the calculated current flow rate and the total bandwidth of the output port 1. Similarly, the RCPU calculates the bandwidth utilization rate of the output port n according to the number of messages sent by the output port n of the output port n and the total bandwidth of the output port n, where n is the port serial number of each port on the switch chip in the switch device. Meanwhile, the RCPU calculates the number of bytes of packet loss at the output port 1 by using the number of packet loss at the output port 1 of the output port 1; and similarly, calculating the number of bytes of the packet loss of the output port n by using the packet loss number of the output port n.

Determining the number of switching chips of the switching equipment, if the number of switching chips in the switching equipment is more than 1, taking the chip ID of the switching chip where the output port 1 is located and the port ID of the output port 1 as port identifications and writing the port identifications and the calculated output port bandwidth utilization rate and output port packet loss byte number of the output port 1, … …, taking the chip ID of the switching chip where the output port n is located and the port ID of the output port n as port identifications and writing the port identifications and the calculated output port bandwidth utilization rate and output port packet loss byte number of the output port n into a multiplexing register. If the number of switching chips in the present device is 1, the port ID of the egress port 1 is used as the port identifier and written into the multiplexing register together with the calculated egress port bandwidth utilization rate and egress port packet loss byte number of the egress port 1, … …, and the port ID of the egress port n is used as the port identifier and written into the multiplexing register together with the calculated egress port bandwidth utilization rate and egress port packet loss byte number of the egress port n.

The method comprises the steps of obtaining an input PORT number from a PORT related register used for storing a PORT number as a metadata register, obtaining TTL from a PACKET used for storing a data PACKET PACKET as a metadata register, and obtaining a time stamp from a time related register used for storing time as a metadata register, wherein the multiplexing register can be a programmable register used for storing a Device identification Device ID as a metadata register, reprogramming the programmable register to form a register used for storing a Device ID, an output PORT bandwidth utilization rate and an output PORT PACKET loss byte number corresponding to a PORT identification of each PORT, and reading the output PORT bandwidth utilization rate and the output PORT PACKET loss byte number corresponding to the output PORT identification according to the output PORT identification of an INT message to be forwarded based on the register. If the exit port is identified as port 1, the port 1 is used to read the Device ID, the bandwidth utilization rate of the exit port 1 corresponding to port 1 and the number of bytes of packet lost by the exit port 1 from the reprogrammed register, and similarly, if the exit port is identified as port n, the Device ID, the bandwidth utilization rate of the exit port n corresponding to port n and the number of bytes of packet lost by the exit port n are read from the reprogrammed register by using port n.

Assuming that the egress port identifier of the INT message to be forwarded is port 1, the obtained ingress/egress port number, Device ID, the bandwidth utilization rate of the egress port 1 corresponding to port 1, and the number of packet loss bytes, TTL, and timestamp of the egress port 1 are written into the metadata field INT METADATA of the NT message to be forwarded, and the INT message to be forwarded is sent to the next-hop Device, or if the present switching Device is the first node, the INT message to be forwarded is sent to the intermediate node. If the switching equipment is an intermediate node, the INT message to be forwarded is sent to the tail node. And if the switching equipment is the tail node, sending the INT message to be forwarded to the monitoring equipment. Finally, the INT message to be forwarded is sent to the monitoring equipment, so that the written metadata information of the INT message conforms to the actual condition of the current network, the upper-layer equipment can analyze the operation condition of the current network more comprehensively by means of the written metadata information of the in-band network telemetering message, and the probability of congestion or errors when the network equipment forwards the message is reduced.

Thus, the description of the embodiments is completed.

The following describes the apparatus provided in the present application:

referring to fig. 4, fig. 4 is a schematic diagram of an in-band network telemetry device 400 provided herein. The in-band network telemetry equipment comprises a memory, a system bus, at least one switching chip and a processor, wherein the switching chip is integrated with a plurality of registers, the registers are respectively a programmable metadata information register and a metadata information register used for storing metadata information of each port, for example, a metadata information register 1, a metadata information register 2-a metadata information register n in fig. 4, and n is a port serial number of the equipment, the registers further comprise an output port information register used for storing output port sending message number and output port lost packet number of each port, for example, an output port information register 1-an output port information register n in fig. 4.

The memory may be used to store processor-executable instructions that may be executed by the switch chip; the switch chip performs operations by executing processor-executable instructions in the memory:

the write-in module is used for writing the port identification of each port, the corresponding bandwidth utilization rate of the output port and the number of bytes of packet loss of the output port into one multiplexing register of the plurality of metadata registers;

the forwarding module is used for acquiring metadata information from a plurality of metadata registers and reading the bandwidth utilization rate of an output port and the number of bytes of an output port packet loss corresponding to the output port identification of the in-band telemetry message to be forwarded from the multiplexing register; writing the obtained metadata information, the bandwidth utilization rate of the output port and the number of bytes of the output port packet loss into a metadata field of the in-band network telemetry message to be forwarded; and sending the in-band network telemetry message to be forwarded to next hop equipment.

In one embodiment of the present application, the apparatus may further include a setting module;

the setting module is used for setting an output port information register for each port;

the write-in module is further configured to write in the output port information register of each port the output port sending message number and the output port packet loss number.

In an embodiment of the present application, the writing module writes the port identifier of each port, and the corresponding bandwidth utilization rate of the egress port and the number of bytes of packet lost at the egress port into a multiplexing register of the plurality of metadata registers, including: reading out port sending message number and output port packet loss number from output port information register of each port; calculating the bandwidth utilization rate of the output port of each port according to the read number of the messages sent by the output port; calculating the number of output port packet loss bytes of each port according to the read output port packet loss number of each port; and writing the port identification of each port and the calculated output port bandwidth utilization rate and output port packet loss byte number into a multiplexing register.

As an embodiment, the processor may include a main CPU and two or more sub-CPUs integrated on the switch chip, the memory for storing processor-executable instructions executable by the main CPU and the two or more sub-CPUs; the main CPU processing performs the following by executing processor-executable instructions in memory: and selecting one auxiliary CPU from all auxiliary CPUs in the network equipment, and redistributing the originally distributed tasks of the selected auxiliary CPU to at least one other auxiliary CPU. Selected ones of the two or more helper CPUs perform the following by executing processor-executable instructions in memory: reading out port sending message number and output port packet loss number from output port information register of each port; calculating the bandwidth utilization rate of the output port of each port according to the number of messages sent by the output port, and calculating the number of output port packet loss bytes of each port according to the read output port packet loss number of each port; and sending the calculated bandwidth utilization rate of the output port and the number of bytes of the output port packet loss to the switching chip so that the switching chip writes the port identification of each port and the calculated bandwidth utilization rate of the output port and the number of bytes of the output port packet loss into the multiplexing register.

In an embodiment of the present application, the port identifier of each port is a port ID of each port or a chip ID and a port ID of each port.

In one embodiment of the present application, the multiplexing register is a programmable register.

The system bus in fig. 4 may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For purposes of illustration, only one arrowed line is shown, but it does not indicate only one bus or one type of bus.

Up to this point, the description shown in fig. 4 is completed.

Therefore, in the technical scheme of the embodiment of the application, when the INT message is forwarded, the obtained metadata information, the output port bandwidth utilization rate and the output port packet loss byte number corresponding to the output port identifier of the INT to be forwarded are written into the metadata field of the INT message to be forwarded, and the INT message to be forwarded is sent to the next hop device. Therefore, the written metadata information of the INT message conforms to the actual condition of the current network, so that the upper-layer equipment can carry out more comprehensive analysis on the operation condition of the current network by means of the written metadata information of the INT message, and the probability of congestion or errors when the network equipment forwards the message is reduced.

For the apparatus embodiment, since it basically corresponds to the method embodiment, reference may be made to the partial description of the method embodiment for relevant points. The above-described device embodiments are merely illustrative, and units illustrated as separate components may or may not be physically separate, and components displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the scheme of the invention. One of ordinary skill in the art can understand and implement it without inventive effort.

The above description is only exemplary of the present application and should not be taken as limiting the present application, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present application should be included in the scope of protection of the present application.

13页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种用于远程心脏彩超检查的数据中转方法

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!