WO2009000211A1 - Method, network device and network system for network clock tracing - Google Patents

Method, network device and network system for network clock tracing Download PDF

Info

Publication number
WO2009000211A1
WO2009000211A1 PCT/CN2008/071455 CN2008071455W WO2009000211A1 WO 2009000211 A1 WO2009000211 A1 WO 2009000211A1 CN 2008071455 W CN2008071455 W CN 2008071455W WO 2009000211 A1 WO2009000211 A1 WO 2009000211A1
Authority
WO
WIPO (PCT)
Prior art keywords
network device
clock
clock tracking
path
tracking path
Prior art date
Application number
PCT/CN2008/071455
Other languages
French (fr)
Chinese (zh)
Inventor
Junjie Feng
Yu Wang
Min Zhao
Kuiwen Ji
Xinghua Shi
Baoquan Rao
Original Assignee
Huawei Technologies Co., Ltd.
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co., Ltd. filed Critical Huawei Technologies Co., Ltd.
Publication of WO2009000211A1 publication Critical patent/WO2009000211A1/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04JMULTIPLEX COMMUNICATION
    • H04J3/00Time-division multiplex systems
    • H04J3/02Details
    • H04J3/14Monitoring arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04JMULTIPLEX COMMUNICATION
    • H04J3/00Time-division multiplex systems
    • H04J3/02Details
    • H04J3/06Synchronising arrangements
    • H04J3/0635Clock or time synchronisation in a network
    • H04J3/0679Clock or time synchronisation in a network by determining clock distribution path in a network

