WO2012022163A1 - Method and system for implementing time stamp synchronization between main and standby optical line terminals - Google Patents
Method and system for implementing time stamp synchronization between main and standby optical line terminals Download PDFInfo
- Publication number
- WO2012022163A1 WO2012022163A1 PCT/CN2011/073094 CN2011073094W WO2012022163A1 WO 2012022163 A1 WO2012022163 A1 WO 2012022163A1 CN 2011073094 W CN2011073094 W CN 2011073094W WO 2012022163 A1 WO2012022163 A1 WO 2012022163A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- onu
- olt
- standby
- value
- rtt value
- 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.)
- Ceased
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04Q—SELECTING
- H04Q11/00—Selecting arrangements for multiplex systems
- H04Q11/0001—Selecting arrangements for multiplex systems using optical switching
- H04Q11/0062—Network aspects
- H04Q11/0067—Provisions for optical access or distribution networks, e.g. Gigabit Ethernet Passive Optical Network (GE-PON), ATM-based Passive Optical Network (A-PON), PON-Ring
-
- 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
- H04Q—SELECTING
- H04Q11/00—Selecting arrangements for multiplex systems
- H04Q11/0001—Selecting arrangements for multiplex systems using optical switching
- H04Q11/0062—Network aspects
- H04Q2011/0079—Operation or maintenance aspects
Definitions
- the present invention relates to an optical link protection technology, and in particular, to a method and system for realizing time stamp synchronization of a primary and backup optical line terminal. Background technique
- EPON Errnet Passive Optical Network
- OLT optical line terminals
- the system usually consists of optical line terminals (OLT, Optical Line). Terminal), the optical network unit (0NU, Optical Network Unit) / optical network termination (0NT, Optical Network Termination) and optical distribution network (ODN, Optical Distribution Network) on the user side.
- the ODN consists of passive optical components such as single-mode fiber and optical splitters and optical connectors, providing an optical transmission medium for the physical connection between the OLT and the ONU.
- ODN is usually a point-to-multipoint structure, that is, one OLT connects multiple ONUs.
- the service traffic is divided into two directions: uplink and downlink:
- the uplink refers to the direction from the ONU to the OLT, and the downlink refers to the OLT sends the direction to the ONU.
- EPON uses the Multipoint Control Protocol (MPCP, Multipoint Control Prototol) as the Medium Access Control (MAC) sublayer.
- MPCP Multipoint Control Protocol
- MAC Medium Access Control
- Both the OLT and the ONU have their own 32-bit counters, incrementing every 16 ns, acting as a local timestamp.
- the local counter value is mapped to the timestamp field in the MPCP protocol frame.
- the ONU sets the timestamp in the MPCP protocol frame to the local counter, and when the ONU receives the MPCP protocol frame, it also calculates the difference between the local counter and the timestamp in the frame. If the difference is greater than the threshold, a timestamp drift alarm will be generated and the MPCP status opportunity will be deregistered.
- the OLT uses the timestamp field in the MPCP protocol frame to calculate the OLT and A round trip time (RTT, Round Trip Time) value between ONUs, the RTT value being equal to the difference between the local counter and the timestamp received in the MPCP protocol frame.
- RTT Round Trip Time
- an optical link protection switching mechanism can be used in an EPON system.
- Type b protection is shown in Figure 1:
- the two PON ports of the OLT use separate PON MAC chips and optical modules to protect the two PON ports.
- the OLT PON port as the standby is in the cold standby state and is detected by the OLT.
- the link protection and the status of the primary OLT PON port control the switching between the primary OLT PON port and the standby OLT PON port.
- the ONU timestamp counter is synchronized with the timestamp counter on the OLT main OLT PON port; when switching, the ONU starts to receive the MPCP protocol frame of the standby OLT PON port, if the MPCP protocol If the timestamp between the frame and the local timestamp counter are too large, the timestamp will drift, causing the ONU to drop. Since the timestamp counters of the OLT's active and standby PON ports are not synchronized, the timestamp drift is easy to occur in the type b switching.
- the Technical Requirements for China Telecom EPON Equipment V2.1 stipulates that the ONU should support the "holdover" function.
- This function means that the ONU can be kept in the "registered” state within the state of the holdover time under the control of the OLT's OAM message (the HoldoverConfig attribute) without registering.
- This feature can solve the ONU offline problem caused by timestamp drift in type b switching. However, this feature reduces the sensitivity of the ONU to normal deregistration events. On the other hand, many ONU devices on the live network do not support the holdover function. When the type b is switched, the time stamp drift is likely to occur. Summary of the invention
- the main purpose of the present invention is to implement a method and a system for realizing the timestamp synchronization of the active and standby optical line terminals, which can effectively synchronize the timestamp counters of the active and standby OLTs in the EPON backbone optical fiber protection system, and avoid the ONU time in the switching.
- the stamp drift occurs offline, ensuring that the switchover can be completed quickly.
- the invention provides a method for realizing time stamp synchronization of a master and backup optical line terminal, and the method comprises:
- the primary OLT and/or the standby OLT select the reference ONU;
- the primary OLT synchronously transmits the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT;
- the standby OLT After receiving the MPCP frame of the reference ONU, the standby OLT sets the value of the local timestamp counter according to the timestamp in the MPCP protocol frame and the RTT value of the primary OLT and the reference ONU.
- the synchronous transmission is: periodically transmitting, and/or transmitting when the RTT value of the primary OLT and any one of the online ONUs is changed, and/or when the RTT value of the primary OLT and the reference ONU is changed.
- the selection reference ONU is: when the reference ONU number is empty, an online ONU is selected as the reference ONU, the ONU number of the ONU is set as the reference ONU number, and the reference ONU number is synchronized to the standby OLT or The main OLT.
- the method further includes: when the primary OLT and/or the standby OLT are queried that the ONU has an offline event and the ONU number of the offline event is the reference ONU number, the ONU number of the online ONU is set as the reference again. The ONU number and synchronize the reference ONU number to the standby OLT or the primary OLT.
- the local timestamp counter is set according to the timestamp in the MPCP protocol frame and the latest RTT value of the primary OLT and the reference ONU, and the timestamp is set to tl in the MPCP protocol frame.
- the latest RTT value of the OLT and the reference ONU is r
- the system provides a system for realizing time-synchronization of an active and standby OLT, and the system includes: a primary OLT and a standby OLT; The primary OLT and/or the standby OLT are used to select the reference ONU;
- the primary OLT is further configured to synchronously send the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT;
- the standby OLT is further configured to: after receiving the MPCP protocol frame of the reference ONU, set the value of the local timestamp counter according to the timestamp in the MPCP protocol frame and the RTT value of the primary OLT and the reference ONU.
- the standby OLT includes: a timestamp counter, a reference ONU setting module, an RTT value saving module, a frame receiving module, and an update module;
- a timestamp counter which is used to start a timer with a period of 16 ns at the time of initialization, and accumulates its own count value each time the 16 ns timer expires;
- the reference ONU setting module is used to select the reference ONU, and notify the RTT value saving module when the reference ONU number is not empty;
- the RTT value saving module is configured to receive an RTT value sent by the primary OLT and all the online ONUs or an RTT value of the reference ONU, and save the information to the local;
- a frame receiving module configured to: when the MPCP protocol frame of the reference ONU is received according to the reference ONU number, extract a timestamp in the MPCP protocol frame, and then notify the update module;
- An update module configured to query an RTT value of the primary OLT and the reference ONU from the RTT value saved by the RTT value saving module, obtain a value of the timestamp counter according to the RTT value and a timestamp extracted by the frame receiving module, and update the timestamp counter. Value.
- the reference ONU setting module is specifically configured to set an ONU number of an online ONU as a reference ONU number when the reference ONU number is empty, and synchronize the reference ONU number to the active OLT.
- the reference ONU setting module is further configured to re-set the ONU number of an online ONU as the reference ONU number when the ONU number of the ONU is detected as an offline event and the ONU number of the offline event is the reference ONU number, and Synchronize the reference ONU number to the standby OLT or The main OLT.
- the method and system for realizing time stamp synchronization of the active and standby optical line terminals are provided by the present invention.
- the primary OLT and/or the standby OLT select the reference ONU; the primary OLT synchronously transmits the RTT value of itself and all the online ONUs or itself and the reference to the standby OLT.
- the RTT value of the ONU after receiving the MPCP protocol frame of the reference ONU, the standby OLT sets the value of the local timestamp counter according to the timestamp in the MPCP protocol frame and the RTT value of the primary OLT and the reference ONU; Synchronize the timestamp counters of the active and standby OLTs in the EPON backbone fiber protection system to avoid the ONUs being offline due to timestamp drift during the switching, thus ensuring that the switching can be completed quickly. Moreover, the requirements for the ONU are lower, and the hold over function is not required. It is compatible with all ONU devices on the live network.
- FIG. 1 is a schematic structural view of a type b protection in the prior art
- FIG. 2 is a schematic flowchart of a method for implementing active/standby OLT timestamp synchronization according to the present invention
- FIG. 3 is a schematic flowchart of a method for selecting a primary ONU OLT timestamp synchronization by using a standby OLT to select a reference ONU according to an embodiment of the present invention
- FIG. 4 is a schematic structural diagram of a system for implementing active/standby 0 LT timestamp synchronization according to the present invention. Detailed ways
- the basic idea of the present invention is: the primary OLT and/or the standby OLT selects the reference ONU; the primary OLT synchronously transmits the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT; the standby OLT receives the reference After the MPCP protocol frame of the ONU, the value of the local timestamp counter is set according to the timestamp in the MPCP protocol frame and the RTT value of the primary OLT and the reference ONU.
- Step 200 The primary OLT and/or the standby OLT select a reference ONU.
- the primary OLT and/or the standby OLT selects an online ONU as the reference ONU, sets the ONU number of the ONU as the reference ONU number, and synchronizes the reference ONU number to the standby.
- the step further includes: when the primary OLT and/or the standby OLT query the ONU that the ONU has an offline event and the offline event occurs as the reference ONU number, set the reference ONU number to be empty, and re-set the ONU number of an online ONU. Set to the reference ONU number and synchronize the reference ONU number to the standby OLT or the primary OLT.
- Step 201 The primary OLT synchronously sends the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT.
- the active OLT calculates an RTT value of itself and all online ONUs according to the received MPCP protocol frames of all online ONUs, and synchronously sends the RTT values to the standby OLT; or, the primary OLT is based on the received reference ONUs.
- the MPCP protocol frame calculates the RTT value of itself and the reference ONU, and synchronously sends the RTT value to the standby OLT;
- the synchronous transmission is generally sent periodically, and/or when the RTT value of the primary OLT and any one of the online ONUs is changed, and/or when the RTT value of the primary OLT and the reference ONU is changed; the periodicity is generally follow the set period.
- Step 202 The standby OLT starts a local timestamp counter. After receiving the MPCP protocol frame of the reference ONU, setting the value of the local timestamp counter according to the timestamp in the MPCP protocol frame and the latest RTT value of the primary OLT and the reference ONU. .
- the standby OLT selects the reference ONU to implement the method for timestamp synchronization of the active and standby OLTs. As shown in FIG. 3, the method includes the following steps:
- Step 301 The standby OLT sets the value t2 of the local timestamp counter to 0, sets the reference ONU number to be empty, is generally represented by -1, and starts a timer with a period of 16 ns;
- Step 302 Determine whether the 16ns timer expires, if it times out, go to step 303, otherwise go to step 304;
- Step 303 The standby OLT accumulates the value t2 of the local timestamp counter according to the formula (1), and performs step 302;
- T2 (t2 + 1) % 2 32 ( 1 )
- Step 304 The standby OLT queries whether the RTT value sent by the active OLT and all the online ONUs is received. If yes, step 305 is performed; otherwise, step 306 is performed;
- Step 305 The standby OLT saves the received RTT value of the active OLT and all online ONUs to the local, and performs step 302;
- Step 306 The standby OLT queries whether there is an offline event of the ONU, and the ONU number of the offline event is the reference ONU number, if yes, step 307 is performed, otherwise step 310 is performed;
- the active OLT sends a notification message that the ONU has an offline event to the standby OLT, and the standby OLT queries whether the notification message is present, and if so, further queries the offline event in the notification message. If the ONU number is the reference ONU number, if it is the reference ONU number, step 307 is performed, if the standby OLT queries that there is no notification message, or the ONU number of the offline event in the notification message is not the reference ONU number , step 310 is performed;
- Step 307 The standby OLT sets the reference ONU number to be empty.
- Step 308 The standby OLT determines whether there is an online ONU p, if yes, step 309 is performed, otherwise step 302 is performed;
- the selection of the online ONU p may be any one of all online ONUs, or may be selected according to the ONU number of the online ONU.
- Step 309 The standby OLT sets the reference ONU number to p, and performs step 302;
- Step 310 The standby OLT determines whether the reference ONU number is empty. If yes, step 308 is performed; otherwise, step 311 is performed;
- Step 311 The standby OLT queries whether the MPCP protocol frame of the reference ONU is received according to the reference ONU number, if yes, step 312 is performed, otherwise step 302 is performed;
- Step 312 The backup OLT extracts the timestamp in the received MPCP protocol frame of the reference ONU, and the timestamp is set to tl.
- the primary OLT and the reference ONU are queried from the locally stored active OLT and the RTT values of all online ONUs. The latest RTT value, the RTT value is set to r;
- Step 313 The standby OLT updates the value t2 of the local timestamp counter according to formula (2), and performs step 302;
- T2 (tl + r) %2 32 ( 2 )
- the present invention further provides a system for implementing time-stamp synchronization of the active and standby OLTs.
- the system includes: a primary OLT and a standby OLT;
- the primary OLT and/or the standby OLT select the reference ONU;
- the primary OLT is further configured to synchronously send the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT; wherein the synchronous transmission is generally sent periodically, and/or in the primary OLT. Transmitted when the RTT value of any one of the online ONUs is changed, and/or when the RTT value of the primary OLT and the reference ONU is changed;
- the standby OLT is further configured to start a local timestamp counter, and after receiving the MPCP protocol frame of the reference ONU, set a local timestamp according to the timestamp in the MPCP protocol frame and the latest RTT value of the primary OLT and the reference ONU.
- the value of the counter is further configured to start a local timestamp counter, and after receiving the MPCP protocol frame of the reference ONU, set a local timestamp according to the timestamp in the MPCP protocol frame and the latest RTT value of the primary OLT and the reference ONU.
- the standby OLT when used to select the reference ONU, includes: a timestamp counter 41, a reference ONU setting module 42, an RTT value saving module 43, a frame receiving module 44, and an updating module 45;
- the timestamp counter 41 includes a timer with a period of 16 ns, which is used to initialize The 16 ns timer is incremented, and each time the 16 ns timer expires, the count value of the timer is incremented. Specifically, the value of the time stamp counter 41 is set to t2, and each timeout of the 16 ns timer, the timestamp counter 41 Accumulate the count value of itself according to formula (1);
- the reference ONU setting module 42 is configured to select the reference ONU, and notify the RTT value saving module 43 when the reference ONU number is not empty;
- the reference ONU setting module 42 sets the reference ONU number to be empty during initialization, and sets the ONU number of an online ONU as the reference ONU number when the reference ONU number is empty, and synchronizes the reference ONU number to the primary use. OLT, notify the RTT value saving module 43;
- the one ONRU may be arbitrarily selected in all online ONUs, or may be selected in the first ONU according to the ONU number of the online ONUs;
- the reference ONU setting module 42 is further configured to: when the ONU number of the ONU occurs, and the ONU number of the offline event is the reference ONU number, set the reference ONU number to be empty, and re-set the ONU number of an online ONU. Set to the reference ONU number, and synchronize the reference ONU number to the standby OLT or the primary OLT;
- the RTT value saving module 43 is configured to receive the RTT value sent by the primary OLT and all the online ONUs or the RTT value of the reference ONU, and save the locality;
- the frame receiving module 44 is configured to extract, according to the reference ONU number set by the reference ONU setting module 42, the timestamp in the MPCP protocol frame when the MPCP protocol frame of the reference ONU is received, and the timestamp is set to tl. Then notify the update module 45;
- the update module 45 is configured to query the latest RTT value of the primary OLT and the reference ONU from the RTT values saved by the RTT value saving module 43, and obtain the value of the timestamp counter according to the RTT value and the timestamp extracted by the frame receiving module 44. Updating the value of the timestamp counter 41;
- the update module 45 queries the latest RTT value of the primary OLT and the reference ONU from the RTT value saved by the RTT value saving module 43, and the RTT value is set to r according to the RTT value r and the frame receiving module 44.
- the extracted timestamp tl gets the value of the timestamp counter t2, when updating The value of the stamp counter 41 is t2; the t2 is calculated according to the formula (2).
- the standby OLT updates the local timestamp counter according to the RRT value of the primary OLT and the reference ONU and the timestamp in the MPCP protocol frame of the reference ONU, so as to be synchronized with the timestamp of the primary OLT, which can be avoided in the switching.
- the ONU goes offline due to time stamp drift, thus ensuring that the switching can be completed quickly.
- the ONU requirement is low, and the hold over function is not required. It can be compatible with all ONU devices on the live network.
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
- Small-Scale Networks (AREA)
Abstract
Description
一种实现主备光线路终端时间戳同步的方法及系统 技术领域 Method and system for realizing time stamp synchronization of active and standby optical line terminals
本发明涉及光链路保护技术, 尤其涉及一种实现主备光线路终端时间 戳同步的方法及系统。 背景技术 The present invention relates to an optical link protection technology, and in particular, to a method and system for realizing time stamp synchronization of a primary and backup optical line terminal. Background technique
以太网无源光网络 ( EPON , Ethernet Passive Optical Network )是基于 IEEE802.3-2005 Section 5标准的新一代宽带无源光综合接入技术, 系统通 常由局侧的光线路终端 ( OLT , Optical Line Terminal )、 用户侧的光网络单 元 (0NU、 Optical Network Unit ) /光网络终端 (0NT、 Optical Network Termination )和光分配网络(ODN、 Optical Distribution Network )组成。 ODN由单模光纤和光分路器、光连接器等无源光器件组成,为 OLT和 ONU 之间的物理连接提供光传输媒质。 ODN通常为点到多点结构, 即一个 OLT 连接多个 ONU。 EPON系统中业务流量分为上行和下行两个方向: 上行指 从 ONU向 OLT发送方向, 下行指 OLT向 ONU发送方向。 EPON使用多 点控制协议( MPCP, Multipoint Control Prototol )作为媒体接入控制( MAC ) 子层。 EPON (Ethernet Passive Optical Network) is a new generation broadband passive optical access technology based on IEEE802.3-2005 Section 5 standard. The system usually consists of optical line terminals (OLT, Optical Line). Terminal), the optical network unit (0NU, Optical Network Unit) / optical network termination (0NT, Optical Network Termination) and optical distribution network (ODN, Optical Distribution Network) on the user side. The ODN consists of passive optical components such as single-mode fiber and optical splitters and optical connectors, providing an optical transmission medium for the physical connection between the OLT and the ONU. ODN is usually a point-to-multipoint structure, that is, one OLT connects multiple ONUs. In the EPON system, the service traffic is divided into two directions: uplink and downlink: The uplink refers to the direction from the ONU to the OLT, and the downlink refers to the OLT sends the direction to the ONU. EPON uses the Multipoint Control Protocol (MPCP, Multipoint Control Prototol) as the Medium Access Control (MAC) sublayer.
OLT和 ONU都有各自的 32 bit计数器, 每 16 ns递增 1次, 起到本地 时间戳的作用。 当 OLT或 ONU设备发送 MPCP协议帧时, 将本地的计数 器值映射到所述 MPCP协议帧中的时间戳字段。 ONU每当接收到 MPCP协 议帧时,会将所述 MPCP协议帧中的时间戳设置到本地的计数器,而且 ONU 接收到 MPCP协议帧时, 还会计算本地计数器和帧中时间戳的差值, 若差 值大于门限则会产生时间戳漂移告警, MPCP 状态机会发生解注册。 OLT 接收到 MPCP协议帧时, 用 MPCP协议帧中的时间戳字段来计算 OLT和 ONU之间的往返时间 ( RTT, Round Trip Time )值, 所述 RTT值等于本地 计数器和接收到 MPCP协议帧中时间戳的差值。 Both the OLT and the ONU have their own 32-bit counters, incrementing every 16 ns, acting as a local timestamp. When the OLT or ONU device sends an MPCP protocol frame, the local counter value is mapped to the timestamp field in the MPCP protocol frame. When receiving the MPCP protocol frame, the ONU sets the timestamp in the MPCP protocol frame to the local counter, and when the ONU receives the MPCP protocol frame, it also calculates the difference between the local counter and the timestamp in the frame. If the difference is greater than the threshold, a timestamp drift alarm will be generated and the MPCP status opportunity will be deregistered. When the OLT receives the MPCP protocol frame, it uses the timestamp field in the MPCP protocol frame to calculate the OLT and A round trip time (RTT, Round Trip Time) value between ONUs, the RTT value being equal to the difference between the local counter and the timestamp received in the MPCP protocol frame.
为了提高网络可靠性和生存性, 可在 EPON系统中釆用光链路保护倒 换机制。类型 b保护如图 1所示: OLT的两个 PON口分别釆用独立的 PON MAC芯片和光模块,实现两个 PON口的保护,其中,作为备用的 OLT PON 口处于冷备用状态, 由 OLT检测链路保护及主用 OLT PON端口状态, 控 制主用 OLT PON口与备用 OLT PON口的倒换。 In order to improve network reliability and survivability, an optical link protection switching mechanism can be used in an EPON system. Type b protection is shown in Figure 1: The two PON ports of the OLT use separate PON MAC chips and optical modules to protect the two PON ports. The OLT PON port as the standby is in the cold standby state and is detected by the OLT. The link protection and the status of the primary OLT PON port control the switching between the primary OLT PON port and the standby OLT PON port.
类型 b保护系统中存在这样一个问题: 倒换前, ONU的时间戳计数器 和 OLT主用 OLT PON口上的时间戳计数器保持同步; 倒换时, ONU开始 接收备用 OLT PON口的 MPCP协议帧 , 如果 MPCP协议帧中的时间戳和 本地时间戳计数器相差过大就会发生时间戳漂移, 造成 ONU掉线。 由于 OLT主备 PON口的时间戳计数器是不同步的, 类型 b倒换中很容易发生时 间戳漂移。 There is such a problem in the type b protection system: Before the switchover, the ONU timestamp counter is synchronized with the timestamp counter on the OLT main OLT PON port; when switching, the ONU starts to receive the MPCP protocol frame of the standby OLT PON port, if the MPCP protocol If the timestamp between the frame and the local timestamp counter are too large, the timestamp will drift, causing the ONU to drop. Since the timestamp counters of the OLT's active and standby PON ports are not synchronized, the timestamp drift is easy to occur in the type b switching.
《中国电信 EPON设备技术要求 V2.1》规定 ONU应支持 "状态保持 ( holdover )"功能。该功能是指 ONU在 OLT的 OAM消息( HoldoverConfig 属性) 的控制下, ONU能在状态保持时间 (holdover time ) 内保持在 "注 册" 状态, 而不解注册。 这个特性能够解决类型 b倒换中时间戳漂移造成 ONU离线问题。 但这个特性降低了 ONU对正常解注册事件的敏感性。 另 一方面, 现网 ONU设备有很多不支持 holdover功能, 类型 b倒换时还是会 很容易发生时间戳漂移。 发明内容 The Technical Requirements for China Telecom EPON Equipment V2.1 stipulates that the ONU should support the "holdover" function. This function means that the ONU can be kept in the "registered" state within the state of the holdover time under the control of the OLT's OAM message (the HoldoverConfig attribute) without registering. This feature can solve the ONU offline problem caused by timestamp drift in type b switching. However, this feature reduces the sensitivity of the ONU to normal deregistration events. On the other hand, many ONU devices on the live network do not support the holdover function. When the type b is switched, the time stamp drift is likely to occur. Summary of the invention
有鉴于此, 本发明的主要目的在于一种实现主备光线路终端时间戳同 步的方法及系统, 可以有效同步 EPON主干光纤保护系统中主备 OLT的时 间戳计数器, 避免在倒换中 ONU因时间戳漂移发生离线, 从而保证倒换能 快速完成。 为达到上述目的, 本发明的技术方案是这样实现的: In view of the above, the main purpose of the present invention is to implement a method and a system for realizing the timestamp synchronization of the active and standby optical line terminals, which can effectively synchronize the timestamp counters of the active and standby OLTs in the EPON backbone optical fiber protection system, and avoid the ONU time in the switching. The stamp drift occurs offline, ensuring that the switchover can be completed quickly. In order to achieve the above object, the technical solution of the present invention is achieved as follows:
本发明提供的一种实现主备光线路终端时间戳同步的方法, 该方法包 括: The invention provides a method for realizing time stamp synchronization of a master and backup optical line terminal, and the method comprises:
主用 OLT和 /或备用 OLT选择基准 ONU; The primary OLT and/or the standby OLT select the reference ONU;
主用 OLT向备用 OLT同步发送自身与所有在线 ONU的 RTT值或自身 与基准 ONU的 RTT值; The primary OLT synchronously transmits the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT;
所述备用 OLT在接收到所述基准 ONU的 MPCP帧后,根据所述 MPCP 协议帧中的时间戳和主用 OLT与基准 ONU的 RTT值设置本地时间戳计数 器的值。 After receiving the MPCP frame of the reference ONU, the standby OLT sets the value of the local timestamp counter according to the timestamp in the MPCP protocol frame and the RTT value of the primary OLT and the reference ONU.
上述方案中, 所述同步发送为: 定期发送、 和 /或在主用 OLT与任意一 个在线 ONU的 RTT值改变时发送、 和 /或在主用 OLT与基准 ONU的 RTT 值改变时发送。 In the above solution, the synchronous transmission is: periodically transmitting, and/or transmitting when the RTT value of the primary OLT and any one of the online ONUs is changed, and/or when the RTT value of the primary OLT and the reference ONU is changed.
上述方案中, 所述选择基准 ONU为: 在基准 ONU号为空时, 选择一 个在线 ONU作为基准 ONU, 将所述 ONU的 ONU号设置为基准 ONU号, 并将基准 ONU号同步到备用 OLT或主用 OLT。 In the above solution, the selection reference ONU is: when the reference ONU number is empty, an online ONU is selected as the reference ONU, the ONU number of the ONU is set as the reference ONU number, and the reference ONU number is synchronized to the standby OLT or The main OLT.
上述方案中, 该方法进一步包括: 主用 OLT和 /或备用 OLT在查询出 有 ONU发生离线事件、 且发生离线事件的 ONU号为基准 ONU号时, 重 新将一个在线 ONU的 ONU号设置为基准 ONU号,并将该基准 ONU号同 步到备用 OLT或主用 OLT。 In the above solution, the method further includes: when the primary OLT and/or the standby OLT are queried that the ONU has an offline event and the ONU number of the offline event is the reference ONU number, the ONU number of the online ONU is set as the reference again. The ONU number and synchronize the reference ONU number to the standby OLT or the primary OLT.
上述方案中, 所述根据所述 MPCP协议帧中的时间戳和主用 OLT与基 准 ONU的最新 RTT值设置本地时间戳计数器, 为: 设所述 MPCP协议帧 中的时间戳为 tl , 主用 OLT与基准 ONU的最新 RTT值为 r, 则本地时间 戳计数器的值 t2为: t2 = (tl + r) %232, 其中, %表示取余操作。 In the above solution, the local timestamp counter is set according to the timestamp in the MPCP protocol frame and the latest RTT value of the primary OLT and the reference ONU, and the timestamp is set to tl in the MPCP protocol frame. The latest RTT value of the OLT and the reference ONU is r, and the value t2 of the local timestamp counter is: t2 = (tl + r) %2 32 , where % indicates the remainder operation.
本发明提供的一种实现主备 OLT时间戳同步的系统, 该系统包括: 主 用 OLT、 备用 OLT; 其中, 主用 OLT和 /或备用 OLT, 用于选择基准 ONU; The system provides a system for realizing time-synchronization of an active and standby OLT, and the system includes: a primary OLT and a standby OLT; The primary OLT and/or the standby OLT are used to select the reference ONU;
所述主用 OLT, 还用于向备用 OLT同步发送自身与所有在线 ONU的 RTT值或自身与基准 ONU的 RTT值; The primary OLT is further configured to synchronously send the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT;
所述备用 OLT, 还用于在接收到基准 ONU的 MPCP协议帧后, 根据 所述 MPCP协议帧中的时间戳和主用 OLT与基准 ONU的 RTT值设置本地 时间戳计数器的值。 The standby OLT is further configured to: after receiving the MPCP protocol frame of the reference ONU, set the value of the local timestamp counter according to the timestamp in the MPCP protocol frame and the RTT value of the primary OLT and the reference ONU.
上述方案中, 所述备用 OLT, 包括: 时间戳计数器、 基准 ONU设置模 块、 RTT值保存模块、 帧接收模块、 更新模块; 其中, In the above solution, the standby OLT includes: a timestamp counter, a reference ONU setting module, an RTT value saving module, a frame receiving module, and an update module;
时间戳计数器,用于在初始化时启动周期为 16ns的定时器,在所述 16ns 定时器每次超时时, 对自身的计数值进行累加; a timestamp counter, which is used to start a timer with a period of 16 ns at the time of initialization, and accumulates its own count value each time the 16 ns timer expires;
基准 ONU设置模块, 用于选择基准 ONU, 在基准 ONU号不为空时通 知 RTT值保存模块; The reference ONU setting module is used to select the reference ONU, and notify the RTT value saving module when the reference ONU number is not empty;
RTT值保存模块, 用于接收主用 OLT发送的与所有在线 ONU的 RTT 值或与基准 ONU的 RTT值, 并保存到本地; The RTT value saving module is configured to receive an RTT value sent by the primary OLT and all the online ONUs or an RTT value of the reference ONU, and save the information to the local;
帧接收模块, 用于根据基准 ONU号查询出接收到基准 ONU的 MPCP 协议帧时, 提取所述 MPCP协议帧中的时间戳, 之后通知更新模块; a frame receiving module, configured to: when the MPCP protocol frame of the reference ONU is received according to the reference ONU number, extract a timestamp in the MPCP protocol frame, and then notify the update module;
更新模块, 用于从 RTT值保存模块保存的 RTT值中查询主用 OLT与 基准 ONU的 RTT值, 根据所述 RTT值和帧接收模块提取的时间戳得到时 间戳计数器的值, 更新时间戳计数器的值。 An update module, configured to query an RTT value of the primary OLT and the reference ONU from the RTT value saved by the RTT value saving module, obtain a value of the timestamp counter according to the RTT value and a timestamp extracted by the frame receiving module, and update the timestamp counter. Value.
上述方案中, 所述基准 ONU设置模块, 具体用于在基准 ONU号为空 时, 将一个在线 ONU的 ONU号设置为基准 ONU号, 并将基准 ONU号同 步到主用 OLT。 In the above solution, the reference ONU setting module is specifically configured to set an ONU number of an online ONU as a reference ONU number when the reference ONU number is empty, and synchronize the reference ONU number to the active OLT.
上述方案中, 所述基准 ONU设置模块, 还用于查询出有 ONU发生离 线事件、且发生离线事件的 ONU号为基准 ONU号时,重新将一个在线 ONU 的 ONU号设置为基准 ONU号, 并将所述基准 ONU号同步到备用 OLT或 主用 OLT。 In the above solution, the reference ONU setting module is further configured to re-set the ONU number of an online ONU as the reference ONU number when the ONU number of the ONU is detected as an offline event and the ONU number of the offline event is the reference ONU number, and Synchronize the reference ONU number to the standby OLT or The main OLT.
本发明提供的实现主备光线路终端时间戳同步的方法及系统, 主用 OLT和 /或备用 OLT选择基准 ONU;主用 OLT向备用 OLT同步发送自身与 所有在线 ONU的 RTT值或自身与基准 ONU的 RTT值; 备用 OLT在接收 到基准 ONU的 MPCP协议帧后 , 根据所述 MPCP协议帧中的时间戳和主 用 OLT与基准 ONU的 RTT值设置本地时间戳计数器的值; 如此, 可以有 效同步 EPON主干光纤保护系统中主备 OLT的时间戳计数器, 避免在倒换 中 ONU因时间戳漂移发生离线,从而保证倒换能快速完成。 而且,对 ONU 要求较低, 不需要有 hold over功能, 能兼容所有现网 ONU设备。 附图说明 The method and system for realizing time stamp synchronization of the active and standby optical line terminals are provided by the present invention. The primary OLT and/or the standby OLT select the reference ONU; the primary OLT synchronously transmits the RTT value of itself and all the online ONUs or itself and the reference to the standby OLT. The RTT value of the ONU; after receiving the MPCP protocol frame of the reference ONU, the standby OLT sets the value of the local timestamp counter according to the timestamp in the MPCP protocol frame and the RTT value of the primary OLT and the reference ONU; Synchronize the timestamp counters of the active and standby OLTs in the EPON backbone fiber protection system to avoid the ONUs being offline due to timestamp drift during the switching, thus ensuring that the switching can be completed quickly. Moreover, the requirements for the ONU are lower, and the hold over function is not required. It is compatible with all ONU devices on the live network. DRAWINGS
图 1为现有技术中类型 b保护的结构示意图; 1 is a schematic structural view of a type b protection in the prior art;
图 2为本发明实现主备 0 LT时间戳同步的方法的流程示意图; 图 3为本发明实施例中备用 OLT选择基准 ONU, 实现主备 OLT时间 戳同步的方法的流程示意图; 2 is a schematic flowchart of a method for implementing active/standby OLT timestamp synchronization according to the present invention; FIG. 3 is a schematic flowchart of a method for selecting a primary ONU OLT timestamp synchronization by using a standby OLT to select a reference ONU according to an embodiment of the present invention;
图 4为本发明实现主备 0 LT时间戳同步的系统的结构示意图。 具体实施方式 FIG. 4 is a schematic structural diagram of a system for implementing active/standby 0 LT timestamp synchronization according to the present invention. Detailed ways
本发明的基本思想是: 主用 OLT和 /或备用 OLT选择基准 ONU; 主用 OLT向备用 OLT同步发送自身与所有在线 ONU的 RTT值或自身与基准 ONU的 RTT值; 备用 OLT在接收到基准 ONU的 MPCP协议帧后, 根据 所述 MPCP协议帧中的时间戳和主用 OLT与基准 ONU的 RTT值设置本地 时间戳计数器的值。 The basic idea of the present invention is: the primary OLT and/or the standby OLT selects the reference ONU; the primary OLT synchronously transmits the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT; the standby OLT receives the reference After the MPCP protocol frame of the ONU, the value of the local timestamp counter is set according to the timestamp in the MPCP protocol frame and the RTT value of the primary OLT and the reference ONU.
下面结合附图及具体实施例对本发明进行详细说明。 The present invention will be described in detail below with reference to the accompanying drawings and specific embodiments.
本发明实现主备 OLT时间戳同步的方法, 如图 2所示, 该方法包括以 下几个步骤: 步骤 200: 主用 OLT和 /或备用 OLT选择基准 ONU; The method for realizing the time synchronization of the active and standby OLTs is as shown in FIG. 2, and the method includes the following steps: Step 200: The primary OLT and/or the standby OLT select a reference ONU.
具体的, 在预先设置的基准 ONU号为空时, 主用 OLT和 /或备用 OLT 选择一个在线 ONU作为基准 ONU,将该 ONU的 ONU号设置为基准 ONU 号, 并将基准 ONU号同步到备用 OLT或主用 OLT; Specifically, when the preset reference ONU number is empty, the primary OLT and/or the standby OLT selects an online ONU as the reference ONU, sets the ONU number of the ONU as the reference ONU number, and synchronizes the reference ONU number to the standby. OLT or primary OLT;
本步骤进一步包括: 主用 OLT和 /或备用 OLT在查询出有 ONU发生离 线事件、 且发生离线事件的 ONU号为基准 ONU号时, 设置基准 ONU号 为空, 重新将一个在线 ONU的 ONU号设置为基准 ONU号, 并将该基准 ONU号同步到备用 OLT或主用 OLT。 The step further includes: when the primary OLT and/or the standby OLT query the ONU that the ONU has an offline event and the offline event occurs as the reference ONU number, set the reference ONU number to be empty, and re-set the ONU number of an online ONU. Set to the reference ONU number and synchronize the reference ONU number to the standby OLT or the primary OLT.
步骤 201 :主用 OLT向备用 OLT同步发送自身与所有在线 ONU的 RTT 值或自身与基准 ONU的 RTT值; Step 201: The primary OLT synchronously sends the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT.
具体的, 主用 OLT根据接收的所有在线 ONU的 MPCP协议帧, 计算 自身与所有在线 ONU的 RTT值, 并将所述 RTT值同步发送到备用 OLT; 或者, 主用 OLT根据接收的基准 ONU的 MPCP协议帧, 计算自身与基准 ONU的 RTT值, 并将该 RTT值同步发送到备用 OLT; Specifically, the active OLT calculates an RTT value of itself and all online ONUs according to the received MPCP protocol frames of all online ONUs, and synchronously sends the RTT values to the standby OLT; or, the primary OLT is based on the received reference ONUs. The MPCP protocol frame, calculates the RTT value of itself and the reference ONU, and synchronously sends the RTT value to the standby OLT;
所述同步发送一般是定期发送、和 /或在主用 OLT与任意一个在线 ONU 的 RTT值改变时发送、 和 /或在主用 OLT与基准 ONU的 RTT值改变时发 送; 所述定期一般是按照设定的周期。 The synchronous transmission is generally sent periodically, and/or when the RTT value of the primary OLT and any one of the online ONUs is changed, and/or when the RTT value of the primary OLT and the reference ONU is changed; the periodicity is generally Follow the set period.
步骤 202: 备用 OLT启动本地时间戳计数器, 在接收到基准 ONU的 MPCP协议帧后, 根据所述 MPCP协议帧中的时间戳和主用 OLT与基准 ONU的最新 RTT值设置本地时间戳计数器的值。 Step 202: The standby OLT starts a local timestamp counter. After receiving the MPCP protocol frame of the reference ONU, setting the value of the local timestamp counter according to the timestamp in the MPCP protocol frame and the latest RTT value of the primary OLT and the reference ONU. .
实施例一 Embodiment 1
本实施例中, 备用 OLT选择基准 ONU, 实现主备 OLT时间戳同步的 方法, 如图 3所示, 该方法包括以下几个步骤: In this embodiment, the standby OLT selects the reference ONU to implement the method for timestamp synchronization of the active and standby OLTs. As shown in FIG. 3, the method includes the following steps:
步骤 301 : 备用 OLT将本地时间戳计数器的值 t2置 0,将基准 ONU号 置为空, 一般以 -1表示, 启动周期为 16ns的定时器; 步骤 302: 判断 16ns定时器是否超时, 若超时则执行步骤 303 , 否则执 行步骤 304; Step 301: The standby OLT sets the value t2 of the local timestamp counter to 0, sets the reference ONU number to be empty, is generally represented by -1, and starts a timer with a period of 16 ns; Step 302: Determine whether the 16ns timer expires, if it times out, go to step 303, otherwise go to step 304;
步骤 303:备用 OLT按公式( 1 )对本地时间戳计数器的值 t2进行累加, 执行步骤 302; Step 303: The standby OLT accumulates the value t2 of the local timestamp counter according to the formula (1), and performs step 302;
t2 = (t2 + 1) % 232 ( 1 ) T2 = (t2 + 1) % 2 32 ( 1 )
其中, %表示取余操作。 Where % indicates the remainder operation.
步骤 304:备用 OLT查询是否接收到主用 OLT发送的与所有在线 ONU 的 RTT值, 若接收到, 则执行步骤 305 , 否则执行步骤 306; Step 304: The standby OLT queries whether the RTT value sent by the active OLT and all the online ONUs is received. If yes, step 305 is performed; otherwise, step 306 is performed;
步骤 305: 备用 OLT将接收到的主用 OLT与所有在线 ONU的 RTT值 保存到本地, 执行步骤 302; Step 305: The standby OLT saves the received RTT value of the active OLT and all online ONUs to the local, and performs step 302;
步骤 306: 备用 OLT查询是否有 ONU发生离线事件、且发生离线事件 的 ONU号为基准 ONU号, 若是则执行步骤 307, 否则执行步骤 310; Step 306: The standby OLT queries whether there is an offline event of the ONU, and the ONU number of the offline event is the reference ONU number, if yes, step 307 is performed, otherwise step 310 is performed;
本步骤中,在有 ONU发生离线事件时,主用 OLT向备用 OLT发送 ONU 发生离线事件的通知消息, 备用 OLT查询是否有所述通知消息, 若有则进 一步查询所述通知消息中发生离线事件的 ONU号是否为基准 ONU号, 若 为基准 ONU号, 则执行步骤 307, 若备用 OLT查询到没有所述通知消息、 或查询所述通知消息中发生离线事件的 ONU号不为基准 ONU号时, 则执 行步骤 310; In this step, when an ONU has an offline event, the active OLT sends a notification message that the ONU has an offline event to the standby OLT, and the standby OLT queries whether the notification message is present, and if so, further queries the offline event in the notification message. If the ONU number is the reference ONU number, if it is the reference ONU number, step 307 is performed, if the standby OLT queries that there is no notification message, or the ONU number of the offline event in the notification message is not the reference ONU number , step 310 is performed;
步骤 307: 备用 OLT将基准 ONU号置为空; Step 307: The standby OLT sets the reference ONU number to be empty.
步骤 308: 备用 OLT判断是否存在一个在线 ONU p, 若存在, 则执行 步骤 309, 否则执行步骤 302; Step 308: The standby OLT determines whether there is an online ONU p, if yes, step 309 is performed, otherwise step 302 is performed;
本步骤中, 所述一个在线 ONU p的选择可以是在所有在线 ONU中任 意选择一个, 也可以是按照在线 ONU的 ONU号顺序, 选择排在最前面的 一个 0而。 In this step, the selection of the online ONU p may be any one of all online ONUs, or may be selected according to the ONU number of the online ONU.
步骤 309: 备用 OLT将基准 ONU号置为 p, 执行步骤 302; 步骤 310:备用 OLT判断基准 ONU号是否为空,若是则执行步骤 308, 否则执行步骤 311 ; Step 309: The standby OLT sets the reference ONU number to p, and performs step 302; Step 310: The standby OLT determines whether the reference ONU number is empty. If yes, step 308 is performed; otherwise, step 311 is performed;
步骤 311 : 备用 OLT根据基准 ONU号查询是否接收到基准 ONU的 MPCP协议帧, 若是则执行步骤 312, 否则执行步骤 302; Step 311: The standby OLT queries whether the MPCP protocol frame of the reference ONU is received according to the reference ONU number, if yes, step 312 is performed, otherwise step 302 is performed;
步骤 312: 备用 OLT提取接收到的基准 ONU的 MPCP协议帧中的时 间戳,所述时间戳设为 tl ,从本地保存的主用 OLT与所有在线 ONU的 RTT 值中查询主用 OLT与基准 ONU的最新 RTT值, 所述 RTT值设为 r; Step 312: The backup OLT extracts the timestamp in the received MPCP protocol frame of the reference ONU, and the timestamp is set to tl. The primary OLT and the reference ONU are queried from the locally stored active OLT and the RTT values of all online ONUs. The latest RTT value, the RTT value is set to r;
步骤 313: 备用 OLT按公式(2 )更新本地时间戳计数器的值 t2, 执行 步骤 302; Step 313: The standby OLT updates the value t2 of the local timestamp counter according to formula (2), and performs step 302;
t2 = (tl + r) %232 ( 2 ) T2 = (tl + r) %2 32 ( 2 )
其中, %表示取余操作。 Where % indicates the remainder operation.
为了实现上述方法, 本发明还提供了一种实现主备 OLT时间戳同步的 系统, 如图 4所示, 该系统包括: 主用 OLT、 备用 OLT; 其中, In order to implement the foregoing method, the present invention further provides a system for implementing time-stamp synchronization of the active and standby OLTs. As shown in FIG. 4, the system includes: a primary OLT and a standby OLT;
主用 OLT和 /或备用 OLT选择基准 ONU; The primary OLT and/or the standby OLT select the reference ONU;
所述主用 OLT, 还用于向备用 OLT同步发送自身与所有在线 ONU的 RTT值或自身与基准 ONU的 RTT值; 其中, 所述同步发送一般是定期发 送、 和 /或在主用 OLT与任意一个在线 ONU的 RTT值改变时发送、 和 /或 在主用 OLT与基准 ONU的 RTT值改变时发送; The primary OLT is further configured to synchronously send the RTT value of itself and all online ONUs or the RTT value of itself and the reference ONU to the standby OLT; wherein the synchronous transmission is generally sent periodically, and/or in the primary OLT. Transmitted when the RTT value of any one of the online ONUs is changed, and/or when the RTT value of the primary OLT and the reference ONU is changed;
所述备用 OLT,还用于启动本地时间戳计数器, 在接收到基准 ONU的 MPCP协议帧后, 根据所述 MPCP协议帧中的时间戳和主用 OLT与基准 ONU的最新 RTT值设置本地时间戳计数器的值; The standby OLT is further configured to start a local timestamp counter, and after receiving the MPCP protocol frame of the reference ONU, set a local timestamp according to the timestamp in the MPCP protocol frame and the latest RTT value of the primary OLT and the reference ONU. The value of the counter;
进一步的,所述备用 OLT用于选择基准 ONU时,所述备用 OLT包括: 时间戳计数器 41、 基准 ONU设置模块 42、 RTT值保存模块 43、 帧接收模 块 44、 更新模块 45; 其中, Further, when the standby OLT is used to select the reference ONU, the standby OLT includes: a timestamp counter 41, a reference ONU setting module 42, an RTT value saving module 43, a frame receiving module 44, and an updating module 45;
时间戳计数器 41 , 包括一个周期为 16ns的定时器, 用于在初始化时启 动所述 16ns定时器,在 16ns定时器每次超时时,对自身的计数值进行累加; 具体的, 设时间戳计数器 41 的值为 t2 , 在 16ns定时器每次超时时, 时间戳计数器 41按照公式( 1 )对自身的计数值进行累加; The timestamp counter 41 includes a timer with a period of 16 ns, which is used to initialize The 16 ns timer is incremented, and each time the 16 ns timer expires, the count value of the timer is incremented. Specifically, the value of the time stamp counter 41 is set to t2, and each timeout of the 16 ns timer, the timestamp counter 41 Accumulate the count value of itself according to formula (1);
基准 ONU设置模块 42, 用于选择基准 ONU, 在基准 ONU号不为空 时通知 RTT值保存模块 43 ; The reference ONU setting module 42 is configured to select the reference ONU, and notify the RTT value saving module 43 when the reference ONU number is not empty;
具体的,所述基准 ONU设置模块 42在初始化时设置基准 ONU号为空, 在基准 ONU号为空时, 将一个在线 ONU的 ONU号设置为基准 ONU号, 并将基准 ONU号同步到主用 OLT, 通知 RTT值保存模块 43; Specifically, the reference ONU setting module 42 sets the reference ONU number to be empty during initialization, and sets the ONU number of an online ONU as the reference ONU number when the reference ONU number is empty, and synchronizes the reference ONU number to the primary use. OLT, notify the RTT value saving module 43;
所述一个在线 ONU可以是在所有在线 ONU中任意选择一个, 也可以 是按照在线 ONU的 ONU号顺序, 选择排在最前面的一个 ONU; The one ONRU may be arbitrarily selected in all online ONUs, or may be selected in the first ONU according to the ONU number of the online ONUs;
进一步的, 所述基准 ONU设置模块 42 , 还用于查询出有 ONU发生离 线事件、 且发生离线事件的 ONU号为基准 ONU号时, 设置基准 ONU号 为空, 重新将一个在线 ONU的 ONU号设置为基准 ONU号, 并将该基准 ONU号同步到备用 OLT或主用 OLT; Further, the reference ONU setting module 42 is further configured to: when the ONU number of the ONU occurs, and the ONU number of the offline event is the reference ONU number, set the reference ONU number to be empty, and re-set the ONU number of an online ONU. Set to the reference ONU number, and synchronize the reference ONU number to the standby OLT or the primary OLT;
RTT值保存模块 43 ,用于接收主用 OLT发送的与所有在线 ONU的 RTT 值或与基准 ONU的 RTT值, 并保存到本地; The RTT value saving module 43 is configured to receive the RTT value sent by the primary OLT and all the online ONUs or the RTT value of the reference ONU, and save the locality;
帧接收模块 44, 用于根据基准 ONU设置模块 42设置的基准 ONU号, 查询出接收到基准 ONU的 MPCP协议帧时, 提取所述 MPCP协议帧中的 时间戳, 所述时间戳设为 tl , 之后通知更新模块 45; The frame receiving module 44 is configured to extract, according to the reference ONU number set by the reference ONU setting module 42, the timestamp in the MPCP protocol frame when the MPCP protocol frame of the reference ONU is received, and the timestamp is set to tl. Then notify the update module 45;
更新模块 45 ,用于从 RTT值保存模块 43保存的 RTT值中查询主用 OLT 与基准 ONU的最新 RTT值,根据所述 RTT值和帧接收模块 44提取的时间 戳得到时间戳计数器的值, 更新时间戳计数器 41的值; The update module 45 is configured to query the latest RTT value of the primary OLT and the reference ONU from the RTT values saved by the RTT value saving module 43, and obtain the value of the timestamp counter according to the RTT value and the timestamp extracted by the frame receiving module 44. Updating the value of the timestamp counter 41;
具体的,所述更新模块 45从 RTT值保存模块 43保存的 RTT值中查询 主用 OLT与基准 ONU的最新 RTT值, 所述 RTT值设为 r, 根据所述 RTT 值 r和帧接收模块 44提取的时间戳 tl得到时间戳计数器的值为 t2,更新时 间戳计数器 41的值为 t2; 所述 t2按照公式( 2 )进行计算得到。 Specifically, the update module 45 queries the latest RTT value of the primary OLT and the reference ONU from the RTT value saved by the RTT value saving module 43, and the RTT value is set to r according to the RTT value r and the frame receiving module 44. The extracted timestamp tl gets the value of the timestamp counter t2, when updating The value of the stamp counter 41 is t2; the t2 is calculated according to the formula (2).
综上所述,备用 OLT根据主用 OLT与基准 ONU的 RRT值及基准 ONU 的 MPCP协议帧中的时间戳, 更新本地时间戳计数器, 从而与主用 OLT的 时间戳同步, 可以避免在倒换中 ONU因时间戳漂移发生离线, 从而保证倒 换能快速完成。 而且, 对 ONU要求较低, 不需要有 hold over功能, 能兼 容所有现网 ONU设备。 In summary, the standby OLT updates the local timestamp counter according to the RRT value of the primary OLT and the reference ONU and the timestamp in the MPCP protocol frame of the reference ONU, so as to be synchronized with the timestamp of the primary OLT, which can be avoided in the switching. The ONU goes offline due to time stamp drift, thus ensuring that the switching can be completed quickly. In addition, the ONU requirement is low, and the hold over function is not required. It can be compatible with all ONU devices on the live network.
以上所述, 仅为本发明的较佳实施例而已, 并非用于限定本发明的保 护范围, 凡在本发明的精神和原则之内所作的任何修改、 等同替换和改进 等, 均应包含在本发明的保护范围之内。 The above description is only for the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included. Within the scope of protection of the present invention.
Claims
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201010259340.8 | 2010-08-19 | ||
| CN201010259340.8A CN102377556B (en) | 2010-08-19 | 2010-08-19 | A kind ofly realize the synchronous method and system of active and standby optical line terminal timestamp |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2012022163A1 true WO2012022163A1 (en) | 2012-02-23 |
Family
ID=45604738
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2011/073094 Ceased WO2012022163A1 (en) | 2010-08-19 | 2011-04-20 | Method and system for implementing time stamp synchronization between main and standby optical line terminals |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN102377556B (en) |
| WO (1) | WO2012022163A1 (en) |
Families Citing this family (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| WO2014161602A1 (en) | 2013-04-05 | 2014-10-09 | Telefonaktiebolaget L M Ericsson (Publ) | Handling of timers |
| CN104753584B (en) * | 2015-04-03 | 2017-06-20 | 烽火通信科技股份有限公司 | EPON backbone's optical link protection system and its quick method switched of realization |
| CN108259106A (en) * | 2016-12-29 | 2018-07-06 | 深圳市中兴微电子技术有限公司 | A kind of time stamp treating method and apparatus in Ethernet passive optical network |
Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1866804A (en) * | 2005-10-19 | 2006-11-22 | 华为技术有限公司 | Method for carrying out fault protection inversion on main stem optical fibre of passive optical network |
| CN101431385A (en) * | 2008-08-26 | 2009-05-13 | 中兴通讯股份有限公司 | Frequency and time synchronization method for passive optical network |
| CN101557539A (en) * | 2008-04-09 | 2009-10-14 | 华为技术有限公司 | Optical network data transmission method as well as system and equipment thereof |
Family Cites Families (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20020171895A1 (en) * | 2001-04-25 | 2002-11-21 | Glory Telecommunications Co., Ltd. | Automatic ranging in a passive optical network |
| KR100475440B1 (en) * | 2003-01-07 | 2005-03-10 | 삼성전자주식회사 | The method for RTT estimation in EPON system |
| US8001076B2 (en) * | 2005-07-12 | 2011-08-16 | International Business Machines Corporation | Ranging scalable time stamp data synchronization |
| CN101459502A (en) * | 2007-12-13 | 2009-06-17 | 华为技术有限公司 | Method and apparatus for network clock synchronization |
| WO2009118878A1 (en) * | 2008-03-28 | 2009-10-01 | 富士通アクセス株式会社 | Pon system |
| CN101771528B (en) * | 2008-12-31 | 2013-08-07 | 华为技术有限公司 | Method, device and system for realizing clock synchronization |
-
2010
- 2010-08-19 CN CN201010259340.8A patent/CN102377556B/en not_active Expired - Fee Related
-
2011
- 2011-04-20 WO PCT/CN2011/073094 patent/WO2012022163A1/en not_active Ceased
Patent Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1866804A (en) * | 2005-10-19 | 2006-11-22 | 华为技术有限公司 | Method for carrying out fault protection inversion on main stem optical fibre of passive optical network |
| CN101557539A (en) * | 2008-04-09 | 2009-10-14 | 华为技术有限公司 | Optical network data transmission method as well as system and equipment thereof |
| CN101431385A (en) * | 2008-08-26 | 2009-05-13 | 中兴通讯股份有限公司 | Frequency and time synchronization method for passive optical network |
Also Published As
| Publication number | Publication date |
|---|---|
| CN102377556B (en) | 2016-04-13 |
| CN102377556A (en) | 2012-03-14 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| EP2675102B1 (en) | Communication system time synchronization method, slave station apparatus, master station apparatus, control apparatus, and program | |
| JP5254494B2 (en) | Method and apparatus for protecting trunk optical fiber in Ethernet passive optical network | |
| US8223648B2 (en) | Method and apparatus for synchronizing time in a passive optical network | |
| US9179204B2 (en) | Optical network system | |
| US8995837B2 (en) | Subscriber-side optical communication device, communication system, control device, and power-saving control method | |
| EP2605427B1 (en) | Method, system and optical network unit for synchronizing data | |
| JP4913865B2 (en) | Optical communication network system, master station optical communication device, optical communication method and communication program | |
| WO2011012007A1 (en) | Method and system for quickly updating ranging results of optical network unit by optical line terminal | |
| CN103227966B (en) | Transparent protection switching operation in a Pon | |
| CN101378311A (en) | Method, system and equipment for protecting rearrange | |
| WO2010088830A1 (en) | Time synchronization method and corresponding synchronization system for passive optical network system | |
| WO2010031326A1 (en) | Method for switching data link in the optical network system, optical line terminal and system | |
| WO2011144110A2 (en) | Method, system and device for communication in the optical network system | |
| CN102149027B (en) | Path switching method, system and downlink data transmission method | |
| WO2011157167A2 (en) | Method and device for transmitting data in passive optical network | |
| WO2013075507A1 (en) | Data sending method and system | |
| WO2012022163A1 (en) | Method and system for implementing time stamp synchronization between main and standby optical line terminals | |
| McGettrick et al. | Ultra-fast 1+ 1 protection in 10 Gb/s symmetric long reach PON | |
| WO2008122178A1 (en) | A data transmission method, system and terminal | |
| WO2012034382A1 (en) | Method for controlling the deregistering of optical network unit (onu) and onu thereof | |
| WO2012119490A1 (en) | Method and system for protecting passive optical network | |
| CN109391319B (en) | double-PON MAC time synchronization switching processing method and device | |
| JP5425692B2 (en) | MPCP link management circuit | |
| JP2019140657A (en) | Optical line terminal, optical network unit, optical communication system, station side program, subscriber side program, and time synchronization program |
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: 11817691 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: 11817691 Country of ref document: EP Kind code of ref document: A1 |