Redundant Ethernet link state monitoring system based on broadcast protocol

文档序号:1478656 发布日期:2020-02-25 浏览:24次 中文

阅读说明:本技术 一种基于广播协议的冗余以太网的链路状态监控系统 (Redundant Ethernet link state monitoring system based on broadcast protocol ) 是由 赵继伟 于 2019-11-14 设计创作,主要内容包括:本发明公开了一种基于广播协议的冗余以太网的链路状态监控系统,其包括:在单广播域下的带有两个以太网接口的计算机A与两个以太网接口的计算机B,计算机A和计算机B通过两个以太网接口数大于四个的交换机实现两路冗余以太网的物理连接;计算机A周期性通过两个以太网接口发送广播报文,计算机B通过两个网口接收计算机A的广播报文并根据不同网口接收到的报文数量来评价链路状态。本发明作为以太网主备链路切换的切换依据,既能够感知phy芯片以上的网络层级的故障,又能够与上层软件解耦,保证上层应用的可移植性。(The invention discloses a link state monitoring system of redundant Ethernet based on broadcast protocol, which comprises: under the single broadcast domain, a computer A with two Ethernet interfaces and a computer B with two Ethernet interfaces are arranged, and the computer A and the computer B realize the physical connection of two paths of redundant Ethernet through a switch with the number of the two Ethernet interfaces being more than four; the computer A periodically sends broadcast messages through two Ethernet interfaces, and the computer B receives the broadcast messages of the computer A through two network interfaces and evaluates the link state according to the number of the messages received by different network interfaces. The method is used as a switching basis for switching the Ethernet master link and the Ethernet slave link, can sense the fault of the network level above the phy chip, can be decoupled with upper software, and ensures the transportability of upper application.)

1. A broadcast protocol based link state monitoring system for redundant ethernet networks, comprising: under the single broadcast domain, a computer A with two Ethernet interfaces and a computer B with two Ethernet interfaces are arranged, and the computer A and the computer B realize the physical connection of two paths of redundant Ethernet through a switch with the number of the two Ethernet interfaces being more than four; the computer A periodically sends broadcast messages through two Ethernet interfaces, and the computer B receives the broadcast messages of the computer A through two network interfaces and evaluates the link state according to the number of the messages received by different network interfaces.

2. The system according to claim 1, wherein the switch comprises a switch a and a switch B, the two ethernet interfaces of the computer a are respectively connected to the switch a and the switch B, and the two ethernet interfaces of the computer B are respectively connected to the switch a and the switch B; the switch A and the switch B are connected by a two-way link configured as port aggregation.

3. A link state monitoring method of a redundant ethernet based on a broadcast protocol, characterized in that the method is performed based on the link state monitoring system of claim 2, and the method for monitoring the state of two ethernet links by a computer a or a computer B is the same as the monitoring method of the computer a and the computer B.

4. The method for monitoring link status of redundant ethernet based on broadcasting protocol according to claim 1, wherein in case that said computer B receives information from computer a, the link status monitoring process of computer B is: two network ports of the computer A respectively send Ethernet broadcast messages to the switch A and the switch B in a cycle of n milliseconds, wherein the message content comprises ID information which is unique in a full broadcast domain and represents the computer A, and the width of the ID information is x bits; the computer B receives the broadcast information in the broadcast domain through two Ethernet ports, screens out messages for monitoring the link state with the computer A through the ID information of the computer A, and counts the broadcast messages received by each Ethernet port; if a certain network port does not receive a new link state broadcast message for m milliseconds continuously, judging that a link where the network port is located has a fault, wherein m is larger than 2 n; if the average interval of receiving the link state broadcast message by a certain network port in a period of time is N milliseconds, and N is greater than N/2, packet loss exists in the certain network port in the period of time, and the packet loss rate is N/2N.

Technical Field

The invention belongs to the technical field of embedded software development, and relates to a broadcast protocol-based link state monitoring system of a redundant Ethernet.

Background

In the field of embedded development, ethernet is increasingly used. Although ethernet has the advantage of large transmission bandwidth, it does not have error handling capability, so it needs extra design to guarantee in the application scenario requiring transmission reliability.

The most common reliability design method of ethernet is the link redundancy design. A common approach in ethernet link redundancy design is active-standby link switching-switching to a standby link when a primary link fails. There are two main methods for monitoring link status in the active/standby link switching method. One method is to monitor the physical connection state of the Ethernet link, and the method has the problems that when the cable, the phy chip of the opposite terminal equipment and the transformer work normally, and the functions of exchange or forwarding and the like fail, errors cannot be sensed to cause redundancy failure; and secondly, whether the network application layer can normally receive information is adopted as a switching criterion, and the method has the problem that the network switching function is tightly coupled with the upper-layer service, so that the portability of the application program is very unfavorable.

In summary, designing a link state monitoring method that can sense network level failures above the phy chip and is not coupled with upper layer services is significant for improving reliability and portability of ethernet communication in an embedded software system.

Disclosure of Invention

Objects of the invention

The purpose of the invention is: the link state monitoring system of the redundant Ethernet based on the broadcast protocol can sense the faults of the network level above a phy chip and is not coupled with upper-layer services.

(II) technical scheme

In order to solve the above technical problem, the present invention provides a broadcast protocol-based link status monitoring system for redundant ethernet, comprising: under the single broadcast domain, a computer A with two Ethernet interfaces and a computer B with two Ethernet interfaces are arranged, and the computer A and the computer B realize the physical connection of two paths of redundant Ethernet through a switch with the number of the two Ethernet interfaces being more than four; the computer A periodically sends broadcast messages through two Ethernet interfaces, and the computer B receives the broadcast messages of the computer A through two network interfaces and evaluates the link state according to the number of the messages received by different network interfaces.