Definitions

  • Network clock tracking method Network device and network system
  • the present invention relates to the field of communications technologies, and in particular, to a network clock tracking method, a network device, and a network system.
  • the clock is a very important factor because it is directly related to the quality of the transmitted service. If there is a problem with the clock, it will cause the pointer adjustment of the Synchronous Digital System (SDH) to change, and the data stream will be slipped and damaged, resulting in data errors. Therefore, it is necessary to ensure clock synchronization of the devices on the entire network, and to ensure fast switching of clock tracking of network devices of the entire network after the topology of the network changes and the network is initialized.
  • SDH Synchronous Digital System
  • the clock tracking operation can be completed by using the Synchronization Status Message (SSM) protocol.
  • SSM Synchronization Status Message
  • the topology of the ring network and the chain network gradually evolved into the topology of the mesh network (MESH network).
  • MESH network the SSM protocol does not start due to its functional limitations. Adapt to the development of transmission networks.
  • the traditional clock tracing technology all network devices are required to configure the priority table of the corresponding reference clock source according to the clock tracing condition, and at the same time configure two reference clock sources for each network device, one of which is used as protection.
  • the traditional clock tracking technology has two main problems:
  • Embodiments of the present invention provide a method for network clock tracking, a network device, and a network system. When a topology of a network changes and a network is initialized, each network device in the network can perform clock tracking quickly.
  • a method for network clock tracking including:
  • a network device comprising:
  • a calculation module configured to calculate a shortest path to the network device directly connected to the clock source, and use the shortest path as a clock tracking path;
  • a determining module configured to determine whether the clock tracking path is changed
  • a sending module configured to send a request message to an adjacent upstream network device on the clock tracking path when the clock tracking path changes
  • a receiving processing module configured to receive a response message returned by the neighboring upstream network device, and perform clock tracking according to the response message.
  • a network system includes at least one network device directly connected to a clock source, a first network device, and a second network device, where the second network device is an adjacent upstream network device of the first network device;
  • the network device directly connected to the clock source is configured to calculate a shortest path to a clock source connected thereto, and use the shortest path as a clock tracking path;
  • the first network device is configured to calculate a maximum number of network devices that are directly connected to the clock source. a short path, and the shortest path is used as a clock tracking path, and when the clock tracking path changes, sending a request message to the second network device;
  • the second network device is configured to receive a request message sent by the first network device, and return a response message to the first network device when the clock tracking path of the second network device is determined;
  • the first network device is further configured to receive a response message returned by the second network device, and perform clock tracking according to the response message.
  • a computer program product comprising a set of instructions, the sequence of instructions being executed by a network device comprising the steps of:
  • each network device in the network can perform fast clock tracking according to the response message, and implement a fast clock. Switching, and using a serial mechanism ensures that the clock tracking path does not loop.
  • the present invention overcomes the complicated clock tracking path planning problem in the conventional clock tracking technology, and can quickly and automatically establish a new clock tracking path in the case of a change in the network topology.
  • FIG. 1 is a schematic diagram of a clock tracking path in a case where a network uses a clock source according to an embodiment of the present invention
  • FIG. 2 is a schematic diagram of a clock tracking path after a link failure occurs in a network according to an embodiment of the present invention
  • FIG. 3 is a schematic diagram of a clock tracking path when a network uses two clock sources according to an embodiment of the present invention
  • Intention is a schematic diagram of the tracking path;
  • FIG. 5 is a flowchart of a method for clock tracking according to an embodiment of the present invention.
  • FIG. 6 is a schematic structural diagram of a network device according to an embodiment of the present invention.
  • Step 501 The network device calculates a clock tracking path of the network device, where the topology of the network changes or the network During initialization, the network device determines the network topology change and obtains the corresponding algorithm (such as the shortest path first algorithm, the minimum spanning tree algorithm, etc.), and the clock tracking path is from the network device directly connected to the clock source to the network device.
  • the shortest path, which determines the network topology change can be achieved by receiving the network topology change message.
  • Step 502 The network device determines whether the clock tracking path of the network device is changed, specifically, whether the calculated clock tracking path is consistent with the original clock tracking path of the network device. If not, proceed to step 503. If they are consistent, enter Step 505.
  • Step 503 The network device sends a request message to the neighboring upstream network device on the clock tracking path calculated by step 501.
  • the request message carries the information of the clock tracking path between the neighboring upstream network device and the network device directly connected to the clock source calculated by the network device, and the clock tracking path calculated in step 501 removes the network device itself, that is, Clock tracking path of adjacent upstream network devices.
  • the neighboring upstream network device After receiving the request message, the neighboring upstream network device sends the response message to the network device if its clock tracking path is determined.
  • the clock tracking path of the adjacent upstream network device is determined, specifically, the clock tracking path is not changed, or although its clock tracking path changes, its new clock tracking path has been determined and established.
  • the adjacent upstream network device determines the clock of the adjacent upstream network device according to the clock tracking path of the received request message and the original clock tracking path of the adjacent upstream network device. Whether the trace path changes.
  • the specific clock tracking path has been determined and established as follows: After sending a request message to the neighboring upstream network device on the clock tracking path where the adjacent upstream network device is located, the response message returned by the neighboring upstream network device is received. And performing clock tracking according to the response message.
  • Step 504 The network device receives the response message returned by the neighboring upstream network device, and performs clock tracking according to the response message. At this time, the new clock tracking path of the network device is successfully established.
  • Step 505 The network device then determines whether the request message of its neighboring downstream network device is received. If yes, the process proceeds to step 506, otherwise the network device has no further action.
  • Step 506 The network device sends a response message to its neighboring downstream network device, and the downstream network device performs clock tracking according to the response message.
  • each network device After receiving the network topology change message, each network device performs a certain delay (for example, 5 seconds) before performing clock tracking. The calculation of the path.
  • the network device in the network and the adjacent upstream network device on the clock tracking path where the network device is located may be an SDH optical transmission device, a wavelength division multiplexing (WDM) optical transmission device, or a synchronous optical network ( Synchronous Opt ica l Network , SONET ) Network equipment such as optical transmission equipment.
  • SDH optical transmission device a wavelength division multiplexing (WDM) optical transmission device
  • WDM wavelength division multiplexing
  • SONET Synchronous Opt ica l Network
  • Network equipment such as optical transmission equipment.
  • the fast tracking method of the request-response mechanism in the embodiment of the present invention can automatically and quickly determine the clock tracking path of each network device in the network when the topology of the network changes and the network is initialized.
  • the clock automatically switches and tracks automatically, which overcomes the problem that it is difficult to plan a suitable clock tracking path in the traditional clock tracking technology and it is difficult to automatically calculate a new tracking path after the network topology changes.
  • the network device carries the information of the clock tracking path of the neighboring upstream network device in the request message, the neighboring upstream network device can select the clock tracking path in the request message and the clock tracking path obtained by the adjacent upstream network device. In comparison, it is determined whether the two clock tracking paths are consistent. When the two are consistent, the adjacent upstream network device sends a response message to the network device, and a request-response serial mechanism is provided, thereby ensuring the network. There is no clock tracking loop in the middle.
  • each network device can determine that the network device is not being used by the network device when tracking a network device by using the method of the embodiment of the present invention. In turn, tracking can also avoid the occurrence of clock interlocks.
  • a clock tracking path as shown by the arrow in Fig. 1 is formed, and the arrow points to the downstream network device of the entire network clock tracking tree.
  • the clock tracking tree is obtained by the network device after receiving the message that the network topology changes, and is calculated by a corresponding algorithm (such as a shortest path first algorithm, a minimum spanning tree algorithm, etc.).
  • a corresponding algorithm such as a shortest path first algorithm, a minimum spanning tree algorithm, etc.
  • the A, C, D, and F network devices in the figure calculate the clock tracking path of the network device. If no change is found, the device does not need to send a request message to the respective upstream network device.
  • the B, E, G, and H network devices calculate the clock tracking path of the local network device and find that the clock tracking path changes. Therefore, the network device sends a request message to the respective upstream network device.
  • the request message includes the calculated information of the clock tracking path of the upstream network device of each network device to the network device A directly connected to the clock source.
  • the clock tracking path of the network device does not change, and the clock of the network device to the A carried in the request message is found. If the tracking path is consistent with the clock tracking path saved by the network device, the response message is sent to the node that sends the request message, and the B, E, and G network devices perform clock tracing according to the response message.
  • the E network device receives the request message of the H network device, the clock tracking path of the network device changes, and the response message of the upstream network device F is not received, and the clock is tracked, so the response cannot be sent to H temporarily.
  • Message After E receives the response message from F, E performs clock tracking according to the response message, and E sends a response message to H, so that H should send according to E. Answer the message for clock tracking.
  • the method of the embodiment of the present invention can also be taken to form an initial clock tracking path and perform corresponding clock tracking.
  • the above embodiment is proposed for a network connected to a clock source. If the network connection has two or more clock sources of the same quality level and priority, the clock tracker can be automatically formed by using the method of the embodiment of the present invention. network. If there is a network device in the network, and the shortest path of the network device to the at least two clock sources accessing the network device is the same, the network device selects a clock source to access the network device tracking. This will be further explained below in conjunction with Figs. 3 and 4.
  • the network device selects the network device directly connected to the clock source with the highest clock quality level to track; if the entire network is connected to multiple clock sources with the same clock quality level, The network device selects the network device directly connected to the clock source with the highest priority to track. If the entire network is connected to multiple clock sources with the same clock quality level and priority, the network device compares the network device to the network connected to these clock sources. The shortest path of the device, and select the one with the shortest path to track; if all of the above are the same, you can further distinguish between the rules that can produce a unique result, for example, which network device is directly connected to the clock source If the node ID is small, which device is tracked.
  • each network device calculates the network device to the network device directly connected to the clock source (see network device A and network device J in the figure).
  • the shortest path of the ) forms a clock tracking path as indicated by the arrow in FIG.
  • the E network device has the same shortest path to A and J.
  • the arbitration mechanism is selected to select the clock source of the tracking. For example, in this embodiment, E preferentially selects a network device (ie, network device A) connected to a clock source with a smaller number to perform tracking.
  • the G network device and the I network device do similar processing. Thus the clock tracking path of the entire network is formed. Use this on this basis
  • the method of the embodiment of the invention can realize fast clock tracking between network devices of the entire network.
  • the method of the embodiment of the present invention can form a clock tracking tree of the network device as shown in FIG. 4 and the clock source connected to the clock source 2 to access the network device J, as shown in FIG. Shown.
  • the software implementing the method of the present invention for clock tracking can be stored in a computer readable medium.
  • the software executes, it includes the following steps:
  • the readable medium can be: ROM/RAM, disk, or optical disk, and the like.
  • Embodiments of the present invention also provide a network device.
  • the network device includes a calculation module, a determination module, a transmission module, and a reception processing module.
  • the calculation module 61 is configured to determine a network topology change and calculate a clock tracking path of the network device.
  • the determining the network topology change includes receiving the network topology change message, and the network device calculates the clock tracking path of the network device, which can be obtained by using a corresponding algorithm (such as a shortest path first algorithm, a minimum spanning tree algorithm, etc.), where the clock tracking path is The shortest path from the clock source to the network device to the network device.
  • a corresponding algorithm such as a shortest path first algorithm, a minimum spanning tree algorithm, etc.
  • the determining module 62 is configured to compare the acquired clock tracking path with the original clock tracking path to determine whether the clock tracking path of the network device changes.
  • the sending module 63 is configured to: when the clock tracking path changes, the network device sends a request message to the neighboring upstream network device on the clock tracking path, where the request message includes information of a clock tracking path of the adjacent upstream network device.
  • the sending module 63 is further configured to use a clock tracking path of the network device. When determined, a reply message is sent to an adjacent downstream network device on the clock tracking path of the network device.
  • the clock tracking path is determined, specifically, the clock tracking path of the network device is unchanged, or although the clock tracking path of the network device changes, its new clock tracking path has been determined and established.
  • the above new clock tracking path has been determined and established as follows: A response message returned by a neighboring upstream network device on its clock tracking path is received, and clock tracking is performed according to the response message. If the returned response message is not received, the network device waits until a response message is received, and after the clock is tracked according to the response message, the response message is sent to the neighboring downstream network device.
  • the receiving processing module 64 is configured to receive a response message returned by the neighboring upstream network device, and perform clock tracking according to the response message, that is, the clock of the network device can track the clock of the adjacent upstream network device.
  • the receiving processing module is further configured to receive a request message sent by the neighboring downstream network device on the clock tracking path of the network device to the network device, where the request message includes information of a clock tracking path of the network device.
  • the clock source access network device may be an SDH optical transmission device, wavelength division multiplexing (Wave) Length Divi s ion Mul t iplex, WDM ) Optical transmission equipment, optical synchronization network (Synchronous Opt ica l Ne twork, SONET) optical transmission equipment and other network equipment.
  • SDH optical transmission device wavelength division multiplexing (Wave) Length Divi s ion Mul t iplex, WDM )
  • WDM wavelength division multiplexing
  • WDM wavelength division multiplexing
  • Optical transmission equipment Optical transmission equipment
  • optical synchronization network Synchronous Opt ica l Ne twork, SONET
  • the network devices in the network when the topology of the network changes and when the network is initialized, automatically track the clock according to the response message, and implement automatic clock switching. And tracking, overcoming the difficulty of planning a suitable clock tracking path in traditional clock tracking techniques.
  • the request message contains the clock tracking path of the adjacent upstream network device on its clock tracking path, a strict request-response serial mechanism is used, so that the clock tracking loop can be effectively prevented.
  • An embodiment of the present invention further provides a network system, including at least one network device directly connected to a clock source, a first network device, and a second network device, where the second network device is a first network Adjacent upstream network device of the network device;
  • the first network device and the second network device respectively calculate clock tracking paths of the network devices directly connected to the clock source.
  • the network device directly connected to the clock source further receives the request message sent by the other network device, and sends a response message to the other network device.
  • the first network device is configured to obtain a shortest path to the network device directly connected to the clock source, and use the shortest path as a clock tracking path, and when the clock tracking path changes, to the second network device Sending a request message, the second network device returns a response message to the first network device when its clock tracking path is determined.
  • the clock tracking path of the second network device is determined by: the second network device discovering that its clock tracking path has not changed, or although a change has occurred, a new clock tracking path has been determined and established.
  • the first network device receives a response message returned by the second network device, and performs clock tracking according to the response message.
  • the specific process of the above clock can be understood as follows: When a network device determines that the clock path of the network device changes, it sends a request message to the neighboring upstream node of the network device on the new clock tracking path, and If the upstream node finds that the clock tracking path of the network device has also changed, the same action is taken until the request message reaches a certain network device. The network device finds that the clock tracking path of the network device has not changed, or although it has occurred. Change, but the new clock tracking path has been determined and established, and a response message is sent to the downstream node. The downstream node establishes a clock tracking path for clock tracking according to the information in the response message.
  • the clock tracking path is the shortest path from the clock source to the network device to the network device.
  • An adjacent upstream network device located on a clock tracking path of the network device, including a network device directly connected to the clock source.
  • the request message includes information of a clock tracking path of the network device.
  • the neighboring upstream network device receives the request message and sends a response message to the network device if its clock tracking path is determined.
  • the clock tracking path determination means that the clock tracking path of the adjacent upstream network device has not changed; or although the clock tracking path of the network device changes, its new clock tracking path has been determined and built. Standing.
  • the first network device, the second network device, and the network device directly connected to the clock source, and other network devices in the network system may be network devices such as an SDH optical transmission device, a WDM optical transmission device, and a SONET optical transmission device. .
  • the network devices in the network automatically and automatically track the clock according to the response message, thereby realizing automatic clock switching and Tracking overcomes the difficulty of planning a suitable clock tracking path in traditional clock tracking techniques.
  • the request message carries the information of the clock tracking path of its neighboring network device, a strict request-response serial mechanism is used, so that the generation of the clock tracking loop can be effectively prevented.

