CN106789437B - Message processing method, forwarding method, related device and packet loss rate measuring method - Google Patents

Message processing method, forwarding method, related device and packet loss rate measuring method Download PDF

Info

Publication number
CN106789437B
CN106789437B CN201611247419.2A CN201611247419A CN106789437B CN 106789437 B CN106789437 B CN 106789437B CN 201611247419 A CN201611247419 A CN 201611247419A CN 106789437 B CN106789437 B CN 106789437B
Authority
CN
China
Prior art keywords
message
control device
forwarding
forwarding device
slave control
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.)
Active
Application number
CN201611247419.2A
Other languages
Chinese (zh)
Other versions
CN106789437A (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.)
Raisecom Technology Co Ltd
Original Assignee
Raisecom 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 Raisecom Technology Co Ltd filed Critical Raisecom Technology Co Ltd
Priority to CN201611247419.2A priority Critical patent/CN106789437B/en
Publication of CN106789437A publication Critical patent/CN106789437A/en
Application granted granted Critical
Publication of CN106789437B publication Critical patent/CN106789437B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • 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
    • H04L43/0823Errors, e.g. transmission errors
    • H04L43/0829Packet loss
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/22Parsing or analysis of headers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/54Store-and-forward switching systems 
    • H04L12/56Packet switching systems
    • H04L12/5601Transfer mode dependent, e.g. ATM
    • H04L2012/5625Operations, administration and maintenance [OAM]

Abstract

The invention discloses a message processing method, a forwarding method, a related device and a packet loss rate measuring method.A slave control device directly performs control message interaction with a forwarding device through a service port by utilizing a request message which has a preset format and carries control information for operating and controlling the forwarding device, optimizes a control communication flow which needs to bypass a master control device and then reaches the forwarding device into a direct control communication mode of the slave control device and the forwarding device, namely, a data communication message with a special format is adopted, and a data flow channel between the slave control device and the forwarding device is multiplexed for transmission so as to realize the direct transmission of control information, thereby releasing the control operation capability of the master control device.

Description