The switch comprises a switch A and a switch B, two Ethernet interfaces of the computer A are respectively connected with the switch A and the switch B, and two Ethernet interfaces of the computer B are respectively connected with the switch A and the switch B; the switch A and the switch B are connected by a two-way link configured as port aggregation.

The invention also provides a link state monitoring method of redundant Ethernet based on broadcast protocol, which is carried out based on the link state monitoring system of claim 2, and the method for monitoring the link states of two paths of Ethernet by the computer A or the computer B is the same as the monitoring method of the computer A and the computer B.

Wherein, when the computer B receives the information from the computer a, the link state monitoring process of the computer B is as follows: two network ports of the computer A respectively send Ethernet broadcast messages to the switch A and the switch B in a cycle of n milliseconds, wherein the message content comprises ID information which is unique in a full broadcast domain and represents the computer A, and the width of the ID information is x bits; the computer B receives the broadcast information in the broadcast domain through two Ethernet ports, screens out messages for monitoring the link state with the computer A through the ID information of the computer A, and counts the broadcast messages received by each Ethernet port; if a certain network port does not receive a new link state broadcast message for m milliseconds continuously, judging that a link where the network port is located has a fault, wherein m is larger than 2 n; if the average interval of receiving the link state broadcast message by a certain network port in a period of time is N milliseconds, and N is greater than N/2, packet loss exists in the certain network port in the period of time, and the packet loss rate is N/2N.

(III) advantageous effects

The link state monitoring system of the redundant Ethernet based on the broadcast protocol, provided by the technical scheme, is used as a switching basis for switching the main link and the standby link of the Ethernet, can sense the fault of a network level above a phy chip, and can be decoupled with upper-layer software, so that the transportability of upper-layer application is ensured.

Drawings

Fig. 1 is a schematic diagram of network physical connections between a computer a and a computer B according to an embodiment of the present invention.

Detailed Description

In order to make the objects, contents and advantages of the present invention clearer, the following detailed description of the embodiments of the present invention will be made in conjunction with the accompanying drawings and examples.

The invention provides a link state monitoring system of redundant Ethernet based on a broadcast protocol, which is shown in figure 1 and comprises a computer A with two Ethernet interfaces and a computer B with two Ethernet interfaces in a single broadcast domain, wherein the computer A and the computer B realize the physical connection of two paths of redundant Ethernet through a switch with the number of the two Ethernet interfaces being more than four; the computer A periodically sends broadcast messages through two Ethernet interfaces, and the computer B receives the broadcast messages of the computer A through two network interfaces and evaluates the link state according to the number of the messages received by different network interfaces.

The switch comprises a switch A and a switch B, two Ethernet interfaces of the computer A are respectively connected with the switch A and the switch B, and two Ethernet interfaces of the computer B are respectively connected with the switch A and the switch B; the switch A and the switch B are connected by a two-way link configured as port aggregation.

The invention also provides a redundancy method of Ethernet hot standby hot switching based on the multicast protocol, which comprises a network topology structure of the computer A and the computer B and a method for sending and receiving network messages.

A first part: the network topology of computer a and computer B.

As shown in fig. 1, 2 ethernet interfaces of a computer a are respectively connected to a switch a and a switch B, like the computer B; the switch A and the switch B are connected by a two-way link configured as port aggregation.

A second part: and the method for monitoring the states of the two paths of Ethernet links by the computer A or the computer B is the same as the monitoring method of the computer A and the computer B.

This embodiment will describe how the method monitors the ethernet link status by taking the link status monitoring method of the computer B as an example when the computer B wants to receive the information from the computer a. Two network ports of the computer A respectively send Ethernet broadcast messages to the switch A and the switch B with n milliseconds as a period, wherein the message content comprises ID information which is unique in a full broadcast domain and represents the computer A, and the width of the ID information is x bits.

And the computer B receives the broadcast information in the broadcast domain through two Ethernet ports, screens out messages for monitoring the link state with the computer A through the ID information of the computer A, and counts the broadcast messages received by each Ethernet port.

If a certain network port does not receive a new link state broadcast message continuously for m milliseconds, determining that a link where the network port is located has a fault, wherein m is greater than 2n generally. The average interval of receiving the link state broadcast message by a certain network port in a period of time is N milliseconds, if N is greater than N/2, packet loss exists in the certain network port in the period of time, and the packet loss rate is N/2N.

When the method has c network devices in the same broadcast domain, the method will additionally occupy the network bandwidth of c × 1000 ÷ n × (x +18 × 8) × 4bps, wherein 18 × 8 represents other data in the actually effective frame format in the ethernet frame. Taking the general value, n is 10, x is 8, the extra occupied bandwidth is 0.058c Mbps. In the hundreds and giga ethernet networks that are currently prevalent, the bandwidth consumed can be said to be unimpaired.

In this embodiment, only one sending end and one receiving end are given, and the network topology structure of this embodiment can be extended to multiple devices and the same monitoring method is adopted.

The above description is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, several modifications and variations can be made without departing from the technical principle of the present invention, and these modifications and variations should also be regarded as the protection scope of the present invention.

6页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:基于广义最大相关熵准则的盲自适应多用户检测方法

网友询问留言

已有0条留言

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

精彩留言,会给你点赞!