Abstract

A method, a network device and a network system are disclosed. The clock tracing path of the network device in the network is computed. If the clock tracing path of the network device changes, a request message is sent to the uplink neighbour network device on the clock tracing path of said network device. Then a response message from the uplink neighbor network device is received, and clock tracing is performed based on the response message. Fast clock handover and clock tracing can be achieved through above implementation.

Description

网络时钟跟踪的方法、 网络设备和网络系统 技术领域  Network clock tracking method, network device and network system
本发明涉及通讯技术领域, 尤其涉及一种网络时钟跟踪的方法、 网络设 备和网络系统。  The present invention relates to the field of communications technologies, and in particular, to a network clock tracking method, a network device, and a network system.
背景技术 Background technique
在通信网络中, 时钟是非常重要的一个因素, 因为它直接关系到所传送 业务的质量。 如果时钟出现问题, 轻则导致同步数字体系 (Synchronous Dig i ta l H ierarchy, SDH ) 的指针调整变化, 重则导致数据流滑动损伤, 造 成数据出错。 因此需要保证全网设备的时钟同步, 并且在网络的拓朴结构发 生变化后和网络初始化时, 需要保证全网各网络设备的时钟跟踪的快速切换。  In a communication network, the clock is a very important factor because it is directly related to the quality of the transmitted service. If there is a problem with the clock, it will cause the pointer adjustment of the Synchronous Digital System (SDH) to change, and the data stream will be slipped and damaged, resulting in data errors. Therefore, it is necessary to ensure clock synchronization of the devices on the entire network, and to ensure fast switching of clock tracking of network devices of the entire network after the topology of the network changes and the network is initialized.
在传统网络中, 由于网络的拓朴结构比较简单, 主要为环型网和链型网 结构, 釆用同步状态消息 (Synchroni za t ion S ta tus Mes sage , SSM )协议即 可以完成时钟跟踪操作。 但是随着传输网络的发展, 环型网和链型网的拓朴 结构逐步发展为网状网络(MESH网络) 的拓朴结构, 而在 MESH网络中, SSM 协议由于其功能的局限, 开始不适应传输网络的发展。  In the traditional network, because the topology of the network is relatively simple, mainly for the ring network and the chain network structure, the clock tracking operation can be completed by using the Synchronization Status Message (SSM) protocol. . However, with the development of the transmission network, the topology of the ring network and the chain network gradually evolved into the topology of the mesh network (MESH network). In the MESH network, the SSM protocol does not start due to its functional limitations. Adapt to the development of transmission networks.
在传统的时钟跟踪技术中, 要求所有的网络设备按照时钟跟踪情况配置 相应的参考时钟源的优先级表, 并且同时为每个网络设备配置两个参考时钟 源, 其中一个作为保护。 而在 MESH网络中, 传统的时钟跟踪技术存在两个主 要的问题:  In the traditional clock tracing technology, all network devices are required to configure the priority table of the corresponding reference clock source according to the clock tracing condition, and at the same time configure two reference clock sources for each network device, one of which is used as protection. In the MESH network, the traditional clock tracking technology has two main problems:
1、 在 MESH 网络中, 由于和每个网络设备连接的其他网络设备的个数较 传统的环型网和链型网更多, 一般大于两个, 在这样的情况下难以人工规划 出合适的时钟跟踪路径。  1. In the MESH network, since the number of other network devices connected to each network device is more than that of the traditional ring network and chain network, generally more than two, in such a situation, it is difficult to manually plan a suitable one. Clock tracking path.
2、 大部分网络设备只能配置两个参考时钟源作为保护, 当网络设备所配 置的参考时钟源都失效的时候, 该网络设备就无法找到可以跟踪的时钟源。 发明内容 本发明的实施例提供了一种网络时钟跟踪的方法、 网络设备和网络系统 , 在网络的拓朴结构发生变化和网络初始化的时候, 网络中的各个网络设备能 快速进行时钟跟踪。 2. Most network devices can only be configured with two reference clock sources as protection. When the reference clock source configured by the network device fails, the network device cannot find the clock source that can be tracked. Summary of the invention Embodiments of the present invention provide a method for network clock tracking, a network device, and a network system. When a topology of a network changes and a network is initialized, each network device in the network can perform clock tracking quickly.
本发明的实施例通过如下技术方案实现:  Embodiments of the present invention are implemented by the following technical solutions:
一种网络时钟跟踪的方法, 包括:  A method for network clock tracking, including:
计算到达与时钟源直接相连的网络设备的最短路径, 并将所述最短路径 作为时钟跟踪路径;  Calculating a shortest path to the network device directly connected to the clock source, and using the shortest path as a clock tracking path;
判断所述时钟跟踪路径是否改变;  Determining whether the clock tracking path is changed;
如果所述时钟跟踪路径改变, 则向所述时钟跟踪路径上的相邻上游网络 设备发送请求消息;  Sending a request message to an adjacent upstream network device on the clock tracking path if the clock tracking path changes;
接收所述相邻上游网络设备返回的应答消息, 并根据所述应答消息进行 时钟艮踪。  Receiving a response message returned by the adjacent upstream network device, and performing clock tracing according to the response message.
一种网络设备, 其特征在于, 包括:  A network device, comprising:
计算模块, 用于计算到达与时钟源直接相连的网络设备的最短路径, 并 将所述最短路径作为时钟跟踪路径;  a calculation module, configured to calculate a shortest path to the network device directly connected to the clock source, and use the shortest path as a clock tracking path;
判断模块, 用于判断所述时钟跟踪路径是否改变;  a determining module, configured to determine whether the clock tracking path is changed;
发送模块, 用于当所述时钟跟踪路径改变时, 向所述时钟跟踪路径上的 相邻上游网络设备发送请求消息; 以及  a sending module, configured to send a request message to an adjacent upstream network device on the clock tracking path when the clock tracking path changes;
接收处理模块, 用于接收所述相邻上游网络设备返回的应答消息, 并根 据所述应答消息进行时钟跟踪。  And a receiving processing module, configured to receive a response message returned by the neighboring upstream network device, and perform clock tracking according to the response message.
一种网络系统, 包括至少一个与时钟源直接相连的网络设备、 第一网络 设备和第二网络设备, 所述第二网络设备为第一网络设备的相邻上游网络设 备;  A network system includes at least one network device directly connected to a clock source, a first network device, and a second network device, where the second network device is an adjacent upstream network device of the first network device;
所述与时钟源直接相连的网络设备用于计算到达与其相连的时钟源的最 短路径, 并将该最短路径作为时钟跟踪路径;  The network device directly connected to the clock source is configured to calculate a shortest path to a clock source connected thereto, and use the shortest path as a clock tracking path;
所述第一网络设备用于计算到达所述与时钟源直接相连的网络设备的最 短路径 , 并将所述最短路径作为时钟跟踪路径 , 当所述时钟跟踪路径改变时 , 向所述第二网络设备发送请求消息; The first network device is configured to calculate a maximum number of network devices that are directly connected to the clock source. a short path, and the shortest path is used as a clock tracking path, and when the clock tracking path changes, sending a request message to the second network device;
所述第二网络设备用于接收第一网络设备发送的请求消息, 并在第二网 络设备的时钟跟踪路径确定时, 向所述第一网络设备返回应答消息;  The second network device is configured to receive a request message sent by the first network device, and return a response message to the first network device when the clock tracking path of the second network device is determined;
所述第一网络设备还用于接收所述第二网络设备返回的应答消息, 并根 据所述应答消息进行时钟跟踪。  The first network device is further configured to receive a response message returned by the second network device, and perform clock tracking according to the response message.
一种计算机程序产品, 包括一组指令序列, 该指令序列被网络设备执行 时包括如下步骤:  A computer program product comprising a set of instructions, the sequence of instructions being executed by a network device comprising the steps of:
计算到达与时钟源直接相连的网络设备的最短路径, 并将所述的最短路 径作为时钟跟踪路径;  Calculating a shortest path to the network device directly connected to the clock source, and using the shortest path as the clock tracking path;
判断所述时钟跟踪路径是否改变;  Determining whether the clock tracking path is changed;
如果所述时钟跟踪路径改变, 则向所述时钟跟踪路径上的相邻上游网络 设备发送请求消息;  Sending a request message to an adjacent upstream network device on the clock tracking path if the clock tracking path changes;
接收所述相邻上游网络设备返回的应答消息, 并根据所述应答消息进行 时钟艮踪。  Receiving a response message returned by the adjacent upstream network device, and performing clock tracing according to the response message.
由上述本发明的实施例提供的具体实施方案可以看出, 其能够实现在网 络的拓朴结构发生变化和网络初始化以后, 网络中各网络设备能够根据应答 消息进行快速的时钟跟踪, 实现时钟快速切换, 并且使用串行机制保证了时 钟跟踪路径不会成环。 这样, 本发明克服了传统的时钟跟踪技术中复杂的时 钟跟踪路径规划问题, 并能够在网络拓朴发生改变的情况下, 快速自动建立 新的时钟跟踪路径。  It can be seen from the specific implementation provided by the foregoing embodiments of the present invention that after the topology of the network changes and the network is initialized, each network device in the network can perform fast clock tracking according to the response message, and implement a fast clock. Switching, and using a serial mechanism ensures that the clock tracking path does not loop. Thus, the present invention overcomes the complicated clock tracking path planning problem in the conventional clock tracking technology, and can quickly and automatically establish a new clock tracking path in the case of a change in the network topology.
附图说明 DRAWINGS
图 1 为本发明实施例的网络使用一个时钟源的情况下的时钟跟踪路径示 意图;  1 is a schematic diagram of a clock tracking path in a case where a network uses a clock source according to an embodiment of the present invention;
图 2为本发明实施例的网络出现链路故障后的时钟跟踪路径的示意图; 图 3 为本发明实施例的网络使用两个时钟源的情况下的时钟跟踪路径示 意图; 的是中跟踪路径示意图; 2 is a schematic diagram of a clock tracking path after a link failure occurs in a network according to an embodiment of the present invention; FIG. 3 is a schematic diagram of a clock tracking path when a network uses two clock sources according to an embodiment of the present invention; Intention; is a schematic diagram of the tracking path;
图 5为本发明实施例的时钟跟踪的方法流程图;  FIG. 5 is a flowchart of a method for clock tracking according to an embodiment of the present invention; FIG.
图 6为本发明实施例的网络设备的结构示意图。  FIG. 6 is a schematic structural diagram of a network device according to an embodiment of the present invention.
具体实施方式 detailed description
本发明实施例的方法在具体实现过程中表现为:  The method of the embodiment of the present invention is expressed in the specific implementation process as follows:
如图 5所示, 是本发明实施例中时钟跟踪的方法流程图, 实施过程如下: 步骤 501 : 网络设备计算本网络设备的时钟跟踪路径, 具体可以在网络的 拓朴结构发生变化时或者网络初始化时, 网络设备确定网络拓朴变化, 并通 过相应的算法 (如最短路径优先算法、 最小生成树算法等)计算获得, 时钟 跟踪路径是从与时钟源直接相连的网络设备到该网络设备的最短路径, 确定 网络拓朴变化可以通过接收网络拓朴变化消息实现。  As shown in FIG. 5, it is a flowchart of a method for clock tracing in the embodiment of the present invention. The implementation process is as follows: Step 501: The network device calculates a clock tracking path of the network device, where the topology of the network changes or the network During initialization, the network device determines the network topology change and obtains the corresponding algorithm (such as the shortest path first algorithm, the minimum spanning tree algorithm, etc.), and the clock tracking path is from the network device directly connected to the clock source to the network device. The shortest path, which determines the network topology change can be achieved by receiving the network topology change message.
步骤 502: 网络设备判断本网络设备的时钟跟踪路径是否改变, 具体为比 较计算出的时钟跟踪路径与本网络设备原来的时钟跟踪路径是否一致, 如果 不一致, 则进入步骤 503 , 如果一致, 则进入步骤 505。  Step 502: The network device determines whether the clock tracking path of the network device is changed, specifically, whether the calculated clock tracking path is consistent with the original clock tracking path of the network device. If not, proceed to step 503. If they are consistent, enter Step 505.
步骤 503: 网络设备向由步骤 501计算出的时钟跟踪路径上的相邻上游网 络设备发送请求消息。 请求消息中携带网络设备计算出的其相邻上游网络设 备到与时钟源直接相连的网络设备之间的时钟跟踪路径的信息, 在步骤 501 中计算出的时钟跟踪路径去掉网络设备本身, 就是其相邻上游网络设备的时 钟跟踪路径。 相邻上游网络设备接收到该请求消息后, 如果其时钟跟踪路径 确定, 则向所述网络设备发送所述应答消息。 其中相邻上游网络设备的时钟 跟踪路径确定, 具体是指其时钟跟踪路径没有改变, 或者虽然其时钟跟踪路 径发生改变, 但其新的时钟跟踪路径已经确定并建立。  Step 503: The network device sends a request message to the neighboring upstream network device on the clock tracking path calculated by step 501. The request message carries the information of the clock tracking path between the neighboring upstream network device and the network device directly connected to the clock source calculated by the network device, and the clock tracking path calculated in step 501 removes the network device itself, that is, Clock tracking path of adjacent upstream network devices. After receiving the request message, the neighboring upstream network device sends the response message to the network device if its clock tracking path is determined. The clock tracking path of the adjacent upstream network device is determined, specifically, the clock tracking path is not changed, or although its clock tracking path changes, its new clock tracking path has been determined and established.
所述相邻上游网络设备, 根据接收到的请求消息中其时钟跟踪路径和该 相邻上游网络设备原有时钟跟踪路径, 判断所述相邻上游网络设备的时钟跟 踪路径是否改变。 The adjacent upstream network device determines the clock of the adjacent upstream network device according to the clock tracking path of the received request message and the original clock tracking path of the adjacent upstream network device. Whether the trace path changes.
上述时钟跟踪路径已经确定并建立的具体体现为: 向此相邻上游网络设 备所在的时钟跟踪路径上的相邻上游网络设备发送请求消息后, 接收到它的 相邻上游网络设备返回的应答消息, 并根据所述应答消息进行时钟跟踪。  The specific clock tracking path has been determined and established as follows: After sending a request message to the neighboring upstream network device on the clock tracking path where the adjacent upstream network device is located, the response message returned by the neighboring upstream network device is received. And performing clock tracking according to the response message.
步骤 504: 网络设备接收其相邻上游网络设备返回的应答消息, 并根据所 述应答消息进行时钟跟踪, 此时本网络设备新的时钟跟踪路径建立成功。  Step 504: The network device receives the response message returned by the neighboring upstream network device, and performs clock tracking according to the response message. At this time, the new clock tracking path of the network device is successfully established.
步骤 505:然后本网络设备判断是否接收到其相邻下游网络设备的请求消 息, 如果是, 则进入步骤 506 , 否则网络设备没有进一步的动作。  Step 505: The network device then determines whether the request message of its neighboring downstream network device is received. If yes, the process proceeds to step 506, otherwise the network device has no further action.
步骤 506: 网络设备向其相邻下游网络设备发送应答消息, 下游网络设备 根据此应答消息进行时钟跟踪。  Step 506: The network device sends a response message to its neighboring downstream network device, and the downstream network device performs clock tracking according to the response message.
为了避免网络拓朴频繁变化带来的影响, 可以预设一定的延时时间, 每 个网络设备在收到网络拓朴变化消息后, 进行一定的延时(例如 5 秒)后再 进行时钟跟踪路径的计算。  To avoid the impact of frequent network topology changes, you can preset a certain delay time. After receiving the network topology change message, each network device performs a certain delay (for example, 5 seconds) before performing clock tracking. The calculation of the path.
网络中的网络设备和其所在的时钟跟踪路径上的相邻上游网络设备可以 是 SDH 光传输设备、 波分复用 (Wave length Divi s ion Mul t iplex, WDM )光 传输设备、 同步光纤网 (Synchronous Opt ica l Network , SONET ) 光传输设 备等网络设备。  The network device in the network and the adjacent upstream network device on the clock tracking path where the network device is located may be an SDH optical transmission device, a wavelength division multiplexing (WDM) optical transmission device, or a synchronous optical network ( Synchronous Opt ica l Network , SONET ) Network equipment such as optical transmission equipment.
釆用本发明实施例中的请求-应答机制的时钟快速跟踪的方法, 能够实现 在网络的拓朴结构发生变化时和网络初始化时, 网络中各网络设备的时钟跟 踪路径的自动快速确定, 实现时钟自动快速切换和跟踪, 克服了传统的时钟 跟踪技术中难以规划合适的时钟跟踪路径、 并在网络拓朴发生变化后难以自 动计算新的跟踪路径的问题。 并且由于网络设备在请求消息中携带其相邻上 游网络设备的时钟跟踪路径的信息, 从而该相邻上游网络设备能够将请求消 息中的时钟跟踪路径和该相邻上游网络设备获得的时钟跟踪路径相比较, 判 断两种时钟跟踪路径是否一致, 在两者一致的情况下, 该相邻上游网络设备 才会向网络设备发送应答消息, 再加上请求-应答串行机制, 从而保证了网络 中不会出现时钟跟踪环路的出现。 The fast tracking method of the request-response mechanism in the embodiment of the present invention can automatically and quickly determine the clock tracking path of each network device in the network when the topology of the network changes and the network is initialized. The clock automatically switches and tracks automatically, which overcomes the problem that it is difficult to plan a suitable clock tracking path in the traditional clock tracking technology and it is difficult to automatically calculate a new tracking path after the network topology changes. And because the network device carries the information of the clock tracking path of the neighboring upstream network device in the request message, the neighboring upstream network device can select the clock tracking path in the request message and the clock tracking path obtained by the adjacent upstream network device. In comparison, it is determined whether the two clock tracking paths are consistent. When the two are consistent, the adjacent upstream network device sends a response message to the network device, and a request-response serial mechanism is provided, thereby ensuring the network. There is no clock tracking loop in the middle.
另外, 由于时钟互锁的形成是产生时钟跟踪环路的特殊情况, 因此釆用 本发明实施例的方法, 每个网络设备能够判断本网络设备在跟踪某个网络设 备时, 不被该网络设备反过来跟踪, 亦可避免时钟互锁的出现。  In addition, since the formation of the clock interlock is a special case of generating a clock tracking loop, each network device can determine that the network device is not being used by the network device when tracking a network device by using the method of the embodiment of the present invention. In turn, tracking can also avoid the occurrence of clock interlocks.
为便于对本发明实施例的方法进一步理解, 下面将结合图 1和图 2就本 发明实施例的方法进行详细的描述。  In order to facilitate a further understanding of the method of the embodiments of the present invention, the method of the embodiments of the present invention will be described in detail below with reference to FIGS. 1 and 2.
假设网络初始化后, 形成了如图 1 箭头所示的时钟跟踪路径, 箭头指向 全网时钟跟踪树的下游网络设备。 时钟跟踪树是网络设备收到网络拓朴发生 变化的消息后, 通过相应的算法(如最短路径优先算法、 最小生成树算法等) 计算获得。 当 A-B和 D-G之间链路中断后, 各网络设备收到网络拓朴发生变 化的消息。 经过一定的延时(例如 5秒)后, 重新计算出如图 2所示的时钟 跟踪路径, 如图中箭头所示。 图中的 A、 C、 D、 F网络设备收到网络拓朴变化 消息后计算本网络设备的时钟跟踪路径, 发现没有变化, 则不用向各自的上 游网络设备发送请求消息。 B、 E、 G、 H 网络设备收到网络拓朴变化消息后计 算其本网络设备的时钟跟踪路径, 发现时钟跟踪路径发生变化, 因此分别向 各自的上游网络设备发送请求消息。 所述请求消息中包括计算出的各网络设 备的上游网络设备到与时钟源直接相连的网络设备 A的时钟跟踪路径的信息。 其中 B的上游网络设备 C , 以及 E和 G的上游网络设备 F收到请求消息后, 由 于本网络设备的时钟跟踪路径没有变化, 并且发现所述请求消息中携带的本 网络设备到 A 的时钟跟踪路径和本网络设备保存的时钟跟踪路径一致, 则向 发送请求消息的节点发送应答消息, 由此 B、 E、 G 网络设备根据应答消息进 行时钟艮踪。  It is assumed that after the network is initialized, a clock tracking path as shown by the arrow in Fig. 1 is formed, and the arrow points to the downstream network device of the entire network clock tracking tree. The clock tracking tree is obtained by the network device after receiving the message that the network topology changes, and is calculated by a corresponding algorithm (such as a shortest path first algorithm, a minimum spanning tree algorithm, etc.). When the link between A-B and D-G is interrupted, each network device receives a message that the network topology has changed. After a certain delay (for example, 5 seconds), recalculate the clock tracking path as shown in Figure 2, as indicated by the arrow in the figure. After receiving the network topology change message, the A, C, D, and F network devices in the figure calculate the clock tracking path of the network device. If no change is found, the device does not need to send a request message to the respective upstream network device. After receiving the network topology change message, the B, E, G, and H network devices calculate the clock tracking path of the local network device and find that the clock tracking path changes. Therefore, the network device sends a request message to the respective upstream network device. The request message includes the calculated information of the clock tracking path of the upstream network device of each network device to the network device A directly connected to the clock source. After the upstream network device C of B and the upstream network device F of the E and the G receive the request message, the clock tracking path of the network device does not change, and the clock of the network device to the A carried in the request message is found. If the tracking path is consistent with the clock tracking path saved by the network device, the response message is sent to the node that sends the request message, and the B, E, and G network devices perform clock tracing according to the response message.
但是 E网络设备在收到 H网络设备的请求消息时, 由于本网络设备的时 钟跟踪路径变化, 并且没有收到其上游网络设备 F 的应答消息, 进行时钟跟 踪, 所以暂时还不能向 H发送应答消息。 等到 E收到 F的应答消息, E的根据 该应答消息进行时钟跟踪后, E再向 H发送应答消息, 从而 H根据 E发送的应 答消息进行时钟跟踪。 However, when the E network device receives the request message of the H network device, the clock tracking path of the network device changes, and the response message of the upstream network device F is not received, and the clock is tracked, so the response cannot be sent to H temporarily. Message. After E receives the response message from F, E performs clock tracking according to the response message, and E sends a response message to H, so that H should send according to E. Answer the message for clock tracking.
在网络初始化的时候, 也可以釆取本发明实施例的方法, 形成初始的时 钟跟踪路径, 并进行相应的时钟跟踪。  At the time of network initialization, the method of the embodiment of the present invention can also be taken to form an initial clock tracking path and perform corresponding clock tracking.
上述实施例是针对连接有一个时钟源的网络提出的, 如果网络连接有两 个或两个以上的质量等级和优先级一样的时钟源, 使用本发明实施例的方法, 能够自动形成时钟跟踪子网。 如果网络中存在网络设备, 网络设备到至少两 个时钟源接入网络设备的最短路径相同, 则所述网络设备选择一个时钟源接 入网络设备跟踪。 下面将结合图 3和图 4进一步说明。  The above embodiment is proposed for a network connected to a clock source. If the network connection has two or more clock sources of the same quality level and priority, the clock tracker can be automatically formed by using the method of the embodiment of the present invention. network. If there is a network device in the network, and the shortest path of the network device to the at least two clock sources accessing the network device is the same, the network device selects a clock source to access the network device tracking. This will be further explained below in conjunction with Figs. 3 and 4.
关于网络设备选择怎样的时钟源进行跟踪, 可以釆取一定的仲裁机制, 这些仲裁机制在不同的情况下可以不同。  Regarding which clock source is selected by the network device for tracking, a certain arbitration mechanism can be obtained. These arbitration mechanisms can be different under different circumstances.
如果全网连接多个时钟源, 且它们的时钟质量等级不同, 网络设备选择 和时钟质量等级最高的时钟源直接相连的网络设备进行跟踪; 如果全网连接 多个时钟质量等级相同的时钟源, 网络设备选择和优先级最高的时钟源直接 相连的网络设备进行跟踪; 如果全网连接多个时钟质量等级和优先级都相同 的时钟源, 网络设备比较本网络设备到与这些时钟源相连的网络设备的最短 路径, 并选择最短路径较小的那条进行跟踪; 如果上述所有都相同, 可釆用 一些能够产生唯一结果的规则进行进一步的区分, 例如, 哪个与时钟源直接 相连的网络设备的节点标识较小, 则跟踪哪个设备。  If multiple clock sources are connected to the entire network, and their clock quality levels are different, the network device selects the network device directly connected to the clock source with the highest clock quality level to track; if the entire network is connected to multiple clock sources with the same clock quality level, The network device selects the network device directly connected to the clock source with the highest priority to track. If the entire network is connected to multiple clock sources with the same clock quality level and priority, the network device compares the network device to the network connected to these clock sources. The shortest path of the device, and select the one with the shortest path to track; if all of the above are the same, you can further distinguish between the rules that can produce a unique result, for example, which network device is directly connected to the clock source If the node ID is small, which device is tracked.
下面的举例涉及到的仲裁机制属于最后一种。  The arbitration mechanism involved in the following examples is the last one.
如图 3所示, 时钟源 1和时钟源 1的 SSM质量等级和优先级相同, 各网 络设备计算本网络设备到与时钟源直接相连的网络设备(见图中的网络设备 A 和网络设备 J )的最短路径, 形成如图 3中箭头所示的时钟跟踪路径。 图中的 E网络设备到 A和 J的最短路径相同,则在确定该网络设备的时钟跟踪路径时, 釆取仲裁机制, 选择其跟踪的时钟源。 例如在本实施例中, E优先选择和编号 较小的时钟源连接的网络设备 (即网络设备 A )进行跟踪。 G网络设备和 I网 络设备做类似处理。 这样整个网络的时钟跟踪路径形成。 在此基础上釆用本 发明实施例的方法, 即可实现全网的各网络设备之间的时钟快速跟踪。 As shown in Figure 3, the SSM quality level and priority of clock source 1 and clock source 1 are the same. Each network device calculates the network device to the network device directly connected to the clock source (see network device A and network device J in the figure). The shortest path of the ) forms a clock tracking path as indicated by the arrow in FIG. In the figure, the E network device has the same shortest path to A and J. When determining the clock tracking path of the network device, the arbitration mechanism is selected to select the clock source of the tracking. For example, in this embodiment, E preferentially selects a network device (ie, network device A) connected to a clock source with a smaller number to perform tracking. The G network device and the I network device do similar processing. Thus the clock tracking path of the entire network is formed. Use this on this basis The method of the embodiment of the invention can realize fast clock tracking between network devices of the entire network.
如果时钟源 1失效, 釆用本发明实施例的方法, 就能形成如图 4所示的 网络设备跟踪和时钟源 2连接的时钟源接入网络设备 J的时钟跟踪树,如图 4 中箭头所示。  If the clock source 1 fails, the method of the embodiment of the present invention can form a clock tracking tree of the network device as shown in FIG. 4 and the clock source connected to the clock source 2 to access the network device J, as shown in FIG. Shown.
当然, 如果没有划分多个时钟子网的需求, 也可以关闭本功能, 为每个 和网络连接的时钟源配置不同的优先级和其他方法, 使得网络成为只有一个 时钟源的时钟艮踪网络。  Of course, if there is no need to divide multiple clock subnets, you can also disable this function, configure different priorities and other methods for each clock source connected to the network, making the network a clock tracing network with only one clock source.
应当理解, 实现本发明进行时钟跟踪的方法的软件可以存储于计算机可 读介质中。 该软件的在执行时, 包括如下步骤:  It should be understood that the software implementing the method of the present invention for clock tracking can be stored in a computer readable medium. When the software is executed, it includes the following steps:
计算某网络设备到达与时钟源直接相连的网络设备的最短路径作为时钟 跟踪路径; 如果所述时钟跟踪路径改变, 则向所述时钟跟踪路径上的相邻上 游网络设备发送请求消息; 接收所述相邻上游网络设备返回的应答消息, 并 根据所述应答消息进行时钟跟踪。 所述的可读介质可以为: R0M/RAM、 磁碟、 或光盘等。  Calculating, by the network device, a shortest path of the network device directly connected to the clock source as a clock tracking path; if the clock tracking path changes, sending a request message to an adjacent upstream network device on the clock tracking path; A response message returned by the adjacent upstream network device, and clock tracking is performed according to the response message. The readable medium can be: ROM/RAM, disk, or optical disk, and the like.
本发明的实施例还提供了一种网络设备。 网络设备包括计算模块、 判断 模块、 发送模块和接收处理模块。  Embodiments of the present invention also provide a network device. The network device includes a calculation module, a determination module, a transmission module, and a reception processing module.
计算模块 61用于确定网络拓朴变化, 并计算网络设备的时钟跟踪路径。 其中确定网络拓朴变化包括接收网络拓朴变化消息, 网络设备计算本网络设 备的时钟跟踪路径, 可以通过相应的算法 (如最短路径优先算法、 最小生成 树算法等)计算获得, 时钟跟踪路径是从时钟源接入网络设备到网络设备的 最短路径。  The calculation module 61 is configured to determine a network topology change and calculate a clock tracking path of the network device. The determining the network topology change includes receiving the network topology change message, and the network device calculates the clock tracking path of the network device, which can be obtained by using a corresponding algorithm (such as a shortest path first algorithm, a minimum spanning tree algorithm, etc.), where the clock tracking path is The shortest path from the clock source to the network device to the network device.
判断模块 62用于将获取的时钟跟踪路径和原来的时钟跟踪路径比较, 判 断网络设备的时钟跟踪路径是否变化。  The determining module 62 is configured to compare the acquired clock tracking path with the original clock tracking path to determine whether the clock tracking path of the network device changes.
发送模块 63用于当时钟跟踪路径发生变化时, 网络设备向其时钟跟踪路 径上的相邻上游网络设备发送请求消息, 该请求消息中包括相邻上游网络设 备的时钟跟踪路径的信息。 该发送模块 63还用于当网络设备的时钟跟踪路径 确定时, 向网络设备的时钟跟踪路径上的相邻下游网络设备发送应答消息。 而时钟跟踪路径确定, 具体是指网络设备的时钟跟踪路径未改变, 或者虽然 网络设备的时钟跟踪路径改变, 但其新的时钟跟踪路径已经确定并建立。 The sending module 63 is configured to: when the clock tracking path changes, the network device sends a request message to the neighboring upstream network device on the clock tracking path, where the request message includes information of a clock tracking path of the adjacent upstream network device. The sending module 63 is further configured to use a clock tracking path of the network device. When determined, a reply message is sent to an adjacent downstream network device on the clock tracking path of the network device. The clock tracking path is determined, specifically, the clock tracking path of the network device is unchanged, or although the clock tracking path of the network device changes, its new clock tracking path has been determined and established.
上述新的时钟跟踪路径已经确定并建立的具体体现为: 接收到其时钟跟 踪路径上的相邻上游网络设备返回的应答消息, 并根据所述应答消息进行时 钟跟踪。 如果没有收到返回的应答消息, 网络设备等待直到收到应答消息, 并且根据所述应答消息进行时钟跟踪后, 才向相邻下游网络设备发送应答消 息。  The above new clock tracking path has been determined and established as follows: A response message returned by a neighboring upstream network device on its clock tracking path is received, and clock tracking is performed according to the response message. If the returned response message is not received, the network device waits until a response message is received, and after the clock is tracked according to the response message, the response message is sent to the neighboring downstream network device.
接收处理模块 64用于接收相邻上游网络设备返回的应答消息, 并根据所 述应答消息进行时钟跟踪, 即网络设备的时钟能够跟踪相邻上游网络设备的 时钟。 该接收处理模块还用于接收网络设备的时钟跟踪路径上的相邻下游网 络设备向所述网络设备发送的请求消息, 该请求消息中包括网络设备的时钟 跟踪路径的信息。  The receiving processing module 64 is configured to receive a response message returned by the neighboring upstream network device, and perform clock tracking according to the response message, that is, the clock of the network device can track the clock of the adjacent upstream network device. The receiving processing module is further configured to receive a request message sent by the neighboring downstream network device on the clock tracking path of the network device to the network device, where the request message includes information of a clock tracking path of the network device.
网络设备、 网络设备的时钟跟踪路径上的相邻下游网络设备和网络设备 的时钟跟踪路径上的相邻上游网络设备、 时钟源接入网络设备可以是 SDH 光 传输设备、 波分复用 (Wave length Divi s ion Mul t iplex, WDM )光传输设备、 光同步网络( Synchronous Opt ica l Ne twork , SONET ) 光传输设备等网络设 备。  Network devices, adjacent downstream network devices on the clock tracking path of the network device, and adjacent upstream network devices on the clock tracking path of the network device, the clock source access network device may be an SDH optical transmission device, wavelength division multiplexing (Wave) Length Divi s ion Mul t iplex, WDM ) Optical transmission equipment, optical synchronization network (Synchronous Opt ica l Ne twork, SONET) optical transmission equipment and other network equipment.
在本发明的网络设备的实施例中, 能够实现在网络的拓朴结构发生变化 时和网络初始化时, 网络中各网络设备的根据所述应答消息进行时钟的自动 快速跟踪, 实现时钟自动快速切换和跟踪, 克服了传统的时钟跟踪技术中难 以规划合适的时钟跟踪路径的问题。 并且由于在所述请求消息中携带了其时 钟跟踪路径上的相邻上游网络设备的时钟跟踪路径, 釆用了严格的请求 -应答 串行机制, 故能有效的防止时钟跟踪环路的产生。  In the embodiment of the network device of the present invention, when the topology of the network changes and when the network is initialized, the network devices in the network automatically track the clock according to the response message, and implement automatic clock switching. And tracking, overcoming the difficulty of planning a suitable clock tracking path in traditional clock tracking techniques. Moreover, since the request message contains the clock tracking path of the adjacent upstream network device on its clock tracking path, a strict request-response serial mechanism is used, so that the clock tracking loop can be effectively prevented.
本发明的实施例还提供了一种网络系统, 包括至少一个与时钟源直接相 连的网络设备、 第一网络设备和第二网络设备, 所述第二网络设备为第一网 络设备的相邻上游网络设备; An embodiment of the present invention further provides a network system, including at least one network device directly connected to a clock source, a first network device, and a second network device, where the second network device is a first network Adjacent upstream network device of the network device;
一般情况下, 所述第一网络设备和第二网络设备在网络初始化或者网络 拓朴发生变化时, 会分别计算各自到与时钟源直接相连的网络设备的时钟跟 踪路径。 上述与时钟源直接相连的网络设备还接收所述其他网络设备发送的 请求消息, 并发送应答消息给所述其他网络设备。  Generally, when the network initialization or the network topology changes, the first network device and the second network device respectively calculate clock tracking paths of the network devices directly connected to the clock source. The network device directly connected to the clock source further receives the request message sent by the other network device, and sends a response message to the other network device.
所述第一网络设备用于获取到达所述与时钟源直接相连的网络设备的最 短路径, 并将该最短路径作为时钟跟踪路径, 当所述时钟跟踪路径改变时, 向所述第二网络设备发送请求消息 , 所述第二网络设备在其时钟跟踪路径确 定时, 向所述第一网络设备返回应答消息。 所述第二网络设备的时钟跟踪路 径确定具体体现为: 所述第二网络设备发现其时钟跟踪路径未变化, 或者虽 然发生了改变, 但新的时钟跟踪路径已经确定并建立。 所述第一网络设备接 收所述第二网络设备返回的应答消息, 并根据所述应答消息进行时钟跟踪。  The first network device is configured to obtain a shortest path to the network device directly connected to the clock source, and use the shortest path as a clock tracking path, and when the clock tracking path changes, to the second network device Sending a request message, the second network device returns a response message to the first network device when its clock tracking path is determined. The clock tracking path of the second network device is determined by: the second network device discovering that its clock tracking path has not changed, or although a change has occurred, a new clock tracking path has been determined and established. The first network device receives a response message returned by the second network device, and performs clock tracking according to the response message.
上述时钟跟中的具体过程可以理解如下: 当某个网络设备判断出本网络 设备的时钟路径发生改变时, 将向新的时钟跟踪路径上的本网络设备的相邻 上游节点发送请求消息, 而上游节点如果发现本网络设备的时钟跟踪路径也 发生了改变, 也会做同样的动作, 直至请求消息到达某一网络设备, 该网络 设备发现本网络设备的时钟跟踪路径未变化, 或者虽然发生了改变, 但新的 时钟跟踪路径已经确定并建立, 便向下游节点发送应答消息, 下游节点根据 根据应答消息中的信息, 建立时钟跟踪路径进行时钟跟踪。  The specific process of the above clock can be understood as follows: When a network device determines that the clock path of the network device changes, it sends a request message to the neighboring upstream node of the network device on the new clock tracking path, and If the upstream node finds that the clock tracking path of the network device has also changed, the same action is taken until the request message reaches a certain network device. The network device finds that the clock tracking path of the network device has not changed, or although it has occurred. Change, but the new clock tracking path has been determined and established, and a response message is sent to the downstream node. The downstream node establishes a clock tracking path for clock tracking according to the information in the response message.
其中时钟跟踪路径是从时钟源接入网络设备到该网络设备的最短路径。 相邻上游网络设备, 其位于网络设备的时钟跟踪路径上, 包括与时钟源直接 相连的网络设备。 请求消息中包括网络设备的时钟跟踪路径的信息。 相邻上 游网络设备接收到请求消息, 并在其时钟跟踪路径确定的情况下, 向网络设 备发送的应答消息。  The clock tracking path is the shortest path from the clock source to the network device to the network device. An adjacent upstream network device, located on a clock tracking path of the network device, including a network device directly connected to the clock source. The request message includes information of a clock tracking path of the network device. The neighboring upstream network device receives the request message and sends a response message to the network device if its clock tracking path is determined.
时钟跟踪路径确定是指, 相邻上游网络设备的时钟跟踪路径未改变; 或 者虽然网络设备的时钟跟踪路径改变, 但其新的时钟跟踪路径已经确定并建 立。 The clock tracking path determination means that the clock tracking path of the adjacent upstream network device has not changed; or although the clock tracking path of the network device changes, its new clock tracking path has been determined and built. Standing.
所述第一网络设备、 第二网络设备和与时钟源直接相连的网络设备, 以 及该网络系统中的其他网络设备均可以是 SDH光传输设备、 WDM光传输设备、 SONET光传输设备等网络设备。  The first network device, the second network device, and the network device directly connected to the clock source, and other network devices in the network system may be network devices such as an SDH optical transmission device, a WDM optical transmission device, and a SONET optical transmission device. .
在本发明的网络系统实施例中, 能够实现在网络的拓朴结构发生变化时 和网络初始化时, 网络中各网络设备的根据所述应答消息进行时钟的自动快 速跟踪, 实现时钟自动快速切换和跟踪, 克服了传统的时钟跟踪技术中难以 规划合适的时钟跟踪路径的问题。 并且由于在所述请求消息中携带了其相邻 网络设备的时钟跟踪路径的信息, 釆用了严格的请求-应答串行机制, 故能有 效的防止时钟跟踪环路的产生。  In the embodiment of the network system of the present invention, when the topology of the network changes and when the network is initialized, the network devices in the network automatically and automatically track the clock according to the response message, thereby realizing automatic clock switching and Tracking overcomes the difficulty of planning a suitable clock tracking path in traditional clock tracking techniques. And because the request message carries the information of the clock tracking path of its neighboring network device, a strict request-response serial mechanism is used, so that the generation of the clock tracking loop can be effectively prevented.
以上所述, 仅为本发明的具体实施方式, 但本发明的保护范围并不局限 于此, 任何熟悉本技术领域的技术人员在本发明揭露的技术范围内, 可轻易 想到的变化或替换, 都应涵盖在本发明的保护范围之内。 因此, 本发明的保 护范围应该以权利要求的保护范围为准。  The above is only the specific embodiment of the present invention, but the scope of the present invention is not limited thereto, and any change or replacement that can be easily conceived by those skilled in the art within the technical scope of the present invention is All should be covered by the scope of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims

