Background
In a transformer substation network, a process layer network realizes communication between a process layer and a bay layer through object-oriented substation event (GOOSE) messages and Sampling Value (SV) messages, the GOOSE messages and the SV messages are transmitted in a multicast mode, if filtering is not performed, multicast data messages of process layer equipment are transmitted to all bay layer equipment, and the bay layer equipment receives a large amount of messages irrelevant to the equipment.
Referring to fig. 1, fig. 1 is a schematic diagram of a networking of a typical substation network in the prior art, where process layer devices and bay level devices are connected through a switch, the process layer devices include conventional switch devices, intelligent unit/merging unit (CT/PT) devices, and the bay level devices include bay level processing devices: the system comprises line measurement and control equipment, line protection equipment and bus protection equipment, wherein the conventional switch equipment corresponds to the line measurement and control equipment one to one, and the CT/PT equipment corresponds to the line protection equipment one to one.
In practical application, the multicast data packets (GOOSE packets and SV packets) of the conventional switch device only need to be sent to the line measurement and control device and the bus protection device corresponding to the conventional switch, the multicast data packets (GOOSE packets and SV packets) of the CT/PT device only need to be sent to the line protection device and the bus protection device corresponding to the CT/PT device, for example, in fig. 1, the multicast data packets of the conventional switch 1 only need to be sent to the line measurement and control device 1 and the bus protection device, and the multicast data packets of the CT/PT device 1 only need to be sent to the line protection device 1 and the bus protection device. However, if the multicast data packets are not filtered, the multicast data packets sent by each process layer device in fig. 1 are transmitted to all the bay layer devices, so that the bay layer devices receive many multicast data packets that are not required to be received.
At present, aiming at a transformer substation network, there are two schemes for realizing multicast message filtering, one is to divide the network into a plurality of broadcast domains by using a VLAN, and multicast data messages are limited to be transmitted in one broadcast domain; the other method is to use GARP Multicast Registration Protocol (GMRP) to realize the multicast data message filtering.
GMRP is an application of Generic Attribute Registration Protocol (GARP), mainly provides a limited multicast diffusion function similar to IGMP probing technology, belongs to a two-layer multicast protocol, and is more suitable for filtering GOOSE messages and SV messages. In a network supporting GMRP, when a network terminal device needs to receive a multicast data stream, a GMRPjoin message needs to be sent, and a switch receiving the GMRPjoin message will add a port receiving the GMRPjoin message to a multicast group corresponding to the GMRPjoin message (i.e., a multicast group to which the GMRPjoin message requests to be added). When the network terminal equipment does not need to receive the multicast data stream, the GMRPleave message needs to be sent, and the switch receiving the GMRPleave message deletes the port receiving the GMRPleave message from the multicast group corresponding to the GMRPjoin message.
When GMRP is used for realizing multicast message filtering in a transformer substation network, process layer equipment, spacer layer equipment and a switch for connecting the process layer equipment and the spacer layer equipment all need to support the GMRP and start the GMRP function, and spacer layer processing equipment joins and leaves a certain multicast group by sending MGRPjoin messages and MGRPleave messages.
In the existing implementation, the line measurement and control device and the line protection device in the bay layer only need to receive the multicast data messages of the corresponding process layer devices, and the bus protection device in the bay layer needs to receive the multicast data messages sent by all the process layer devices. At present, two methods are available to ensure that a bus control device can receive all multicast data packets sent by a process layer device, the first method is that a bus protection device sends MGRPjoin packets for all multicast groups, and the second method is that a static GMRP group is configured on all switches connecting the process layer device and a bay layer device. When the first method is adopted, a large amount of configuration work needs to be carried out on the bus protection equipment, and the on-site bus protection equipment does not support the function generally; when the second method is adopted, complex configuration needs to be performed on each switch, errors are easy to occur, and when the device is replaced to cause the change of the multicast destination MAC address, the overall configuration is very complicated.
Disclosure of Invention
In view of this, the present invention provides a method for filtering multicast data packets in a substation network, which can reduce configuration complexity.
In order to achieve the purpose, the technical scheme provided by the invention is as follows:
a method for filtering multicast data messages in a transformer substation network comprises a plurality of process layer devices belonging to a process layer and a plurality of bay layer devices belonging to a bay layer, wherein the bay layer devices comprise bay layer processing devices and bus protection devices; the process layer equipment is connected with the interval layer equipment through a switch; the process layer equipment, the spacer layer equipment and the switch all start GMRP functions; the method comprises the following steps:
setting ports connected with other switches on the current switch as cascade ports, and if the current switch is directly connected with the bus protection equipment, setting the ports connected with the bus equipment of the current switch as monitoring ports;
when the current switch receives a GMRPjoin message sent by the interval layer processing equipment, adding a port for receiving the GMRPjoin message and a cascade port of the current switch into a multicast group corresponding to the GMRPjoin message, and if the current switch is provided with an interception port, adding the interception port into the multicast group corresponding to the GMRPjoin message; broadcasting and sending a GMRPjoin message;
when the current switch receives the multicast data message sent by the process layer equipment, the multicast group to which the multicast data message belongs is determined, and the multicast data message is forwarded from all ports added to the multicast group.
A filtering device for multicast data messages in a transformer substation network comprises a plurality of process layer devices belonging to a process layer and a plurality of bay layer devices belonging to a bay layer, wherein the bay layer devices comprise bay layer processing devices and bus protection devices; the process layer equipment is connected with the interval layer equipment through the switch; the GMRP function is all opened to process layer equipment, wall layer equipment and switch, and the device is applied to the switch of connecting process layer equipment and wall layer equipment, includes: the device comprises a configuration unit, a receiving unit, a processing unit and a sending unit;
the configuration unit is used for setting a port of the switch where the device is located, which is connected with other switches, as a cascade port, and if the switch where the device is located is directly connected with the bus protection equipment, setting the port of the switch where the device is located, which is connected with the bus equipment, as an interception port;
the receiving unit is used for receiving the GMRPjoin message sent by the spacer layer processing equipment; the device is used for receiving the multicast data message sent by the process layer device;
the processing unit is used for adding a port for receiving the GMRPjoin message and a cascade port of an exchanger where the device is located into a multicast group corresponding to the GMRPjoin message when the receiving unit receives the GMRPjoin message sent by the spacer layer processing equipment, and adding an interception port into the multicast group corresponding to the GMRPjoin message if the exchanger where the device is located is provided with the interception port; the multicast group determining unit is used for determining a multicast group to which the multicast data message belongs when the receiving unit receives the multicast data message sent by the process layer equipment;
the transmitting unit is used for broadcasting and transmitting the GMRPjoin message after the receiving unit receives the GMRPjoin message transmitted by the spacer layer processing equipment; and the processing unit is used for forwarding the multicast data message from all ports added into the multicast group after the processing unit determines that the receiving unit receives the multicast group to which the multicast data message sent by the process layer equipment belongs.
In summary, the ports between the switches are set as the cascade ports, and when the switches are directly connected with the bus protection device, the ports connected with the bus protection device on the switches are set as the interception ports; and the cascade port and the interception port allow all multicast data messages to pass through by improving the GMRP, thereby ensuring that all multicast data messages can finally reach the bus protection equipment through the cascade port and the interception port. The invention can enable the bus protection equipment to receive all multicast data messages only by configuring the superior connection port and/or the interception port of the switch and utilizing the improved GMRP, and the configuration is simpler.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the embodiments of the present invention will be described in detail with reference to the accompanying drawings.
In the invention, based on the requirement that bus protection equipment in a spacer layer of a transformer substation network receives all multicast data messages sent by process layer equipment, two ports allowing all multicast data messages to pass are defined: the method comprises the steps of monitoring ports and cascade ports, configuring the cascade ports and the monitoring ports on a switch and improving MGRP, so that all multicast data messages can be transmitted to bus protection equipment through the cascade ports and the monitoring ports.
In the invention, process layer equipment, bay level equipment and a switch for connecting the process layer equipment and the bay level equipment in the transformer substation network all need to support and start the MGRP function.
Referring to fig. 2, fig. 2 is a schematic flow chart of a method for filtering multicast data packets in a substation network according to an embodiment of the present invention, where the substation network includes a plurality of process layer devices belonging to a process layer and a plurality of bay layer devices belonging to a bay layer, where the bay layer devices include bay layer processing devices and bus bar protection devices; the process layer equipment is connected with the interval layer equipment through a switch; as shown in fig. 2, the method mainly includes the following steps:
step 201, setting the ports of the current switch connected with other switches as cascade ports, and if the current switch is directly connected with the bus protection device, setting the port of the current switch connected with the bus device as an interception port.
In this embodiment, a direct connection port between switches needs to be configured as a cascade port, and for a switch directly connected to a bus protection device in an interlayer, a port connected to the bus protection device on the switch needs to be configured as an interception port.
The interception port and the cascade port need to allow all multicast data messages to pass through, including known multicast data messages and unknown multicast data messages.
Step 202, when the current switch receives a GMRPjoin message sent by the bay level processing device, adding a port for receiving the GMRPjoin message and a cascade port of the current switch to a multicast group corresponding to the GMRPjoin message, and if the current switch is provided with an interception port, adding the interception port to the multicast group corresponding to the GMRPjoin message; and broadcasting and sending the GMRPjoin message.
In this embodiment, the bay level processing equipment includes line measurement and control equipment and line protection equipment.
In this step, when the switch receives the GMRPjoin message, the port that receives the GMRPjoin message needs to be added to the multicast group corresponding to the GMRPjoin message, so that when the switch receives the multicast data message belonging to the multicast group corresponding to the GMRPjoin message, the multicast data message can be sent out from the port that receives the GMRPjoin message. In addition, if the switch is provided with a cascade port, the cascade port of the switch is also required to be added into the multicast group corresponding to the GMRPjoin message, so that the cascade port in the switch allows the multicast data message belonging to the multicast group to pass through; if the switch is provided with the interception port, the interception port of the switch is also required to be added into the multicast group corresponding to the GMRPjoin message, so that the interception port in the switch allows the multicast data message belonging to the multicast group to pass through.
Step 203, when the current switch receives the multicast data packet sent by the process layer device, determining the multicast group to which the multicast data packet belongs, and forwarding the multicast data packet from all ports added to the multicast group.
Here, the multicast data packet received by the current switch is divided into two cases: one is a known multicast data packet and the other is an unknown multicast data packet.
For a known multicast data packet, the current switch needs to determine the multicast group to which the known multicast data packet belongs, and send the known multicast data packet out from all ports added to the multicast group. When receiving a GMRPjoin message requesting to join the multicast group, the current switch already joins the port receiving the GMRPjoin message to the multicast group, and joins the cascade port to the multicast group when the current switch is provided with the cascade port, and joins the interception port to the multicast group when the current switch is provided with the interception port, so that the cascade port and the interception port of the current switch allow the known multicast data message to pass through.
For an unknown multicast data message, if the current switch is provided with a cascade port, the unknown multicast data message needs to be sent out from the cascade port of the current switch, and if the current switch is provided with an interception port, the unknown multicast data message needs to be sent out from the interception port of the current switch.
Therefore, after the current switch receives the multicast data packet sent by the process layer device in step 203 and before determining the multicast group to which the multicast data packet belongs, the method further includes: judging whether the multicast data message is a known multicast data message or not, and if so, determining a multicast group to which the multicast data message belongs; otherwise, the multicast data message is sent out from the cascade port of the current switch, and if the current switch is provided with the interception port, the multicast data message is also sent out from the interception port of the current switch.
In practical application, when a certain spacer layer device in a spacer layer does not need to receive a certain multicast data stream, it needs to send an MRGPleave message to request to leave a corresponding multicast group. Correspondingly, when the switch receives the GMRPleave message sent by the spacer layer device, all ports added to the multicast group corresponding to the GMRPleave message need to be deleted from the multicast group corresponding to the GMRPleave message, so that when the multicast data message belonging to the multicast group corresponding to the GMRPleave message is received again, the multicast data message is processed as an unknown multicast data message.
In the embodiment of the present invention shown in fig. 2, the bay level devices include line measurement and control devices, line protection devices, and bus protection devices, wherein for convenience of distinction, the line measurement and control devices and the line protection devices are bay level processing devices, and the process level devices include conventional switch devices and CT/PT devices; the multicast data message comprises a GOOSE message and an SV message. In addition, the cascade port and the interception port can be added into the multicast group in a recessive way, and the user does not need to know.
The implementation of the embodiment of the present invention shown in fig. 2 will be described below with reference to fig. 1 as an example.
First, each switch performs configuration of a cascade port and a snoop port, for example, switch 1 sets port P12 connected to switch 2 as a cascade port, switch 2 sets port P21 connected to switch 1 and the port connected to switch 3 as cascade ports, and so on. Since the switch n is directly connected to the bus bar protection device, the switch n also needs to set the port connected to the bus bar protection device as the listening port.
Because the line measurement and control device in the spacer layer needs to receive the multicast data packet of the conventional switch device corresponding to the process layer, and the line protection device in the spacer layer needs to receive the multicast data packet of the CT/PT device corresponding to the process layer, in fig. 1, the line measurement and control device 1 needs to send an MGRPjoin packet for a multicast group using the conventional switch device 1 as a multicast source, and the line protection device 1 needs to send an MGRPjoin packet for a multicast group using the CT/PT device 1 as a multicast source; the line measurement and control equipment 2 needs to send MGRPjoin messages for multicast groups using the conventional switch equipment 2 as a multicast source, and the line protection equipment 2 needs to send MGRPjoin messages for multicast groups using the CT/PT equipment 2 as a multicast source; and so on.
When the line measurement and control device 1 needs to send an MGRPjoin message to a multicast group (assumed to be a multicast group 1) using the conventional switch device 1 as a multicast source, the switch 1 receives a port P10 of the MGRPjoin to join the multicast group 1, and additionally needs to join the cascade port P12 to the multicast group 1. Similarly, for MGRPjoin messages of other spacer layer devices for a multicast group, the switch also performs the operation of adding the receiving port, the cascade port and the interception port to the multicast group according to the same principle after receiving the MGRPjoin messages.
When the switch 1 receives the multicast data packet sent by the conventional switch device 1, it may be determined that the multicast data packet belongs to the multicast group 1, and therefore, the multicast data packet is sent from all ports that join the multicast group 1: the P10 and the P12 send out, the multicast data message sent out from the P12 port will reach the switch n through the cascade port of the switch 2 and the switch 3 … switch n, and the switch n sends out to the bus bar protection device through the interception port. The multicast data messages sent by other process layer devices can finally reach the bus protection device according to the same principle.
Based on the same inventive concept, the invention also provides a filtering device for multicast data messages in the transformer substation network, which is described below with reference to fig. 3.
Fig. 3 is a schematic structural diagram of a filtering apparatus for multicast data packets in a substation network according to an embodiment of the present invention, where the substation network includes a plurality of process layer devices belonging to a process layer and a plurality of bay layer devices belonging to a bay layer; the process layer device and the bay level device are connected through a switch, wherein the bay level device includes a bay level processing device and a bus bar protection device, the process layer device, the bay level device, and the switch all start GMRP functions, the apparatus is applied to the switch connecting the process layer device and the bay level device, as shown in fig. 3, the apparatus includes: a configuration unit 301, a receiving unit 302, a processing unit 303, and a transmitting unit 304; wherein,
a configuration unit 301, configured to set a port of the switch where the apparatus is located, which is connected to another switch, as a cascade port, and set a port of the switch where the apparatus is located, which is connected to the bus device, as an intercept port if the switch where the apparatus is located is directly connected to the bus protection device;
a receiving unit 302, configured to receive a GMRPjoin message sent by a spacer layer processing device; the device is used for receiving the multicast data message sent by the process layer device;
a processing unit 303, configured to add, when the receiving unit 302 receives a GMRPjoin message sent by the bay layer processing device, a port that receives the GMRPjoin message and a cascade port of an switch where the apparatus is located to a multicast group corresponding to the GMRPjoin message, and if the switch where the apparatus is located is provided with an interception port, add the interception port to the multicast group corresponding to the GMRPjoin message; the multicast group determining unit is configured to determine, when the receiving unit 302 receives a multicast data packet sent by a process layer device, a multicast group to which the multicast data packet belongs;
a sending unit 304, configured to broadcast and send the GMRPjoin message after the receiving unit 302 receives the GMRPjoin message sent by the spacer layer processing device; the processing unit 303 is configured to forward the multicast data packet from all ports added to the multicast group after determining that the receiving unit 302 receives the multicast group to which the multicast data packet sent by the process layer device belongs.
In the above-mentioned device, the liquid crystal display device,
after the multicast data packet sent by the process layer device and received by the receiving unit 302, and before determining the multicast group to which the multicast data packet belongs, the processing unit 303 is further configured to: judging whether the multicast data message is a known multicast data message or not, and if so, determining a multicast group to which the multicast data message belongs;
the sending unit 304 is configured to send the multicast data packet from the cascade port of the switch where the apparatus is located when the processing unit 303 determines that the multicast data packet sent by the process layer device and received by the receiving unit 302 is an unknown multicast data packet, and if the switch where the apparatus is located is provided with an interception port, send the multicast data packet from the interception port of the switch where the apparatus is located.
In the above-mentioned device, the liquid crystal display device,
the receiving unit 302 is further configured to receive a GMRPleave message sent by the spacer layer processing device;
the processing unit 303 is further configured to delete all ports added to the multicast group corresponding to the GMRPleave packet from the multicast group corresponding to the GMRPleave packet when the receiving unit 302 receives the GMRPleave packet sent by the spacer layer processing device.
In summary, in the embodiment of the present invention, a port between switches is set as a cascade port, a port connected to a bus protection device on a switch is set as an interception port, and an MGRP is improved so that when the switch receives an MGRPjoin message, the switch not only adds a receiving port to a multicast group corresponding to the MGRPjoin message, but also adds a cascade port and an interception port of the switch (if the cascade port and the interception port exist) to a multicast group corresponding to the MGRPjoin message, so that the cascade port and the interception port of the switch allow multicast data messages belonging to the multicast group corresponding to the MGRPjoin message to pass through, and further allow the multicast data messages to reach the bus protection device through the cascade port and the interception port.
In the embodiment of the invention, the bus protection equipment can receive all multicast data messages sent by the process layer equipment only by configuring the cascade port and the interception port on each switch, and the configuration is simpler.
The above description is only a preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.