Message processing method, forwarding method, related device and packet loss rate measuring method
Technical Field
The present invention relates to the field of communications technologies, and in particular, to a method for processing a packet, a method for forwarding the packet, a related apparatus, and a method for measuring a packet loss rate.
Background
Conventional communication devices typically employ an architecture of a forwarding device 3 and a master control device 1 as shown in fig. 1. Therefore, in order to realize complex control functions, the conventional communication device needs to use the high-performance main control device 1, and the high-performance main control device 1 is relatively expensive, which affects the cost performance of the communication device.
At present, on the premise of controlling cost, in order to implement complex control functions, communication equipment often adopts a framework in which a master control device 1, a slave control device 2 and a forwarding device 3 cooperate as shown in fig. 2. The load on the master controller 1 is reduced by providing the slave controller 2, and the computing power of the master controller 1 is released and used for realizing the device management function. The control channel of the forwarding device 3 usually has only one, e.g. CPU port in fig. 2, and the slave control device 2 can only operate and control the forwarding device 3 through the master control device 1. When the slave control device 2 and the forwarding device 3 cooperate to complete a relatively independent task, the slave control device 2 and the forwarding device 3 usually need to frequently interact, the complexity is high, and the burden of the master control device 1 is still large, which may affect the timeliness of the operation effect.
Disclosure of Invention
The embodiment of the invention provides a message processing method, a message forwarding method, a related device and a packet loss rate measuring method.
The embodiment of the invention provides a message processing method, which is applied to a slave control device in message communication equipment consisting of a master control device, a slave control device and a forwarding device which are connected with each other, and comprises the following steps:
sending a request message with a preset format and carrying control information for operating and controlling the forwarding device to the forwarding device through a second service port, so that the forwarding device feeds back a response message carrying control response information after identifying and analyzing the request message;
if the response message with the preset format fed back by the forwarding device is not received through the second service port within the preset time, sending a request message with the preset format and carrying control information for operating and controlling the forwarding device to the forwarding device through the second service port again;
and if a response message with the preset format fed back by the forwarding device is received through the second service port within the preset time after the request message is sent, acquiring the control response information according to the response message.
Preferably, the processing method provided in the embodiment of the present invention further includes:
receiving an OAM message transmitted by remote equipment and forwarded by a forwarding device through a first service port;
and processing the received OAM message according to a preset rule.
Preferably, in the processing method provided in the embodiment of the present invention, the processing the received OAM message according to a preset rule specifically includes:
directly processing the OAM message; alternatively, the first and second electrodes may be,
preprocessing the OAM message; sending the preprocessed OAM message to a forwarding device through the first service port, and sending the OAM message to a main control device through the forwarding device, so that the main control device further processes the preprocessed OAM message; alternatively, the first and second electrodes may be,
analyzing the received OAM message; determining whether the OAM message is a preset message according to an analysis result; if so, preprocessing the OAM message and then sending the OAM message to a forwarding device through the first service port so as to send the OAM message to a main control device through the forwarding device, so that the main control device further processes the preprocessed OAM message; and if not, directly processing the OAM message.
Preferably, the processing method provided in the embodiment of the present invention further includes:
receiving configuration information of OAM issued by a main control device through a data and control bus;
constructing an OAM message according to the received OAM configuration information;
and sending the constructed OAM message to a forwarding device through the first service port so as to forward the OAM message to remote equipment through the forwarding device.
Preferably, the processing method provided in the embodiment of the present invention further includes:
receiving an OAM message transmitted by a main control device and forwarded by a forwarding device through the first service port;
and modifying the received OAM message sent by the main control device, and sending the modified OAM message to the forwarding device through the first service port so as to forward the modified OAM message to the remote equipment through the forwarding device.
Correspondingly, an embodiment of the present invention further provides a method for forwarding a packet, where the method is applied to a forwarding device in a packet communication device including a master control device, a slave control device, and a forwarding device that are connected to each other, and the method includes:
receiving a request message which is sent from the control device through a second service port, has a preset format and carries control information for operating and controlling the forwarding device;
analyzing the received request message, and operating the forwarding device according to the analysis result;
and feeding back a response message which has the preset format and carries control response information to a slave control device through the second service port according to an operation result.
Preferably, in the forwarding method provided in the embodiment of the present invention, the method further includes:
receiving an OAM message sent by the remote equipment through a third service port;
and after the OAM message is identified, the OAM message is sent to a slave control device through a first service port, so that the slave control device processes the OAM message according to a preset rule.
Preferably, in the forwarding method provided in the embodiment of the present invention, the method further includes:
receiving an OAM message sent from a control device through the first service port;
after the OAM message is identified, the OAM message is sent to a remote device through the third service port; or after the OAM message is identified, the OAM message is sent to the main control device through a fourth service port.
Preferably, in the forwarding method provided in the embodiment of the present invention, the method further includes:
receiving a service message through a fifth service port; when determining that the next hop of the received service message is the remote equipment, sending the received service message to the remote equipment through the third service port;
receiving a service message sent by the remote equipment through the third service port; and sending the received service message through the fifth service port.
Preferably, in the forwarding method provided in the embodiment of the present invention, the method further includes: and accumulating the message statistic value in the sending direction by 1 every time a message is sent to the remote equipment through the third service port, and accumulating the message statistic value in the receiving direction by 1 every time a message sent by the remote equipment is received through the first service port.
Correspondingly, the embodiment of the invention also provides a slave control device, which comprises: a first interactive message processing module; wherein the first interactive message processing module is configured to:
sending a request message with a preset format and carrying control information for operating and controlling the forwarding device to the forwarding device through a second service port, so that the forwarding device feeds back a response message with the preset format and carrying control response information after identifying and analyzing the request message;
if the response message with the preset format fed back by the forwarding device is not received through the second service port within the preset time, sending a request message with the preset format and carrying control information for operating and controlling the forwarding device to the forwarding device through the second service port again;
and if a response message with the preset format fed back by the forwarding device is received through the second service port within a preset time after the request message is sent, acquiring the control response information according to the response message.
Preferably, the slave control device provided in the embodiment of the present invention further includes: a processing module; wherein the content of the first and second substances,
the processing module is used for receiving an OAM message transmitted by the remote equipment and forwarded by the forwarding device through the first service port; and processing the received OAM message according to a preset rule.
Preferably, in the slave control apparatus provided in the embodiment of the present invention, the processing module is specifically configured to:
directly processing the OAM message; alternatively, the first and second electrodes may be,
preprocessing the OAM message; sending the preprocessed OAM message to a forwarding device through the first service port, and sending the OAM message to a main control device through the forwarding device, so that the main control device further processes the preprocessed OAM message; alternatively, the first and second electrodes may be,
analyzing the received OAM message; determining whether the OAM message is a preset message according to an analysis result; if so, preprocessing the OAM message and then sending the OAM message to a forwarding device through the first service port so as to send the OAM message to a main control device through the forwarding device, so that the main control device further processes the preprocessed OAM message; and if not, directly processing the OAM message.
Preferably, in the slave control apparatus provided in the embodiment of the present invention, the processing module is further configured to: receiving configuration information of OAM issued by a main control device through a data and control bus;
constructing an OAM message according to the received OAM configuration information; and sending the constructed OAM message to a forwarding device through the first service port so as to forward the OAM message to remote equipment through the forwarding device.
Preferably, in the slave control apparatus provided in the embodiment of the present invention, the processing module is further configured to:
receiving an OAM message transmitted by a main control device and forwarded by a forwarding device through the first service port;
and sending the received OAM message sent by the main control device to a forwarding device through the first service port, so as to forward the OAM message to a remote device through the forwarding device.
Correspondingly, an embodiment of the present invention further provides a forwarding apparatus, including: a second interactive message processing module; wherein, the second interactive message processing module is used for:
receiving a request message which is sent from the control device through a second service port, has a preset format and carries control information for operating and controlling the forwarding device;
analyzing the received request message, and operating the forwarding device according to the analysis result;
and feeding back a response message which has the preset format and carries control response information to the slave control device through the second service port according to an operation result.
Preferably, in the slave forwarding apparatus provided in the embodiment of the present invention, the slave forwarding apparatus further includes: a first channel; wherein the first channel is to:
receiving an OAM message sent by a remote device through a third service port, identifying the OAM message, and sending the OAM message to a slave control device through a first service port so that the slave control device processes the OAM message according to a preset rule;
and receiving an OAM message sent from a control device through the first service port, identifying the OAM message, and sending the OAM message to remote equipment through the third service port.
Preferably, the slave forwarding device provided in the embodiment of the present invention further includes a second channel; wherein the second channel is to:
receiving an OAM message sent from a control device through the first service port;
and after the OAM message is identified, the OAM message is sent to a main control device through a fourth service port.
Preferably, in the slave forwarding apparatus provided in the embodiment of the present invention, the slave forwarding apparatus further includes: a third channel; wherein the third channel is to:
receiving a service message through a fifth service port; when determining that the next hop of the received service message is the remote equipment, sending the received service message to the remote equipment through the third service port;
receiving a service message sent by the remote equipment through the third service port; and sending the received service message through the fifth service port.
Preferably, in the slave forwarding apparatus provided in the embodiment of the present invention, the slave forwarding apparatus further includes: a statistical module; wherein the statistics module is to:
and when the third service port receives a message sent by the remote equipment, the message statistic value of the receiving direction of the forwarding device is accumulated by 1.
Correspondingly, the embodiment of the invention also provides message communication equipment, which comprises a master control device, a slave control device and a forwarding device;
the slave control device is used for sending a request message which has a preset format and carries control information for operating and controlling the forwarding device to the forwarding device through the second service port, so that the forwarding device feeds back a response message carrying control response information after identifying and analyzing the request message; if the response message with the preset format fed back by the forwarding device is not received through the second service port within the preset time, sending a request message with the preset format and carrying control information for operating and controlling the forwarding device to the forwarding device through the second service port again; if a response message with the preset format fed back by a forwarding device is received through the second service port within a preset time after the request message is sent, acquiring the control response information according to the response message;
the forwarding device is used for receiving a request message which is sent from the control device through the second service port, has a preset format and carries control information for operating and controlling the forwarding device; analyzing the received request message, and operating the forwarding device according to the analysis result; and feeding back a response message which has the preset format and carries control response information to the slave control device through the second service port according to an operation result.
Correspondingly, an embodiment of the present invention further provides a method for measuring a packet loss rate of the message communication device, including:
the master control device in the message communication equipment sends the constructed L MM message to the slave control device in the message communication equipment through the forwarding device in the message communication equipment;
after receiving the L MM message, the slave control device sends a first request message with a preset format to the forwarding device;
after receiving the first request message, the forwarding device feeds back a first response message which has the preset format and carries a message statistic value c1 of the current sending direction of the forwarding device to the slave control device according to the first request message;
the slave control device fills c1 carried by the first response message into the L MM message and then sends the message to the remote device through the forwarding device;
the slave control device receives a L MR message fed back by a remote device based on an L MM message through the forwarding device, wherein the L MR message carries c1, a message statistic c2 of a receiving direction of the remote device and a message statistic c3 of a sending direction of the remote device when the remote device sends the L MR message;
after receiving the L MR message, the slave control device sends a second request message with a preset format to the forwarding device;
after receiving the second request message, the forwarding device feeds back a second response message which has a preset format and carries the message statistic value c4 of the current receiving direction of the forwarding device to the slave control device according to the second request message;
the slave control device fills c4 carried by the second response message into the L MR message and then sends the message to the master control device through the forwarding device;
and the main control device calculates the packet loss rate according to the c1, c2, c3 and c4 in the received L MR message.
Correspondingly, an embodiment of the present invention further provides a method for measuring a packet loss rate of the message communication device, including:
a forwarding device in the message communication equipment sends a received L MM message sent by the remote equipment to a slave control device in the message communication equipment, wherein the L MM message carries a message statistic d1 of the sending direction of the remote equipment when the remote equipment sends the L MM message;
after receiving the L MM message, the slave control device sends a first request message with a preset format to the forwarding device;
after receiving the first request message, the forwarding device feeds back a first response message which has the preset format and carries the message statistic d2 of the current receiving direction of the forwarding device to the slave control device according to the first request message;
the slave control device fills d2 carried by the first response message into the L MM message and then sends the message to a master control device in the message communication equipment through the forwarding device;
after the master control device receives the L MM message sent by the slave control device through the forwarding device, the master control device obtains a message statistic d3 of the current sending direction of the forwarding device;
the master control device constructs a L MR message according to the d3 and the received L MM message, wherein the L MR message carries d1, d2 and d 3;
the master control device sends the L MR message to the slave control device through the forwarding device;
the slave control device sends the L MR message to the remote device through the forwarding device, so that the remote device performs packet loss rate calculation according to d1, d2 and d3 carried in the L MR message, and a message statistic d4 of the remote device receiving direction when the remote device receives the L MR message.
The invention has the following beneficial effects:
in the method for processing a packet, the forwarding method, the related device and the method for measuring a packet loss ratio provided by the embodiments of the present invention, the slave control device directly performs control packet interaction with the forwarding device through the service port by using a request packet having a preset format and carrying control information for performing operation control on the forwarding device, and optimizes a control communication flow that originally needs to bypass the master control device and then reaches the forwarding device to a direct control communication manner of the slave control device and the forwarding device, that is, a data communication packet having a special format is used, and a data flow channel between the slave control device and the forwarding device is multiplexed for transmission, so as to realize direct transmission of control information, thereby releasing the control operation capability of the master control device.
Drawings
Fig. 1 is a schematic structural diagram of a conventional communication device;
fig. 2 is a second schematic structural diagram of a conventional communication device;
fig. 3 is a flowchart of a message processing method according to an embodiment of the present invention;
fig. 4 is a flowchart of a message forwarding method according to an embodiment of the present invention;
fig. 5 is a schematic diagram of a forwarding device according to an embodiment of the present invention performing hierarchical statistics;
FIG. 6 is a schematic structural diagram of a slave control device according to an embodiment of the present invention;
fig. 7 is a schematic structural diagram of a forwarding device according to an embodiment of the present invention;
fig. 8 is a schematic structural diagram of another forwarding device according to an embodiment of the present invention;
fig. 9 is a schematic diagram of message interaction of a communication device for implementing an OAM function according to an embodiment of the present invention;
fig. 10 is a schematic diagram of another message interaction for implementing an OAM function in a communication device according to an embodiment of the present invention;
fig. 11 is another schematic diagram of message interaction of the communication device to implement an OAM function according to the embodiment of the present invention;
fig. 12 is a schematic diagram of another message interaction for implementing an OAM function in a communication device according to an embodiment of the present invention;
fig. 13 is an interaction diagram of message interaction between a slave control device and a forwarding device in a communication apparatus according to an embodiment of the present invention;
fig. 14 is a flowchart of a packet loss rate measurement of a communication device according to an embodiment of the present invention;
fig. 15 is a flowchart of another packet loss ratio measurement of a communication device according to an embodiment of the present invention.
Detailed Description
In order to solve the problem that a slave control device in the existing communication equipment can only communicate with a forwarding device through a master control device to control message communication, embodiments of the present invention provide a message processing method, a forwarding method, a related device, and a packet loss rate measurement method, which can enable the slave control device to directly communicate with the forwarding device to control message communication, and improve timeliness of an operation effect.
In order to make the objects, technical solutions and advantages of the present invention clearer, the present invention will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In view of the above, for the slave control device, an embodiment of the present invention provides a message processing method, which is applied to a slave control device in a message communication apparatus composed of a master control device, a slave control device and a forwarding device connected to each other, and as shown in fig. 3, the message processing method includes:
s301, sending a request message with a preset format and carrying control information for operating and controlling the forwarding device to the forwarding device through a second service port, so that the forwarding device feeds back a response message carrying control response information after identifying and analyzing the request message;
s302, if a response message with a preset format fed back by the forwarding device is not received through the second service port within a preset time, sending a request message with the preset format and carrying control information for operating and controlling the forwarding device to the forwarding device through the second service port again;
and S303, if a response message with a preset format fed back by the forwarding device is received through the second service port within a preset time after the request message is sent, acquiring control response information according to the response message.
In the method for processing a packet provided in the embodiment of the present invention, the slave control device directly performs control packet interaction with the forwarding device through the service port by using the request packet having the preset format and carrying the operation control information for operating and controlling the forwarding device, and optimizes the control communication flow that originally needs to bypass the master control device and then reaches the forwarding device into a direct control communication mode between the slave control device and the forwarding device, that is, a data communication packet having a special format is used, and a data flow channel between the slave control device and the forwarding device is multiplexed for transmission, so as to implement direct transmission of control information, thereby releasing the control operation capability of the master control device.
In a specific implementation, in the message processing method provided in the embodiment of the present invention, the request message having the preset format and carrying the operation and control information for controlling the operation of the forwarding device is sent from the control device, so that the forwarding device can identify and analyze the request message. The preset format can be a special communication message format or various standard protocol message formats. Taking the preset format as the ETH message format as an example, the ETH message format is shown in table 1. And fields of dst _ mac/src _ mac/tpid/vlan/ethertype/tlv offset and the like in the ETH message format adopt the content agreed in advance by the slave control device and the forwarding device, so that both ends can normally process the communication message.
Field(s) Length of Means of
dst_mac 6 bytes Destination MAC
src_mac 6 bytes Source MAC
tpid 2 bytes vlan TPID, default 0x8100, configurable
vlan
2 bytes vlan tag
ethertype
2 bytes Ether type, using agreed message type
tlv offset 1 byte tlv offset value
packet type
1 byte Opcode, 0x01 for REQUEST, 0x2 for REP L Y
opcode
1 byte The operation types add/del/modify/get correspond to 0x 1-0 x4 respectively
addr 4 bytes Address of register table entry of forwarding device
data 4 bytes The address corresponds to the content of the table entry
reserved Byte reserved must be 0
end tlv 1 byte Finally tlv
Table 1 shows the ETH message format
In specific implementation, because the preset format is used in the slave control device and the forwarding device, the communication range has locality, so the mac address can be reserved; a fixed vlan may also be used for the vlan.
In specific implementation, in the processing method provided in the embodiment of the present invention, if a response packet fed back by the forwarding device is not received within a preset time, it is determined that the packet interaction is failed; therefore, the slave control device will send the request message which carries the control information for operating and controlling the forwarding device once again so as to further confirm whether the forwarding device is normal; if the response message fed back by the forwarding device can not be received within the preset time, marking 'offline of the forwarding device' error in the slave control device; the network manager confirms the error reason, and after the corresponding reason is solved, the error of 'off-line' of the forwarding device in the slave control device is cleared, and the slave control device can carry out the interactive communication of the next message with the forwarding device. The communication mechanism is a serial communication mechanism, and the slave control device does not send a new request interaction message before the last request interaction message does not receive a response message.
In specific implementation, the preset time is generally in the us level, and the time for normal transmission of the packet is related to the type of the slave control device, the type of the forwarding device, the implementation manner of the device for processing the packet, and the forwarding delay of the second service port, so that the preset time can be configured according to a specific system environment.
In specific implementation, the preset time may be set as: the average time of one message interaction under the condition that the forwarding device and the slave control device work normally is 3 times.
In specific implementation, in the message processing method provided in the embodiment of the present invention, the method further includes: receiving an OAM message transmitted by remote equipment and forwarded by a forwarding device through a first service port; and processing the received OAM message according to a preset rule.
In this way, the slave control device processes the received OAM message sent by the remote device, so the load of the master control device can be further reduced.
In a specific implementation, in the message processing method provided in the embodiment of the present invention, the slave control device may process the received OAM message according to a preset rule in three ways.
The first mode is as follows: and directly processing the OAM message. Therefore, the participation of the master control device is not needed, the OAM message interaction process between the slave control device and the master control device is omitted, the control efficiency can be well improved, the transmission resources are saved, and the burden of the slave control device is increased.
The second way is: preprocessing the OAM message; and sending the preprocessed OAM message to a forwarding device through the first service port so as to send the message to the main control device through the forwarding device, so that the main control device further processes the preprocessed OAM message. Therefore, the OAM message is simply preprocessed and then is further processed by the main control device, so that the burden of the main control device is reduced.
The third mode is that the received OAM message is analyzed, whether the OAM message is a preset message is confirmed according to an analysis result, if so, the OAM message is preprocessed and then sent to a forwarding device through a first service port, so that the OAM message is further processed by a main control device through the forwarding device, and if not, the OAM message is directly processed.
In specific implementation, the processing method provided in the embodiment of the present invention further includes: receiving configuration information of OAM issued by a main control device through a data and control bus; constructing an OAM message according to the received OAM configuration information; and sending the constructed OAM message to a forwarding device through the first service port so as to forward the constructed OAM message to the remote equipment through the forwarding device. That is, the slave control device can construct an OAM message.
Or, in specific implementation, in the processing method provided in the embodiment of the present invention, the processing method further includes: receiving an OAM message transmitted by a main control device and forwarded by a forwarding device through a first service port; and modifying the received OAM message sent by the main control device, and sending the modified OAM message to the forwarding device through the first service port so as to forward the modified OAM message to the remote equipment through the forwarding device. Namely, the construction of the OAM message is executed by the master control device, the slave control device modifies the constructed OAM message, and the forwarding device forwards the OAM message.
Of course, the master control device and the slave control device may cooperate with each other to implement the construction and transmission of various OAM messages. Preferably, the configuration information of the OAM received from the control device is only configuration information required for constructing an OAM message belonging to the preset message; the OAM message forwarded by the master control device to the slave control device through the forwarding device is an OAM message which does not belong to a preset message.
Based on the same inventive concept, for a forwarding device, an embodiment of the present invention further provides a forwarding method for a packet, where the forwarding method is applied to a forwarding device in a packet communication device composed of a master control device, a slave control device, and a forwarding device that are connected to each other, as shown in fig. 4, the forwarding method includes:
s401, receiving a request message which is sent from a control device through a second service port, has a preset format and carries control information for operating and controlling a forwarding device;
s402, analyzing the received request message, and operating the forwarding device according to the analysis result;
and S403, feeding back a response message which has a preset format and carries control response information to the slave control device through the second service port according to the operation result.
In the message forwarding method provided in the embodiment of the present invention, the forwarding device and the slave control device directly perform control message interaction through the service port by using the request/response message with the preset format, and optimize the control communication flow that originally needs to bypass the master control device and then reaches the forwarding device to a direct control communication mode between the slave control device and the forwarding device, that is, a data communication message with a special format is adopted, and a data flow channel between the slave control device and the forwarding device is multiplexed for transmission, so as to realize direct transmission of control information, thereby releasing the control operation capability of the master control device.
In specific implementation, in the forwarding method provided in the embodiment of the present invention, the operation performed on the forwarding device according to the analysis result may be an update control operation on a hardware table entry resource; the forwarding device forwards the service message based on the hardware table resource; of course, other control operations for the forwarding device are also possible, such as reading the statistical values of the messages in the transmission and reception directions counted by the forwarding device.
In a specific implementation, in the forwarding method provided in the embodiment of the present invention, the update control operation on the hardware table entry resource generally includes operations of adding, deleting, modifying, or checking.
In specific implementation, in the forwarding method provided in the embodiment of the present invention, the method further includes:
receiving an OAM message sent by the remote equipment through a third service port;
after the OAM message is identified, the OAM message is sent to the slave control device through the first service port, so that the slave control device processes the OAM message according to a preset rule.
In specific implementation, in the forwarding method provided in the embodiment of the present invention, the method further includes:
receiving an OAM message sent from a control device through a first service port;
after the OAM message is identified, the OAM message is sent to the remote equipment through the third service port; or after the OAM message is identified, the OAM message is sent to the main control device through the fourth service port.
In specific implementation, in the forwarding method provided in the embodiment of the present invention, the method further includes:
receiving a service message through a fifth service port; when determining that the next hop of the received service message is the remote equipment, sending the received service message to the remote equipment through a third service port;
receiving a service message sent by the remote equipment through a third service port; and sending the received service message through a fifth service port.
In specific implementation, in the forwarding method provided in the embodiment of the present invention, the method further includes: and accumulating the message statistic value in the sending direction by 1 every time a message is sent to the remote equipment through the third service port, and accumulating the message statistic value in the local receiving direction by 1 every time a message sent by the remote equipment is received through the third service port.
Certainly, in a specific implementation, in the forwarding method provided in the embodiment of the present invention, every time a service packet or an OAM packet is sent to a remote device through the third service port, the statistical value of the service packet or the OAM packet in the sending direction is accumulated by 1, and every time a service packet or an OAM packet sent by the remote device is received through the third service port, the statistical value of the service packet or the OAM packet in the receiving direction is accumulated by 1.
In the forwarding method provided in the embodiment of the present invention, statistics of the packet can be performed by a method for realizing packet statistics in a hierarchical manner, specifically, as shown in fig. 5, a forwarding device can respectively realize statistics of a receiving direction and a sending direction for an ethernet (eth) layer, a pseudo-wire (pw) layer, a channel (tunnel) layer, and a segment (section) layer, where the ethernet (eth) layer realizes statistics of ethernet packet transmission and reception at a UNI interface, and the pseudo-wire (pw) layer, the channel (tunnel) layer, and the segment (section) layer all realize statistics of packet transmission and reception at a NNI interface, and when a packet is counted, a counter can be added in a packet forwarding flow of the forwarding device, or an AC L method matching attributes of packets at each layer can be used to be hung in the counter.
Based on the same inventive concept, an embodiment of the present invention further provides a slave control device 2, as shown in fig. 6, including: a first interactive message processing module 22; the first interactive packet processing module 22 is configured to:
a request message which is sent to the forwarding device 3 through the second service port2 and has a preset format and carries control information for performing operation control on the forwarding device, so that the forwarding device 3 feeds back a response message which has a preset format and carries control response information after recognizing and analyzing the request message;
if the response message with the preset format fed back by the forwarding device 3 is not received through the second service port2 within the preset time, sending a request message with the preset format and carrying the operation and control information for operating and controlling the forwarding device to the forwarding device 3 through the second service port2 again;
if a response message with a preset format fed back by the forwarding device 3 is received through the second service port2 within a preset time after the request message is sent, control response information is obtained according to the response message.
The slave control device provided by the embodiment of the invention directly performs control message interaction with the forwarding device through the service port by using the request message which has the preset format and carries the control information for operating and controlling the forwarding device, optimizes the control communication process which needs to bypass the master control device and then reaches the forwarding device originally into a direct control communication mode of the slave control device and the forwarding device, namely, adopts a data communication message with a special format, and multiplexes a data flow channel between the slave control device and the forwarding device for transmission so as to realize the direct transmission of the control information, thereby releasing the control operation capability of the master control device.
In specific implementation, as shown in fig. 6, the slave control device provided in the embodiment of the present invention further includes: a processing module 21; wherein the content of the first and second substances,
the processing module 21 is configured to receive, through the first service port1, an OAM message sent by the remote device and forwarded by the forwarding apparatus 3; and processing the received OAM message according to a preset rule.
In a specific implementation, in the slave control apparatus provided in an embodiment of the present invention, the processing module is specifically configured to: directly processing the OAM message; alternatively, the first and second electrodes may be,
preprocessing the OAM message; sending the preprocessed OAM message to a forwarding device through a first service port so as to be sent to a main control device through the forwarding device, and enabling the main control device to further process the preprocessed OAM message; alternatively, the first and second electrodes may be,
analyzing the received OAM message; confirming whether the OAM message is a preset message or not according to the analysis result; if so, sending the preprocessed OAM message to a forwarding device through a first service port, and sending the OAM message to a main control device through the forwarding device, so that the main control device further processes the preprocessed OAM message; and if not, directly processing the OAM message.
In a specific implementation, in the slave control device provided in the embodiment of the present invention, the processing module is further configured to receive configuration information of OAM that is issued by the master control device through the data and control bus;
constructing an OAM message according to the received OAM configuration information; and sending the constructed OAM message to a forwarding device through the first service port so as to forward the constructed OAM message to the remote equipment through the forwarding device.
In a specific implementation, in the slave control device provided in the embodiment of the present invention, the processing module is further configured to receive, through the first service port, an OAM message that is forwarded by the forwarding device and sent by the master control device;
and modifying the received OAM message sent by the main control device, and sending the modified OAM message to the forwarding device through the first service port so as to forward the modified OAM message to the remote equipment through the forwarding device.
In specific implementation, in the slave control device provided in the embodiment of the present invention, the processing module is further configured to process the OAM message according to the control response information obtained by the first interactive message processing module, for example, fill the control response information into the OAM message; or the processing module is further configured to provide the control response information obtained by the first interactive packet processing module to the main control device, which is not limited herein.
Based on the same inventive concept, an embodiment of the present invention further provides a forwarding apparatus 3, as shown in fig. 7 and fig. 8, including: a second interactive message processing module 34; the second interactive packet processing module 34 is configured to:
receiving, through the second service port2, a request packet which is sent from the control device 2 and has a preset format and carries control information for performing operation control on the forwarding device;
analyzing the received request message, and operating the forwarding device according to the analysis result;
and feeding back a response message which has a preset format and carries control response information to the slave control device 2 through the second service port2 according to the operation result.
The forwarding device provided by the embodiment of the invention utilizes the request/response message with the preset format to directly perform control message interaction with the slave control device through the service port, optimizes the control communication flow which needs to bypass the master control device and then reaches the forwarding device to the direct control communication mode of the slave control device and the forwarding device, namely, adopts a data communication message with a special format to multiplex the data flow channel between the slave control device and the forwarding device for transmission so as to realize the direct transmission of control information, thereby releasing the control operation capability of the master control device.
In specific implementation, as shown in fig. 7, the forwarding device provided in the embodiment of the present invention further includes: a first channel 31; wherein the first channel 31 is configured to:
receiving an OAM message sent by a remote device through the third service port3, identifying the OAM message, and sending the OAM message to the slave control device 2 through the first service port1, so that the slave control device 2 processes the OAM message according to a preset rule;
the OAM message sent from the control device 2 is received through the first service port1, and after the OAM message is identified, the OAM message is sent to the remote device through the third service port 3.
In a specific implementation, in the forwarding device provided in the embodiment of the present invention, the first channel may be implemented by using acl and a mirror mechanism or acl and a redirect port mechanism, which is not limited herein.
As shown in fig. 8, the forwarding device provided in the embodiment of the present invention further includes a second channel 32; wherein the second channel 32 is for:
receiving an OAM message sent from the control device 2 through the first service port 1;
after the OAM message is identified, the OAM message is sent to the main control device 1 through the fourth service port 4.
In specific implementation, as shown in fig. 7 and 8, the forwarding device provided in the embodiment of the present invention further includes: a third channel 33; wherein the third channel 33 is for:
receiving a service message through a fifth service port 5; when determining that the next hop of the received service message is a remote device, sending the received service message to the remote device through a third service port 3;
receiving a service message sent by a remote device through a third service port 3; and sending out the received service message through a fifth service port 5.
In specific implementation, the forwarding device provided in the embodiment of the present invention further includes a statistics module; wherein the statistics module is to:
when the third service port sends a message to the remote device, the statistical value of the message in the sending direction of the forwarding device is accumulated by 1, and when the third service port receives a message sent by the remote device, the statistical value of the message in the receiving direction of the forwarding device is accumulated by 1.
In a specific implementation, in the forwarding device provided in the embodiment of the present invention, the first channel, the second channel, and the third channel all provide the message received from one service port to another service port as it is.
Based on the same inventive concept, the embodiment of the invention also provides message communication equipment, which comprises a master control device, a slave control device and a forwarding device;
the slave control device is used for sending a request message which has a preset format and carries control information for operating and controlling the forwarding device to the forwarding device through the second service port, so that the forwarding device feeds back a response message carrying control response information after identifying and analyzing the request message; if the response message with the preset format fed back by the forwarding device is not received through the second service port within the preset time, sending a request message with the preset format and carrying control information for operating and controlling the forwarding device to the forwarding device through the second service port again; if a response message with the preset format fed back by a forwarding device is received through the second service port within a preset time after the request message is sent, acquiring the control response information according to the response message;
the forwarding device is used for receiving a request message which is sent from the control device through the second service port, has a preset format and carries control information for operating and controlling the forwarding device; analyzing the received request message, and operating the forwarding device according to the analysis result; and feeding back a response message which has the preset format and carries control response information to the slave control device through the second service port according to an operation result.
In the message communication device provided in the embodiment of the present invention, the slave control device directly performs control message interaction with the forwarding device through the service port by using the request message having the preset format and carrying the operation and control information for operating and controlling the forwarding device, and optimizes the control communication flow that originally needs to bypass the master control device and then reach the forwarding device into a direct control communication mode between the slave control device and the forwarding device, that is, a data communication message having a special format is used, and a data flow channel between the slave control device and the forwarding device is multiplexed for transmission, so as to realize direct transmission of control information, thereby releasing the control operation capability of the master control device.
In specific implementation, the further functions of the forwarding device and the slave control device in the message communication device provided in the embodiment of the present invention may refer to the implementation of the forwarding device and the slave control device provided in the embodiment of the present invention, and are not described herein again.
In a specific implementation, in the message communication device provided in the embodiment of the present invention, the master control device and the slave control device are connected via a data and control bus.
The following describes a working process of the message communication device according to the embodiment of the present invention to implement an OAM function.
The first embodiment,
And the first interactive message processing module in the slave control device and the second interactive message processing module in the forwarding device interact by adopting a message in a preset format through the second service port. In specific implementation, a request message with a preset format and carrying control information for operating and controlling the forwarding device is sent from a first interactive message processing module of the control device to a second interactive message processing module of the forwarding device through a second service port; the second interactive message processing module analyzes the received request message carrying the control information for operating and controlling the forwarding device, operates the forwarding device according to the analysis result, and feeds back a response message which has a preset format and carries control response information to the first interactive message processing module through the second service port according to the operation result; and if the first interactive message processing module receives the response message within the preset time, acquiring control response information according to the response message. And if the first interactive message processing module does not receive the response message within the preset time, sending a request message which has a preset format and carries control information for operating and controlling the forwarding device through the second service port again. If the second interactive message processing module still does not receive the response message within the preset time, the slave control device marks an error of 'off-line of the forwarding device'. Specifically, the flow of the interactive message communication between the slave control device and the forwarding device is shown in fig. 13.
In the first embodiment, the slave control device and the forwarding device directly perform control packet interaction through the second service port. The control communication flow which needs to bypass the main control device and then reaches the forwarding device is optimized to be a direct control communication mode of the slave control device and the forwarding device, so that the control computing capability of the main control device can be released.
Example II,
As shown in fig. 9 and fig. 11, the forwarding device 3 implements forwarding of the service packet; the slave control device 2 realizes the receiving and sending of the OAM message, and realizes the interaction of the OAM message with the remote device through the first channel 31 of the forwarding device 3.
In specific implementation, the first channel 31 of the forwarding device 3 recognizes the OAM message received from the third service port3, forwards the OAM message to the first service port1 as it is, and sends the OAM message to the slave control device 2 through the first service port 1; the OAM message sent from the control device 2 is sent to the forwarding device 3 through the first service port1, and the first channel 31 of the forwarding device 3 recognizes the OAM message received from the first service port1 and sends it to the remote device through the third service port3 as it is.
The configuration information of OAM is sent to the slave control device 2 by the master control device 1 through a data and control bus, and the slave control device 2 constructs an OAM message according to the received configuration information of OAM; the slave control device 2 reports the OAM related alarm to the control device 1 via the data and control bus.
Example III,
As shown in fig. 10 and 12, specifically, in the process of transmitting and receiving an OAM message, the master control device 1 performs construction of the OAM message. The second channel 32 of the forwarding device 3 is used for transparently transmitting OAM messages in an internal format between the master control device 1 and the slave control device 2. After receiving the OAM message sent from the remote device by the first channel 31 of the forwarding device 3 through the first service port1, the slave control device 2 preprocesses the OAM message and sends it to the forwarding device 3 through the first service port1, the second channel 32 of the forwarding device 3 recognizes it and sends it to the master control device 1 through the fourth service port4, and the master control device 1 further processes the preprocessed OAM message.
In the third embodiment, the slave control device performs preprocessing on the OAM message first, and then the master control device performs further processing, thereby reducing the load of the master control device.
In specific implementation, the slave control device may perform preprocessing on the OAM message first by filling the obtained message statistics into the OAM message.
The master control means 1 and the slave control means 2 are connected by a data and control bus for further communication.
Example four,
As shown in fig. 10 and fig. 12, after receiving the OAM message sent by the first channel 31 of the forwarding device 3 through the first service port1, the control device 2 parses the OAM message to identify whether the OAM message is a preset message; if so, the OAM message is preprocessed and then sent to the forwarding device 3 through the first service port1, the second channel 32 of the forwarding device 3 identifies the OAM message and then sends the OAM message to the main control device 1 through the fourth service port4, and the main control device 1 further processes the preprocessed OAM message; if not, the slave control device 2 directly processes the OAM message.
That is, in the fourth embodiment, the preset message is processed by the method of the third embodiment, and the non-preset message is processed by the method of the second embodiment.
In specific implementation, the preset messages may be designed according to the difficulty level of the OAM messages, for example, the preset messages may be L M protocol messages, signal degradation messages, DM protocol messages, jitter messages, and the like, which are more complex OAM messages, and the slave control devices perform preprocessing and then perform further processing by the master control device, but CCM protocol messages, L B protocol messages, L T protocol messages, AIS protocol messages, L CK protocol messages, and the like in the OAM messages are all simple OAM messages, so that the slave control devices directly process the OAM messages, thereby reducing the burden of the master control device, and not greatly increasing the burden of the slave control devices, so that the processing capability of the slave control devices is not strictly limited, and thus reasonable configuration and efficient management and control of resources are achieved.
In specific implementation, the communication device provided by the embodiment of the present invention may be used to measure a packet loss rate, where the communication device and the remote device may perform Message interaction based on any one, two, or more of an ethernet (eth) layer, a pseudo-wire (pw) layer, a channel (tunnel) layer, and a segment (section) layer as a local device and a remote device, where the local device and the remote device may be regarded as one forwarding entity based on a Message interaction channel of each layer, and L M messages may be associated with at least one of four forwarding entities corresponding to the four layers.
The method comprises the steps of receiving a CCM message sent by a local terminal device, transmitting the CCM message to a forwarding device through a first service port, transmitting the CCM message to a CCM forwarding device through a second service port, transmitting the CCM message to the forwarding device through the first service port, transmitting the CCM message received by the first service port and transmitted by the second service port to a third service port connected with a remote device through the first service port by a first channel of the forwarding device, transmitting the CCM message received by the first service port to the CCM forwarding device through the third service port connected with the remote device, transmitting the CCM message to the remote device through the third service port, transmitting the CCM message to the CCM forwarding device through the fifth service port, transmitting the CCM message received by the third service port in a real-time receiving communication network except the remote device to the service port connected with the L M forwarding device in the forwarding device of the local terminal device, determining that the CCM receiving device receives the CCM message and transmits the CCM message to the third service port through a CCM forwarding device, transmitting the CCM message to the third service port, transmitting the CCM forwarding device, determining that the CCM receiving device is a third service port, transmitting the CCM receiving device, transmitting the third message, transmitting the CCM message, transmitting the third message, transmitting the CCM receiving device, transmitting the third message to the third service port, transmitting the third service port, and transmitting the CCM receiving device, and transmitting the third service port, wherein the CCM receiving device, the third service port is a third service port, and transmitting the third service port, the CCM receiving device, and transmitting the third service port, and transmitting the CCM receiving device, and transmitting the third service port, and.
Correspondingly, the remote device receives the CCM message and the service message sent by the local device, and updates the statistical value of the received CCM message and the service message sent by the local device in real time.
On the other hand, the remote device may also actively construct a CCM message of the forwarding entity associated with L M and send the CCM message to the local device, forward a service message of the forwarding entity associated with L M that the next-hop receiving device is the local device and sent by another device except the local device to the local device, and update the CCM message and the statistical value of the service message sent to the local device in real time.
In specific implementation, the slave control device respectively counts CCM messages of L M-associated forwarding entities in the sending and receiving directions, obtains statistical values of service messages of L M-associated forwarding entities in the forwarding device in the sending and receiving directions through the first interactive message processing module, and sums the statistical values to obtain a counting source for calculating the sending and receiving directions of the packet loss rate.
In one embodiment, L MM message sent from control device is filled with message statistics value of current sending direction of forwarding device (the message statistics value is sum of CCM message and service message of forwarding entity associated with L M), and then sent to third service port through first channel of forwarding device, after receiving L MM message sent by remote device transferred from control device, based on L MM message, L MR message is constructed, and after filling message statistics value of current receiving direction and message statistics value of sending direction of forwarding device in constructed L MR message (wherein, after filling message statistics value of current receiving direction and message statistics value of sending direction of forwarding device are obtained by first interactive message processing module to forwarding device), the message statistics value of current receiving direction of forwarding device is sent to third service port through first channel of forwarding device, remote device transferred from control device obtains message statistics value of current receiving direction, and sends back message statistics value of L MR message returned by local device to third service port, and obtains message statistics value of packet loss and packet loss carried by remote device, thereby, when message statistics value of remote device transferred from control device receives packet loss and sends packet loss, it to control device, thus, it can obtain statistics value of packet loss and packet loss carried by remote device, thus, it can obtain packet loss control packet loss calculation value of packet loss control device for sending device, and packet loss control device, and packet loss control device, thus, and packet loss control device.
In another embodiment, the master control device may be responsible for transmitting and receiving L MM messages or L MR messages and calculating the number of lost packets, the slave control device only fills the statistical value in L MM messages or L MR messages, and the second channel in the forwarding device is used for transmitting L MM messages or L MR message information in an internal format between the master control device and the slave control device.
Specifically, in the sending direction, after receiving a L MM message or L MR message sent by the master control device from the control device, the slave control device obtains a message statistic of the current forwarding device sending direction from the forwarding device through the first interactive message processing module, fills the obtained message statistic into a L MM message or L MR message and converts the message statistic into an internal format identified by a first channel of the forwarding device, and then sends the message to the remote device through the first channel of the forwarding device.
In this embodiment, after receiving a L MR message returned by a remote device for a L MM message and obtaining a message statistic value in a current forwarding device receiving direction, the slave control device does not adopt any of (1) reporting the L MR message and the obtained message statistic value in the current forwarding device receiving direction to the master control device through different transmission modes (i.e., L1 MR message is reported to the master control device through a second channel of the forwarding device, and the obtained message statistic value in the current forwarding device receiving direction is reported to the master control device through data and a control bus), (2) after receiving a L MR message carrying 3 statistic values, the slave control device actively accesses the slave control device through the data and the control bus to obtain a 4 th statistic value (i.e., the message statistic value in the current forwarding device receiving direction), but modifies the existing L MR message (as shown in tables 2 and 3, wherein MR 2 is a L message before modification, table 3 is a message in a filling state of the obtained message receiving direction, and then the message is transmitted to the master control device based on MR loss rate measurement results of the calculation of the MR loss rate, and the MR loss rate measurement results of the MR loss rate measurement of the MR report results of the loss of all the MR report loss, and the results of all the results of the MR loss rate measurement of the MR report results of all the MR loss are improved by using MR report of MR report methods including that the MR format including that when the MR format including the number of MR format including the number.
Figure BDA0001197406840000261
Table 2 shows L MR message format before modification
Figure BDA0001197406840000262
Table 3 shows the L MR message format after filling the obtained message statistics of the current forwarding device receiving direction
In specific implementation, the forwarding device can directly count the number of the receiving and sending directions of the service message and the CCM message, and does not need to add the number of the receiving and sending directions of the service message and the number of the CCM message on the control device 2.
Therefore, based on the same inventive concept, an embodiment of the present invention further provides a method for measuring a packet loss rate of a packet communication device, as shown in fig. 14, where the method includes the following steps S141 to S149.
S141, the master control device in the message communication equipment sends the constructed L MM message to the slave control device in the message communication equipment through the forwarding device in the message communication equipment;
in specific implementation, the master control device sends the constructed L MM message to the forwarding device through the fourth service port, and the second channel of the forwarding device sends the constructed L MM message to the slave control device through the first service port.
S142, after receiving the L MM message from the control device, sending a first request message with a preset format to the forwarding device;
in specific implementation, a first request message with a preset format is sent from a first interactive message processing module of the control device to a second interactive message processing module of the forwarding device through a second service port.
S143, after receiving the first request message, the forwarding device feeds back a first response message which has a preset format and carries the message statistic value c1 of the current forwarding device sending direction to the slave control device according to the first request message;
in specific implementation, after receiving the first request message, the second interactive message processing module of the forwarding device feeds back a first response message to the slave control device through the second service port.
S144, the slave control device fills c1 carried by the first response message into a L MM message and then sends the message to the remote equipment through the forwarding device;
in specific implementation, the L MM packet filled with c1 is sent from the control device to the forwarding device through the first service port, and is sent to the third service port through the first channel, and is sent to the remote device through the third service port.
S145, receiving a L MR message fed back by the remote equipment through the forwarding device based on the L MM message from the control device, wherein the L MR message carries c1, a message statistic c2 of the receiving direction of the remote equipment when the remote equipment sends L MR message, and a message statistic c3 of the sending direction of the remote equipment;
in specific implementation, the forwarding device receives, through the third service port, a L MR packet fed back by the remote device based on the L MM packet, and sends the L MR packet to the first service port through the first channel, and receives, from the control device, the L MR packet through the first service port.
S146, after receiving L MR message from the control device, sending a second request message with a preset format to the forwarding device;
in specific implementation, the first interactive message processing module of the control device sends a second request message with a preset format to a second interactive message processing module of the forwarding device through the second service port.
S147, after the forwarding device receives the second request message, feeding back a second response message which has a preset format and carries the message statistic value c4 of the current forwarding device receiving direction to the slave control device according to the second request message;
in specific implementation, after receiving the first request message, the second interactive message processing module of the forwarding device feeds back a second response message to the slave control device through the second service port.
S148, the slave control device fills the c4 carried by the second response message into the L MR message and then sends the MR message to the master control device through the forwarding device;
in specific implementation, the slave control device sends the L MR message filled with c4 to the forwarding device through the first service port, and sends the message to the fourth service port through the second channel, and sends the message to the master control device through the fourth service port.
And S149, the main control device calculates the packet loss rate according to the c1, c2, c3 and c4 in the received L MR message.
In specific implementation, after receiving a L MR message sent by a slave control device through a forwarding device, a master control device extracts c1, c2, c3, and c4 carried in the message, and stores the extracted message to perform local frame loss calculation and remote frame loss calculation according to the extracted message, for example, the local device interacts with an nth L M message of a remote device, 4 statistics obtained by the master control device on the local device are c1n, c2n, c3n, and c4n, the n-1 st L M message interacts, 4 statistics obtained by the master control device on the local device are c1n-1, c2n-1, c3n-1, and c4n-1, and a remote packet loss | c1n-c 1-1 | - | c2n-c2n-1|, a local packet loss | c 3-n-c 3 | -n | -c-3 | -599 | c 639 | c 9 | -9 | c 3-c 639 | c 9 | c3 | c 9 | -c3 | -c 9 | -c.
Certainly, in specific implementation, not only may the local device actively construct L MM packets and the remote device replies L MR packets to perform packet loss rate measurement, but also the remote device may actively construct L MM packets and the local device replies L MR packets to perform packet loss rate measurement, as follows.
Based on the same inventive concept, an embodiment of the present invention further provides a method for measuring a packet loss rate of a packet communication device, as shown in fig. 15, where the method includes the following steps S151 to S158:
s151, a forwarding device in the message communication equipment sends a received L MM message sent by the remote equipment to a slave control device in the message communication equipment, wherein the L MM message carries a message statistic d1 of the sending direction of the remote equipment when the remote equipment sends a L MM message;
in specific implementation, the forwarding device receives the L MM packet sent by the remote device through the third service port, and sends the L MM packet to the first service port through the first channel, and receives the L MM packet from the control device through the first service port.
S152, after receiving L MM message from the control device, sending a first request message with a preset format to the forwarding device;
in specific implementation, a first request message with a preset format is sent from a first interactive message processing module of the control device to a second interactive message processing module of the forwarding device through a second service port.
S153, after receiving the first request message, the forwarding device feeds back a first response message which has a preset format and carries the message statistic d2 of the current receiving direction of the forwarding device to the slave control device according to the first request message;
in specific implementation, after receiving the first request message, the second interactive message processing module of the forwarding device feeds back a first response message to the slave control device through the second service port.
S154, the slave control device fills the d2 carried by the first response message into the L MM message and then sends the message to the master control device in the message communication equipment through the forwarding device;
in specific implementation, the slave control device sends the L MM packet filled with d1 to the forwarding device through the first service port, and sends the packet to the fourth service port through the second channel, and sends the packet to the master control device through the fourth service port.
S155, after receiving the L MM message sent by the slave control device through the forwarding device, the master control device acquires a message statistic d3 of the current sending direction of the forwarding device;
s156, constructing a L MR message by the master control device according to the d3 and the received L MM message, wherein the L MR message carries d1, d2 and d 3;
s157, the master control device sends L MR messages to the slave control device through the forwarding device;
in specific implementation, the master control device sends the L MR message to the forwarding device through the fourth service port, and the second channel of the forwarding device sends the message to the slave control device through the first service port.
And S158, the slave control device sends the L MR message to the remote equipment through the forwarding device, so that the remote equipment calculates the packet loss rate according to d1, d2 and d3 carried in the L MR message and the message statistic value d4 of the receiving direction of the remote equipment when the remote equipment receives L MR message.
In specific implementation, the slave control device sends L an MR message to the forwarding device through the first service port, and sends the MR message to the third service port through the first channel, and sends the MR message to the remote device through the third service port.
In the method for processing a packet, the forwarding method, the related device and the method for measuring a packet loss ratio provided by the embodiments of the present invention, the slave control device directly performs control packet interaction with the forwarding device through the service port by using a request packet having a preset format and carrying control information for performing operation control on the forwarding device, and optimizes a control communication flow that originally needs to bypass the master control device and then reaches the forwarding device to a direct control communication manner of the slave control device and the forwarding device, that is, a data communication packet having a special format is used, and a data flow channel between the slave control device and the forwarding device is multiplexed for transmission, so as to realize direct transmission of control information, thereby releasing the control operation capability of the master control device.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (2)

1. A packet loss rate measuring method of a message communication device, the message communication device includes a master control device, a slave control device and a forwarding device, and the packet loss rate measuring method includes:
the master control device in the message communication equipment sends the constructed packet loss measurement information (L MM) message to the slave control device in the message communication equipment through the forwarding device in the message communication equipment;
after receiving the L MM message, the slave control device sends a first request message with a preset format to the forwarding device;
after receiving the first request message, the forwarding device feeds back a first response message which has the preset format and carries a message statistic value c1 of the current sending direction of the forwarding device to the slave control device according to the first request message;
the slave control device fills c1 carried by the first response message into the L MM message and then sends the message to the remote device through the forwarding device;
the slave control device receives a packet loss reply information (L MR) message fed back by the remote device based on an L MM message through the forwarding device, wherein the L MR message carries c1, a message statistic c2 of a receiving direction of the remote device and a message statistic c3 of a sending direction of the remote device when the remote device sends the L MR message;
after receiving the L MR message, the slave control device sends a second request message with a preset format to the forwarding device;
after receiving the second request message, the forwarding device feeds back a second response message which has a preset format and carries the message statistic value c4 of the current receiving direction of the forwarding device to the slave control device according to the second request message;
the slave control device fills c4 carried by the second response message into the L MR message and then sends the message to the master control device through the forwarding device;
and the main control device calculates the packet loss rate according to the c1, c2, c3 and c4 in the received L MR message.
2. A packet loss rate measuring method of a message communication device, the message communication device includes a master control device, a slave control device and a forwarding device, and the packet loss rate measuring method includes:
a forwarding device in the message communication equipment sends a received packet loss measurement information (L MM) message sent by the remote equipment to a slave control device in the message communication equipment, wherein the L MM message carries a message statistic d1 of the sending direction of the remote equipment when the remote equipment sends the L MM message;
after receiving the L MM message, the slave control device sends a first request message with a preset format to the forwarding device;
after receiving the first request message, the forwarding device feeds back a first response message which has the preset format and carries the message statistic d2 of the current receiving direction of the forwarding device to the slave control device according to the first request message;
the slave control device fills d2 carried by the first response message into the L MM message and then sends the message to a master control device in the message communication equipment through the forwarding device;
after the master control device receives the L MM message sent by the slave control device through the forwarding device, the master control device obtains a message statistic d3 of the current sending direction of the forwarding device;
the main control device constructs a packet loss reply information (L MR) message according to the d3 and the received L MM message, wherein the L MR message carries d1, d2 and d 3;
the master control device sends the L MR message to the slave control device through the forwarding device;
the slave control device sends the L MR message to the remote device through the forwarding device, so that the remote device performs packet loss rate calculation according to d1, d2 and d3 carried in the L MR message, and a message statistic d4 of the remote device receiving direction when the remote device receives the L MR message.
CN201611247419.2A 2016-12-29 2016-12-29 Message processing method, forwarding method, related device and packet loss rate measuring method Active CN106789437B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611247419.2A CN106789437B (en) 2016-12-29 2016-12-29 Message processing method, forwarding method, related device and packet loss rate measuring method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611247419.2A CN106789437B (en) 2016-12-29 2016-12-29 Message processing method, forwarding method, related device and packet loss rate measuring method

Publications (2)

Publication Number Publication Date
CN106789437A CN106789437A (en) 2017-05-31
CN106789437B true CN106789437B (en) 2020-07-28

Family

ID=58929236

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611247419.2A Active CN106789437B (en) 2016-12-29 2016-12-29 Message processing method, forwarding method, related device and packet loss rate measuring method

Country Status (1)

Country Link
CN (1) CN106789437B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110545196A (en) * 2018-05-28 2019-12-06 华为技术有限公司 data transmission method and related network equipment
CN111371736B (en) * 2018-12-26 2022-12-06 中兴通讯股份有限公司 iOAM information processing method, iOAM information processing device and computer readable storage medium
CN109981414B (en) * 2019-03-29 2021-08-24 烽火通信科技股份有限公司 method for acquiring packet loss number between mpls network nodes
CN114567574B (en) * 2022-03-01 2023-11-10 烽火通信科技股份有限公司 Method and device for realizing LM flow-free test based on time sequence control

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104348678A (en) * 2013-08-05 2015-02-11 华为技术有限公司 Method, device and system for measuring performance of Ethernet
CN106034045A (en) * 2015-03-20 2016-10-19 中兴通讯股份有限公司 Ethernet link failure positioning method, device and system
WO2016177120A1 (en) * 2015-07-27 2016-11-10 中兴通讯股份有限公司 Measurement method and system for packet loss of link packet, target node and initiating-end node

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105515809A (en) * 2014-09-28 2016-04-20 中兴通讯股份有限公司 Software definition network realization method and main controller

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104348678A (en) * 2013-08-05 2015-02-11 华为技术有限公司 Method, device and system for measuring performance of Ethernet
CN106034045A (en) * 2015-03-20 2016-10-19 中兴通讯股份有限公司 Ethernet link failure positioning method, device and system
WO2016177120A1 (en) * 2015-07-27 2016-11-10 中兴通讯股份有限公司 Measurement method and system for packet loss of link packet, target node and initiating-end node

Also Published As

Publication number Publication date
CN106789437A (en) 2017-05-31

Similar Documents

Publication Publication Date Title
CN106789437B (en) Message processing method, forwarding method, related device and packet loss rate measuring method
CN112866075B (en) In-band network telemetering method, system and related device for Overlay network
US8774056B2 (en) Automated device discovery on a network
CN106936661B (en) Network monitoring method, device and system
EP3958521A1 (en) Method and apparatus for providing service for service flow
JP5462954B2 (en) Packet loss detection method and apparatus, and router
EP3817298A1 (en) Data message detection method, device and system
CN104243268B (en) Association method and device between virtual extensible local area networks (VXLAN) and tunnel
WO2022104869A1 (en) Chip-level encryption-based ethernet and field bus fusion gateway and transmission method
US20220078106A1 (en) Packet Measurement Method, Device, and System
EP4207647A1 (en) Method for detecting multicast service flow and related apparatus
US20150036510A1 (en) Method and device for measuring ethernet performance
CN103067278B (en) A kind of method for transmission processing of Frame, equipment and system
US9596167B1 (en) Internet protocol virtual private network service performance monitoring
CN109428782B (en) Network monitoring method and equipment
CN105591834A (en) Traffic monitoring method and device in VXLAN
CN107995130A (en) A kind of fast shifting method of fragment message
EP1944918A1 (en) A method and system for realizing the consistency of the virtual circuit status
CN102916883B (en) LINK detection method and routing forwarding equipment
WO2015196636A1 (en) Packet collection method and system, network device and network management centre
EP3379781A1 (en) Method for counting bgp community attribute or extended community attribute flow value, and device
CN113055293A (en) Routing method and device in software defined wide area network and communication system
KR20230017324A (en) BIER multicast traffic statistics collection method, device and system
CN102752169B (en) Transmitting, monitoring method and device
CN100496024C (en) A method to forward the channel message and a network device

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: 100094 First to Fifth Floors of Building 11, East Yard, No. 10 Wangdong Road, Northwest Haidian District, Beijing

Applicant after: Raisecom Technology Inc.

Address before: 100085 No. 2 Building, No. 28 Shangdi Sixth Street, Haidian District, Beijing

Applicant before: Raisecom Technology Inc.

GR01 Patent grant
GR01 Patent grant