权 利 要求 书 Claim
1、 一种网络时钟跟踪的方法, 其特征在于, 包括:  A method for tracking network clocks, comprising:
计算到达与时钟源直接相连的网络设备的最短路径, 并将所述的最短路径 作为时钟跟踪路径;  Calculating a shortest path to the network device directly connected to the clock source, and using the shortest path as a clock tracking path;
判断所述时钟跟踪路径是否改变;  Determining whether the clock tracking path is changed;
如果所述时钟跟踪路径改变, 则向所述时钟跟踪路径上的相邻上游网络设 备发送请求消息;  Sending a request message to an adjacent upstream network device on the clock tracking path if the clock tracking path changes;
接收所述相邻上游网络设备返回的应答消息, 并根据所述应答消息进行时 钟跟踪。  Receiving a response message returned by the adjacent upstream network device, and performing clock tracking according to the response message.
2、 根据权利要求 1所述的方法, 其特征在于, 所述接收所述应答消息之前 还包括:  2. The method according to claim 1, wherein the receiving the response message further comprises:
所述相邻上游网络设备接收到所述请求消息, 如果该相邻上游网络设备的 时钟跟踪路径确定, 则发送应答消息。  The neighboring upstream network device receives the request message, and if the clock tracking path of the neighboring upstream network device determines, sends a response message.
3、 根据权利要求 2所述的方法, 其特征在于, 所述时钟跟踪路径确定, 更 具体是:  3. The method according to claim 2, wherein the clock tracking path is determined, and more specifically:
所述相邻上游网络设备的时钟跟踪路径未改变; 或者所述相邻上游网络设 备的时钟跟踪路径改变, 但其新的时钟跟踪路径已经确定并建立。  The clock tracking path of the adjacent upstream network device is unchanged; or the clock tracking path of the adjacent upstream network device changes, but its new clock tracking path has been determined and established.
4、 根据权利要求 3所述的方法, 其特征在于, 所述请求消息中包括所述相 邻上游网络设备的时钟跟踪路径的信息, 所述相邻上游网络设备的时钟跟踪路 径在计算到达与时钟源直接相连的网络设备的最短路径时得出;  The method according to claim 3, wherein the request message includes information of a clock tracking path of the adjacent upstream network device, and a clock tracking path of the adjacent upstream network device is calculated to arrive and When the shortest path of the network device directly connected to the clock source is obtained;
所述相邻上游网络设备, 根据接收到的请求消息中其时钟跟踪路径和该相 邻上游网络设备原有时钟跟踪路径, 判断所述相邻上游网络设备的时钟跟踪路 径是否改变。  The adjacent upstream network device determines whether the clock tracking path of the adjacent upstream network device changes according to the clock tracking path of the received request message and the original clock tracking path of the adjacent upstream network device.
5、 根据权利要求 1或 2所述的方法, 其特征在于, 如果所述网络和至少两 个时钟源相连, 且到达至少两个时钟源接入网络设备的时钟跟踪路径长度相同, 则根据仲裁机制选择一个与时钟源直接相连的网络设备进行跟踪。 The method according to claim 1 or 2, wherein, if the network is connected to at least two clock sources, and the clock tracking path length of the at least two clock source access network devices is the same, according to arbitration The mechanism selects a network device directly connected to the clock source for tracking.
6、 一种网络设备, 其特征在于, 包括: 6. A network device, comprising:
计算模块(61 ), 用于计算到达与时钟源直接相连的网络设备的最短路径, 并将所述的最短路径作为时钟跟踪路径;  a calculation module (61), configured to calculate a shortest path to the network device directly connected to the clock source, and use the shortest path as a clock tracking path;
判断模块(62 ), 用于判断所述时钟跟踪路径是否改变;  a determining module (62), configured to determine whether the clock tracking path is changed;
发送模块(63 ), 用于当所述时钟跟踪路径改变时, 向所述时钟跟踪路径上 的相邻上游网络设备发送请求消息; 以及  a sending module (63), configured to send a request message to an adjacent upstream network device on the clock tracking path when the clock tracking path changes;
接收处理模块(64 ), 用于接收所述相邻上游网络设备返回的应答消息, 并 根据所述应答消息进行时钟跟踪。  The receiving processing module (64) is configured to receive a response message returned by the neighboring upstream network device, and perform clock tracking according to the response message.
7、 根据权利要求 6所述的网络设备, 其特征在于,  7. The network device according to claim 6, wherein
所述接收处理模块(64 ), 还用于接收处于所述时钟跟踪路径上的相邻下游 网络设备发送的请求消息;  The receiving processing module (64) is further configured to receive a request message sent by an adjacent downstream network device on the clock tracking path;
所述发送模块(63 ), 还用于当所述时钟跟踪路径确定时, 向所述相邻下游 网络设备发送应答消息。  The sending module (63) is further configured to send a response message to the neighboring downstream network device when the clock tracking path is determined.
8、根据权利要求 7所述的网络设备, 其特征在于, 所述时钟跟踪路径确定, 更具体是:  The network device according to claim 7, wherein the clock tracking path is determined, and more specifically:
所述网络设备的时钟跟踪路径未改变; 或者所述网络设备的时钟跟踪路径 改变, 但其新的时钟跟踪路径已经确定并建立。  The clock tracking path of the network device is unchanged; or the clock tracking path of the network device changes, but its new clock tracking path has been determined and established.
9、 一种网络系统, 包括至少一个与时钟源直接相连的网络设备、 第一网络 设备和第二网络设备, 其特征在于, 所述第二网络设备为第一网络设备的相邻 上游网络设备;  A network system, comprising at least one network device directly connected to a clock source, a first network device, and a second network device, wherein the second network device is an adjacent upstream network device of the first network device ;
所述与时钟源直接相连的网络设备用于计算到达与其相连的时钟源的最短 路径, 并将该最短路径作为时钟跟踪路径;  The network device directly connected to the clock source is configured to calculate a shortest path to a clock source connected thereto, and use the shortest path as a clock tracking path;
所述第一网络设备用于计算到达所述与时钟源直接相连的网络设备的最短 路径, 并将所述最短路径作为时钟跟踪路径, 当所述时钟跟踪路径改变时, 向 所述第二网络设备发送请求消息;  The first network device is configured to calculate a shortest path to the network device directly connected to the clock source, and use the shortest path as a clock tracking path, and when the clock tracking path changes, to the second network The device sends a request message;
所述第二网络设备用于接收第一网络设备发送的请求消息, 并在第二网络 设备的时钟跟踪路径确定时, 向所述第一网络设备返回应答消息; 所述第一网络设备还用于接收所述第二网络设备返回的应答消息, 并根据 所述应答消息进行时钟跟踪。 The second network device is configured to receive a request message sent by the first network device, and in the second network When the clock tracking path of the device is determined, the response message is returned to the first network device; the first network device is further configured to receive a response message returned by the second network device, and perform clock tracking according to the response message.
10、 一种计算机程序产品, 其特征在于, 包括一组指令序列, 该指令序列 被网络设备执行时包括如下步骤:  10. A computer program product, comprising: a set of instruction sequences, the sequence of instructions being executed by a network device comprising the steps of:
计算到达与时钟源直接相连的网络设备的最短路径, 并将所述的最短路径 作为时钟跟踪路径;  Calculating a shortest path to the network device directly connected to the clock source, and using the shortest path as a clock tracking path;
判断所述时钟跟踪路径是否改变;  Determining whether the clock tracking path is changed;
如果所述时钟跟踪路径改变, 则向所述时钟跟踪路径上的相邻上游网络设 备发送请求消息;  Sending a request message to an adjacent upstream network device on the clock tracking path if the clock tracking path changes;
接收所述相邻上游网络设备返回的应答消息, 并根据所述应答消息进行时 钟跟踪。  Receiving a response message returned by the adjacent upstream network device, and performing clock tracking according to the response message.
PCT/CN2008/071455 2007-06-26 2008-06-26 Method, network device and network system for network clock tracing WO2009000211A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN200710076142.6 2007-06-26
CN2007100761426A CN101335609B (en) 2007-06-26 2007-06-26 Network time clock tracking method, network apparatus and network system

