CN109005088A - The detection method and device of duplicate message in parallel redundancy network - Google Patents

The detection method and device of duplicate message in parallel redundancy network Download PDF

Info

Publication number
CN109005088A
CN109005088A CN201811136858.5A CN201811136858A CN109005088A CN 109005088 A CN109005088 A CN 109005088A CN 201811136858 A CN201811136858 A CN 201811136858A CN 109005088 A CN109005088 A CN 109005088A
Authority
CN
China
Prior art keywords
message
data message
sequence number
information
management
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201811136858.5A
Other languages
Chinese (zh)
Other versions
CN109005088B (en
Inventor
尹二飞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Kyland Technology Co Ltd
Original Assignee
Kyland Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Kyland Technology Co Ltd filed Critical Kyland Technology Co Ltd
Priority to CN201811136858.5A priority Critical patent/CN109005088B/en
Publication of CN109005088A publication Critical patent/CN109005088A/en
Application granted granted Critical
Publication of CN109005088B publication Critical patent/CN109005088B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/16Threshold monitoring
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters

Abstract

This application discloses the detection methods and device of duplicate message in a kind of parallel redundancy network.This method receives the data message and management message sent by the first local area network, and the propagation delay time of the first local area network is much larger than the propagation delay time of the second local area network, obtains the sequence number of the source MAC of data message, the sequence number of data message and neighbor management message;The sequence number of the source MAC of received data message, the sequence number of data message and corresponding neighbor management message that informational table of nodes based on storage records, duplicate message detection is carried out to received data message, by, with the presence or absence of the above- mentioned information obtained, determining whether the corresponding data message of above- mentioned information is duplicate message in detection node information table.Wherein, the preservation duration of informational table of nodes does not invert duration no more than management sequence of message number, and the transmission interval between two neighboring management message be less than the sequence number of data message do not invert duration, improve the accuracy of duplicate message detection.

Description

The detection method and device of duplicate message in parallel redundancy network
Technical field
This application involves a kind of detection method of duplicate message in field of communication technology more particularly to parallel redundancy network and Device.
Background technique
As the progress of industrial technology occurs simultaneously in order to further enhance the reliability of the technology of message redundancy backup Row redundancy protocol (Parallel redundancy protocol, PRP) network, the network application is in application layer.Such as Fig. 1 institute Show, PRP network is dependent on two network equipments for supporting PRP agreement, and such as the network equipment 1 and the network equipment 2, which is set The standby dual link node to support PRP agreement, there are two independently operated ports for each network equipment, such as port 1 and port 2, two ports are connected respectively on the local area network of two independent parallels work, such as local area network A and local area network B.The network equipment 1 will Each data message for sending of needs is replicated, and obtains two identical data messages, and by two ports with Local area network A and local area network B are sent to the network equipment 2.The network equipment 2 carries out duplicate message detection, tool after receiving data message Body are as follows: according in data message the source physical address address (Media Access Control, MAC) and sequence number, determine should Whether data message is duplicate message, if not recording the MAC Address and sequence number in the informational table of nodes of storage, it is determined that should Data message is not duplicate message, and the MAC Address of the data message and sequence number are stored, to update the table;If depositing Record has the MAC Address and sequence number in the informational table of nodes of storage, it is determined that the data message is duplicate message, deletes the data Message.The Serial No. network equipment 1 is carried out the data message of duplicate identity by incremental order.
However, it is found by the inventors that having certain limitation in PRP network to the size of two local area networks, when the net of local area network A Network is larger, and when the network of local area network B is smaller, if local area network A only has an interchanger, local area network B has tens interchangers, local The propagation delay time of net A will be substantially less that the propagation delay time of local area network B, and the same data message is simultaneously from two ends of the network equipment 1 Mouthful issue reach the network equipment 2 time difference be more than the informational table of nodes stored in the network equipment 2 holding time (or " ageing time "), the network equipment 2 may can repeat to receive identical data message.
If the network delay difference between local area network A and local area network B is 2 milliseconds, holding time of informational table of nodes (or " protect Deposit duration ") it is 1 millisecond;Receiving end t moment (unit millisecond), the data message of Serial No. 1 is received by local area network A, and Sequence number and source MAC are recorded in informational table of nodes;The t+1 moment receives the data of Serial No. 2 by local area network A Message, and sequence number and source MAC are recorded in informational table of nodes;Due to being more than informational table of nodes after the t+1 moment Preservation duration, therefore the sequence of the sequence number and source MAC of the data message of Serial No. 1 and the data message of Serial No. 2 Number and source MAC will all be deleted.The t+3 moment receives the data message of Serial No. 3 by local area network A, by its sequence Number and source MAC be recorded in informational table of nodes, the data message of Serial No. 1 is received by local area network A, due to node believe It ceases and its sequence number and source MAC is not present in table, therefore the information is recorded in informational table of nodes, cause to receive repetition report Text.
The preservation duration of informational table of nodes is the hair between digit and adjacent data message according to sequence number in data message Interval is sent to determine.If the digit of sequence number is fewer, and send interval it is shorter, it is determined that preservation duration it is shorter, if sequence Number digit it is more, and send interval it is longer, it is determined that preservation duration it is longer.If the digit of sequence number only has 16bit (range 0~65536), and send interval it is shorter (negligible), it is determined that preservation duration there was only a few tens of milliseconds, that is to say, that In the case that the preservation duration of informational table of nodes is constant, when the network delay difference of two local area networks in PRP network is larger, And network delay, when being greater than the preservation duration of informational table of nodes, the accuracy of above-mentioned duplicate message detection is lower.
Summary of the invention
The embodiment of the present application provides the detection method and device of duplicate message in a kind of parallel redundancy network, and this method is used for Above-mentioned problems of the prior art are solved, the accuracy of duplicate message detection is improved.
In a first aspect, a kind of detection method of duplicate message in parallel redundancy network is provided, in parallel redundancy network The first port of one network equipment sends datagram and manages message, the first net to second network equipment by the first local area network The second port of network equipment sends datagram and manages message, this method packet to second network equipment by the second local area network It includes:
The first port of second network equipment receives the data message sent by the first local area network and manages message, and first The propagation delay time of local area network is much larger than the propagation delay time of the second local area network;
It obtains data message and manages the message information of message, message information includes the source MAC of data message, the number According to the sequence number of message and the sequence number of neighbor management message;Neighbor management message is that the first port of second network equipment is connecing Before receiving data message, the received management message of last time;
The received datagram of second port by second network equipment recorded in informational table of nodes based on storage Text source MAC, the sequence number of the data message and the sequence number of corresponding neighbor management message, to received data message into The detection of row duplicate message;Wherein, in informational table of nodes the source MAC of received data message, the data message sequence Number and the preservations duration of sequence number of corresponding neighbor management message do not invert duration, and phase no more than the sequence number for managing message What the transmission interval between adjacent two management messages was less than the sequence number of data message does not invert duration;
When, there is no when the message information obtained, the corresponding data message of confirmation message information is non-heavy in informational table of nodes Multiple message;
When there is the message information obtained in informational table of nodes, the corresponding data message of confirmation message information is attached most importance to Multiple message.
Compared with now with technology, the application above method passes through the message information of data message and corresponding management message Sequence number identifies whether to have received duplicate message jointly, to improve the accuracy of duplicate message detection.
One it is optional realize, recorded in the informational table of nodes based on storage by the second of second network equipment The sequence number of the source MAC of the received data message in port, the sequence number of the data message and corresponding neighbor management message, Duplicate message detection is carried out to received data message, comprising:
Whether existed simultaneously in recognition node information table and the consistent received data message of message information of acquisition The sequence number of source MAC, sequence number and corresponding neighbor management message.
The above method is further described through the message information of data message in query node information table and the datagram Whether the sequence number of the adjacent management message of text is consistent with the management sequence number of message with the message information of received data message, To realize the detection of duplicate message.
In an optional realization, the corresponding data message of confirmation message information is this method after non-duplicate message Further include:
The corresponding data message of message information is sent to destination network device, and recorded message is believed in informational table of nodes Breath, to realize the transmission of data message.
In an optional realization, it is the party after duplicate message that the corresponding data message of message information is deleted in confirmation Method further include:
Delete the corresponding data message of message information.
Second aspect provides a kind of detection device, the device include: receiving unit, acquiring unit, detection unit and really Recognize unit;
Receiving unit passes through the data message and management message that the first local area network is sent for receiving, the first local area network Propagation delay time is much larger than the propagation delay time of the second local area network;
Acquiring unit, for obtaining data message and managing the message information of message, message information includes data message The sequence number of source MAC, the sequence number of the data message and neighbor management message;Neighbor management message is second network equipment First port before receiving data message, the received management message of last time;
Detection unit, the second port by second network equipment for recording in the informational table of nodes based on storage is The sequence number of the source MAC of received data message, the sequence number of the data message and corresponding neighbor management message, to reception Data message carry out duplicate message detection;Wherein, the source MAC of received data message, the number in informational table of nodes It is not more than the sequence number of management message not according to the preservation duration of the sequence number of the sequence number and corresponding neighbor management message of message Invert duration, and the transmission interval between two neighboring management message is less than the sequence number of data message and does not invert duration;
Confirmation unit, for when, there is no when the message information obtained, confirmation message information is corresponding in informational table of nodes Data message is non-duplicate message;
When there is the message information obtained in informational table of nodes, the corresponding data message of confirmation message information is attached most importance to Multiple message.
In an optional realization, detection unit, specifically for whether existing simultaneously and obtaining in recognition node information table The source MAC of the consistent received data message of the message information taken, the sequence number of the data message and corresponding adjacent tubes Manage the sequence number of message.
In an optional realization, which further includes recording unit and transmission unit;
Transmission unit after non-duplicate message, is set for the corresponding data message of confirmation message information to target network Preparation send message information corresponding data message;
Recording unit, for the recorded message information in informational table of nodes.
In an optional realization, which further includes deleting unit;
Unit is deleted, being also used to delete the corresponding data message of message information in confirmation is deletion report after duplicate message The corresponding data message of literary information.
The third aspect provides a kind of electronic equipment, which includes processor, communication interface, memory and lead to Believe bus, wherein processor, communication interface, memory complete mutual communication by communication bus;
Memory, for storing computer program;
Processor when for executing the program stored on memory, realizes any side in above-mentioned first aspect Method step.
Fourth aspect provides a kind of computer readable storage medium, and meter is stored in the computer readable storage medium Calculation machine program, the computer program realize any method and step in above-mentioned first aspect when being executed by processor.
Technical scheme is receiving the data message and management message sent by the first local area network, the first local area network Propagation delay time be much larger than the second local area network propagation delay time, obtain the source MAC of data message, the sequence number of data message With the sequence number of neighbor management message;The source MAC of the received data message of informational table of nodes record based on storage, The sequence number of the sequence number of data message and corresponding neighbor management message carries out duplicate message detection to received data message, By, with the presence or absence of the above- mentioned information obtained, determining whether the corresponding data message of above- mentioned information attaches most importance in detection node information table Multiple message.Wherein, the preservation duration of informational table of nodes does not invert duration, and two neighboring pipe no more than management sequence of message number The sequence number that transmission interval between reason message is less than data message does not invert duration, improves the accurate of duplicate message detection Property.
Detailed description of the invention
Fig. 1 is a kind of structural schematic diagram of the PRP network provided;
Fig. 2 is to lead to applied by the detection method of duplicate message in a kind of parallel redundancy network provided in an embodiment of the present invention The structural schematic diagram of communication network;
Fig. 3 is the process signal of the detection method of duplicate message in a kind of parallel redundancy network provided in an embodiment of the present invention Figure;
Fig. 4 is a kind of form schematic diagram of the PRP message provided;
Fig. 5 is a kind of form schematic diagram of PTP management message provided;
Fig. 6 is that the process of the detection method of duplicate message in another parallel redundancy network provided in an embodiment of the present invention is shown It is intended to;
Fig. 7 is a kind of structural schematic diagram of detection device provided in an embodiment of the present invention;
Fig. 8 is the structural schematic diagram of a kind of electronic equipment provided in an embodiment of the present invention.
Specific embodiment
Below in conjunction with the attached drawing in the embodiment of the present application, technical solutions in the embodiments of the present application carries out clear, complete Site preparation description, it is clear that described embodiment is only some embodiments of the present application, is not whole embodiments.Based on this Apply for embodiment, every other implementation obtained by those of ordinary skill in the art without making creative efforts Example, shall fall in the protection scope of this application.
The detection method of duplicate message can be applied shown in Fig. 2 in parallel redundancy network provided in an embodiment of the present invention In communication network.The network includes first network equipment, second network equipment, the first local area network, the second local area network and target network Network equipment.
First network equipment and second network equipment support PRP agreement, and first network equipment includes local reception port, with And first port and second port, such as port A1 and port B1, second network equipment includes local sending port and first end Mouth and second port, such as port A2 and port B2.First local area network and the second local area network are respectively that two independent parallels work Local area network has different IP address, such as respectively address IP1 and the address IP2.In the identical message to consolidated network equipment Transmission in, transmission time difference between the first local area network and the second local area network is greater than preset duration.Destination network device is for receiving Message.Wherein, first network equipment, second network equipment and destination network device can be terminal, be also possible to server.Eventually End, which can be, supports PRP protocols User equipment (User Equipment, UE), the handheld device with wireless communication function, vehicle Equipment, wearable device are carried, equipment is calculated or is connected to other processing equipments of radio modem, mobile station (Mobile Station, MS) etc., server can be application server or Cloud Server etc..
Message, port A1 and port B1 are used to datagram for receiving data for the local reception port of first network equipment The transmission of text and management message, the local sending port of second network equipment are used to send duplicate message inspection to destination network device Data message after survey, port A2 are used for through the first local area network receiving port A1 data message sent and management message, end Mouth B1 is used for through the second local area network receiving port B2 data message sent and manages message.
Preferred embodiment of the present application is illustrated below in conjunction with Figure of description, it should be understood that described herein Preferred embodiment only for the purpose of illustrating and explaining the present invention and is not intended to limit the present invention, and in the absence of conflict, this Shen Please in embodiment and embodiment in feature can be combined with each other.
Below with reference to network frame shown in Fig. 2, the embodiment of the present invention is described in detail.
Fig. 3 is the process signal of the detection method of duplicate message in a kind of parallel redundancy network provided in an embodiment of the present invention Figure.As shown in figure 3, this method may include:
Step 310, the first port of second network equipment receive the data message sent by the first local area network and management Message.
Wherein, the propagation delay time of the first local area network is much larger than the propagation delay time of the second local area network.
Before executing the step, after the local interface of first network equipment receives a data message, by the data Message is copied into two parts of identical data messages, and adds the redundancy of 6 bytes at the end of this two parts of identical data messages Abstract factory (Redundancy Control Tag, RCT), then it is packaged into through ICP/IP protocol layer the datagram of PRP frame format Text.
Optionally, PRP message (or " frame ") format is as shown in figure 4, the frame includes frame head, data portion (DATA), RCT With Frame Check Sequence (Frame Check Sequence, FCS).Wherein, frame head includes the purpose physics of 6 bits (byte) The frame type of the address, the source MAC of 6yte and 2byte (Media Access Control, MAC);RCT includes 16bit's Sequence number (Sequence Number, SeqNr), 4bit LAN ID symbol LAN ID, 12bit data length LSDU, The type suffix PRP suffix of 16bit, the bit number that DATA is occupied can be determined according to the size of data for being actually subjected to transmission.
It is understood that in order to reach time and Frequency Synchronization, second network equipment is also required to through local area network to One network equipment sends management message.
Optionally, PTP manages message (or " frame ") format as shown in figure 5, including heading, main body of the packet and extension word Section.
The management message of first network device configuration clock synchronization protocol (Precision Time Protocol, PTP), And replicate two parts of identical management messages, identical management message message information having the same.PTP is a kind of pair of standard ether The agreement of net equipment progress time and Frequency Synchronization.Synchronous basic principle includes sending and receiving the note of temporal information the time Record, and one " timestamp " is increased to each information.The sending cycle of management message can be preset.
First network equipment can by itself first port by the data message of a PRP and a management message from First local area network is sent, by itself second port by the data message of another PRP and another management message from Second local area network is sent.
It should be noted that the corresponding local area network of first port and second port of first network equipment and the second net The corresponding local area network of first port and second port of network equipment can be preset, as first network equipment and the second network are set Standby first port corresponds to the first local area network of the address IP1, and the second port of first network equipment and second network equipment is equal Second local area network of the corresponding address IP2.
Further, the management message of the data message of PRP and PTP are respectively provided with the reversion duration of sequence number, data message Sequence number and management message sequence number reversion when the rearrangement of a length of sequence number duration, otherwise the sequence of data message Number with management message sequence number the duration that a length of sequence number is not resequenced when not inverting.Between two neighboring management message It sends interval and is less than the sequence number of data message and do not invert duration, a length of datagram when not inverting of the sequence number of data message The duration that the sequence number of text is not resequenced, the sequence number of a length of management message when not inverting for managing the sequence number of message do not weigh The duration of new sort.
By taking the sequence number of the data message of PRP as an example, the Serial No. 1-100 of the data message of PRP is preset.When After one network equipment issues the data message of the data message of Serial No. 1 to Serial No. 100, the sequence number of data message It will resequence, first network equipment will issue the data message of Serial No. 1, the i.e. number of Serial No. 1-100 later The when a length of sequence number for all issuing according to message experience does not invert duration.
Step 320 obtains data message and manages the message information of message, and message information includes the source MAC of data message Address, the sequence number of data message and neighbor management message sequence number.
Wherein, neighbor management message is the first port of second network equipment before receiving data message, last time Received management message.
Neighbor management message in the step is the first port of second network equipment before receiving data message, finally Primary received management message.That is, the neighbor management message is the previous moment management report adjacent with the data message Text.Such as, receiving time of the first port of second network equipment based on management message and data message, it is available such as the following table 1.
Table 1
In table 1, in t1 reception to the first management message, t2 reception to the second management message, t3 reception To the first data message, t4 reception to the second data message, t5 reception to third manages message.Based on table 1, first The neighbor management message of data message is the second management message, and the neighbor management message of the second data message is the second management report Text, the neighbor management message of third data message are third management message, therefore the available source MAC to the first data message Location is MAC1, the source MAC of the Serial No. 002A of the management message of Serial No. 001B and second, the second data message is The source MAC of MAC1, Serial No. 002B and the second management Serial No. 002A of message, third data message be MAC1, The Serial No. 003A of Serial No. 003B and third management message.
It is understood that due to the first local area network propagation delay time be much larger than the second local area network propagation delay time, therefore After the first port of second network equipment subtracts propagation delay time by the receiving time of the first local area network in table 1, available The second port of two network equipments passes through the receiving time of the second local area network, it is to be understood that the first of second network equipment The sequence of port and the received management message of second port and data message is identical as in table 1, and only receiving time is different.
For example, for same data message, if the propagation delay time of the first local area network is much larger than the transmission of the second local area network Prolong, and transmission time delay difference is T, then the second port of second network equipment passes through the received management message of the second local area network and data Message is as shown in table 2, after time T, the first port of second network equipment by the received management message of the first local area network with Data message is as shown in table 3.Wherein, Mac indicates that the source MAC of data message, seq indicate data message, management frame table Show management message.
Table 2
Table 3
In conjunction with table 2 with table 3 it is found that the received management message of the two and data message are identical, only receiving time is different.
The second port by second network equipment recorded in step 330, the informational table of nodes based on storage has received The source MAC of data message, the sequence number of data message and corresponding neighbor management message sequence number, to received data Message carries out duplicate message detection.
The informational table of nodes of storage is used to record the received management message of second port for passing through second network equipment The sequence number of sequence number, the source MAC of data message and data message, and save duration.
The source MAC and data of a length of sequence number for saving received neighbor management message, data message when preservation The maximum time of the sequence number of message.If the sequence number of the received management message of informational table of nodes record, data message The sequence number of source MAC and data message reaches preservation duration, then the information will be deleted.Wherein, in informational table of nodes When the preservation of the sequence number of the source MAC of received data message, the sequence number of data message and corresponding neighbor management message It fails to grow up and does not invert duration in management sequence of message number, i.e., the source MAC of received data message at first in informational table of nodes When the sequence number of location, sequence number and corresponding neighbor management message reaches preservation duration, management sequence of message number is not centainly in anti- Turn in duration.
Optionally, the source MAC of data message, the sequence number of data message and corresponding neighbor management in informational table of nodes The maximum of the sequence number of message saves duration TSFor the reversion duration T for managing messageFWith the receiving time T of current data message1With The receiving time T of neighbor management message2Time difference difference, can indicate are as follows: TS=TF-(T1-T2) (formula one).
The informational table of nodes of storage is as shown in table 4.
Table 4
In table 4, informational table of nodes includes the number that source MAC is the address MAC1 of first network equipment, Serial No. 0 According to the neighbor management message of message and its Serial No. 0, the residue of the information a length of T1 when saving;The datagram of Serial No. 1 The neighbor management message of text and its Serial No. 0, the residue of the information a length of T2 when saving;The data message of Serial No. 2, With the neighbor management message of its Serial No. 0, the residue of the information a length of T3 when saving;The data message of Serial No. 3 and its The neighbor management message of sequence number 1, the residue of the information a length of T4 when saving.
Second network equipment is connect according to sequence number sequence in the sequence number of data message and the sequence number of management message It receives, therefore the remaining duration that saves of the data message of Serial No. 0 and adjacent management message is less than sequence number in informational table of nodes Duration is saved for 1 data message and the remaining of neighbor management message, and so on, the data message of Serial No. N and adjacent Remaining data message of the preservation duration less than Serial No. N+1 of message and the remaining preservation duration of management message are managed, N is not small In zero integer, therefore T1 is less than T2 and is less than T3 less than T4.If it is zero that residue, which saves duration T1, T1 all letters of the row are deleted Breath.
For example, a length of 60s when informational table of nodes is to the preservation of every information, every information includes received adjacent tubes Manage sequence number, the source MAC of data message and the sequence number of data message of message.
The current receiving time of the data message of Serial No. 0 is t+0, the sequence of the neighbor management message of the data message It number is 0, at this point, the corresponding remaining 60s a length of when saving of the data message;
The current receiving time of the data message of Serial No. 1 is t+20, the sequence of the neighbor management message of the data message Row number is 0, at this point, the corresponding remaining 40s a length of when saving of the data message of Serial No. 0, the data message pair of Serial No. 1 A length of 60s when the remaining preservation answered;
The current receiving time of the data message of Serial No. 2 is t+40, the sequence of the neighbor management message of the data message Row number is 0, at this point, the corresponding remaining 0s a length of when saving of the data message of Serial No. 0, the data message pair of Serial No. 1 A length of 20s when the remaining preservation answered, the data message of Serial No. 2 corresponding residue a length of 60s when saving.
Step 330 is returned to, carries out duplicate message detection to from the received data message of first network equipment.
For same data message, if the propagation delay time of the first local area network is much larger than the propagation delay time of the second local area network, The sequence number of the source MAC of data message, the sequence number of data message and neighbor management message is corresponding in informational table of nodes It manages message and data message is received by the corresponding second port of the second local area network, the message letter obtained in step 320 Breath is received by the corresponding first port of the first local area network.
Whether query node information table, exist simultaneously in recognition node information table and the message information that obtains is consistent has connect The sequence number of the source MAC of the data message of receipts, sequence number and neighbor management message.
When there is no when the message information obtained, confirm that the corresponding data message of the message information is non-in informational table of nodes Duplicate message;Later, the corresponding data message of the message information is sent to destination network device, and is recorded in informational table of nodes The message information, to realize the normal transmission of data message.
When there is the message information obtained in informational table of nodes, the corresponding data message of the message information is confirmed to repeat Message.At this point, abandoning the data message.
As it can be seen that compared with now with technology, the application above method by the source MAC of data message, sequence number and The sequence number of neighbor management message identifies whether to have received duplicate message jointly, i.e., not only received in query node information table Source MAC, the sequence number of data message also inquire the sequence number of the neighbor management message of the data message, to improve The accuracy of duplicate message detection.
Below for same data message, the propagation delay time of the first local area network is much larger than the propagation delay time of the second local area network Example.
Fig. 6 is that the process of the detection method of duplicate message in another parallel redundancy network provided in an embodiment of the present invention is shown It is intended to.As shown in fig. 6, this method may include:
Received data message and preconfigured management message are copied as two parts of phases by step 610, first network equipment The data message and two parts of identical management messages of same addition RCT.
The data message for adding RCT and management message are sent to the by first port by step 620, first network equipment One local area network and second port are sent to the second local area network.
Step 630, second network equipment receive the number for the addition RCT that the second local area network is sent by the second port of itself According to message and management message.
Source MAC, the number of the data message of step 640, second network equipment based on the received addition RCT of second port According to the sequence number of message and the sequence number of management message, informational table of nodes is generated.
Step 650, second network equipment receive the number for the addition RCT that the first local area network is sent by the first port of itself According to message and management message.
Source MAC, the number of the data message of step 660, second network equipment based on the received addition RCT of first port According to the sequence number of message and the sequence number of management message, message information is obtained.
Message information includes the source MAC of the data message, the sequence number of data message and neighbor management message Sequence number.
Step 670, when in informational table of nodes there is no obtain message information when, confirm the corresponding data of the message information Message is non-duplicate message, and the message information is recorded in informational table of nodes.
Step 680 sends the corresponding data message of the message information to destination network device.
Step 690, when in informational table of nodes exist obtain message information when, confirm the corresponding datagram of the message information Text is duplicate message, and abandons the data message.
The above method of the embodiment of the present invention is receiving the data message and management message sent by the first local area network, the After the propagation delay time of one local area network is much larger than the propagation delay time of the second local area network, obtains data message and manage the message letter of message Breath, message information includes the sequence number of the source MAC of data message, the sequence number of data message and neighbor management message;Base The source MAC of the received data message of second port by second network equipment recorded in the informational table of nodes of storage Location, the sequence number of data message and corresponding neighbor management message sequence number, to received data message carry out duplicate message inspection It surveys, by, with the presence or absence of the message information obtained, whether determining the corresponding data message of message information in detection node information table For duplicate message, compared with prior art, this method is not more than management sequence of message number in the preservation duration of informational table of nodes Duration is not inverted, and the transmission interval between two neighboring management message is less than the case where not inverting duration of data message sequence number Under, known jointly by the sequence number of the source MAC of data message, the sequence number of data message and corresponding neighbor management message Whether duplicate message is not had received, improves the accuracy of duplicate message detection.
Corresponding with the above method, the embodiment of the present invention also provides a kind of detection device, as shown in fig. 7, the detection device It include: receiving unit 710, acquiring unit 720, detection unit 730 and confirmation unit 740;
Receiving unit 710 passes through the data message and management message that the first local area network is sent, the first local area network for receiving Propagation delay time be much larger than the second local area network propagation delay time;
Acquiring unit 720, for obtaining data message and managing the message information of message, message information includes data message Source MAC, the sequence number of data message and the sequence number of neighbor management message;Neighbor management message is second network equipment First port before receiving data message, the received management message of last time;
Detection unit 730, the second end by second network equipment for being recorded in the informational table of nodes based on storage Source MAC, the sequence number of data message and the sequence number of corresponding neighbor management message of the received data message of mouth, docking The data message of receipts carries out duplicate message detection;Wherein, the source MAC of received data message, number in informational table of nodes It is not more than the sequence number of management message not according to the preservation duration of the sequence number of the sequence number and corresponding neighbor management message of message Duration is inverted, and the transmission interval between two neighboring management message does not invert duration less than data message sequence number;
Confirmation unit 740, for when, there is no when the message information obtained, confirmation message information is corresponding in informational table of nodes Data message be non-duplicate message;
When there is the message information obtained in informational table of nodes, the corresponding data message of confirmation message information is attached most importance to Multiple message.
One it is optional realize, detection unit 730, specifically for whether existed simultaneously in recognition node information table with The source MAC of the consistent received data message of the message information of acquisition, the sequence number of data message and corresponding adjacent tubes Manage the sequence number of message.
In an optional realization, which further includes recording unit 750 and transmission unit 760;
Transmission unit 760, for the corresponding data message of confirmation message information be non-duplicate message after, to target network Equipment sends the corresponding data message of the message information;
Recording unit 750, for recording the message information in informational table of nodes.
In an optional realization, which further includes deleting unit 770;
Unit 770 is deleted, being also used to delete the corresponding data message of message information in confirmation is deletion after duplicate message The corresponding data message of message information.
The function of each functional unit for the detection device that the above embodiment of the present invention provides, can be walked by above-mentioned each method It is rapid to realize, therefore, the specific work process and beneficial effect of each unit in detection device provided in an embodiment of the present invention, It does not repeat again herein.
The embodiment of the invention also provides a kind of electronic equipment, as shown in figure 8, include processor 810, communication interface 820, Memory 830 and communication bus 840, wherein processor 810, communication interface 820, memory 830 are complete by communication bus 840 At mutual communication.
Memory 830, for storing computer program;
Processor 810 when for executing the program stored on memory 830, realizes following steps:
It receives the data message sent by the first local area network and management message, the propagation delay time of the first local area network is much larger than The propagation delay time of second local area network;
It obtains data message and manages the message information of message, message information includes the source MAC of data message, data The sequence number of message and the sequence number of neighbor management message;Neighbor management message is that the first port of second network equipment is receiving Before data message, the received management message of last time;
The received datagram of second port by second network equipment recorded in informational table of nodes based on storage Source MAC, the sequence number of data message and the sequence number of corresponding neighbor management message of text carry out received data message Duplicate message detection;Wherein, the source MAC of received data message in informational table of nodes, the sequence number of data message and The preservation duration of the sequence number of corresponding neighbor management message does not invert duration, and adjacent two no more than the sequence number for managing message The sequence number that transmission interval between a management message is less than data message does not invert duration;
When, there is no when the message information obtained, the corresponding data message of confirmation message information is non-heavy in informational table of nodes Multiple message;
When there is the message information obtained in informational table of nodes, the corresponding data message of confirmation message information is to repeat to report Text.
One it is optional realize, recorded in the informational table of nodes based on storage by the second of second network equipment The sequence number of the source MAC of the received data message in port, the sequence number of data message and corresponding neighbor management message, it is right Received data message carries out duplicate message detection, comprising:
Whether existed simultaneously in recognition node information table and the consistent received data message of message information of acquisition The sequence number of source MAC, the sequence number of data message and corresponding neighbor management message.
One it is optional realize, after the corresponding data message of confirmation message information is non-duplicate message, to target The network equipment sends the corresponding data message of message information, and the message information is recorded in informational table of nodes.
In an optional realization, confirmation deletes the corresponding data message of message information to delete after duplicate message The corresponding data message of message information.
Communication bus mentioned above can be Peripheral Component Interconnect standard (Peripheral Component Interconnect, PCI) bus or expanding the industrial standard structure (Extended Industry Standard Architecture, EISA) bus etc..The communication bus can be divided into address bus, data/address bus, control bus etc..For just It is only indicated with a thick line in expression, figure, it is not intended that an only bus or a type of bus.
Communication interface is for the communication between above-mentioned electronic equipment and other equipment.
Memory may include random access memory (Random Access Memory, RAM), also may include non-easy The property lost memory (Non-Volatile Memory, NVM), for example, at least a magnetic disk storage.Optionally, memory may be used also To be storage device that at least one is located remotely from aforementioned processor.
Above-mentioned processor can be general processor, including central processing unit (Central Processing Unit, CPU), network processing unit (Network Processor, NP) etc.;It can also be digital signal processor (Digital Signal Processing, DSP), it is specific integrated circuit (Application Specific Integrated Circuit, ASIC), existing It is field programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic device, discrete Door or transistor logic, discrete hardware components.
The embodiment and beneficial effect solved the problems, such as due to each device of electronic equipment in above-described embodiment can join Each step in embodiment as shown in Figure 3 realizes, therefore, the specific works mistake of electronic equipment provided in an embodiment of the present invention Journey and beneficial effect, do not repeat again herein.
In another embodiment provided by the invention, a kind of computer readable storage medium is additionally provided, which can It reads to be stored with instruction in storage medium, when run on a computer, so that computer executes any institute in above-described embodiment The detection method for the duplicate message stated.
In another embodiment provided by the invention, a kind of computer program product comprising instruction is additionally provided, when it When running on computers, so that computer executes the detection method of any duplicate message in above-described embodiment.
It should be understood by those skilled in the art that, the embodiment in the embodiment of the present application can provide as method, system or meter Calculation machine program product.Therefore, complete hardware embodiment, complete software embodiment can be used in the embodiment of the present application or combine soft The form of the embodiment of part and hardware aspect.Moreover, being can be used in the embodiment of the present application in one or more wherein includes meter Computer-usable storage medium (including but not limited to magnetic disk storage, CD-ROM, the optical memory of calculation machine usable program code Deng) on the form of computer program product implemented.
It is referring to according to the method for embodiment, equipment (system) and calculating in the embodiment of the present application in the embodiment of the present application The flowchart and/or the block diagram of machine program product describes.It should be understood that can be realized by computer program instructions flow chart and/or The combination of the process and/or box in each flow and/or block and flowchart and/or the block diagram in block diagram.It can mention For the processing of these computer program instructions to general purpose computer, special purpose computer, Embedded Processor or other programmable datas The processor of equipment is to generate a machine, so that being executed by computer or the processor of other programmable data processing devices Instruction generation refer to for realizing in one or more flows of the flowchart and/or one or more blocks of the block diagram The device of fixed function.
These computer program instructions, which may also be stored in, is able to guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works, so that it includes referring to that instruction stored in the computer readable memory, which generates, Enable the manufacture of device, the command device realize in one box of one or more flows of the flowchart and/or block diagram or The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device, so that counting Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, thus in computer or The instruction executed on other programmable devices is provided for realizing in one or more flows of the flowchart and/or block diagram one The step of function of being specified in a box or multiple boxes.
Although the preferred embodiment in the embodiment of the present application has been described, once a person skilled in the art knows Basic creative concept, then additional changes and modifications may be made to these embodiments.So appended claims are intended to explain Being includes preferred embodiment and all change and modification for falling into range in the embodiment of the present application.
Obviously, those skilled in the art embodiment in the embodiment of the present application can be carried out various modification and variations without It is detached from the spirit and scope of embodiment in the embodiment of the present application.If in this way, in the embodiment of the present application embodiment these modification Within the scope of belonging in the embodiment of the present application claim and its equivalent technologies with modification, then also it is intended in the embodiment of the present application It includes these modifications and variations.

Claims (10)

1. the detection method of duplicate message in a kind of parallel redundancy network, the of first network equipment in the parallel redundancy network Single port sends datagram and manages message to second network equipment by the first local area network, and the of the first network equipment Two-port netwerk sends the data message to second network equipment by the second local area network and the management message, feature exist In, which comprises
The first port of second network equipment receives the data message sent by first local area network and described Message is managed, the propagation delay time of first local area network is much larger than the propagation delay time of second local area network;
It obtains the data message and manages the message information of message, the message information includes the source MAC of the data message Address, the sequence number of the data message and neighbor management message sequence number;The neighbor management message is second net The first port of network equipment is before receiving the data message, the received management message of last time;
The received datagram of second port by second network equipment recorded in informational table of nodes based on storage Source MAC, the sequence number of the data message and the sequence number of corresponding neighbor management message of text, to the received data Message carries out duplicate message detection;Wherein, the source MAC of received data message, the number in the informational table of nodes It is not more than the sequence number of the management message according to the preservation duration of the sequence number of the sequence number and corresponding neighbor management message of message Do not invert duration, and the transmission interval between two neighboring management message is less than when not the inverting of sequence number of the data message It is long;
When the message information obtained is not present in the informational table of nodes, the corresponding number of the message information is confirmed It is non-duplicate message according to message;
When there is the message information obtained in the informational table of nodes, the corresponding data of the message information are confirmed Message is duplicate message.
2. the method as described in claim 1, which is characterized in that recorded in the informational table of nodes based on storage by described the The source MAC of the received data message of the second port of two network equipments, the sequence number of the data message and corresponding phase The sequence number of neighbour's management message carries out duplicate message detection to the received data message, comprising:
Identify the consistent received datagram of the message information for whether existing simultaneously and obtaining in the informational table of nodes Source MAC, the sequence number of the data message and the sequence number of corresponding neighbor management message of text.
3. the method as described in claim 1, which is characterized in that confirm that the corresponding data message of the message information is non- After duplicate message, the method also includes:
The corresponding data message of the message information is sent to destination network device, and is recorded in the informational table of nodes The message information.
4. the method as described in claim 1, which is characterized in that the corresponding data message of the message information is deleted in confirmation After duplicate message, the method also includes:
Delete the corresponding data message of the message information.
5. a kind of detection device, which is characterized in that described device includes: receiving unit, acquiring unit, detection unit and confirmation form Member;
The receiving unit, for receiving the data message and the management message that send by first local area network, The propagation delay time of first local area network is much larger than the propagation delay time of second local area network;
The acquiring unit, for obtaining the data message and managing the message information of message, the message information includes institute State the sequence number of the source MAC of data message, the sequence number of the data message and neighbor management message;The neighbor management Message is the first port of second network equipment before receiving the data message, the received management report of last time Text;
The detection unit, the second end by second network equipment for being recorded in the informational table of nodes based on storage Source MAC, the sequence number of the data message and the sequence number of corresponding neighbor management message of the received data message of mouth, Duplicate message detection is carried out to the received data message;Wherein, received data message in the informational table of nodes The preservation duration of the sequence number of source MAC, the sequence number of the data message and corresponding neighbor management message is no more than described Manage the sequence number of message does not invert duration, and the transmission interval between two neighboring management message is less than the data message Sequence number does not invert duration;
The confirmation unit, for confirming the report when the message information obtained is not present in the informational table of nodes The corresponding data message of literary information is non-duplicate message;
When there is the message information obtained in the informational table of nodes, the corresponding data of the message information are confirmed Message is duplicate message.
6. device as claimed in claim 5, which is characterized in that the detection unit is specifically used for identifying the nodal information Whether source MAC, the number with the message information consistent received data message that obtains is existed simultaneously in table According to the sequence number of message and the sequence number of corresponding neighbor management message.
7. device as claimed in claim 5, which is characterized in that described device further includes recording unit and transmission unit;
The transmission unit, for confirm the corresponding data message of the message information be non-duplicate message after, to mesh It marks the network equipment and sends the corresponding data message of the message information;
The recording unit, for recording the message information in the informational table of nodes.
8. device as claimed in claim 5, which is characterized in that described device further includes deleting unit;
The deletion unit, be also used to confirmation delete the corresponding data message of the message information be duplicate message it Afterwards, the corresponding data message of the message information is deleted.
9. a kind of electronic equipment, which is characterized in that the electronic equipment includes that processor, communication interface, memory and communication are total Line, wherein processor, communication interface, memory complete mutual communication by communication bus;
Memory, for storing computer program;
Processor when for executing the program stored on memory, realizes any method and step of claim 1-4.
10. a kind of computer readable storage medium, which is characterized in that be stored with computer in the computer readable storage medium Program realizes claim 1-4 any method and step when the computer program is executed by processor.
CN201811136858.5A 2018-09-28 2018-09-28 Method and device for detecting repeated messages in parallel redundant network Active CN109005088B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811136858.5A CN109005088B (en) 2018-09-28 2018-09-28 Method and device for detecting repeated messages in parallel redundant network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811136858.5A CN109005088B (en) 2018-09-28 2018-09-28 Method and device for detecting repeated messages in parallel redundant network

Publications (2)

Publication Number Publication Date
CN109005088A true CN109005088A (en) 2018-12-14
CN109005088B CN109005088B (en) 2020-07-17

Family

ID=64588958

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811136858.5A Active CN109005088B (en) 2018-09-28 2018-09-28 Method and device for detecting repeated messages in parallel redundant network

Country Status (1)

Country Link
CN (1) CN109005088B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109981479A (en) * 2019-02-27 2019-07-05 西安微电子技术研究所 A kind of sliding of single window dynamic and Redundancy Management system and method towards PRP network
CN110912655A (en) * 2019-12-24 2020-03-24 瑞斯康达科技发展股份有限公司 Data redundancy backup method, device, equipment and medium
CN111935243A (en) * 2020-07-17 2020-11-13 杭州海康机器人技术有限公司 Data information transmission method, device, system and equipment
US11303568B1 (en) 2021-04-05 2022-04-12 Honeywell International Inc. Method and system for parallel redundancy protocol in connected networks
CN115102673A (en) * 2022-04-29 2022-09-23 中国船舶重工集团公司第七一六研究所 PRP protocol repeated frame distinguishing and processing method and system based on frame memory pool
CN115378816A (en) * 2022-08-02 2022-11-22 深信服科技股份有限公司 Network configuration detection method, device and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102523108A (en) * 2011-12-07 2012-06-27 中国航空无线电电子研究所 Aviation electronic management system based on avionics full-duplex switched Ethernet (AFDX)
CN103684852A (en) * 2013-11-26 2014-03-26 中国电子科技集团公司第三十二研究所 Redundancy removing method and system in AFDX (avionics full Duplex switched Ethernet) network redundancy management module
CN106789425A (en) * 2016-12-22 2017-05-31 北京东土科技股份有限公司 A kind of method and device for determining duplicate message
CN107257301A (en) * 2017-08-10 2017-10-17 北京东土科技股份有限公司 The detection method and device of duplicate message and failure in a kind of parallel redundancy network

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102523108A (en) * 2011-12-07 2012-06-27 中国航空无线电电子研究所 Aviation electronic management system based on avionics full-duplex switched Ethernet (AFDX)
CN103684852A (en) * 2013-11-26 2014-03-26 中国电子科技集团公司第三十二研究所 Redundancy removing method and system in AFDX (avionics full Duplex switched Ethernet) network redundancy management module
CN106789425A (en) * 2016-12-22 2017-05-31 北京东土科技股份有限公司 A kind of method and device for determining duplicate message
CN107257301A (en) * 2017-08-10 2017-10-17 北京东土科技股份有限公司 The detection method and device of duplicate message and failure in a kind of parallel redundancy network

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
MARKUS RENTSCHLER等,: ""The Parallel Redundancy Protocol for industrial IP networks"", 《 2013 IEEE INTERNATIONAL CONFERENCE ON INDUSTRIAL TECHNOLOGY (ICIT)》 *
陈原子,: ""基于并行冗余网络的数字化变电站通信网络构架"", 《电力自动化设备》 *

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109981479A (en) * 2019-02-27 2019-07-05 西安微电子技术研究所 A kind of sliding of single window dynamic and Redundancy Management system and method towards PRP network
CN109981479B (en) * 2019-02-27 2022-06-28 西安微电子技术研究所 PRP network-oriented single-window dynamic sliding and redundancy management system and method
CN110912655A (en) * 2019-12-24 2020-03-24 瑞斯康达科技发展股份有限公司 Data redundancy backup method, device, equipment and medium
CN111935243A (en) * 2020-07-17 2020-11-13 杭州海康机器人技术有限公司 Data information transmission method, device, system and equipment
CN111935243B (en) * 2020-07-17 2023-06-30 杭州海康机器人股份有限公司 Data information transmission method, device, system and equipment
US11303568B1 (en) 2021-04-05 2022-04-12 Honeywell International Inc. Method and system for parallel redundancy protocol in connected networks
CN115102673A (en) * 2022-04-29 2022-09-23 中国船舶重工集团公司第七一六研究所 PRP protocol repeated frame distinguishing and processing method and system based on frame memory pool
CN115102673B (en) * 2022-04-29 2023-11-03 中国船舶集团有限公司第七一六研究所 PRP protocol repeated frame discrimination processing method and system based on frame memory pool
CN115378816A (en) * 2022-08-02 2022-11-22 深信服科技股份有限公司 Network configuration detection method, device and storage medium
CN115378816B (en) * 2022-08-02 2024-02-23 深信服科技股份有限公司 Network configuration detection method, device and storage medium

Also Published As

Publication number Publication date
CN109005088B (en) 2020-07-17

Similar Documents

Publication Publication Date Title
CN109005088A (en) The detection method and device of duplicate message in parallel redundancy network
US9742514B2 (en) Method, apparatus, and system for generating timestamp
US8332867B2 (en) Methods and devices for sending transmission-time or reception-time information for a transmitted or received message
EP2448168A1 (en) Method and system for bearing time synchronization protocol in optical transport network
CN102833061A (en) Method for improving clock accuracy based on seamless redundancy ring network and node
CN1937541A (en) Network performance test method
CN103001846B (en) Embedded end-to-end delay information for data network
CN106850397A (en) Message delivery method and device in Internet of Things
CN104144223B (en) A kind of data capture method and device
CN105391612B (en) A kind of method and device of VXLAN VTEP adjoinings study
US8599845B2 (en) Software-assisted VLAN aging timer scheme for distributed switching systems
CN102882793A (en) Topology change message transmitting and processing method and network equipment
CN113300798A (en) Transmission certainty access method of asynchronous terminal
CN107508648A (en) Time triggered Ethernet substep time synchronized strategy based on functions of the equipments classification
CN114301793A (en) Path generation method and device in optical transmission network
CN106454767A (en) Business data synchronization method, device and system
CN104601269A (en) Master and slave clock synchronization method and system
CN105072043B (en) Client announcement procedure optimization method in MESH network Routing Protocol
CN112039621B (en) Time synchronization method and system
CN103117883B (en) A kind of packet equipment running status synchronous method
CN105634999B (en) A kind of aging method and device of Media Access Control address
CN114745318A (en) IPv6 dynamic Internet of things-oriented path recovery method
CN113364694B (en) BIER message forwarding method and system
CN112600641A (en) Network equipment time synchronization method, device, equipment and storage medium
TWI599260B (en) Local communication wireless network system and method thereof

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant