US20150229587A1 - Method and apparatus for selecting passive port of transparent clock node based on ptp - Google Patents
Method and apparatus for selecting passive port of transparent clock node based on ptp Download PDFInfo
- Publication number
- US20150229587A1 US20150229587A1 US14/350,021 US201214350021A US2015229587A1 US 20150229587 A1 US20150229587 A1 US 20150229587A1 US 201214350021 A US201214350021 A US 201214350021A US 2015229587 A1 US2015229587 A1 US 2015229587A1
- Authority
- US
- United States
- Prior art keywords
- port
- identifier information
- forwarding
- network device
- clock
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 58
- 239000002674 ointment Substances 0.000 claims description 3
- 108700009949 PTP protocol Proteins 0.000 abstract description 3
- 238000010586 diagram Methods 0.000 description 12
- 239000000284 extract Substances 0.000 description 7
- ATJFFYVFTNAWJD-UHFFFAOYSA-N Tin Chemical compound [Sn] ATJFFYVFTNAWJD-UHFFFAOYSA-N 0.000 description 2
- 238000004891 communication Methods 0.000 description 2
- 238000012360 testing method Methods 0.000 description 2
- 230000002159 abnormal effect Effects 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 238000013480 data collection Methods 0.000 description 1
- 230000007812 deficiency Effects 0.000 description 1
- 230000003111 delayed effect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000005259 measurement Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L69/00—Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
- H04L69/28—Timers or timing mechanisms used in protocols
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L49/00—Packet switching elements
- H04L49/30—Peripheral units, e.g. input or output ports
- H04L49/3009—Header conversion, routing tables or routing tags
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04J—MULTIPLEX COMMUNICATION
- H04J3/00—Time-division multiplex systems
- H04J3/02—Details
- H04J3/06—Synchronising arrangements
- H04J3/0635—Clock or time synchronisation in a network
- H04J3/0638—Clock or time synchronisation among nodes; Internode synchronisation
- H04J3/0641—Change of the master or reference, e.g. take-over or failure of the master
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L49/00—Packet switching elements
- H04L49/25—Routing or path finding in a switch fabric
- H04L49/253—Routing or path finding in a switch fabric using establishment or release of connections between ports
- H04L49/254—Centralised controller, i.e. arbitration or scheduling
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04J—MULTIPLEX COMMUNICATION
- H04J3/00—Time-division multiplex systems
- H04J3/02—Details
- H04J3/06—Synchronising arrangements
- H04J3/0635—Clock or time synchronisation in a network
- H04J3/0638—Clock or time synchronisation among nodes; Internode synchronisation
- H04J3/0658—Clock or time synchronisation among packet nodes
- H04J3/0661—Clock or time synchronisation among packet nodes using timestamps
- H04J3/0667—Bidirectional timestamps, e.g. NTP or PTP for compensation of clock drift and for compensation of propagation delays
Definitions
- the present invention relates to the field of Precision Time Protocol (PTP) technologies in network transmission and particularly to a method and apparatus for selecting a passive port of a transparent clock node based on PTP.
- PTP Precision Time Protocol
- time synchronization at a sub-microsecond level has been required especially in the majority of industrial Ethernet-based distributed control systems.
- higher time uniformity may be required in view of real-time data collection, scheduling and control.
- a precision synchronization clock protocol relating to network communication, local computation and object allocation in a test and control network has been defined in the IEEE-1588 Precision Time Protocol (PTP).
- PTP Precision Time Protocol
- This protocol supporting system-wide time synchronization can be applicable to both a wide area Ethernet and a multipoint transmission-enabled local area network and can achieve the time synchronization precision at a sub-microsecond level.
- the IEEE-1588 precision time synchronization algorithm has been widely applied in power supply management, industrial control, test and measurement, network communication and other fields due to its high synchronization precision, low-cost implementation, convenience to deploy and maintain and other superiorities.
- the currently used PTP version is generally the IEEE1588V2 version with an additional support of a transparent clock comparing to the V1 version to thereby further alleviate the difficulty to implement IEEE1588 and improve the stability and the time synchronization precision of IEEE1588, and particularly for the network node run on transparent clock protocol (that is transparent clock node), it is more appropriate to transport the clock information in a switch system.
- a transparent clock node performs only frequency synchronization upon a received PTP packet without phase synchronization, and a transparent clock node forwards the PTP packet simply after performing tome process on the received PTP packet, so there may be a protocol storm in the loop network due to the PTP packets and consequently time synchronization cannot be performed in the network.
- the invention provides a method and apparatus for selecting a passive port of a transparent clock node based on PTP so as to address the problem of a protocol storm due to PTP packets in a PTP-disabled complex topology network or loop network including a plurality of transparent clock nodes.
- the invention provides a method for selecting a passive port of a transparent clock node based on PTP, including:
- a port of a network device receiving an Announce packet transmitted from another network device, extracting a TLV field of the Announce packet, and obtaining clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field, wherein the network device are provided with at least two ports;
- the port of the network device is not a slave port, comparing the number of forwarding carried in the TLV field received via the port of the network device with the number of forwarding carried in a TLV field received via the slave port of the network device, and if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0 or 1, selecting a port with the lowest priority as the passive port; and
- the port of the network device is a slave port or the absolute value of the said difference between the numbers of forwarding is not 0 or 1, updating clock identifier information of the network device and port identifier information of an Announce packet forwarding port of the network device into the TLV field of the received Announce packet respectively as clock identifier information and port identifier information, and forwarding the updated Announce packet via the Announce packet forwarding port after incrementing the number of forwarding of the Announce packet by one.
- the invention provides an apparatus for selecting a passive port of a transparent clock node based on PTP, including:
- a receiving and extracting module configured for a port of a network device to receive an Announce packet transmitted from another network device, to extract a TLV field of the Announce packet, and to obtain clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field;
- a judging module configured to judge whether the port of the network device is a slave port
- a comparing and selecting module configured, if it is judged that the port of the network device is not a slave port, to compare the number of forwarding carried in the TLV field received via the port of the network device with the number of forwarding carried in a TLV field received via the slave port of the network device, and to select a port with the lowest priority as the passive port upon judging that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0 or 1;
- an updating and forwarding module configured, if the port of the network device is a slave port or the absolute value of the said difference between the numbers of forwarding is not 0 or 1, to update clock identifier information of the network device and port identifier information of an Announce packet forwarding port of the network device into the TLV field of the received Announce packet respectively as clock identifier information and port identifier information, and to forward the updated Announce packet via the Announce packet forwarding port after incrementing the number of forwarding of the Announce packet by one.
- the invention provides a method and apparatus for selecting a passive port of a transparent clock node based on PTP, and a first port of a network device in the method receives an Announce packet transmitted from another network device, extracts a TLV field of the Announce packet, and obtains clock identifier information, number-of-forwarding information and port identifier information carried in the TIN field; judges whether the first port is a slave port; if it is judged that the first port is not a slave port, the number of forwarding carried in the TLV field received via the first port is compared with the number of forwarding carried in a TLV field received via its own slave port, and if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the first port and the number of forwarding carried in the TLV field received via the slave port is 0 or 1, a port with the lowest priority is selected as the passive port; and if the first port is a slave port or the absolute value of the difference between the numbers of forwarding is not
- a first port of a network device in the invention extracts a TLV field of a received Announce packet and obtains clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field; and compares the number-of-forwarding information and the clock identifier information carried in the TLV field with number-of-forwarding information carried in the TLV field included in an Announce packet received via its own slave port and the clock identifier information of the network device to thereby select a port with the lowest priority as the passive port, so the clock identifier information, the number-of-forwarding information and the port identifier information are added to the TLV field of the Announce packet as comparison factors to enable a transparent clock node to support the PTP so as to avoid a protocol storm in a complex topology network or loop network including transparent clock nodes due to the PTP packets and improve the stability of the network.
- FIG. 1 is a schematic diagram of a process for selecting a passive port of a transparent clock node based on PTP according to the invention
- FIG. 2 is a schematic diagram of a detailed process for selecting a passive port of a transparent clock node based on PTP in a symmetric network according to the invention
- FIG. 3 is a structural diagram of a symmetric network to which the method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention
- FIG. 4 is a structural diagram of an asymmetric network to which the method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention
- FIG. 5 is a structural diagram of a redundant network to which the method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention.
- FIG. 6 is a structural diagram of an apparatus for selecting a passive port of a transparent clock node based on PTP according to the invention.
- a transparent clock node performs only frequency synchronization upon a received PTP packet without phase synchronization, and a transparent clock node forwards the received PTP packet simply after performing some process on the received PTP packet, so there may be a protocol storm in the loop network due to the PTP packets, and in order to address such a problem, embodiments of the invention provide a method and apparatus for selecting a passive port of a transparent clock node based on PTP, where an Announce packet is extended to enable the transparent clock node to support the PTP so as to avoid a protocol storm due to the PTP packets and improve the stability of the network.
- FIG. 1 is a schematic diagram of a process for selecting a passive port of a transparent clock node based on PTP according to the invention, where the selecting process includes the following steps.
- a first port of a network device receives an Announce packet transmitted from another network device, where a TLV field of the Announce packet carries clock identifier information, number-of-forwarding information and port identifier information.
- the network device adds comparison factors in the TLV field of the Announce packet, e.g., the clock identifier information, the number-of-forwarding information and the port identifier information, to compare data sets in respective transparent clock nodes, where the network device in the invention includes but will not be limited to a switcher, a router and other smart devices with transparent clock function.
- the clock identifier information carried in the TLV field in the invention includes the priority of a clock identifier
- the port identifier information includes the priority of a port identifier
- the number-of-forwarding information includes the number of times that the Announce packet has been forwarded through other transparent clock nodes in the complex topology network or the loop network, where the priority of the clock identifier is determined according to the ID and particular configuration of a local clock of the network device itself, and the priority of the port identifier is determined according to the ID and particular configuration of the port.
- the network device selects a port with the highest priority as the slave port according to number-of-forwarding information carried in TLV fields in Announce packets received via its own respective ports and identifier information of its own respective ports.
- the port with the highest priority as the slave port is selected by: comparing numbers of forwarding carried in the TLV fields in the Announce packets received via the respective ports, selecting a port with the lowest number of forwarding carried in the TLV field in the received Announce packet, judging whether there is a unique port with the lowest number of forwarding carried in the TLV field in the received Announce packet, and if it is judged that there is a unique port with the lowest number of forwarding carried in the TLV field in the received Announce packet, determining the port as the slave port;
- the first port is selected as the passive port
- the clock identifier information carried in the TIN field received via the first port is compared with clock identifier information of the network device, and
- the first port is selected as the passive port.
- the method further includes:
- the clock identifier information of the network device and port identifier information of the Announce packet forwarding port of the network device are updated into the TLV field of the Announce packet, and the updated Announce packet is forwarded via the Announce packet forwarding port after the number of forwarding of the Announce packet is incremented by one.
- the network device adds to a revision field of the Announce packet a period of time by which the Announce packet passing the network device is delayed (in the case that the network device is an E2E transparent clock, it calculates and adds its own staying period of time to the revision field of the packet, and in the case that the network device is a P2P transparent clock, it calculates and adds a point-to-point link delay and its own staying period of time to the revision field of the packet), updates its own clock identifier information and port identifier information of the forwarding port respectively into the clock identifier information and the port identifier information in the TLV field of the received Announce packet, increments the number of forwarding carried in the TLV field of the received Announce packet by one, and forwards the updated Announce packet via the Announce packet forwarding port corresponding to the port identifier information.
- the boundary clock node does not need to compare or update the information included in the TLV field of the Announce packet upon receiving or forwarding of the Announce packet, so the TLV field of the Announce packet carries no clock identifier information, number-of-forwarding information and port identifier information, and thus the TLV field of the Announce packet via the port of the network device in the complex topology network or the loop network carries no clock identifier information, number-of-forwarding information and port identifier information.
- the following process is performed before the slave port is selected.
- the Announce packet is parsed, clock ID identifier information carried in the Announce packet is obtained, the clock ID identifier information carried in the Announce packet is updated into the TLV field of the Announce packet as parent clock ID identifier information, clock identifier information of the network device and port identifier information of Announce packet forwarding port of the network device are updated respectively into the TLV field of the Announce packet as clock identifier information and port identifier information, the number of forwarding of the Announce packet is set to 1 in the TLV field, and the updated Announce packet is forwarded via all its own other ports than the passive port.
- the transparent clock node in the invention updates the revision field of the Announce packet by its own staying period of time and link delay of the Announce packet without modifying the clock ID identifier information of the Announce packet, and in the case that the Announce packet is transmitted to a network including a boundary clock node over the network including the transparent clock nodes, the boundary clock node updates the clock ID identifier information of the Announce packet without modifying the TLV field of the Announce packet, so after the Announce packet is further transmitted from the boundary clock node to another loop network including transparent clocks, the number-of-forwarding information carried in the TLV field of the Announce packet is incremented further to the performance done by a preceding transparent clock node, thus making a result of selecting a passive port inaccurate.
- the clock ID identifier information included in the Announce packet is updated into the TLV field of the Announce packet as parent clock ID identifier information
- its own clock identifier information and port identifier information of its own Announce packet forwarding port are updated respectively into the TLV field of the Announce packet as clock identifier information and port identifier information
- the number of forwarding of the Announce packet is set to 1 in the TLV field of the Announce packet, and the Announce packet is forwarded via the Announce packet forwarding port without judging any slave port.
- FIG. 2 is a schematic diagram of a detailed process for selecting a passive port of a transparent clock node based on PTP according to the invention, where the selecting process includes the following steps.
- a first port of a network device receives an Announce packet transmitted from another network device and extracts a TLV field of the Announce packet.
- the first port is selected as a passive port.
- the clock ID identifier information included in the Announce packet is updated into the TLV field of the Announce packet as parent clock ID identifier information, its own clock identifier information and port identifier information of its own Announce packet forwarding port are updated respectively into the TLV field of the Announce packet as clock identifier information and port identifier information, the number of forwarding of the Announce packet is set to 1, and the Announce packet is forwarded via the Announce packet forwarding port.
- FIG. 3 is a structural diagram of a symmetric network to which the foregoing method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention.
- singly present numerals represent the number of forwarding of the Announce packet.
- a first port of the network device TC 1 receives an Announce packet transmitted from an external network, extracts the TLV field of the Announce packet, judges whether the TLV field of the Announce packet carries no clock identifier information, number-of-forwarding information and port identifier information, and if so, then the first port parses the Announce packet, updates clock ID identifier information included in the Announce packet into the TLV field of the Announce packet as parent clock ID identifier information, the clock identifier information and port identifier information of a second port of the network device TC 1 are updated respectively into the TLV field of the Announce packet as clock identifier information and port identifier information, and forwarding the Announce packet via the second port after the number of forwarding of the Announce packet is set to 1.
- the network devices TC 2 to TC 6 receive the Announce packet forwarded through the other network devices in the loop network, extract the TLV field of the Announce packet, obtain the clock identifier information, the number-of-forwarding information and the port identifier information carried in the TLV field, and select a port with the lowest priority as the passive port according to the clock identifier information and the number-of-forwarding information carried in the TLV field, where a port illustrated as a black dot of the network device TC 4 in the FIG.
- the protocol particularly the Announce packet
- the protocol is extended to enable the transparent clock node to support the PTP protocol so as to avoid a protocol storm in the complex topology network or the loop network including the transparent clock nodes due to the PTP packets and improve the stability of the network.
- FIG. 4 is a structural diagram of an asymmetric network to which the foregoing method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention.
- singly present numerals represent the number of forwarding of the Announce packet.
- FIG. 5 is a structural diagram of a redundant network to which the foregoing method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention.
- singly present numerals represent the number of forwarding of the Announce packet.
- the network devices TC 4 and TC 5 are a redundant section of the loop network, and with the method for selecting a passive port of a transparent clock node according to the invention, the deployment structure of the loop network can be translated effectively into a tree-like deployment structure to thereby avoid a protocol storm in the loop network due to the PTP packets and improve the stability of the network.
- FIG. 6 is a structural diagram of an apparatus for selecting a passive port of a transparent clock node based on PTP according to the invention, where the selecting apparatus includes:
- a receiving and extracting module 61 configured for a port of a network device to receive an Announce packet transmitted from another network device, to extract a TLV field of the Announce packet, and to obtain clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field;
- a judging module 62 configured to judge whether the port of the network device is a slave port
- a comparing and selecting module 63 configured, if the judging module 62 judges that the port of the network device is not a slave port, to compare the number of forwarding carried in the TLV field received via the port of the network device with the number of forwarding carried in a TLV field received via the slave port of the network device, and to select a port with the lowest priority as the passive port upon judging that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0 or 1;
- An updating and forwarding module 64 configured, if the judging module 62 judges that the port of the network device is a slave port or the comparing and selecting module 63 judges that the absolute value of the said difference between the numbers of forwarding is not 0 or 1, to update clock identifier information of the network device and port identifier information of an Announce packet forwarding port of the network device into the TLV field of the received Announce packet respectively as clock identifier information and port identifier information, and to forward the updated Announce packet via the Announce packet forwarding port after the number of forwarding of the Announce packet is incremented by one.
- the judging module 62 is further configured to judge whether the TLV field of the Announce packet received via the port of the network device carries no clock identifier information, number-of-forwarding information and port identifier information;
- the updating and forwarding module 64 is further configured, if the judging module 62 judges that the TLV field of the Announce packet carries no clock identifier information, number-of-forwarding information and port identifier information, to parse the Announce packet, to obtain clock ID identifier information carried in the Announce packet, to update the clock ID identifier information carried in the Announce packet into the TLV field of the Announce packet as parent clock ID identifier information, to update the clock identifier information of the network device and the port identifier information of the Announce packet forwarding port of the network device into the TLV field of the Announce packet respectively as clock identifier information and port identifier information, to set the number of forwarding of the Announce packet to 1, and to forward the Announce packet via the Announce packet forwarding port.
- the judging module 62 is further configured to judge whether parent clock ID identifier information carried in the TLV field of the Announce packet received via the port of the network device is consistent with clock ID identifier information included in the Announce packet;
- the updating and forwarding module 64 is further configured, if the judging module 62 judges that the parent clock ID identifier information carried in the TLV field of the Announce packet received via the port of the network device is not consistent with the clock ID identifier information included in the Announce packet, to update the clock ID identifier information included in the Announce packet into the TLV field of the Announce packet as parent clock ID identifier information, to update the clock identifier information of the network device and the port identifier information of the Announce packet forwarding port of the network device into the TLV field of the Announce packet respectively as clock identifier information and port identifier information, to set the number of forwarding of the Announce packet to 1, and to forward the Announce packet via the Announce packet forwarding port.
- the comparing and selecting module 63 is further configured for the network device to select a port with the highest priority as the slave port according to number-of-forwarding information carried in TLV fields in Announce packets received via respective ports of the network device and port identifier information of the respective ports of the network device, where the port identifier information includes the priority of a port.
- the comparing and selecting module 63 is particularly configured to compare numbers of forwarding carried in the TLV fields in the Announce packets received via the respective ports, to select a port with the lowest number of forwarding carried in the TLV field in the received Announce packet, to judge whether there is a unique port with the lowest number of forwarding carried in the TLV field in the received Announce packet, and if it is judged that there is a unique port with the lowest number of forwarding carried in the TLV field in the received Announce packet, to select the port as a salve port; otherwise, to compare the priorities in the port identifier information of the respective ports with the lowest numbers of forwarding carried in the TLV fields in the received Announce packets, and to select a port with the highest priority as the slave port.
- the comparing and selecting module 63 is further configured, if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0, to select the port of the network device as the passive port.
- the comparing and selecting module 63 is further configured, if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 1, to compare the clock identifier information carried in the TLV field received via the port of the network device with the clock identifier information of the network device, and if it is judged that a priority in the clock identifier information carried in the TLV field received via the port of the network device is higher than a priority in the clock identifier information of the network device, to select the port of the network device as the passive port, where the clock identifier information includes the priority of a clock identifier.
- the updating and forwarding module 64 is further configured, if it is judged that the priority in the clock identifier information carried in the TLV field received via the port of the network device is not higher than the priority in the clock identifier information of the network device, to update the clock identifier information of the network device and the port identifier information of the Announce packet forwarding port of the network device into the TLV field of the Announce packet respectively as clock identifier information and port identifier information, and to forward the Announce packet via the Announce packet forwarding port after the number of forwarding of the Announce packet is incremented by one.
- the selecting apparatus further includes:
- a resuming module 65 configured to resume automatically the set passive port when a link becomes abnormal.
- the invention provides a method and apparatus for selecting a passive port of a transparent clock node based on PTP, and a port of a network device in the method receives an Announce packet transmitted from another network device, extracts the TLV field of the Announce packet, and obtains clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field; judges whether the port of the network device is a slave port; if it is judged that the port of the network device is not a slave port, the number of forwarding carried in the TLV field received via the port of the network device is compared with the number of forwarding carried in a TLV field received via the slave port of the network device, and if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0 or 1, a port with the lowest priority is selected as the passive port; and if the port of the network device is a slave
- a port of a network device in the invention extracts a TLV field of a received Announce packet and obtains clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field; and compares the number-of-forwarding information and the clock identifier information carried in the TLV field respectively with number-of-forwarding information carried in a TLV field included in an Announce packet received via the slave port of the network device and clock identifier information of the network device, to thereby select a passive port, so the clock identifier information, the number-of-forwarding information and the port identifier information are added to the TLV field of the Announce packet as comparison factors to enable a transparent clock node to support the PTP so as to avoid a protocol storm in a complex topology network or a loop network including transparent clocks due to the PTP packets and improve the stability of the network.
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Small-Scale Networks (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
Description
- The present application is a US National Stage of International Application No. PCT/CN2012/076216, filed May 29, 2012, designating the United States, and claiming priority to Chinese Patent Application No. 201210168427.3, filed with the Chinese Patent Office on May 25, 2012 and entitled “method and apparatus for selecting passive port of transparent clock node based on PTP”, which is hereby incorporated by reference in its entirety.
- The present invention relates to the field of Precision Time Protocol (PTP) technologies in network transmission and particularly to a method and apparatus for selecting a passive port of a transparent clock node based on PTP.
- Along with rapid development of computer networks, more stringent time synchronization has been required in an increasing number of industrial fields, and time synchronization at a sub-microsecond level has been required especially in the majority of industrial Ethernet-based distributed control systems. Particularly, in a smart substation automation system and distributed control system, higher time uniformity may be required in view of real-time data collection, scheduling and control.
- A precision synchronization clock protocol relating to network communication, local computation and object allocation in a test and control network has been defined in the IEEE-1588 Precision Time Protocol (PTP). This protocol supporting system-wide time synchronization can be applicable to both a wide area Ethernet and a multipoint transmission-enabled local area network and can achieve the time synchronization precision at a sub-microsecond level. The IEEE-1588 precision time synchronization algorithm has been widely applied in power supply management, industrial control, test and measurement, network communication and other fields due to its high synchronization precision, low-cost implementation, convenience to deploy and maintain and other superiorities.
- The currently used PTP version is generally the IEEE1588V2 version with an additional support of a transparent clock comparing to the V1 version to thereby further alleviate the difficulty to implement IEEE1588 and improve the stability and the time synchronization precision of IEEE1588, and particularly for the network node run on transparent clock protocol (that is transparent clock node), it is more appropriate to transport the clock information in a switch system.
- During existing network deployment, if a complex topology network or a loop network is deployed across a plurality of transparent clock nodes, then a transparent clock node performs only frequency synchronization upon a received PTP packet without phase synchronization, and a transparent clock node forwards the PTP packet simply after performing tome process on the received PTP packet, so there may be a protocol storm in the loop network due to the PTP packets and consequently time synchronization cannot be performed in the network.
- In the prior art, there is such a solution to this problem that whether to forward a PTP packet is determined by a port status of a spanning tree, and this solution can address the problem of transparent time synchronization in a network with a spanning tree, but a device, for which there are a plurality of spanning trees and a network is deployed with routing, can not judge, or can not judge purely, from the status of a port spanning tree, whether to forward a transparent clock packet and consequently the PTP may fail.
- In view of this, the invention provides a method and apparatus for selecting a passive port of a transparent clock node based on PTP so as to address the problem of a protocol storm due to PTP packets in a PTP-disabled complex topology network or loop network including a plurality of transparent clock nodes.
- The invention provides a method for selecting a passive port of a transparent clock node based on PTP, including:
- a port of a network device receiving an Announce packet transmitted from another network device, extracting a TLV field of the Announce packet, and obtaining clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field, wherein the network device are provided with at least two ports;
- judging whether the port of the network device is a slave port;
- if it is judged that the port of the network device is not a slave port, comparing the number of forwarding carried in the TLV field received via the port of the network device with the number of forwarding carried in a TLV field received via the slave port of the network device, and if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0 or 1, selecting a port with the lowest priority as the passive port; and
- if the port of the network device is a slave port or the absolute value of the said difference between the numbers of forwarding is not 0 or 1, updating clock identifier information of the network device and port identifier information of an Announce packet forwarding port of the network device into the TLV field of the received Announce packet respectively as clock identifier information and port identifier information, and forwarding the updated Announce packet via the Announce packet forwarding port after incrementing the number of forwarding of the Announce packet by one.
- The invention provides an apparatus for selecting a passive port of a transparent clock node based on PTP, including:
- a receiving and extracting module configured for a port of a network device to receive an Announce packet transmitted from another network device, to extract a TLV field of the Announce packet, and to obtain clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field;
- a judging module configured to judge whether the port of the network device is a slave port;
- a comparing and selecting module configured, if it is judged that the port of the network device is not a slave port, to compare the number of forwarding carried in the TLV field received via the port of the network device with the number of forwarding carried in a TLV field received via the slave port of the network device, and to select a port with the lowest priority as the passive port upon judging that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0 or 1; and
- an updating and forwarding module configured, if the port of the network device is a slave port or the absolute value of the said difference between the numbers of forwarding is not 0 or 1, to update clock identifier information of the network device and port identifier information of an Announce packet forwarding port of the network device into the TLV field of the received Announce packet respectively as clock identifier information and port identifier information, and to forward the updated Announce packet via the Announce packet forwarding port after incrementing the number of forwarding of the Announce packet by one.
- The invention provides a method and apparatus for selecting a passive port of a transparent clock node based on PTP, and a first port of a network device in the method receives an Announce packet transmitted from another network device, extracts a TLV field of the Announce packet, and obtains clock identifier information, number-of-forwarding information and port identifier information carried in the TIN field; judges whether the first port is a slave port; if it is judged that the first port is not a slave port, the number of forwarding carried in the TLV field received via the first port is compared with the number of forwarding carried in a TLV field received via its own slave port, and if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the first port and the number of forwarding carried in the TLV field received via the slave port is 0 or 1, a port with the lowest priority is selected as the passive port; and if the first port is a slave port or the absolute value of the difference between the numbers of forwarding is not 0 or 1, its own clock identifier information and port identifier information of its own Announce packet forwarding port are updated into the TLV field of the received Announce packet, and the updated Announce packet is forwarded via the Announce packet forwarding port after the number of forwarding of the Announce packet is incremented by one.
- A first port of a network device in the invention extracts a TLV field of a received Announce packet and obtains clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field; and compares the number-of-forwarding information and the clock identifier information carried in the TLV field with number-of-forwarding information carried in the TLV field included in an Announce packet received via its own slave port and the clock identifier information of the network device to thereby select a port with the lowest priority as the passive port, so the clock identifier information, the number-of-forwarding information and the port identifier information are added to the TLV field of the Announce packet as comparison factors to enable a transparent clock node to support the PTP so as to avoid a protocol storm in a complex topology network or loop network including transparent clock nodes due to the PTP packets and improve the stability of the network.
- The drawings described here serve to provide further understanding of the invention and constitute a part of the invention, and exemplary embodiments of the invention and their description are intended to explain the invention but not to limit unduly the invention. In the drawings:
-
FIG. 1 is a schematic diagram of a process for selecting a passive port of a transparent clock node based on PTP according to the invention; -
FIG. 2 is a schematic diagram of a detailed process for selecting a passive port of a transparent clock node based on PTP in a symmetric network according to the invention; -
FIG. 3 is a structural diagram of a symmetric network to which the method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention; -
FIG. 4 is a structural diagram of an asymmetric network to which the method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention; -
FIG. 5 is a structural diagram of a redundant network to which the method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention; and -
FIG. 6 is a structural diagram of an apparatus for selecting a passive port of a transparent clock node based on PTP according to the invention. - In order to make the technical problem to be addressed by the invention and the technical solution and advantageous effects of the invention more apparent, the invention will be further described below in details with reference to the drawings and embodiments. It shall be appreciated that the particular embodiments described here are only intended to explain the invention but not to limit the invention.
- In a complex topology network or a loop network including a plurality of transparent clock nodes, a transparent clock node performs only frequency synchronization upon a received PTP packet without phase synchronization, and a transparent clock node forwards the received PTP packet simply after performing some process on the received PTP packet, so there may be a protocol storm in the loop network due to the PTP packets, and in order to address such a problem, embodiments of the invention provide a method and apparatus for selecting a passive port of a transparent clock node based on PTP, where an Announce packet is extended to enable the transparent clock node to support the PTP so as to avoid a protocol storm due to the PTP packets and improve the stability of the network.
- The embodiments of the invention will be described below in details with reference to the drawings.
-
FIG. 1 is a schematic diagram of a process for selecting a passive port of a transparent clock node based on PTP according to the invention, where the selecting process includes the following steps. - S101: A first port of a network device receives an Announce packet transmitted from another network device, where a TLV field of the Announce packet carries clock identifier information, number-of-forwarding information and port identifier information.
- In order to overcome the deficiency that in a complex topology network or a loop network including a plurality of transparent clock nodes, a transparent clock node performs only frequency synchronization without phase synchronization and consequently can not function as a master clock, the network device according to the invention adds comparison factors in the TLV field of the Announce packet, e.g., the clock identifier information, the number-of-forwarding information and the port identifier information, to compare data sets in respective transparent clock nodes, where the network device in the invention includes but will not be limited to a switcher, a router and other smart devices with transparent clock function.
- S102: The TLV field of the Announce packet is extracted, and the clock identifier information, the number-of-forwarding information and the port identifier information carried in the TLV field are obtained.
- The clock identifier information carried in the TLV field in the invention includes the priority of a clock identifier, the port identifier information includes the priority of a port identifier, and the number-of-forwarding information includes the number of times that the Announce packet has been forwarded through other transparent clock nodes in the complex topology network or the loop network, where the priority of the clock identifier is determined according to the ID and particular configuration of a local clock of the network device itself, and the priority of the port identifier is determined according to the ID and particular configuration of the port.
- S103: It is judged whether the first port is a slave port, and if so, then the process proceeds to the step S106; otherwise, the process proceeds to the step S104.
- In a method for selecting a slave port of the network device in the invention, the network device selects a port with the highest priority as the slave port according to number-of-forwarding information carried in TLV fields in Announce packets received via its own respective ports and identifier information of its own respective ports.
- Particularly, the port with the highest priority as the slave port is selected by: comparing numbers of forwarding carried in the TLV fields in the Announce packets received via the respective ports, selecting a port with the lowest number of forwarding carried in the TLV field in the received Announce packet, judging whether there is a unique port with the lowest number of forwarding carried in the TLV field in the received Announce packet, and if it is judged that there is a unique port with the lowest number of forwarding carried in the TLV field in the received Announce packet, determining the port as the slave port;
- otherwise, comparing the priorities in the port identifier information of the respective ports with the lowest numbers of forwarding carried in the TLV fields in the received Announce packets, and selecting a port with the highest priority as the slave port.
- S104: It is judged whether the absolute value of the difference between the number of forwarding carried in the TLV field received via the first port and the number of forwarding carried in the TLV field received via its own slave port is 0 or 1, and if so, then the process proceeds to the step S105; otherwise, the process proceeds to the step S106.
- S105: If it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the first port and the number of forwarding carried in the TLV field received via its own slave port is 0 or 1, a port with the lowest priority is selected as the passive port.
- If it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the first port and the number of forwarding carried in the TLV field received via the slave port is 0, the first port is selected as the passive port; and
- If it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the first port and the number of forwarding carried in the TLV field received via the slave port is 1, the clock identifier information carried in the TIN field received via the first port is compared with clock identifier information of the network device, and
- If it is judged that the priority in the clock identifier information carried in the TLV field received via the first port is higher than the priority in the clock identifier information of the network device, the first port is selected as the passive port.
- If it is judged that the priority in the clock identifier information carried in the TLV field received via the first port is not higher than the priority in the clock identifier information of the network device, the method further includes:
- the clock identifier information of the network device and port identifier information of the Announce packet forwarding port of the network device are updated into the TLV field of the Announce packet, and the updated Announce packet is forwarded via the Announce packet forwarding port after the number of forwarding of the Announce packet is incremented by one.
- S106: The clock identifier information of the network device and port identifier information of the Announce packet forwarding port of the network device are updated into the TLV field of the Announce packet, and the updated Announce packet is forwarded via the Announce packet forwarding port corresponding to the port identifier information after the number of forwarding of the Announce packet is incremented by one.
- Particularly, after the network device receives the Announce packet transmitted from another device, the network device adds to a revision field of the Announce packet a period of time by which the Announce packet passing the network device is delayed (in the case that the network device is an E2E transparent clock, it calculates and adds its own staying period of time to the revision field of the packet, and in the case that the network device is a P2P transparent clock, it calculates and adds a point-to-point link delay and its own staying period of time to the revision field of the packet), updates its own clock identifier information and port identifier information of the forwarding port respectively into the clock identifier information and the port identifier information in the TLV field of the received Announce packet, increments the number of forwarding carried in the TLV field of the received Announce packet by one, and forwards the updated Announce packet via the Announce packet forwarding port corresponding to the port identifier information.
- In the case that the Announce packet is initially transmitted from a boundary clock node to the complex topology network or the loop network including transparent clock nodes, the boundary clock node does not need to compare or update the information included in the TLV field of the Announce packet upon receiving or forwarding of the Announce packet, so the TLV field of the Announce packet carries no clock identifier information, number-of-forwarding information and port identifier information, and thus the TLV field of the Announce packet via the port of the network device in the complex topology network or the loop network carries no clock identifier information, number-of-forwarding information and port identifier information. Preferably in this case, the following process is performed before the slave port is selected.
- In the case that it is judged that the TLV field of the Announce packet carries no clock identifier information, number-of-forwarding information and port identifier information, the Announce packet is parsed, clock ID identifier information carried in the Announce packet is obtained, the clock ID identifier information carried in the Announce packet is updated into the TLV field of the Announce packet as parent clock ID identifier information, clock identifier information of the network device and port identifier information of Announce packet forwarding port of the network device are updated respectively into the TLV field of the Announce packet as clock identifier information and port identifier information, the number of forwarding of the Announce packet is set to 1 in the TLV field, and the updated Announce packet is forwarded via all its own other ports than the passive port.
- In the case that the TLV field of the Announce packet further carries the parent clock ID identifier information, in addition to updating the TLV field of the received Announce packet in the method according to the invention, the transparent clock node in the invention updates the revision field of the Announce packet by its own staying period of time and link delay of the Announce packet without modifying the clock ID identifier information of the Announce packet, and in the case that the Announce packet is transmitted to a network including a boundary clock node over the network including the transparent clock nodes, the boundary clock node updates the clock ID identifier information of the Announce packet without modifying the TLV field of the Announce packet, so after the Announce packet is further transmitted from the boundary clock node to another loop network including transparent clocks, the number-of-forwarding information carried in the TLV field of the Announce packet is incremented further to the performance done by a preceding transparent clock node, thus making a result of selecting a passive port inaccurate. In order to address this problem, the transparent clock node in the complex topology network or the loop network preferably further performs the following process before the salve port is selected.
- It is judged whether the parent clock ID identifier information carried in the TLV field of the Announce packet received via the first port is consistent with the clock ID identifier information included in the Announce packet; and if it is judged that the parent clock ID identifier information carried in the TLV field of the Announce packet received via the first port is not consistent with the clock ID identifier information included in the Announce packet, the clock ID identifier information included in the Announce packet is updated into the TLV field of the Announce packet as parent clock ID identifier information, its own clock identifier information and port identifier information of its own Announce packet forwarding port are updated respectively into the TLV field of the Announce packet as clock identifier information and port identifier information, the number of forwarding of the Announce packet is set to 1 in the TLV field of the Announce packet, and the Announce packet is forwarded via the Announce packet forwarding port without judging any slave port.
-
FIG. 2 is a schematic diagram of a detailed process for selecting a passive port of a transparent clock node based on PTP according to the invention, where the selecting process includes the following steps. - S201: A first port of a network device receives an Announce packet transmitted from another network device and extracts a TLV field of the Announce packet.
- S202: It is judged whether the TLV field of the Announce packet received via the first port carries no clock identifier information, number-of-forwarding information and port identifier information, and if so, then the process proceeds to the step S210; otherwise, the process proceeds to the step S203.
- S203: It is judged whether parent clock ID identifier information carried in the TLV field of the Announce packet received via the first port is consistent with clock ID identifier information included in the Announce packet, and if so, then the process proceeds to the step S204: otherwise, the process proceeds to the step S210.
- S204: It is judged whether the first port is a slave port, and if so, then the process proceeds to the step S209; otherwise, the process proceeds to the step S205.
- S205: It is judged whether the number of forwarding carried in the TLV field received via the first port is consistent with the number of forwarding carried in a TLV field received via its own slave port, and if so, then the process proceeds to the step S208; otherwise, the process proceeds to the step S206.
- S206: It is judged whether the absolute value of the difference between the number of forwarding carried in the TLV field received via the first port and the number of forwarding carried in the TLV field received via its own slave port is 1, and if so, then the process proceeds to the step S207; otherwise, the process proceeds to the step S209.
- S207: It is judged whether a priority in the clock identifier information carried in the TLV field received via the first port is higher than a priority in its own clock identifier information, and if so, then the process proceeds to the step S208; otherwise, the process proceeds to the step S209.
- S208: The first port is selected as a passive port.
- S209: Its own clock identifier information and port identifier information of its own Announce packet forwarding port are updated into the TLV field of the received Announce packet as clock identifier information and port identifier information, and the Announce packet is forwarded via the Announce packet forwarding port after the number of forwarding of the Announce packet is incremented by one.
- S210: The clock ID identifier information included in the Announce packet is updated into the TLV field of the Announce packet as parent clock ID identifier information, its own clock identifier information and port identifier information of its own Announce packet forwarding port are updated respectively into the TLV field of the Announce packet as clock identifier information and port identifier information, the number of forwarding of the Announce packet is set to 1, and the Announce packet is forwarded via the Announce packet forwarding port.
-
FIG. 3 is a structural diagram of a symmetric network to which the foregoing method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention. InFIG. 3 , singly present numerals represent the number of forwarding of the Announce packet. As illustrated, in a loop network including network devices TC1 to TC6 which are transparent clock nodes, a first port of the network device TC1 receives an Announce packet transmitted from an external network, extracts the TLV field of the Announce packet, judges whether the TLV field of the Announce packet carries no clock identifier information, number-of-forwarding information and port identifier information, and if so, then the first port parses the Announce packet, updates clock ID identifier information included in the Announce packet into the TLV field of the Announce packet as parent clock ID identifier information, the clock identifier information and port identifier information of a second port of the network device TC1 are updated respectively into the TLV field of the Announce packet as clock identifier information and port identifier information, and forwarding the Announce packet via the second port after the number of forwarding of the Announce packet is set to 1. - The network devices TC2 to TC6 receive the Announce packet forwarded through the other network devices in the loop network, extract the TLV field of the Announce packet, obtain the clock identifier information, the number-of-forwarding information and the port identifier information carried in the TLV field, and select a port with the lowest priority as the passive port according to the clock identifier information and the number-of-forwarding information carried in the TLV field, where a port illustrated as a black dot of the network device TC4 in the
FIG. 3 is the passive port, so the protocol, particularly the Announce packet, is extended to enable the transparent clock node to support the PTP protocol so as to avoid a protocol storm in the complex topology network or the loop network including the transparent clock nodes due to the PTP packets and improve the stability of the network. -
FIG. 4 is a structural diagram of an asymmetric network to which the foregoing method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention. InFIG. 4 , singly present numerals represent the number of forwarding of the Announce packet. As illustrated, there is a difference of 1 between the numbers of forwarding of the two ports of the network devices TC4 and TC5, so if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the first port and the number of forwarding carried in the TLV field received via its own second port is 1 in the method according to the invention, a port with the lowest priority in the clock identifier information is selected as the passive port, and thus the port of the network device TC4 connected with TC5 is a passive port in the asymmetric loop network including the transparent -
FIG. 5 is a structural diagram of a redundant network to which the foregoing method for selecting a passive port of a transparent clock node based on PTP is applied according to the invention. InFIG. 5 , singly present numerals represent the number of forwarding of the Announce packet. As illustrated, the network devices TC4 and TC5 are a redundant section of the loop network, and with the method for selecting a passive port of a transparent clock node according to the invention, the deployment structure of the loop network can be translated effectively into a tree-like deployment structure to thereby avoid a protocol storm in the loop network due to the PTP packets and improve the stability of the network. -
FIG. 6 is a structural diagram of an apparatus for selecting a passive port of a transparent clock node based on PTP according to the invention, where the selecting apparatus includes: - A receiving and extracting
module 61 configured for a port of a network device to receive an Announce packet transmitted from another network device, to extract a TLV field of the Announce packet, and to obtain clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field; - A judging
module 62 configured to judge whether the port of the network device is a slave port; - A comparing and selecting
module 63 configured, if the judgingmodule 62 judges that the port of the network device is not a slave port, to compare the number of forwarding carried in the TLV field received via the port of the network device with the number of forwarding carried in a TLV field received via the slave port of the network device, and to select a port with the lowest priority as the passive port upon judging that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0 or 1; and - An updating and forwarding
module 64 configured, if the judgingmodule 62 judges that the port of the network device is a slave port or the comparing and selectingmodule 63 judges that the absolute value of the said difference between the numbers of forwarding is not 0 or 1, to update clock identifier information of the network device and port identifier information of an Announce packet forwarding port of the network device into the TLV field of the received Announce packet respectively as clock identifier information and port identifier information, and to forward the updated Announce packet via the Announce packet forwarding port after the number of forwarding of the Announce packet is incremented by one. - The judging
module 62 is further configured to judge whether the TLV field of the Announce packet received via the port of the network device carries no clock identifier information, number-of-forwarding information and port identifier information; and - The updating and forwarding
module 64 is further configured, if the judgingmodule 62 judges that the TLV field of the Announce packet carries no clock identifier information, number-of-forwarding information and port identifier information, to parse the Announce packet, to obtain clock ID identifier information carried in the Announce packet, to update the clock ID identifier information carried in the Announce packet into the TLV field of the Announce packet as parent clock ID identifier information, to update the clock identifier information of the network device and the port identifier information of the Announce packet forwarding port of the network device into the TLV field of the Announce packet respectively as clock identifier information and port identifier information, to set the number of forwarding of the Announce packet to 1, and to forward the Announce packet via the Announce packet forwarding port. - The judging
module 62 is further configured to judge whether parent clock ID identifier information carried in the TLV field of the Announce packet received via the port of the network device is consistent with clock ID identifier information included in the Announce packet; and - The updating and forwarding
module 64 is further configured, if the judgingmodule 62 judges that the parent clock ID identifier information carried in the TLV field of the Announce packet received via the port of the network device is not consistent with the clock ID identifier information included in the Announce packet, to update the clock ID identifier information included in the Announce packet into the TLV field of the Announce packet as parent clock ID identifier information, to update the clock identifier information of the network device and the port identifier information of the Announce packet forwarding port of the network device into the TLV field of the Announce packet respectively as clock identifier information and port identifier information, to set the number of forwarding of the Announce packet to 1, and to forward the Announce packet via the Announce packet forwarding port. - The comparing and selecting
module 63 is further configured for the network device to select a port with the highest priority as the slave port according to number-of-forwarding information carried in TLV fields in Announce packets received via respective ports of the network device and port identifier information of the respective ports of the network device, where the port identifier information includes the priority of a port. - The comparing and selecting
module 63 is particularly configured to compare numbers of forwarding carried in the TLV fields in the Announce packets received via the respective ports, to select a port with the lowest number of forwarding carried in the TLV field in the received Announce packet, to judge whether there is a unique port with the lowest number of forwarding carried in the TLV field in the received Announce packet, and if it is judged that there is a unique port with the lowest number of forwarding carried in the TLV field in the received Announce packet, to select the port as a salve port; otherwise, to compare the priorities in the port identifier information of the respective ports with the lowest numbers of forwarding carried in the TLV fields in the received Announce packets, and to select a port with the highest priority as the slave port. - The comparing and selecting
module 63 is further configured, if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0, to select the port of the network device as the passive port. - The comparing and selecting
module 63 is further configured, if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 1, to compare the clock identifier information carried in the TLV field received via the port of the network device with the clock identifier information of the network device, and if it is judged that a priority in the clock identifier information carried in the TLV field received via the port of the network device is higher than a priority in the clock identifier information of the network device, to select the port of the network device as the passive port, where the clock identifier information includes the priority of a clock identifier. - The updating and forwarding
module 64 is further configured, if it is judged that the priority in the clock identifier information carried in the TLV field received via the port of the network device is not higher than the priority in the clock identifier information of the network device, to update the clock identifier information of the network device and the port identifier information of the Announce packet forwarding port of the network device into the TLV field of the Announce packet respectively as clock identifier information and port identifier information, and to forward the Announce packet via the Announce packet forwarding port after the number of forwarding of the Announce packet is incremented by one. - The selecting apparatus further includes:
- A resuming
module 65 configured to resume automatically the set passive port when a link becomes abnormal. - The invention provides a method and apparatus for selecting a passive port of a transparent clock node based on PTP, and a port of a network device in the method receives an Announce packet transmitted from another network device, extracts the TLV field of the Announce packet, and obtains clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field; judges whether the port of the network device is a slave port; if it is judged that the port of the network device is not a slave port, the number of forwarding carried in the TLV field received via the port of the network device is compared with the number of forwarding carried in a TLV field received via the slave port of the network device, and if it is judged that the absolute value of the difference between the number of forwarding carried in the TLV field received via the port of the network device and the number of forwarding carried in the TLV field received via the slave port is 0 or 1, a port with the lowest priority is selected as the passive port; and if the port of the network device is a slave port or the absolute value of the difference between the numbers of forwarding is not 0 or 1, clock identifier information of the network device and port identifier information of an Announce packet forwarding port of the network device are updated into the TLV field of the Announce packet, and the updated Announce packet is forwarded via the Announce packet forwarding port after the number of forwarding of the Announce packet is incremented by one. A port of a network device in the invention extracts a TLV field of a received Announce packet and obtains clock identifier information, number-of-forwarding information and port identifier information carried in the TLV field; and compares the number-of-forwarding information and the clock identifier information carried in the TLV field respectively with number-of-forwarding information carried in a TLV field included in an Announce packet received via the slave port of the network device and clock identifier information of the network device, to thereby select a passive port, so the clock identifier information, the number-of-forwarding information and the port identifier information are added to the TLV field of the Announce packet as comparison factors to enable a transparent clock node to support the PTP so as to avoid a protocol storm in a complex topology network or a loop network including transparent clocks due to the PTP packets and improve the stability of the network.
- The foregoing description illustrates and describes preferred embodiments of the invention, but as described above, it shall be appreciated that the invention will not be limited to the disclosure of this context and shall not be construed as precluding other embodiments but can be practiced in various other combinations, variations and environments and can be modified in light of the foregoing teaching or skills or knowledge in the art without departing from the scope of the invention. Any modifications and variations made by those skilled in the art without departing from the scope of the invention shall come into the scope of the appended claims of the invention.
Claims (12)
Applications Claiming Priority (4)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210168427.3A CN103428086B (en) | 2012-05-25 | 2012-05-25 | The passive port electoral machinery of transparent clock based on PTP protocol and device |
CN201210168427.3 | 2012-05-25 | ||
CN201210168427 | 2012-05-25 | ||
PCT/CN2012/076216 WO2013174025A1 (en) | 2012-05-25 | 2012-05-29 | Transparent clock passive port election method and device based on ptp protocol |
Publications (2)
Publication Number | Publication Date |
---|---|
US20150229587A1 true US20150229587A1 (en) | 2015-08-13 |
US9363206B2 US9363206B2 (en) | 2016-06-07 |
Family
ID=49623040
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US14/350,021 Active US9363206B2 (en) | 2012-05-25 | 2012-05-29 | Method and apparatus for selecting passive port of transparent clock node based on PTP |
Country Status (4)
Country | Link |
---|---|
US (1) | US9363206B2 (en) |
CN (1) | CN103428086B (en) |
DE (1) | DE112012004227B4 (en) |
WO (1) | WO2013174025A1 (en) |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10594422B2 (en) | 2016-01-19 | 2020-03-17 | Huawei Technologies Co., Ltd. | Method and apparatus for transmitting clock packet |
US11057475B2 (en) * | 2016-12-27 | 2021-07-06 | Cloudminds (Shanghai) Robotics Co., Ltd. | Methods, apparatus and systems for resuming transmission link |
US20210344435A1 (en) * | 2016-12-30 | 2021-11-04 | Huawei Technologies Co., Ltd. | Method for exchanging time synchronization packet and network apparatus |
US11463187B2 (en) * | 2020-04-14 | 2022-10-04 | Google Llc | Fault tolerant design for clock-synchronization systems |
EP3902164A4 (en) * | 2018-12-18 | 2022-12-07 | China Mobile Communication Co., Ltd. Research Institute | Method for determining port status and network node |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP6382322B2 (en) * | 2014-01-17 | 2018-08-29 | クゥアルコム・インコーポレイテッドQualcomm Incorporated | Forwarding messages within a communications network |
CN104092528B (en) * | 2014-07-14 | 2017-06-06 | 新华三技术有限公司 | A kind of clock synchronizing method and device |
CN110865962B (en) * | 2019-10-09 | 2020-11-20 | 北京空间机电研究所 | Dynamically configurable high-precision and high-reliability clock network |
CN115396058B (en) * | 2022-08-15 | 2024-04-12 | 中国联合网络通信集团有限公司 | Signal transmission method, device and storage medium |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8472346B1 (en) * | 2007-06-08 | 2013-06-25 | Juniper Networks, Inc. | Failure detection for tunneled label-switched paths |
US9137119B2 (en) * | 2013-03-07 | 2015-09-15 | Cisco Technology, Inc. | Efficient handling of multi-destination traffic in an internet protocol fabric data center |
Family Cites Families (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101207606A (en) * | 2006-12-18 | 2008-06-25 | 华为技术有限公司 | Method and apparatus for main clock selecting |
CN101399655B (en) | 2007-09-27 | 2011-04-20 | 华为技术有限公司 | Determining method and apparatus for synchronization port of transparent clock device |
CN101170373A (en) * | 2007-11-27 | 2008-04-30 | 上海自动化仪表股份有限公司 | Clock synchronization realization method for loop network |
FR2939587B1 (en) | 2008-12-09 | 2011-04-08 | Alcatel Lucent | CLOCK FOR A NODE OF A PACKET SWITCHING NETWORK AND ASSOCIATED SYNCHRONIZATION METHOD. |
CN102026364B (en) | 2009-09-17 | 2014-07-09 | 华为技术有限公司 | Precise time protocol message processing method and clock equipment |
CN102195996B (en) * | 2010-03-09 | 2013-06-26 | 杭州华三通信技术有限公司 | Time synchronization method for stacking system, stacking system and member equipment |
US8625640B2 (en) * | 2010-08-02 | 2014-01-07 | Futurewei Technologies, Inc. | Transparent clocks in access networks |
CN101938318B (en) * | 2010-09-15 | 2013-02-27 | 中兴通讯股份有限公司 | Synchronous method, system and convergent ring device among devices in convergent network |
-
2012
- 2012-05-25 CN CN201210168427.3A patent/CN103428086B/en active Active
- 2012-05-29 WO PCT/CN2012/076216 patent/WO2013174025A1/en active Application Filing
- 2012-05-29 DE DE112012004227.1T patent/DE112012004227B4/en active Active
- 2012-05-29 US US14/350,021 patent/US9363206B2/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8472346B1 (en) * | 2007-06-08 | 2013-06-25 | Juniper Networks, Inc. | Failure detection for tunneled label-switched paths |
US9137119B2 (en) * | 2013-03-07 | 2015-09-15 | Cisco Technology, Inc. | Efficient handling of multi-destination traffic in an internet protocol fabric data center |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10594422B2 (en) | 2016-01-19 | 2020-03-17 | Huawei Technologies Co., Ltd. | Method and apparatus for transmitting clock packet |
US11057475B2 (en) * | 2016-12-27 | 2021-07-06 | Cloudminds (Shanghai) Robotics Co., Ltd. | Methods, apparatus and systems for resuming transmission link |
US20210344435A1 (en) * | 2016-12-30 | 2021-11-04 | Huawei Technologies Co., Ltd. | Method for exchanging time synchronization packet and network apparatus |
US11606155B2 (en) * | 2016-12-30 | 2023-03-14 | Huawei Technologies Co., Ltd. | Method for exchanging time synchronization packet and network apparatus |
EP3902164A4 (en) * | 2018-12-18 | 2022-12-07 | China Mobile Communication Co., Ltd. Research Institute | Method for determining port status and network node |
US11463187B2 (en) * | 2020-04-14 | 2022-10-04 | Google Llc | Fault tolerant design for clock-synchronization systems |
US20220393783A1 (en) * | 2020-04-14 | 2022-12-08 | Google Llc | Fault Tolerant Design For Clock-Synchronization Systems |
US11799577B2 (en) * | 2020-04-14 | 2023-10-24 | Google Llc | Fault tolerant design for clock-synchronization systems |
Also Published As
Publication number | Publication date |
---|---|
CN103428086B (en) | 2016-08-03 |
DE112012004227B4 (en) | 2019-06-27 |
CN103428086A (en) | 2013-12-04 |
US9363206B2 (en) | 2016-06-07 |
DE112012004227T5 (en) | 2014-07-10 |
WO2013174025A1 (en) | 2013-11-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9363206B2 (en) | Method and apparatus for selecting passive port of transparent clock node based on PTP | |
US9577774B2 (en) | Time synchronization method and system | |
US20130227008A1 (en) | Clock synchronization based on predefined grandmaster | |
EP3140932B1 (en) | A method for robust ptp synchronization with default 1588v2 profile | |
EP2688240B1 (en) | Method, system and device for switching and selecting clock source device | |
US9882704B2 (en) | Method and apparatus to add new system functions to deployed network element using smart transceivers | |
US9749073B2 (en) | Clock recovery in a packet based network | |
RU2638645C2 (en) | Method for identification of reference clock signals subjected to asymmetry changes to delay propagation path between nodes in communication network | |
US20160080100A1 (en) | Method for precision time protocol synchronization network and apparatus | |
KR20180035145A (en) | Error detection in communication networks | |
EP3352392B1 (en) | Time synchronization packet processing method and device | |
JP2012209791A (en) | Network node, time synchronization method, and network system | |
US20180198698A1 (en) | Distributed database for synchronizing the accessibility of nodes and shared devices | |
WO2013152700A1 (en) | Clock source selection method and device for microwave network element | |
CN101616163A (en) | Precise time transfer protocol message processing method and device | |
CN101848193B (en) | Method, system and network node for network synchronization | |
CN102158335B (en) | Method and device for processing time synchronization port | |
Zarick et al. | Transparent clocks vs. enterprise ethernet switches | |
CN102457346A (en) | Time synchronization implementation method and clock node | |
CN105281885A (en) | Time synchronization method and device used for network equipment and time synchronization server | |
US9325442B2 (en) | Externally connected time port changeover method and device | |
JP6326468B2 (en) | Time synchronization method for passive optical network | |
CN108462548B (en) | Time synchronization method and device | |
Han et al. | A software-defined time synchronization solution in transport networks | |
US20160309435A1 (en) | Segment synchronization method for network based display |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
AS | Assignment |
Owner name: KYLAND TECHNOLOGY CO.,LTD, CHINA Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNORS:MA, HUAYI;XUE, BAIHUA;HUANG, JIANCHAO;REEL/FRAME:032762/0849 Effective date: 20140120 |
|
STCF | Information on status: patent grant |
Free format text: PATENTED CASE |
|
FEPP | Fee payment procedure |
Free format text: PAYOR NUMBER ASSIGNED (ORIGINAL EVENT CODE: ASPN); ENTITY STATUS OF PATENT OWNER: SMALL ENTITY |
|
MAFP | Maintenance fee payment |
Free format text: PAYMENT OF MAINTENANCE FEE, 4TH YR, SMALL ENTITY (ORIGINAL EVENT CODE: M2551); ENTITY STATUS OF PATENT OWNER: SMALL ENTITY Year of fee payment: 4 |
|
MAFP | Maintenance fee payment |
Free format text: PAYMENT OF MAINTENANCE FEE, 8TH YR, SMALL ENTITY (ORIGINAL EVENT CODE: M2552); ENTITY STATUS OF PATENT OWNER: SMALL ENTITY Year of fee payment: 8 |