Publications (1)

Publication Number Publication Date
WO2009000211A1 true WO2009000211A1 (en) 2008-12-31

Family

ID=40185206

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2008/071455 WO2009000211A1 (en) 2007-06-26 2008-06-26 Method, network device and network system for network clock tracing

Country Status (2)

Country Link
CN (1) CN101335609B (en)
WO (1) WO2009000211A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019112979A1 (en) 2017-12-04 2019-06-13 Schlumberger Technology Corporation Systems and methods for operating a downhole battery

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102082652B (en) * 2009-11-26 2013-11-06 华为技术有限公司 Method, device and system for acquiring network clock topological structure
CN102195709B (en) * 2011-06-22 2014-06-04 烽火通信科技股份有限公司 Method for obtaining clock states and operation modes of network element in simulation of fiber breaking failure
CN103151765B (en) * 2013-02-25 2015-09-30 西安交通大学 Adaptive zero hour differential overcurrent protection method
US11165681B2 (en) * 2019-09-27 2021-11-02 Juniper Networks, Inc. Inter-autonomous system trace route message

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4939752A (en) * 1989-05-31 1990-07-03 At&T Company Distributed timing recovery for a distributed communication system
CN1770701A (en) * 2004-11-03 2006-05-10 华为技术有限公司 Clock track realizing method in MESH network
US7096442B2 (en) * 2003-07-10 2006-08-22 Lsi Logic Corporation Optimizing IC clock structures by minimizing clock uncertainty

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100550761C (en) * 2003-11-15 2009-10-14 华为技术有限公司 A kind of management method of network clocking

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4939752A (en) * 1989-05-31 1990-07-03 At&T Company Distributed timing recovery for a distributed communication system
US7096442B2 (en) * 2003-07-10 2006-08-22 Lsi Logic Corporation Optimizing IC clock structures by minimizing clock uncertainty
CN1770701A (en) * 2004-11-03 2006-05-10 华为技术有限公司 Clock track realizing method in MESH network

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019112979A1 (en) 2017-12-04 2019-06-13 Schlumberger Technology Corporation Systems and methods for operating a downhole battery

Also Published As

Publication number Publication date
CN101335609A (en) 2008-12-31
CN101335609B (en) 2011-08-10

Similar Documents

Publication Publication Date Title
EP3419230B1 (en) Method of determining clock synchronization path, and apparatus
US8160053B2 (en) Method, apparatus and network element for clock tracing
EP2182670B1 (en) A method and apparatus for tracking clock source
CN100542111C (en) Determine the method and apparatus of network routing information based on shared risk link group information
US9112629B2 (en) Configuration of synchronisation network having synchronization trails for time sync and frequency sync
RU2638645C2 (en) Method for identification of reference clock signals subjected to asymmetry changes to delay propagation path between nodes in communication network
US8139938B2 (en) Hierarchical routing query method of automatic switched optical network
US9651984B2 (en) Feed-forward time transfer mechanism for time synchronization
WO2006047946A1 (en) Method for determining clock trace path and method of clock trace in the network
WO2009000211A1 (en) Method, network device and network system for network clock tracing
CN107852682B (en) Method and apparatus for determining synchronization reference
JP6437587B2 (en) Method, system, and apparatus for synchronizing clocks
CN112968725B (en) Satellite link switching method and device
KR102180041B1 (en) Apparatus and method for controlling time synchronization of node
JP6274918B2 (en) Communications system
JP2018098556A (en) Optical ring network system and path control method therefor
WO2015184763A1 (en) Method, apparatus and system for instructing to select synchronization time source
CN108462548B (en) Time synchronization method and device
WO2013097365A1 (en) Method and network device for converging master clock sources
CN103354507B (en) The configuration protection schema update method and apparatus of RPR website
WO2018014274A1 (en) Method for establishing path, and node
WO2012174963A1 (en) Method and device for selecting ptp lsp

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 08757854

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 08757854

Country of ref document: EP

Kind code of ref document: A1