Movatterモバイル変換


[0]ホーム

URL:


CN103338124A - Abnormal chain scission processing method, device and system - Google Patents

Abnormal chain scission processing method, device and system
Download PDF

Info

Publication number
CN103338124A
CN103338124ACN201310293884XACN201310293884ACN103338124ACN 103338124 ACN103338124 ACN 103338124ACN 201310293884X ACN201310293884X ACN 201310293884XACN 201310293884 ACN201310293884 ACN 201310293884ACN 103338124 ACN103338124 ACN 103338124A
Authority
CN
China
Prior art keywords
control appliance
data
area network
data block
control device
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201310293884XA
Other languages
Chinese (zh)
Other versions
CN103338124B (en
Inventor
韦启蒙
刘楚腾
陈保栈
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
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 LtdfiledCriticalHuawei Technologies Co Ltd
Priority to CN201310293884.XApriorityCriticalpatent/CN103338124B/en
Publication of CN103338124ApublicationCriticalpatent/CN103338124A/en
Application grantedgrantedCritical
Publication of CN103338124BpublicationCriticalpatent/CN103338124B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Images

Landscapes

Abstract

Translated fromChinese

本发明提供一种异常断链的处理方法、装置和系统,涉及通信技术领域,以在利用数据去重技术进行数据传输时,减小广域网加速控制器之间的数据块的交互次数,提高了广域网传输的速度。本发明的方法具体可以包括:当第一控制设备所在的局域网断链时,第一控制设备通过广域网向第二控制设备发送第一控制设备存储的第一数据块,以便第二控制设备存储第一数据块;当第一控制设备所在的局域网连接恢复正常后,第一控制设备向第二控制设备发送第一数据的索引,以便第二控制设备根据第一数据的索引获取所述第一数据,第一数据为第一数据块中的数据。可应用于异常断链的处理中。

Figure 201310293884

The invention provides a processing method, device and system for abnormal link disconnection, which relate to the field of communication technology, so as to reduce the number of interactions of data blocks between wide area network acceleration controllers when data transmission is performed using data deduplication technology, and improve the The speed of the WAN transfer. The method of the present invention may specifically include: when the local area network where the first control device is located is disconnected, the first control device sends the first data block stored by the first control device to the second control device through the wide area network, so that the second control device can store the first data block. A data block; when the LAN connection where the first control device is located returns to normal, the first control device sends the index of the first data to the second control device, so that the second control device obtains the first data according to the index of the first data , the first data is the data in the first data block. It can be applied to the processing of abnormal link disconnection.

Figure 201310293884

Description

Translated fromChinese
异常断链的处理方法、装置和系统Processing method, device and system for abnormal link disconnection

技术领域technical field

本发明涉及通信技术领域,尤其涉及异常断链的处理方法、装置和系统。The present invention relates to the technical field of communications, and in particular to a processing method, device and system for abnormal link disconnection.

背景技术Background technique

数据去重技术是WAN(Wide Area Network,广域网)加速的核心技术之一,它需要WAN两端的WOC(WAN optimization controller,广域网加速控制器)部署cache(高速缓冲存储器)用来存储传输的数据块。Data deduplication technology is one of the core technologies of WAN (Wide Area Network, wide area network) acceleration, which requires WOC (WAN optimization controller, wide area network acceleration controller) at both ends of the WAN to deploy cache (high-speed buffer memory) to store transmitted data blocks .

具体的,如图1所示,采用数据去重技术进行数据传输可以但不限于包括:Specifically, as shown in Figure 1, the use of data deduplication technology for data transmission may include, but is not limited to:

WOC1可以运用去重技术将发送端通过局域网发送的大数据切成数据块(在WAN上传输的数据是以数据块为单位进行传输的)后再进行传输(小数据可被认为是一个数据块),同时,WOC1的cache1存储接收到的数据块;当数据块在对端WOC2的cache2中已经有存储时,WOC1可以将该数据块的索引(可以为数据块的哈希值)通过WAN传输至WOC2,由于索引的大小远小于数据块的大小,这就极大的减少了WAN传输的流量,起到加速的效果;WOC2再根据接收到的索引从自身的cache中获取相应的数据块,并将该数据块传输至相应的接收端。若cache2中未存储数据块,说明数据块可能是第一次进行传输,则WOC1将数据块传输至WOC2,并存储至cache2中,在第二次需要传输该数据块时,则可以传输该数据块的索引。WOC1 can use deduplication technology to cut the large data sent by the sender through the LAN into data blocks (the data transmitted on the WAN is transmitted in units of data blocks) and then transmit it (small data can be considered as a data block) ), at the same time, the cache1 of WOC1 stores the received data block; when the data block is already stored in the cache2 of the peer WOC2, WOC1 can transmit the index of the data block (which can be the hash value of the data block) through WAN As for WOC2, since the size of the index is much smaller than the size of the data block, this greatly reduces the traffic transmitted by the WAN and has the effect of accelerating; WOC2 then obtains the corresponding data block from its own cache according to the received index, And transmit the data block to the corresponding receiving end. If no data block is stored in cache2, it means that the data block may be transmitted for the first time, then WOC1 transmits the data block to WOC2 and stores it in cache2, and when the data block needs to be transmitted for the second time, the data can be transmitted The index of the block.

如图1说明了通过WAN多次传输同一数据块时的流量变化,同一数据块在WAN第二次传输时只需要传输索引,使得流量变小,传输就比较快,起到明显的加速效果。Figure 1 illustrates the traffic changes when the same data block is transmitted multiple times through the WAN. The same data block only needs to transmit the index when the same data block is transmitted for the second time, so that the traffic becomes smaller and the transmission is faster, which has an obvious acceleration effect.

当发送端与WOC1之间、或WOC2与接收端之间的LAN(Local Area Network,局域网)的TCP(Transmission Control Protocol,传输控制协议)连接异常断链时,则会关闭WAN(如图1中WOC1与WOC2之间的WAN)的TCP连接。When the TCP (Transmission Control Protocol, Transmission Control Protocol) connection between the sending end and WOC1, or between WOC2 and the receiving end is abnormally disconnected from the LAN (Local Area Network, local area network), the WAN will be closed (as shown in Figure 1) WAN between WOC1 and WOC2) TCP connection.

在实现上述异常断链的处理的过程中,发明人发现现有技术中至少存在如下问题:TCP连接异常断链时,会导致cache1与cache2之间存储的数据块没有进行同步,即cache1与cache2中存储的数据块不一致,在后续连接恢复后,若传输索引,无法对未存储的数据块的索引进行解码,从而增加了广域网数据块的交互过程,极大的影响了广域网传输的速度。In the process of implementing the above-mentioned abnormal link disconnection process, the inventor found that there are at least the following problems in the prior art: when the TCP connection is abnormally disconnected, the data blocks stored between cache1 and cache2 will not be synchronized, that is, cache1 and cache2 The data blocks stored in the network are inconsistent. After the subsequent connection is restored, if the index is transmitted, the index of the unstored data block cannot be decoded, which increases the interaction process of the WAN data block and greatly affects the speed of the WAN transmission.

发明内容Contents of the invention

本发明的实施例提供一种异常断链的处理方法、装置和系统,以在利用数据去重技术进行数据传输时,减小广域网加速控制器之间的数据块的交互次数,提高了广域网传输的速度。Embodiments of the present invention provide a processing method, device, and system for abnormal link disconnection, so as to reduce the number of interactions of data blocks between WAN acceleration controllers and improve WAN transmission when using data deduplication technology for data transmission. speed.

为达到上述目的,本发明的实施例采用如下技术方案:In order to achieve the above object, embodiments of the present invention adopt the following technical solutions:

第一方面,提供一种异常断链的处理方法,包括:In the first aspect, a processing method for abnormal link disconnection is provided, including:

当第一控制设备所在的局域网断链时,所述第一控制设备通过广域网向第二控制设备发送所述第一控制设备存储的第一数据块,以便所述第二控制设备存储所述第一数据块;When the local area network where the first control device is located is disconnected, the first control device sends the first data block stored by the first control device to the second control device through the wide area network, so that the second control device can store the first data block. a data block;

当所述第一控制设备所在的局域网连接恢复正常后,所述第一控制设备向所述第二控制设备发送第一数据的索引,以便所述第二控制设备根据所述第一数据的索引获取所述第一数据,所述第一数据为所述第一数据块中的数据。When the local area network connection where the first control device is located returns to normal, the first control device sends the index of the first data to the second control device, so that the second control device Acquire the first data, where the first data is data in the first data block.

在第一种可能的实现方式中,当所述第一控制设备所在的局域网断链时,所述方法还包括:In a first possible implementation manner, when the local area network where the first control device is located is disconnected, the method further includes:

所述第一控制设备通过所述广域网向所述第二控制设备发送第一断链指令,以使所述第二控制设备根据所述第一断链指令的指示,将所述第二控制设备存储的第二数据块发送给所述第一控制设备,然后断开所述第二控制设备与所述广域网的连接;The first control device sends a first link disconnection instruction to the second control device through the wide area network, so that the second control device, according to the instruction of the first link disconnection instruction, sends the second control device sending the stored second data block to the first control device, and then disconnecting the second control device from the wide area network;

所述第一控制设备接收并存储所述第二控制设备发送的所述第二数据块;The first control device receives and stores the second data block sent by the second control device;

当所述第一控制设备的局域网连接恢复正常后,所述第一控制设备接收所述第二控制设备发送的第二数据的索引,所述第二数据为所述第二数据块中的数据。After the local area network connection of the first control device returns to normal, the first control device receives the index of the second data sent by the second control device, and the second data is the data in the second data block .

结合第一方面的第一种可能的实现方式,在第二种可能的实现方式中,在所述第一控制设备将所述第一数据块发送至所述第二控制设备后,所述方法还包括:With reference to the first possible implementation of the first aspect, in a second possible implementation, after the first control device sends the first data block to the second control device, the method Also includes:

所述第一控制设备接收所述第二控制设备发送的第二断链指令;The first control device receives a second link disconnection instruction sent by the second control device;

根据所述第二断链指令的指示,断开与所述广域网的连接。Disconnect from the wide area network according to the instruction of the second link disconnection instruction.

结合第一方面的第一种可能的实现方式或第二种可能的实现方式,在第三种可能的实现方式中,所述第一控制设备接收并存储所述第二控制设备发送的所述第二数据块包括:With reference to the first possible implementation manner or the second possible implementation manner of the first aspect, in a third possible implementation manner, the first control device receives and stores the The second data block includes:

所述第一控制设备存储所述第二数据块中与所述第一数据块不同的数据。The first control device stores different data in the second data block from the first data block.

结合第一方面,在第四种可能的实现方式中,当所述第一控制设备所在的局域网断链,且所述第二控制设备所在的局域网也断链时,所述方法还包括:With reference to the first aspect, in a fourth possible implementation manner, when the link of the local area network where the first control device is located is disconnected and the link of the local area network where the second control device is located is also disconnected, the method further includes:

所述第一控制设备接收并存储所述第二控制设备发送的自身存储的第二数据块;The first control device receives and stores the second data block stored by itself sent by the second control device;

在所述第一控制设备所在的局域网与所述第二控制设备所在的局域网均恢复正常后,接收所述第二控制设备发送的第二数据的索引,所述第二数据为所述第二数据块中的数据。After the local area network where the first control device is located and the local area network where the second control device is located both return to normal, receive the index of the second data sent by the second control device, the second data is the second data in the data block.

第二方面,提供另一种异常断链的处理方法,包括:In the second aspect, another method for handling abnormal link disconnection is provided, including:

第二控制设备通过广域网接收并存储第一控制设备发送的所述第一控制设备存储的第一数据块,所述第一数据块是所述第一控制设备在自身所在的局域网断链后发送的;The second control device receives and stores the first data block stored by the first control device sent by the first control device through the wide area network, and the first data block is sent by the first control device after the local area network where it is located is disconnected. of;

接收所述第一控制设备在所述第一控制设备所在的局域网连接恢复后发送的第一数据的索引,所述第一数据为所述第一数据块中的数据;receiving an index of first data sent by the first control device after the local area network connection where the first control device is located is restored, where the first data is data in the first data block;

根据所述第一数据的索引获取所述第一数据。The first data is acquired according to the index of the first data.

在第一种可能的实现方式中,所述方法还包括:In a first possible implementation manner, the method further includes:

所述第二控制设备接收所述第一控制设备在所述第一控制设备所在的局域网断链时发送的第一断链指令;The second control device receives a first link disconnection instruction sent by the first control device when the local area network where the first control device is located is disconnected;

根据所述第一断链指令的指示,断开所述第二控制设备的局域网连接,将自身存储的第二数据块发送至所述第一控制设备;Disconnecting the LAN connection of the second control device according to the instruction of the first link disconnection instruction, and sending the second data block stored by itself to the first control device;

断开所述第二控制设备的广域网连接;disconnecting the wide area network connection of the second control device;

当所述第一控制设备的局域网连接恢复正常后,向所述第一控制设备发送第二数据的索引,所述第二数据为所述第二数据块中的数据。After the local area network connection of the first control device returns to normal, the index of the second data is sent to the first control device, and the second data is the data in the second data block.

结合第二方面的第一种可能的实现方式,在第二种可能的实现方式中,在所述第二控制设备通过广域网接收并存储第一控制设备发送的所述第一控制设备中存储的第一数据块之后,所述方法还包括:With reference to the first possible implementation manner of the second aspect, in a second possible implementation manner, the second control device receives and stores the information stored in the first control device sent by the first control device through a wide area network. After the first data block, the method further includes:

向所述第一控制设备发送第二断链指令,以便所述第一控制设备在将所述第一数据块发送至所述第二控制设备后,根据所述第二断链指令的指示断开所述第一控制设备与所述广域网的连接。sending a second link disconnection instruction to the first control device, so that after the first control device sends the first data block to the second control device, it disconnects according to the instruction of the second link disconnection instruction. Open the connection between the first control device and the wide area network.

结合第二方面或第二方面的第一种可能的实现方式或第二种可能的实现方式,在第三种可能的实现方式中,所述第二控制设备通过广域网接收并存储第一控制设备发送的所述第一控制设备中存储的第一数据块包括:With reference to the second aspect or the first possible implementation manner or the second possible implementation manner of the second aspect, in a third possible implementation manner, the second control device receives and stores the The sent first data block stored in the first control device includes:

所述第二控制设备存储所述第一数据块中与所述第二数据块不同的数据。The second control device stores different data in the first data block from the second data block.

结合第二方面,在第四种可能的实现方式中,当所述第一控制设备所在的局域网断链,且所述第二控制设备所在的局域网也断链时,所述方法还包括:With reference to the second aspect, in a fourth possible implementation manner, when the link of the local area network where the first control device is located is disconnected and the link of the local area network where the second control device is located is also disconnected, the method further includes:

所述第二控制设备向所述第一控制设备发送自身存储的第二数据块;The second control device sends the second data block stored by itself to the first control device;

在所述第一控制设备所在的局域网与所述第二控制设备所在的局域网均恢复正常后,向所述第一控制设备发送第二数据的索引,所述第二数据为所述第二数据块中的数据。After both the local area network where the first control device is located and the local area network where the second control device is located return to normal, send an index of second data to the first control device, where the second data is the second data data in the block.

第三方面,提供一种网络设备,包括:In a third aspect, a network device is provided, including:

第一发送单元,用于当所述网络设备所在的局域网断链时,通过广域网向控制设备发送所述网络设备存储的第一数据块,以便所述控制设备存储所述第一数据块;The first sending unit is configured to send the first data block stored by the network device to the control device through the wide area network when the local area network where the network device is located is disconnected, so that the control device stores the first data block;

第二发送单元,用于当所述网络设备所在的局域网连接恢复正常后,向所述控制设备发送第一数据的索引,以便所述控制设备根据所述第一数据的索引获取所述第一数据,所述第一数据为所述第一数据块中的数据。The second sending unit is configured to send the index of the first data to the control device after the connection of the local area network where the network device is located returns to normal, so that the control device can obtain the first data according to the index of the first data. data, the first data is data in the first data block.

在第一种可能的实现方式中,所述网络设备还包括:In a first possible implementation manner, the network device further includes:

第三发送单元,用于当所述网络设备的局域网断链时,通过所述广域网向所述控制设备发送第一断链指令,以使所述控制设备根据所述第一断链指令的指示,将自身存储的第二数据块发送给所述网络设备,然后断开所述控制设备与所述广域网的连接;A third sending unit, configured to send a first link disconnection instruction to the control device through the wide area network when the local area network of the network device is disconnected, so that the control device follows the instruction of the first link disconnection instruction , sending the second data block stored by itself to the network device, and then disconnecting the control device from the wide area network;

所述第一接收单元,用于接收并存储所述控制设备发送的所述第二数据块;The first receiving unit is configured to receive and store the second data block sent by the control device;

第二接收单元,用于当所述网络设备的局域网连接恢复正常后,接收所述控制设备发送的第二数据的索引,所述第二数据为所述第二数据块中的数据。The second receiving unit is configured to receive the index of the second data sent by the control device after the LAN connection of the network device returns to normal, the second data being the data in the second data block.

结合第三方面的第一种可能的实现方式,在第二种可能的实现方式中,所述网络设备还包括:With reference to the first possible implementation manner of the third aspect, in a second possible implementation manner, the network device further includes:

第三接收单元,用于在所述网络设备将所述第一数据块发送至所述控制设备后,接收所述控制设备发送的第二断链指令;a third receiving unit, configured to receive a second link disconnection instruction sent by the control device after the network device sends the first data block to the control device;

断链单元,用于根据所述第二断链指令的指示,断开与所述广域网的连接。A link breaking unit, configured to break the connection with the wide area network according to the instruction of the second link breaking instruction.

结合第三方面的第一种可能的实现方式或第二种可能的实现方式,在第三种可能的实现方式中,所述第一接收单元,具体用于存储所述第二数据块中与所述第一数据块不同的数据。With reference to the first possible implementation manner or the second possible implementation manner of the third aspect, in a third possible implementation manner, the first receiving unit is specifically configured to store the The first data block is different data.

结合第三方面,在第四种可能的实现方式中,所述网络设备还包括:With reference to the third aspect, in a fourth possible implementation manner, the network device further includes:

第四接收单元,用于当所述网络设备所在的局域网断链,且所述控制设备所在的局域网也断链时,接收并存储所述控制设备发送的自身存储的第二数据块;The fourth receiving unit is configured to receive and store the second data block sent by the control device and stored by itself when the local area network where the network device is located is disconnected and the local area network where the control device is located is also disconnected;

第五接收单元,用于在所述网络设备所在的局域网与所述控制设备所在的局域网均恢复正常后,接收所述控制设备发送的第二数据的索引,所述第二数据为所述第二数据块中的数据。The fifth receiving unit is configured to receive an index of second data sent by the control device after the local area network where the network device is located and the local area network where the control device is located both return to normal, and the second data is the index of the second data sent by the control device. Data in the second data block.

第四方面,提供一种网络设备,包括:In a fourth aspect, a network device is provided, including:

第一接收单元,用于通过广域网接收并存储控制设备发送的所述控制设备存储的第一数据块,所述第一数据块是所述控制设备在自身所在的局域网断链后发送的;The first receiving unit is configured to receive and store the first data block sent by the control device and stored by the control device through the wide area network, and the first data block is sent by the control device after the local area network where it is located is disconnected;

第二接收单元,用于接收所述控制设备在所述控制设备所在的局域网连接恢复后发送的第一数据的索引,所述第一数据为所述第一数据块中的数据;The second receiving unit is configured to receive the index of the first data sent by the control device after the connection of the local area network where the control device is located is restored, the first data is the data in the first data block;

获取单元,用于根据所述第一数据的索引获取所述第一数据。An obtaining unit, configured to obtain the first data according to the index of the first data.

在第一种可能的实现方式中,所述网络设备还包括:In a first possible implementation manner, the network device further includes:

第三接收单元,用于接收所述控制设备在所述控制设备所在的局域网断链时发送的第一断链指令;A third receiving unit, configured to receive a first link disconnection instruction sent by the control device when the local area network where the control device is located is disconnected;

第一断链单元,用于根据所述第一断链指令的指示,断开所述网络设备的局域网连接;a first link disconnection unit, configured to disconnect the LAN connection of the network device according to the instruction of the first link disconnection instruction;

第一发送单元,用于将自身存储的第二数据块发送至所述控制设备;a first sending unit, configured to send the second data block stored by itself to the control device;

第二断链单元,用于断开所述网络设备的广域网连接;a second link disconnection unit, configured to disconnect the wide area network connection of the network device;

第二发送单元,用于当所述控制设备的局域网连接恢复正常后,向所述控制设备发送第二数据的索引,所述第二数据为所述第二数据块中的数据。The second sending unit is configured to send an index of second data to the control device after the local area network connection of the control device returns to normal, and the second data is the data in the second data block.

结合第四方面的第一种可能的实现方式,第二种可能的实现方式中,所述网络设备还包括:With reference to the first possible implementation manner of the fourth aspect, in the second possible implementation manner, the network device further includes:

第三发送单元,用于在所述网络设备通过广域网接收并存储控制设备发送的所述控制设备中存储的第一数据块之后,向所述控制设备发送第二断链指令,以便所述控制设备在将所述第一数据块发送至所述网络设备后,根据所述第二断链指令的指示断开所述控制设备与所述广域网的连接。The third sending unit is configured to send a second link disconnection instruction to the control device after the network device receives and stores the first data block sent by the control device through the wide area network and stored in the control device, so that the control After the device sends the first data block to the network device, it disconnects the connection between the control device and the wide area network according to the instruction of the second link disconnection instruction.

结合第四方面或第四方面的第一种可能的实现方式或第二种可能的实现方式,在第三种可能的实现方式中,所述第一接收单元,具体用于存储所述第一数据块中与所述第二数据块不同的数据。With reference to the fourth aspect or the first possible implementation manner or the second possible implementation manner of the fourth aspect, in a third possible implementation manner, the first receiving unit is specifically configured to store the first Data in the data block that is different from the second data block.

结合第四方面,在第四种可能的实现方式中,所述网络设备还包括:With reference to the fourth aspect, in a fourth possible implementation manner, the network device further includes:

第四发送单元,用于当所述控制设备所在的局域网断链,且所述网络设备所在的局域网也断链时,向所述控制设备发送自身存储的第二数据块;The fourth sending unit is configured to send the second data block stored by itself to the control device when the local area network where the control device is located is disconnected and the local area network where the network device is located is also disconnected;

第五发送单元,用于在所述控制设备所在的局域网断链,且所述网络设备所在的局域网也恢复正常后,向所述控制设备发送第二数据的索引,所述第二数据为所述第二数据块中的数据。The fifth sending unit is configured to send an index of second data to the control device after the local area network where the control device is located is disconnected and the local area network where the network device is located returns to normal, the second data is the the data in the second data block.

第五方面,提供一种异常断链的处理系统,包括:In the fifth aspect, a processing system for abnormal link disconnection is provided, including:

第一控制设备和第二控制设备,所述第一控制设备通过局域网与客户端连接,通过广域网与所述第二控制设备连接,所述第二控制设备通过局域网与服务器连接;A first control device and a second control device, the first control device is connected to a client through a local area network, connected to the second control device through a wide area network, and the second control device is connected to a server through a local area network;

所述第一控制设备,用于当第一控制设备与所述客户端之间的局域网断链时,通过所述广域网向所述第二控制设备发送所述第一控制设备存储的第一数据块,以便所述第二控制设备存储所述第一数据块;当所述第一控制设备与所述客户端之间的局域网连接恢复正常后,向所述第二控制设备发送第一数据的索引,所述第一数据为所述第一数据块中的数据;The first control device is configured to send the first data stored by the first control device to the second control device through the wide area network when the link between the first control device and the client is disconnected. block, so that the second control device stores the first data block; when the LAN connection between the first control device and the client returns to normal, send the first data block to the second control device an index, the first data is data in the first data block;

所述第二控制设备,用于通过所述广域网接收并存储所述第一数据块;接收所述第一控制设备在所述第一控制设备所在的局域网连接恢复后发送的所述第一数据的索引;根据所述第一数据的索引获取所述第一数据。The second control device is configured to receive and store the first data block through the wide area network; receive the first data sent by the first control device after the connection of the local area network where the first control device is located is restored the index of the first data; obtaining the first data according to the index of the first data.

在第一种可能的实现方式中,当所述第一控制设备与所述客户端之间的局域网断链时,In a first possible implementation manner, when the local area network link between the first control device and the client is disconnected,

所述第一控制设备,还用于通过所述广域网向所述第二控制设备发送第一断链指令,以使所述第二控制设备根据所述第一断链指令的指示,将所述第二控制设备存储的第二数据块发送给所述第一控制设备,然后断开所述第二控制设备的广域网连接;接收并存储所述第二控制设备发送的所述第二数据块;当所述第一控制设备的局域网连接恢复正常后,接收所述第二控制设备发送的第二数据的索引,所述第二数据为所述第二数据块中的数据;The first control device is further configured to send a first link disconnection instruction to the second control device through the wide area network, so that the second control device, according to the instruction of the first link disconnection instruction, sends the sending the second data block stored by the second control device to the first control device, and then disconnecting the wide area network connection of the second control device; receiving and storing the second data block sent by the second control device; After the local area network connection of the first control device returns to normal, receive the index of the second data sent by the second control device, the second data is the data in the second data block;

所述第二控制设备,还用于接收所述第一断链指令;根据所述第一断链指令的指示,断开所述第二控制设备的局域网连接,将所述第二数据块发送至所述第一控制设备;断开所述第二控制设备的广域网连接;当所述第一控制设备的局域网连接恢复正常后,向所述第一控制设备发送所述第二数据的索引。The second control device is further configured to receive the first link disconnection instruction; disconnect the LAN connection of the second control device according to the instruction of the first link disconnection instruction, and send the second data block to the first control device; disconnect the wide area network connection of the second control device; and send the index of the second data to the first control device after the local area network connection of the first control device returns to normal.

结合第五方面的第一种可能的实现方式,在第二种可能的实现方式中,所述第一控制设备,还用于在所述第一控制设备将所述第一数据块发送至所述第二控制设备后,接收所述第二控制设备发送的第二断链指令;根据所述第二断链指令的指示,断开与所述广域网的连接;With reference to the first possible implementation manner of the fifth aspect, in a second possible implementation manner, the first control device is further configured to send the first data block to the After the second control device, receiving a second link disconnection instruction sent by the second control device; according to the instruction of the second link disconnection instruction, disconnecting from the wide area network;

所述第二控制设备,还用于在所述第二控制设备通过广域网接收并存储第一控制设备发送的所述第一控制设备中存储的第一数据块之后,向所述第一控制设备发送所述第二断链指令。The second control device is further configured to, after the second control device receives and stores the first data block stored in the first control device sent by the first control device through the wide area network, send the first data block to the first control device Send the second link disconnection instruction.

结合第五方面的第一种可能的实现方式或第二种可能的实现方式,在第三种可能的实现方式中,所述第一控制设备,具体用于存储所述第二数据块中与所述第一数据块不同的数据;With reference to the first possible implementation manner or the second possible implementation manner of the fifth aspect, in a third possible implementation manner, the first control device is specifically configured to store the different data of the first data block;

所述第二控制设备,具体用于存储所述第一数据块中与所述第二数据块不同的数据。The second control device is specifically configured to store data in the first data block that is different from the second data block.

结合第五方面,在第四种可能的实现方式中,当所述第一控制设备所在的局域网断链,且所述第二控制设备所在的局域网也断链时,With reference to the fifth aspect, in a fourth possible implementation manner, when the link of the local area network where the first control device is located is disconnected, and the link of the local area network where the second control device is located is also disconnected,

所述第一控制设备,还用于接收并存储所述第二控制设备发送的自身存储的第二数据块;在所述第一控制设备所在的局域网与所述第二控制设备所在的局域网均恢复正常后,接收所述第二控制设备发送的第二数据的索引,所述第二数据为所述第二数据块中的数据;The first control device is further configured to receive and store the second data block sent by the second control device; where the local area network where the first control device is located and the local area network where the second control device is located are both After returning to normal, receiving the index of the second data sent by the second control device, the second data is the data in the second data block;

所述第二控制设备,还用于向所述第一控制设备发送所述第二数据块;在所述第一控制设备所在的局域网与所述第二控制设备所在的局域网均恢复正常后,向所述第一控制设备发送所述第二数据的索引。The second control device is further configured to send the second data block to the first control device; after both the local area network where the first control device is located and the local area network where the second control device is located return to normal, An index of the second data is sent to the first control device.

本发明实施例提供的异常断链的处理方法、装置和系统,采用上述方案后,当第一控制设备的局域网连接断链时,第一控制设备通过广域网将第一数据块发送至第二控制设备存储,这样,第二控制设备中存储有第一控制设备中的所有数据块,在连接恢复后,第一控制设备向第二控制设备发送第一数据的索引时,由于第二控制设备存储有该索引对应的数据,因此第二控制设备可以对该索引进行解码后得到第一数据,避免了第一控制设备与第二控制设备之间传输第一数据,减少了广域网数据交互过程,增加了广域网传输的速度。In the method, device and system for processing abnormal link disconnection provided by the embodiments of the present invention, after adopting the above scheme, when the LAN connection of the first control device is disconnected, the first control device sends the first data block to the second control device through the wide area network. Device storage, in this way, all the data blocks in the first control device are stored in the second control device. After the connection is restored, when the first control device sends the index of the first data to the second control device, because the second control device stores There is data corresponding to the index, so the second control device can decode the index to obtain the first data, which avoids the transmission of the first data between the first control device and the second control device, reduces the data interaction process of the wide area network, and increases The transmission speed of the WAN.

附图说明Description of drawings

为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only These are some embodiments of the present invention. Those skilled in the art can also obtain other drawings based on these drawings without creative work.

图1为现有技术中采用去重技术进行数据传输的方法流程图;Fig. 1 is a flow chart of a method for data transmission using deduplication technology in the prior art;

图2为TCP三次握手的数据交互图;Figure 2 is a data interaction diagram of the TCP three-way handshake;

图3为现有技术中当Client侧的TCP连接异常断链时,Sever向Client发送数据的流程图;Fig. 3 is the flow chart of Sever sending data to Client when the TCP connection on Client side is disconnected abnormally in the prior art;

图4为本实施例提供的一种在第一控制设备的局域网断链时,异常断链的处理方法流程图;FIG. 4 is a flow chart of a processing method for abnormal link disconnection when the local area network of the first control device is disconnected provided by this embodiment;

图5为本实施例提供的一种在第二控制设备的局域网断链时,异常断链的处理方法流程图;FIG. 5 is a flowchart of a processing method for abnormal link disconnection when the LAN link of the second control device is disconnected provided by this embodiment;

图6为本实施例提供的一种在WOC1的局域网断链时,异常断链的处理方法的数据交互图;FIG. 6 is a data interaction diagram of a processing method for abnormal link disconnection when the local area network of WOC1 is disconnected provided by this embodiment;

图7为本实施例提供的一种在WOC1的局域网断链时,异常断链的处理方法流程图;FIG. 7 is a flowchart of a processing method for abnormal link disconnection when the local area network of WOC1 is disconnected provided by this embodiment;

图8为本实施例提供的一种在WOC1和WOC2的局域网均断链时,异常断链的处理方法的数据交互图;FIG. 8 is a data interaction diagram of a processing method for abnormal link disconnection when both LANs of WOC1 and WOC2 are disconnected provided by this embodiment;

图9为本实施例提供的一种在WOC1和WOC2的局域网均断链时,异常断链的处理方法的流程图;FIG. 9 is a flow chart of a processing method for abnormal link disconnection when both WOC1 and WOC2 LANs are disconnected provided by this embodiment;

图10为本实施例提供的一种第一控制设备的结构示意图;FIG. 10 is a schematic structural diagram of a first control device provided in this embodiment;

图11为本实施例提供的另一种第一控制设备的结构示意图;FIG. 11 is a schematic structural diagram of another first control device provided in this embodiment;

图12为本实施例提供的一种第二控制设备的结构示意图;FIG. 12 is a schematic structural diagram of a second control device provided in this embodiment;

图13为本实施例提供的另一种第二控制设备的结构示意图;FIG. 13 is a schematic structural diagram of another second control device provided in this embodiment;

图14为本实施例提供的一种异常断链的处理系统的结构示意图;FIG. 14 is a schematic structural diagram of a processing system for abnormal link disconnection provided by this embodiment;

图15为本实施例提供的一种计算机的结构示意图。FIG. 15 is a schematic structural diagram of a computer provided in this embodiment.

具体实施方式Detailed ways

下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of the present invention.

为了可以更好的对以下实施例进行理解,首先对与以下实施例相关的技术进行简单介绍。In order to better understand the following embodiments, technologies related to the following embodiments are briefly introduced first.

本实施例应用的背景可以包括:WOC通过TCP代理设备(proxy)截获网络上传输的数据。如图2所示,链路上节点间的TCP连接是终结式的,即每相邻个节点间都是独立的TCP连接,都是独立的TCP三次握手过程。The application background of this embodiment may include: the WOC intercepts data transmitted on the network through a TCP proxy device (proxy). As shown in Figure 2, the TCP connection between nodes on the link is terminated, that is, each adjacent node is an independent TCP connection, which is an independent TCP three-way handshake process.

具体的,TCP三次握手过程可以但不限于包括:Specifically, the TCP three-way handshake process may include, but is not limited to:

在Client(客户端)与WOC1建立连接之前,首先,Client向WOC1发送SYN(Synchronize Sequence Numbers,同步序列编号);然后,WOC1向Client发送SYN ACK(SYN响应);最后,Client向WOC1发送ACK。Before the Client (client) establishes a connection with WOC1, first, the Client sends SYN (Synchronize Sequence Numbers) to WOC1; then, WOC1 sends SYN ACK (SYN response) to Client; finally, Client sends ACK to WOC1.

其中,本实施例对TCP三次握手过程不作限定,为本领域技术人员熟知的技术,在此不作限定。Wherein, this embodiment does not limit the TCP three-way handshake process, which is a technology well known to those skilled in the art, and is not limited here.

当局域网(可以为发送端与WOC1之间、WOC2与接收端之间)的TCP(Transmission Control Protocol,传输控制协议)连接异常断链时,不考虑cache1与cache2的一致性,直接关闭WAN(可以为WOC1与WOC2之间的)的TCP连接。When the TCP (Transmission Control Protocol, Transmission Control Protocol) connection of the local area network (which can be between the sender and WOC1, or between WOC2 and the receiver) is abnormally disconnected, the WAN is directly closed regardless of the consistency between cache1 and cache2 (you can is the TCP connection between WOC1 and WOC2).

如图3所示,TCP连接异常断链时,cache1与cache2之间存储的数据没有进行同步,即cache1与cache2中存储的数据不一致,无法对未存储的数据的索引进行解码,在WAN重传的过程中,若TCP连接异常断链,则在建立好链接后,还需要进行数据的传输,这样,增加了WAN数据交互,极大的影响了WAN传输的速度。As shown in Figure 3, when the TCP connection is abnormally disconnected, the data stored between cache1 and cache2 is not synchronized, that is, the data stored in cache1 and cache2 is inconsistent, and the index of the unstored data cannot be decoded, and the data is retransmitted over the WAN. During the process, if the TCP connection is disconnected abnormally, data transmission needs to be carried out after the connection is established. In this way, WAN data interaction is increased, which greatly affects the speed of WAN transmission.

具体的,图3中,以Sever(服务器)向Client发送数据为例进行说明:Sever向WOC2发送待传输数据;WOC2将待传输数据进行编码(可以包括计算待传输数据的哈希值);将计算得到的哈希值发送至WOC1,由于cache1与cache2不同步,即cache1中未存储待发送数据,因此cache1无法对接收到的哈希值进行解码(即根据哈希值计算出待传输数据)。由此可以看出,在WAN重传的过程中,若TCP连接异常断链,则增加了WAN数据交互,极大的影响了WAN传输的速度。Specifically, in Fig. 3, it is explained by taking Sever (server) sending data to Client as an example: Sever sends data to be transmitted to WOC2; WOC2 encodes the data to be transmitted (which may include calculating the hash value of the data to be transmitted); The calculated hash value is sent to WOC1. Since cache1 and cache2 are not synchronized, that is, no data to be sent is stored in cache1, cache1 cannot decode the received hash value (that is, calculate the data to be transmitted based on the hash value) . It can be seen from this that during the WAN retransmission process, if the TCP connection is abnormally disconnected, the WAN data interaction will be increased, which will greatly affect the speed of WAN transmission.

为了描述简单,以下提供的连接(例如,LAN(Local Area Network,局域网)连接和WAN连接等)均可以为TCP连接。For simplicity of description, the connections provided below (for example, LAN (Local Area Network, local area network) connections and WAN connections, etc.) can all be TCP connections.

为了解决上述问题,本实施例提供一种异常断链的处理方法,且该方法的执行主体可以为第一控制设备,如图4所示,可以包括:In order to solve the above problems, this embodiment provides a processing method for abnormal link disconnection, and the execution subject of the method may be the first control device, as shown in FIG. 4 , which may include:

401、当第一控制设备所在的局域网断链时,第一控制设备通过广域网向第二控制设备发送第一控制设备存储的第一数据块,以便第二控制设备存储第一数据块。401. When the local area network where the first control device is located is disconnected, the first control device sends the first data block stored by the first control device to the second control device through the wide area network, so that the second control device stores the first data block.

在第一控制设备的局域网断链时,由于,第一控制设备与第二控制设备中存储的数据可能不同,因此,在后续连接恢复后,第一控制设备与第二控制设备之间无法传输第一数据的索引,只能传输第一数据,因为,若未存储有该索引对应的数据,控制设备无法对该索引进行解码,进而无法得到第一数据,其中,第一数据是第一数据块的数据。When the LAN link of the first control device is disconnected, since the data stored in the first control device and the second control device may be different, after the subsequent connection is restored, the transmission between the first control device and the second control device cannot The index of the first data can only transmit the first data, because if the data corresponding to the index is not stored, the control device cannot decode the index, and thus cannot obtain the first data, wherein the first data is the first data block of data.

为了使在连接恢复后,第二控制设备可以对第一数据块的索引进行解码,则在第一控制设备的局域网断链时,第一控制设备通过广域网向第二控制设备发送第一数据块,以便第二控制设备存储第一数据块。In order to enable the second control device to decode the index of the first data block after the connection is restored, when the LAN of the first control device is disconnected, the first control device sends the first data block to the second control device through the wide area network , so that the second control device stores the first data block.

402、当第一控制设备所在的局域网连接恢复正常后,第一控制设备向第二控制设备发送第一数据的索引,以便第二控制设备根据第一数据的索引获取第一数据。402. After the local area network connection where the first control device is located returns to normal, the first control device sends the index of the first data to the second control device, so that the second control device obtains the first data according to the index of the first data.

其中,第一数据为第一数据块的数据。Wherein, the first data is the data of the first data block.

当第一控制设备的局域网连接恢复正常后,为了节省网络资源,则第一控制设备可以向第二控制设备发送第一数据的索引(第一数据的索引的大小小于第一数据的大小),由于第二控制设备中存储有第一数据块,因此,第二控制设备可以对第一数据的索引进行解码,进而得到第一数据。When the LAN connection of the first control device returns to normal, in order to save network resources, the first control device may send the index of the first data to the second control device (the size of the index of the first data is smaller than the size of the first data), Since the first data block is stored in the second control device, the second control device can decode the index of the first data to obtain the first data.

采用上述方案后,当第一控制设备的局域网连接断链时,第一控制设备通过广域网将第一数据块发送至第二控制设备存储,这样,使得第二控制设备中存储有第一控制设备中的所有数据块。在连接恢复后,第一控制设备向第二控制设备发送第一数据的索引时,由于第二控制设备存储有该索引对应的数据,因此第二控制设备可以对该索引进行解码后得到第一数据,避免了第一控制设备与第二控制设备之间传输第一数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above scheme, when the LAN connection of the first control device is disconnected, the first control device sends the first data block to the second control device for storage through the wide area network, so that the second control device stores the first control device All data blocks in . After the connection is restored, when the first control device sends the index of the first data to the second control device, since the second control device stores the data corresponding to the index, the second control device can decode the index to obtain the first The data avoids the transmission of the first data between the first control device and the second control device, reduces the data interaction process of the wide area network, and increases the transmission speed of the wide area network.

本实施例提供另一种异常断链的处理方法,该方法的执行主体可以为第二控制设备,如图5所示,可以包括:This embodiment provides another method for processing abnormal link disconnection. The execution subject of the method may be the second control device, as shown in FIG. 5 , which may include:

501、第二控制设备通过广域网接收并存储第一控制设备发送的第一控制设备存储的第一数据块。501. The second control device receives and stores the first data block sent by the first control device and stored by the first control device through a wide area network.

其中,第一数据块可以是第一控制设备在自身所在的局域网断链后向所述第二控制设备发送的。Wherein, the first data block may be sent by the first control device to the second control device after the local area network where it is located is disconnected.

为了使连接恢复后,第二控制设备可以对第一数据块的索引进行解码,则第二控制设备可以接收并存储第一控制设备发送的第一控制设备中存储的第一数据块。In order to enable the second control device to decode the index of the first data block after the connection is restored, the second control device may receive and store the first data block stored in the first control device sent by the first control device.

502、第二控制设备接收第一控制设备在第一控制设备所在的局域网连接恢复后发送的第一数据的索引。502. The second control device receives the index of the first data sent by the first control device after the local area network connection where the first control device is located is restored.

其中,第一数据为第一数据块中的数据。Wherein, the first data is data in the first data block.

503、第二控制设备根据第一数据的索引获取第一数据。503. The second control device acquires the first data according to the index of the first data.

当第一控制设备的局域网连接恢复正常后,为了节省网络资源,则第一控制设备可以向第二控制设备发送第一数据的索引(第一数据的索引的大小小于第一数据的大小),由于第二控制设备中存储有第一数据块,因此,第控制设备可以对第一数据的索引进行解码,进而得到第一数据。When the LAN connection of the first control device returns to normal, in order to save network resources, the first control device may send the index of the first data to the second control device (the size of the index of the first data is smaller than the size of the first data), Since the first data block is stored in the second control device, the first control device can decode the index of the first data to obtain the first data.

采用上述方案后,当第一控制设备的局域网连接断链时,第一控制设备通过广域网将第一数据块发送至第二控制设备存储,这样,使得第二控制设备中存储有第一控制设备中的所有数据块。在连接恢复后,第一控制设备向第二控制设备发送第一数据的索引时,由于第二控制设备存储有该索引对应的数据,因此第二控制设备可以对该索引进行解码后得到第一数据,避免了第一控制设备与第二控制设备之间传输第一数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above scheme, when the LAN connection of the first control device is disconnected, the first control device sends the first data block to the second control device for storage through the wide area network, so that the second control device stores the first control device All data blocks in . After the connection is restored, when the first control device sends the index of the first data to the second control device, since the second control device stores the data corresponding to the index, the second control device can decode the index to obtain the first The data avoids the transmission of the first data between the first control device and the second control device, reduces the data interaction process of the wide area network, and increases the transmission speed of the wide area network.

下面为了可以更清楚的对上述实施例进行理解,下面提供其他一些实施例对上述提供的异常断链的处理方法进行详细描述。In order to understand the above-mentioned embodiments more clearly, some other embodiments are provided below to describe in detail the method for handling abnormal link disconnection provided above.

以下实施例中,第一控制设备和第二控制设备均可以但不限于为独立的WOC,且该WOC可以设置有Cache。In the following embodiments, both the first control device and the second control device may be, but are not limited to, independent WOCs, and the WOC may be provided with a Cache.

以下实施例应用的场景中可以但不限于包括:Client、Client侧的WOC1、设置与WOC1中的Cache1、Sever侧的WOC2、设置于WOC2中的Cache2,其中,Cache1、Cache2可以分别用于存储第一数据块、第二数据块等,Client与Client侧的WOC1之间可以通过局域网进行连接,Sever与Sever侧的WOC2之间可以通过局域网进行连接。The application scenarios of the following embodiments may include, but are not limited to: Client, WOC1 on the Client side, Cache1 set in WOC1, WOC2 on the Sever side, and Cache2 set in WOC2, where Cache1 and Cache2 can be used to store the first For the first data block, the second data block, etc., the Client and WOC1 on the Client side can be connected through a local area network, and the Sever and WOC2 on the Sever side can be connected through a local area network.

本实施例提供另一种异常断链的处理方法,该方法是对图4和图5所示的方法的进一步扩展,本实施例以Client侧的局域网断链(即Client与WOC1之间的连接)断链为例进行说明。This embodiment provides another processing method for abnormal link disconnection, which is a further extension of the methods shown in Figure 4 and Figure 5. In this embodiment, the LAN disconnection on the Client side (i.e. the connection between ) broken chain as an example for illustration.

其中,图6为本实施例的数据交互图,如图7所示,为本实施例提供的异常断链的处理方法的流程图,具体可以包括:Among them, FIG. 6 is a data interaction diagram of this embodiment. As shown in FIG. 7, it is a flow chart of the method for processing abnormal link disconnection provided by this embodiment, which may specifically include:

701、Client获取Client与WOC1之间的LAN连接状态。701. The client acquires the LAN connection status between the client and WOC1.

作为本实施例的一种实施方式,Client与WOC1之间的LAN连接状态可以用于表征Client与WOC1之间的LAN是处于正常连接状态,还是处于断链状态。若Client与WOC1之间的LAN处于正常连接状态,则继续执行步骤701,若Client与WOC1之间的LAN处于断链状态,则执行步骤702。As an implementation of this embodiment, the LAN connection state between the Client and WOC1 may be used to indicate whether the LAN between the Client and WOC1 is in a normal connection state or in a disconnected state. If the LAN between the Client and WOC1 is in a normal connection state, continue to execute step 701 , and if the LAN between the Client and WOC1 is in a disconnected state, execute step 702 .

本实施例对Client与WOC1之间的LAN连接状态包括的内容不作限定,可以根据实际需要进行设定,在此不再赘述。In this embodiment, the content included in the LAN connection state between the Client and WOC1 is not limited, and can be set according to actual needs, and will not be repeated here.

进一步的,Client可以每隔预设时间获取Client与WOC1之间的LAN连接状态。Further, the Client can acquire the LAN connection status between the Client and WOC1 at preset intervals.

本实施例对Client获取Client与WOC1之间的LAN连接状态的方法不作限定,为本领域技术人员熟知的技术,且可以根据实际需要进行设定,在此不再赘述。In this embodiment, the method for the client to obtain the LAN connection status between the client and WOC1 is not limited, it is a technology well known to those skilled in the art, and can be set according to actual needs, and will not be repeated here.

702、Client指示WOC1通过WAN向WOC2发送WOC1中存储的第一数据块,以便WOC2存储第一数据块。702. The Client instructs WOC1 to send the first data block stored in WOC1 to WOC2 through the WAN, so that WOC2 stores the first data block.

当WOC1与Client之间的LAN连接断链时,为了使在WOC1与Client之间的LAN恢复连接后,Cache2存储有Cache1中存储的第一数据块,则WOC1可以通过WAN向WOC2发送第一数据块,以便WOC2将第一数据块存储至Cache2中,这样,当在后续连接恢复后,Client向Sever发送第一数据块中第一数据的索引时,由于Cache2中存储有第一数据块,因此,Sever可以对第一数据的索引进行解码,进而从Cache2中得到第一数据,其中,第一数据为第一数据块中的数据。When the LAN connection between WOC1 and Client is disconnected, in order to restore the LAN connection between WOC1 and Client, Cache2 stores the first data block stored in Cache1, then WOC1 can send the first data to WOC2 through WAN block, so that WOC2 stores the first data block in Cache2, so that when the client sends the index of the first data in the first data block to Sever after the subsequent connection is restored, since the first data block is stored in Cache2, therefore , the Sever may decode the index of the first data, and then obtain the first data from Cache2, where the first data is the data in the first data block.

进一步的,WOC2存储第一数据块可以但不限于包括:直接存储第一数据块;或者,存储第一数据块中与第二数据块不同的数据。Further, the storage of the first data block by the WOC2 may, but is not limited to, include: directly storing the first data block; or storing data different from the second data block in the first data block.

本实施例对WOC2存储第一数据块的方法不作限定,不限于上述列举的方法,可以根据实际需要进行设定,在此不再赘述。This embodiment does not limit the method for WOC2 to store the first data block, and is not limited to the methods listed above, which can be set according to actual needs, and will not be repeated here.

作为本实施例的一种实施方式,Client指示WOC1通过WAN向WOC2发送WOC1中存储的第一数据块可以包括:As an implementation of this embodiment, the Client instructing WOC1 to send the first data block stored in WOC1 to WOC2 through the WAN may include:

Client向WOC1发送第一数据块发送请求,该请求可以用于指示WOC1通过WAN向WOC2发送自身存储的第一数据块;WOC1向Client发送第一数据块发送相应,同时还可以通过WAN向WOC2发送WOC1中存储的第一数据块。Client sends the first data block sending request to WOC1, which can be used to instruct WOC1 to send the first data block stored by itself to WOC2 through WAN; WOC1 sends the first data block to Client to send a response, and can also send to WOC2 through WAN The first data block stored in WOC1.

本实施例对Client指示WOC1通过WAN向WOC2发送WOC1中存储的第一数据块的方法不作限定,可以根据实际需要进行设定,在此不再赘述。This embodiment does not limit the method for the Client to instruct WOC1 to send the first data block stored in WOC1 to WOC2 through the WAN, which can be set according to actual needs, and will not be repeated here.

703、WOC2通过广域网接收并存储WOC1发送的WOC1存储的第一数据块。703. WOC2 receives and stores the first data block stored in WOC1 sent by WOC1 through the wide area network.

作为本实施例的一种实施方式,WOC2可以将接收到的第一数据块存储在Cache2中。As an implementation manner of this embodiment, WOC2 may store the received first data block in Cache2.

704、WOC1通过WAN向WOC2发送第一断链指令。704. WOC1 sends a first link disconnection instruction to WOC2 through the WAN.

其中,第一断链指令可以但不限于用于指示:WOC2将自身存储的(即Cache2存储的)第二数据块发送至WOC1、断开WOC2与Sever之间的LAN连接、以及在发送完第二数据块后断开WOC1与WOC2之间的广域网连接。Wherein, the first link disconnection instruction may be but not limited to be used to indicate: WOC2 sends the second data block stored by itself (that is, stored in Cache2) to WOC1, disconnects the LAN connection between WOC2 and Sever, and after sending the second data block Disconnect the WAN connection between WOC1 and WOC2 after two data blocks.

作为本实施例的一种实施方式,当WOC1的LAN连接断链时,为了使WOC1与WOC2之间、WOC2与Sever之间不再进行数据传输,则WOC1通过WAN向WOC2发送第一断链指令,以使WOC2根据第一断链指令的指示,将自身存储的第二数据块发送给WOC1,并根据第一断链指令的指示,在WOC2发送第二数据块后,断开WOC2与WOC1之间的广域网连接。As an implementation of this embodiment, when the LAN connection of WOC1 is disconnected, in order to stop data transmission between WOC1 and WOC2, and between WOC2 and Server, WOC1 sends the first link disconnection command to WOC2 through WAN so that WOC2 sends the second data block stored by itself to WOC1 according to the instruction of the first link disconnection instruction, and disconnects the connection between WOC2 and WOC1 after WOC2 sends the second data block according to the instruction of the first link disconnection instruction. WAN connections between them.

值得说明的是,步骤703与步骤702的执行顺序不限于本实施例中列举的顺序,即可以包括:WOC1同时向WOC2发送第一数据块与第一断链指令;或者,WOC1先向WOC2发送第一数据块再向WOC2发送第一断链指令;或者,WOC1先向WOC2发送第一断链指令再向WOC2发送第一数据块。It is worth noting that the execution sequence of step 703 and step 702 is not limited to the sequence listed in this embodiment, that is, it may include: WOC1 sends the first data block and the first link disconnection command to WOC2 at the same time; or, WOC1 sends WOC2 first The first data block then sends the first link disconnection command to WOC2; or, WOC1 first sends the first link disconnection command to WOC2 and then sends the first data block to WOC2.

705、WOC2接收WOC1在WOC1所在的局域网断链时发送的第一断链指令。705. WOC2 receives the first link disconnection instruction sent by WOC1 when the link of the local area network where WOC1 is located is disconnected.

706、WOC2根据第一断链指令的指示,断开WOC2的局域网连接。706. WOC2 disconnects the local area network connection of WOC2 according to the instruction of the first link disconnection instruction.

707、WOC2向WOC1发送自身存储的第二数据块。707. WOC2 sends the second data block stored by itself to WOC1.

708、WOC2向WOC1发送第二断链指令,以便WOC1在将第一数据块发送至WOC2后,根据第二断链指令的指示断开WOC1与WOC2之间的广域网连接。708. WOC2 sends a second link disconnection instruction to WOC1, so that after WOC1 sends the first data block to WOC2, it disconnects the wide area network connection between WOC1 and WOC2 according to the instruction of the second link disconnection instruction.

709、WOC2根据第一断链指令的指示,断开与WOC1的广域网连接。709. WOC2 disconnects the wide area network connection with WOC1 according to the instruction of the first link disconnection instruction.

710、WOC1接收并存储WOC2发送的第二数据块,并接收第二断链指令。710. WOC1 receives and stores the second data block sent by WOC2, and receives a second link disconnection instruction.

为了使WOC1与WOC2(即Cache2与Cache1)中存储的数据相同,则在WOC1向WOC2发送第一数据块后,WOC1还可以接收WOC2发送的Cache2存储的第二数据块,并可以将接收到的第二数据块存储在Cache1中。In order to make the data stored in WOC1 and WOC2 (that is, Cache2 and Cache1) the same, after WOC1 sends the first data block to WOC2, WOC1 can also receive the second data block stored in Cache2 sent by WOC2, and the received The second data block is stored in Cache1.

进一步的,WOC1存储第二数据块可以但不限于包括:直接存储第二数据块;或者,存储第二数据块中与第一数据块不同的数据块。Further, storing the second data block by WOC1 may include, but is not limited to: directly storing the second data block; or storing a data block in the second data block that is different from the first data block.

本实施例对WOC1存储第二数据块的方法不作限定,不限于上述列举的方法,可以根据实际需要进行设定,在此不再赘述。In this embodiment, the method for storing the second data block by WOC1 is not limited, and is not limited to the methods listed above, which can be set according to actual needs, and will not be repeated here.

711、WOC1根据第二断链指令的指示,断开与WOC2之间的WAN连接。711. WOC1 disconnects the WAN connection with WOC2 according to the instruction of the second link disconnection instruction.

在WOC1与WOC2各自存储好对端的数据块,且断开各自的LAN连接后,断开WOC1的WAN连接。After WOC1 and WOC2 respectively store the data blocks of the opposite end and disconnect their respective LAN connections, disconnect the WAN connection of WOC1.

此时,WOC1与WOC2之间的WAN连接、WOC1的LAN连接、WOC2的WAN连接、WOC2的LAN连接均已断开。At this time, the WAN connection between WOC1 and WOC2, the LAN connection of WOC1, the WAN connection of WOC2, and the LAN connection of WOC2 have all been disconnected.

值得说明的是,Sever侧的网络出现异常,即Sever的LAN连接(即Client与WOC1之间的连接)断链后的处理方法与图7所示的实施例的处理方法相同,在此不再赘述。It is worth noting that the network on the Sever side is abnormal, that is, the processing method after the LAN connection of the Sever (that is, the connection between Client and WOC1) is disconnected is the same as that of the embodiment shown in Figure 7, and will not be repeated here. repeat.

712、当WOC1的局域网连接恢复正常后,WOC1向WOC2发送第一数据的索引,WOC2向WOC1发送第二数据的索引。712. After the LAN connection of WOC1 returns to normal, WOC1 sends the index of the first data to WOC2, and WOC2 sends the index of the second data to WOC1.

其中,第二数据为第二数据块中的数据。Wherein, the second data is data in the second data block.

当WOC1的局域网连接恢复正常后,由于WOC1与WOC2中存储的数据相同(即可以存储有第一数据块和第二数据块),因此,WOC1与WOC2可以对第一数据的索引和第二数据对应的索引进行解码,得到第一数据或第二数据。When the LAN connection of WOC1 returns to normal, since the data stored in WOC1 and WOC2 are the same (that is, the first data block and the second data block can be stored), WOC1 and WOC2 can index the first data and the second data The corresponding index is decoded to obtain the first data or the second data.

具体的,当WOC1接收到第二数据的索引后,可以对第二数据的索引进行解码,并根据解码后的数据从存储的第二数据块中获取第二数据;当WOC2获取到第一数据的索引后,可以对第一数据的索引进行解码,并根据解码后的数据从存储的第一数据块中获取第一数据。Specifically, when WOC1 receives the index of the second data, it can decode the index of the second data, and obtain the second data from the stored second data block according to the decoded data; when WOC2 obtains the first data After the index of the first data, the index of the first data can be decoded, and the first data can be obtained from the stored first data block according to the decoded data.

本实施例对根据数据的索引获取数据的方法不作限定,为本领域技术人员熟知的技术,且可以根据实际需要进行设定,在此不再赘述。In this embodiment, the method of acquiring data according to the index of the data is not limited, it is a technology well known to those skilled in the art, and it can be set according to actual needs, and will not be repeated here.

采用上述方案后,当WOC1的局域网连接断链时,WOC1通过广域网将第一数据块发送至WOC2存储,这样,WOC2中存储有WOC1中的所有数据块,另外,在连接恢复后,WOC1与WOC2之间可以传输待传输数据的索引,由于,Cache1与Cache2中均存储有相同的数据(可以包括第一数据块和第二数据块),因此,WOC1与WOC2可以对相应数据的索引进行解码后得到待传输数据(可以包括第一数据或第二数据),避免了WOC1与WOC2之间传输第一数据或第二数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above scheme, when WOC1’s LAN connection is disconnected, WOC1 sends the first data block to WOC2 for storage through the WAN, so that all data blocks in WOC1 are stored in WOC2. In addition, after the connection is restored, WOC1 and WOC2 The index of the data to be transmitted can be transmitted between Cache1 and Cache2, since both Cache1 and Cache2 store the same data (including the first data block and the second data block), therefore, WOC1 and WOC2 can decode the index of the corresponding data Obtaining the data to be transmitted (which may include the first data or the second data), avoids the transmission of the first data or the second data between WOC1 and WOC2, reduces the WAN data interaction process, and increases the speed of WAN transmission.

本实施例提供另一种异常断链的处理方法,本实施例以Client侧和Sever侧的局域网同时断链(即第一控制设备所在的局域网断链,且第二控制设备所在的局域网也断链)为例进行说明,且该方法与图7所示的方法类似,图8为本实施例的系统结构图,如图9所示,本实施例提供的异常断链的处理方法的流程图,具体可以包括:This embodiment provides another method for handling abnormal link disconnection. In this embodiment, the LANs on the Client side and the Sever side are disconnected at the same time (that is, the LAN where the first control device is located is disconnected, and the LAN where the second control device is located is also disconnected. chain) as an example, and this method is similar to the method shown in Figure 7, Figure 8 is a system structure diagram of this embodiment, as shown in Figure 9, the flow chart of the processing method for abnormal link disconnection provided by this embodiment , which can include:

901、Client获取Client与WOC1之间的LAN连接状态,Sever获取Sever与WOC2之间的LAN连接状态。901. The Client acquires the LAN connection status between the Client and WOC1, and the Sever acquires the LAN connection status between the Sever and WOC2.

902、Client指示WOC1通过WAN向WOC2发送WOC1中存储的第一数据块,以便WOC2存储第一数据块;Sever指示WOC2通过WAN向WOC1发送WOC2中存储的第二数据块,以便WOC1存储第一数据块。902. Client instructs WOC1 to send the first data block stored in WOC1 to WOC2 through WAN, so that WOC2 can store the first data block; Sever instructs WOC2 to send the second data block stored in WOC2 to WOC1 through WAN, so that WOC1 can store the first data piece.

903、WOC1通过WAN向WOC2发送第一断链指令,WOC2通过WAN向WOC1发送第二断链指令。903. WOC1 sends a first link disconnection command to WOC2 through the WAN, and WOC2 sends a second link disconnection command to WOC1 through the WAN.

作为本实施例的一种实施方式,第一断链指令可以用于指示WOC2断开WAN连接,第二断链指令可以用于指示WOC1断开WAN连接。As an implementation of this embodiment, the first link disconnection instruction may be used to instruct WOC2 to disconnect the WAN connection, and the second link disconnection instruction may be used to instruct WOC1 to disconnect the WAN connection.

具体的,第一断链指令可以用于指示WOC2在向WOC1发送第二数据块以及第二断链指令后再断开WAN连接,第二断链指令可以用于指示WOC1在向WOC2发送第一数据块以及第一断链指令后再断开WAN连接。Specifically, the first link disconnection command may be used to instruct WOC2 to disconnect the WAN connection after sending the second data block and the second link disconnection command to WOC1, and the second link disconnection command may be used to instruct WOC1 to send the first link to WOC2. After the data block and the first link disconnection command, the WAN connection is disconnected.

904、WOC1接收并存储WOC2发送的第二数据块,WOC2接收并存储WOC1发送的第一数据块。904. WOC1 receives and stores the second data block sent by WOC2, and WOC2 receives and stores the first data block sent by WOC1.

作为本实施例的一种实施方式,WOC1可以将接收到的第二数据块存储于Cache1中,WOC2可以将接收到的第二数据块存储于Cache2中。As an implementation manner of this embodiment, WOC1 may store the received second data block in Cache1, and WOC2 may store the received second data block in Cache2.

其中,步骤903与步骤904可以包含的四个步骤:1.WOC1接收WOC2发送的第二数据块;2.WOC1接收WOC2发送的第二断链指令;3.WOC2接收WOC1发送的第一数据块;4.WOC2接收WOC1发送的第一断链指令。Among them,step 903 and step 904 may include four steps: 1. WOC1 receives the second data block sent by WOC2; 2. WOC1 receives the second link disconnection instruction sent by WOC2; 3. WOC2 receives the first data block sent by WOC1 ; 4. WOC2 receives the first link disconnection command sent by WOC1.

值得说明的是,本实施例对上述的四个步骤的执行顺序不作限定,可以根据实际需要进行设定,在此不再赘述。It is worth noting that the execution order of the above four steps is not limited in this embodiment, and can be set according to actual needs, and details are not repeated here.

进一步的,WOC1可以直接存储第二数据块;或者,存储第二数据块中与第一数据块不同的数据;WOC2可以直接存储第一数据块;或者,存储第一数据块中与第二数据块不同的数据。Further, WOC1 can directly store the second data block; or, store data different from the first data block in the second data block; WOC2 can directly store the first data block; or, store the second data in the first data block block different data.

905、WOC1根据第二断链指令的指示,断开与WOC2的WAN连接,WOC2根据第一断链指令的指示,断开与WOC1的WAN连接。905. WOC1 disconnects the WAN connection with WOC2 according to the instruction of the second link disconnection instruction, and WOC2 disconnects the WAN connection with WOC1 according to the instruction of the first link disconnection instruction.

换言之,只有在WOC接收到对端的相应的数据块,且已向对端WOC发送本端的数据块,且已接收到对端WOC发送的断链指令以及已向对端WOC发送了断链指令后才断开WAN连接。In other words, only after the WOC receives the corresponding data block from the opposite end, and has sent the local data block to the opposite end WOC, and has received the link disconnection command sent by the opposite end WOC, and has sent the link disconnection command to the opposite end WOC. Disconnect the WAN connection.

本实施例中,WOC1的对端可以为WOC2,WOC2的对端可以为WOC1。In this embodiment, the opposite end of WOC1 may be WOC2, and the opposite end of WOC2 may be WOC1.

906、当WOC1的局域网连接与WOC2的局域网连接均恢复正常后,WOC1向WOC2发送第一数据的索引,WOC2向WOC1发送第二数据的索引。906. When both the LAN connection of WOC1 and the LAN connection of WOC2 are restored to normal, WOC1 sends the index of the first data to WOC2, and WOC2 sends the index of the second data to WOC1.

当WOC1的局域网连接恢复正常后,由于WOC1与WOC2中存储的数据相同(即可以存储有第一数据块和第二数据块),因此,WOC1与WOC2可以对第一数据的和第二数据对应的索引进行解码,得到第一数据或第二数据。When the LAN connection of WOC1 returns to normal, since the data stored in WOC1 and WOC2 are the same (that is, the first data block and the second data block can be stored), WOC1 and WOC2 can correspond to the first data and the second data The index is decoded to obtain the first data or the second data.

具体的,当WOC1接收到第二数据的索引后,可以对第二数据的索引进行解码,并根据解码后的数据从存储的第二数据块中获取第二数据;当WOC2获取到第一数据的索引后,可以对第一数据的索引进行解码,并根据解码后的数据从存储的第一数据块中获取第一数据。Specifically, when WOC1 receives the index of the second data, it can decode the index of the second data, and obtain the second data from the stored second data block according to the decoded data; when WOC2 obtains the first data After the index of the first data, the index of the first data can be decoded, and the first data can be obtained from the stored first data block according to the decoded data.

本实施例对根据数据的索引获取数据的方法不作限定,为本领域技术人员熟知的技术,且可以根据实际需要进行设定,在此不再赘述。In this embodiment, the method of acquiring data according to the index of the data is not limited, it is a technology well known to those skilled in the art, and it can be set according to actual needs, and will not be repeated here.

采用上述方案后,当WOC1的局域网连接与WOC1的局域网连接均断链时,WOC1通过广域网将第一数据块发送至WOC2中进行存储,WOC2可以通过广域网将第而数据块发送至WOC1中进行存储,在WOC1的局域网连接与WOC1的局域网连接均恢复后,WOC1与WOC2之间传输第一数据的索引和第二数据的索引时,由于,Cache1与Cache2中均存储有第一数据块和第二数据块,因此,WOC1与WOC2均可以对相应的索引进行解码,进而得到第一数据或第二数据,避免了WOC1与WOC2之间传输第一数据或第二数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above solution, when both the LAN connection of WOC1 and the LAN connection of WOC1 are disconnected, WOC1 sends the first data block to WOC2 for storage through the WAN, and WOC2 can send the second data block to WOC1 for storage through the WAN , after the LAN connection of WOC1 and the LAN connection of WOC1 are both restored, when the index of the first data and the index of the second data are transmitted between WOC1 and WOC2, since the first data block and the second data block are stored in both Cache1 and Cache2 Data block, therefore, both WOC1 and WOC2 can decode the corresponding index, and then obtain the first data or the second data, avoiding the transmission of the first data or the second data between WOC1 and WOC2, reducing the wide area network data interaction process, Increased the speed of WAN transfers.

下面提供一些装置实施例。且该装置实施例分别与上述提供的相应方法实施例对应。Some device examples are provided below. And the device embodiments respectively correspond to the corresponding method embodiments provided above.

本实施例提供一种网络设备,如图10所示,可以包括:This embodiment provides a network device, as shown in FIG. 10 , which may include:

第一发送单元101,用于当网络设备所在的局域网断链时,通过广域网向控制设备发送网络设备存储的第一数据块,以便控制设备存储第一数据块。Thefirst sending unit 101 is configured to send the first data block stored by the network device to the control device through the wide area network when the local area network where the network device is located is disconnected, so that the control device stores the first data block.

在网络设备的局域网断链时,由于,网络设备与控制设备中存储的数据可能不同,因此,在后续连接恢复后,网络设备与控制设备之间无法传输第一数据的索引,只能传输第一数据,因为,若未存储有该索引对应的数据,控制设备无法对该索引进行解码,进而无法得到第一数据,其中,第一数据是第一数据块的数据。When the local area network of the network device is disconnected, because the data stored in the network device and the control device may be different, after the subsequent connection is restored, the index of the first data cannot be transmitted between the network device and the control device, only the index of the first data can be transmitted. One data, because if the data corresponding to the index is not stored, the control device cannot decode the index, and thus cannot obtain the first data, wherein the first data is the data of the first data block.

为了使在连接恢复后,控制设备可以对第一数据块的索引进行解码,则在网络设备的局域网断链时,第一发送单元101通过广域网向控制设备发送第一数据块,以便控制设备存储第一数据块。In order to enable the control device to decode the index of the first data block after the connection is restored, when the local area network of the network device is disconnected, the first sendingunit 101 sends the first data block to the control device through the wide area network, so that the control device stores first data block.

第二发送单元102,用于当网络设备所在的局域网连接恢复正常后,向控制设备发送第一数据的索引,以便控制设备根据第一数据的索引获取第一数据,第一数据为第一数据块中的数据。Thesecond sending unit 102 is configured to send the index of the first data to the control device after the local area network connection where the network device is located returns to normal, so that the control device obtains the first data according to the index of the first data, and the first data is the first data data in the block.

当网络设备的局域网连接恢复正常后,为了节省网络资源,则第二发送单元102可以向控制设备发送第一数据的索引(第一数据的索引的大小小于第一数据的大小),由于控制设备中存储有第一数据块,因此,控制设备可以对第一数据的索引进行解码,进而得到第一数据。When the LAN connection of the network device returns to normal, in order to save network resources, thesecond sending unit 102 can send the index of the first data to the control device (the size of the index of the first data is smaller than the size of the first data), because the control device The first data block is stored in , therefore, the control device can decode the index of the first data to obtain the first data.

采用上述方案后,当网络设备的局域网连接断链时,网络设备通过广域网将第一数据块发送至控制设备存储,这样,使得控制设备中存储有网络设备中的所有数据块。在连接恢复后,网络设备向控制设备发送第一数据的索引时,由于控制设备存储有该索引对应的数据,因此控制设备可以对该索引进行解码后得到第一数据,避免了网络设备与控制设备之间传输第一数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above solution, when the LAN connection of the network device is disconnected, the network device sends the first data block to the control device for storage through the wide area network, so that all the data blocks in the network device are stored in the control device. After the connection is restored, when the network device sends the index of the first data to the control device, since the control device stores the data corresponding to the index, the control device can decode the index to obtain the first data, avoiding the network device and the control device. The first data is transmitted between devices, which reduces the data interaction process of the wide area network and increases the transmission speed of the wide area network.

本实施例提供另一种网络设备,该网络设备是对图10所示的网络设备的进一步扩展,如图11所示,可以包括:This embodiment provides another network device, which is a further extension of the network device shown in Figure 10, as shown in Figure 11, may include:

第一发送单元111,用于当网络设备所在的局域网断链时,通过广域网向控制设备发送网络设备存储的第一数据块,以便控制设备存储第一数据块。Thefirst sending unit 111 is configured to send the first data block stored by the network device to the control device through the wide area network when the local area network where the network device is located is disconnected, so that the control device stores the first data block.

作为本实施例的一种实施方式,在第一发送单元111通过广域网向控制设备发送网络设备存储的第一数据块之前,网络设备可以获取所在的LAN的连接状态。As an implementation of this embodiment, before the first sendingunit 111 sends the first data block stored by the network device to the control device through the wide area network, the network device may obtain the connection status of the LAN where it is located.

第二发送单元112,用于当网络设备所在的局域网连接恢复正常后,向控制设备发送第一数据的索引,以便控制设备根据第一数据的索引获取第一数据,第一数据为第一数据块中的数据。Thesecond sending unit 112 is configured to send the index of the first data to the control device after the connection of the local area network where the network device is located returns to normal, so that the control device obtains the first data according to the index of the first data, and the first data is the first data data in the block.

进一步的,本实施例提供的网络设备还可以包括:Further, the network device provided in this embodiment may also include:

第三发送单元113,用于当网络设备的局域网断链时,通过广域网向控制设备发送第一断链指令,以使控制设备根据第一断链指令的指示,将自身存储的第二数据块发送给网络设备,然后断开控制设备的广域网连接。Thethird sending unit 113 is configured to send the first link disconnection instruction to the control device through the wide area network when the local area network of the network device is disconnected, so that the control device sends the second data block stored by itself according to the instruction of the first link disconnection instruction. Send to the network device, and then disconnect the WAN connection of the controlling device.

作为本实施例的一种实施方式,当网络设备所在的LAN连接断链时,为了使网络设备与控制设备之间不再进行数据传输,则第三发送单元113通过WAN向控制设备发送第一断链指令,以使控制设备根据第一断链指令的指示,将自身存储的第二数据块发送给网络设备,并根据第一断链指令的指示,在控制设备发送第二数据块后,断开网络设备与控制设备之间的广域网连接。As an implementation of this embodiment, when the LAN connection where the network device is located is disconnected, in order to stop data transmission between the network device and the control device, thethird sending unit 113 sends the first A link disconnection instruction, so that the control device sends the second data block stored by itself to the network device according to the instruction of the first link disconnection instruction, and according to the instruction of the first link disconnection instruction, after the control device sends the second data block, Disconnect the WAN connection between the network device and the control device.

第一接收单元114,用于接收并存储控制设备发送的第二数据块。Thefirst receiving unit 114 is configured to receive and store the second data block sent by the control device.

为了使网络设备与控制设备中存储的数据相同,则在第一发送单元111向控制设备发送第一数据块后,第一接收单元114还可以接收并存储控制设备发送的本身存储的第二数据块。In order to make the data stored in the network device and the control device the same, after the first sendingunit 111 sends the first data block to the control device, thefirst receiving unit 114 can also receive and store the second data stored by the control device. piece.

第二接收单元115,用于当网络设备的局域网连接恢复正常后,接收控制设备发送的第二数据的索引,第二数据为第二数据块中的数据。Thesecond receiving unit 115 is configured to receive the index of the second data sent by the control device after the LAN connection of the network device returns to normal, and the second data is the data in the second data block.

进一步的,本实施例提供的网络设备还可以包括:Further, the network device provided in this embodiment may also include:

第三接收单元116,用于在网络设备将第一数据块发送至控制设备后,接收控制设备发送的第二断链指令;Thethird receiving unit 116 is configured to receive a second link disconnection instruction sent by the control device after the network device sends the first data block to the control device;

断链单元117,用于根据第二断链指令的指示,断开与广域网的连接。Thelink disconnection unit 117 is configured to disconnect the connection with the wide area network according to the instruction of the second link disconnection instruction.

进一步的,第一接收单元114,具体用于直接存储第二数据块;或者,存储第二数据块中与第一数据块不同的数据。Further, thefirst receiving unit 114 is specifically configured to directly store the second data block; or store data different from the first data block in the second data block.

进一步的,本实施例提供的网络设备还可以包括:Further, the network device provided in this embodiment may also include:

第四接收单元118,用于当网络设备所在的局域网断链,且控制设备所在的局域网也断链时,接收并存储控制设备发送的自身存储的第二数据块;Thefourth receiving unit 118 is configured to receive and store the second data block sent by the control device and stored by itself when the local area network where the network device is located is disconnected and the local area network where the control device is located is also disconnected;

第五接收单元119,用于在网络设备所在的局域网与控制设备所在的局域网均恢复正常后,接收控制设备发送的第二数据的索引,第二数据的索引为第二数据块中的数据。Thefifth receiving unit 119 is configured to receive the index of the second data sent by the control device after the local area network where the network device is located and the local area network where the control device is located return to normal. The index of the second data is the data in the second data block.

采用上述方案后,当网络设备的局域网连接断链时,网络设备通过广域网将第一数据块发送至控制设备存储,这样,控制设备中存储有网络设备中的所有数据块,另外,在连接恢复后,网络设备与控制设备之间可以传输待传输数据的索引,由于,网络设备与控制设备中均存储有相同的数据(可以包括第一数据块和第二数据块),因此,网络设备与控制设备可以对相应数据的索引进行解码后得到待传输数据(可以包括第一数据或第二数据),避免了网络设备与控制设备之间传输第一数据或第二数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above solution, when the LAN connection of the network device is disconnected, the network device sends the first data block to the control device for storage through the wide area network. In this way, all the data blocks in the network device are stored in the control device. In addition, when the connection is restored Finally, the index of the data to be transmitted can be transmitted between the network device and the control device. Since the same data (which may include the first data block and the second data block) are stored in the network device and the control device, the network device and the control device The control device can decode the index of the corresponding data to obtain the data to be transmitted (including the first data or the second data), which avoids the transmission of the first data or the second data between the network device and the control device, and reduces the wide area network data interaction process, increasing the speed of WAN transmission.

本实施例提供一种网络设备,如图12所示,可以包括:This embodiment provides a network device, as shown in FIG. 12, which may include:

第一接收单元121,用于通过广域网接收并存储控制设备发送的控制设备存储的第一数据块,第一数据块是控制设备在自身所在的局域网断链后发送的。The first receiving unit 121 is configured to receive and store the first data block sent by the control device and stored by the control device through the wide area network. The first data block is sent by the control device after the local area network where it is located is disconnected.

为了使连接恢复后,网络设备可以对第一数据块的索引进行解码,则第一接收单元121可以接收并存储控制设备发送的控制设备中存储的第一数据块。In order for the network device to decode the index of the first data block after the connection is restored, the first receiving unit 121 may receive and store the first data block stored in the control device sent by the control device.

第二接收单元122,用于接收控制设备在控制设备所在的局域网连接恢复后发送的第一数据的索引,第一数据为第一数据块中的数据。The second receiving unit 122 is configured to receive the index of the first data sent by the control device after the connection of the local area network where the control device is located is restored, where the first data is the data in the first data block.

获取单元123,用于根据所述第一数据的索引获取所述第一数据。The obtaining unit 123 is configured to obtain the first data according to the index of the first data.

当控制设备的局域网连接恢复正常后,为了节省网络资源,则控制设备可以向网络设备发送第一数据的索引(第一数据的索引的大小小于第一数据的大小),由于网络设备中存储有第一数据块,因此,第控制设备可以对第一数据的索引进行解码,进而得到第一数据。When the LAN connection of the control device returns to normal, in order to save network resources, the control device can send the index of the first data to the network device (the size of the index of the first data is smaller than the size of the first data). The first data block, therefore, the first control device can decode the index of the first data to obtain the first data.

采用上述方案后,当控制设备的局域网连接断链时,控制设备通过广域网将第一数据块发送至网络设备存储,这样,使得网络设备中存储有控制设备中的所有数据块。在连接恢复后,控制设备向网络设备发送第一数据的索引时,由于,网络设备存储有第一数据,因此,网络设备可以对该索引进行解码后得到第一数据,避免了控制设备与网络设备之间传输第一数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above scheme, when the LAN connection of the control device is disconnected, the control device sends the first data block to the network device for storage through the wide area network, so that all the data blocks in the control device are stored in the network device. After the connection is restored, when the control device sends the index of the first data to the network device, since the network device stores the first data, the network device can decode the index to obtain the first data, avoiding the communication between the control device and the network. The first data is transmitted between devices, which reduces the data interaction process of the wide area network and increases the transmission speed of the wide area network.

本实施例提供另一种网络设备,该网络设备是对图12所示的网络设备的进一步扩展,如图13所示,可以包括:This embodiment provides another network device, which is a further extension of the network device shown in Figure 12, as shown in Figure 13, may include:

第一接收单元131,用于通过广域网接收并存储控制设备发送的控制设备存储的第一数据块,第一数据块是控制设备在自身所在的局域网断链后发送的。Thefirst receiving unit 131 is configured to receive and store the first data block sent by the control device and stored by the control device through the wide area network. The first data block is sent by the control device after the local area network where it is located is disconnected.

为了使连接恢复后,网络设备可以对第一数据块的索引进行解码,则第一接收单元131可以接收并存储控制设备发送的控制设备中存储的第一数据块。In order for the network device to decode the index of the first data block after the connection is restored, thefirst receiving unit 131 may receive and store the first data block stored in the control device sent by the control device.

第二接收单元132,用于接收控制设备在控制设备所在的局域网连接恢复后发送的第一数据的索引,第一数据为第一数据块中的数据。Thesecond receiving unit 132 is configured to receive the index of the first data sent by the control device after the connection of the local area network where the control device is located is restored, where the first data is the data in the first data block.

获取单元133,用于根据所述第一数据的索引获取所述第一数据。The obtainingunit 133 is configured to obtain the first data according to the index of the first data.

当控制设备的局域网连接恢复正常后,为了节省网络资源,则控制设备可以向网络设备发送第一数据的索引(第一数据的索引的大小小于第一数据的大小),由于网络设备中存储有第一数据块,因此,第控制设备可以对第一数据的索引进行解码,进而得到第一数据。When the LAN connection of the control device returns to normal, in order to save network resources, the control device can send the index of the first data to the network device (the size of the index of the first data is smaller than the size of the first data). The first data block, therefore, the first control device can decode the index of the first data to obtain the first data.

进一步的,本实施例提供的网络设备还可以包括:Further, the network device provided in this embodiment may also include:

第三接收单元134,用于接收控制设备在控制设备所在的局域网断链时发送的第一断链指令;Thethird receiving unit 134 is configured to receive a first link disconnection instruction sent by the control device when the local area network where the control device is located is disconnected;

第一断链单元134,用于根据第一断链指令的指示,断开网络设备的局域网连接;The firstlink disconnection unit 134 is configured to disconnect the LAN connection of the network device according to the instruction of the first link disconnection instruction;

第一发送单元135,用于将自身存储的第二数据块发送至控制设备;Thefirst sending unit 135 is configured to send the second data block stored by itself to the control device;

第二断链单元136,用于断开网络设备的广域网连接;Thesecond disconnection unit 136 is configured to disconnect the wide area network connection of the network device;

第二发送单元137,用于当控制设备的局域网连接恢复正常后,向控制设备发送第二数据的索引,第二数据为第二数据块中的数据。Thesecond sending unit 137 is configured to send the index of the second data to the control device after the local area network connection of the control device returns to normal, and the second data is the data in the second data block.

进一步的,本实施例提供的网络设备还可以包括:Further, the network device provided in this embodiment may also include:

第三发送单元138,用于在网络设备通过广域网接收并存储控制设备发送的控制设备中存储的第一数据块之后,向控制设备发送第二断链指令,以便控制设备在将第一数据块发送至网络设备后,根据第二断链指令的指示断开控制设备的广域网连接。Thethird sending unit 138 is configured to send a second link disconnection instruction to the control device after the network device receives and stores the first data block sent by the control device through the wide area network and stored in the control device, so that the control device sends the first data block After sending to the network device, disconnect the wide area network connection of the control device according to the instruction of the second link disconnection instruction.

进一步的,第一接收单元131,具体用于直接存储第一数据块;或者,存储第一数据块中与第二数据块不同的数据。Further, thefirst receiving unit 131 is specifically configured to directly store the first data block; or store data different from the second data block in the first data block.

进一步的,本实施例提供的网络设备还可以包括:Further, the network device provided in this embodiment may also include:

第四发送单元139,用于当控制设备所在的局域网断链,且网络设备所在的局域网也断链时,向控制设备发送自身存储的第二数据块;Thefourth sending unit 139 is configured to send the second data block stored by itself to the control device when the link of the local area network where the control device is located is disconnected, and the local area network where the network device is located is also disconnected;

第五发送单元1310,用于在控制设备所在的局域网与网络设备所在的局域网均恢复正常后,向控制设备发送第二数据的索引,第二数据的索引为第二数据块中的数据。Thefifth sending unit 1310 is configured to send the index of the second data to the control device after the local area network where the control device is located and the local area network where the network device is located return to normal. The index of the second data is the data in the second data block.

采用上述方案后,当控制设备的局域网连接断链时,控制设备通过广域网将第一数据块发送至网络设备存储,这样,网络设备中存储有控制设备中的所有数据块,另外,在连接恢复后,控制设备与网络设备之间可以传输待传输数据的索引,由于,控制设备与网络设备中均存储有相同的数据(可以包括第一数据块和第二数据块),因此,控制设备与网络设备可以对相应数据的索引进行解码后得到待传输数据(可以包括第一数据或第二数据),避免了控制设备与网络设备之间传输第一数据或第二数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above solution, when the LAN connection of the control device is disconnected, the control device sends the first data block to the network device for storage through the WAN, so that all the data blocks in the control device are stored in the network device. In addition, when the connection is restored Finally, the index of the data to be transmitted can be transmitted between the control device and the network device. Since both the control device and the network device store the same data (which may include the first data block and the second data block), the control device and the network device The network device can decode the index of the corresponding data to obtain the data to be transmitted (which may include the first data or the second data), avoiding the transmission of the first data or the second data between the control device and the network device, and reducing the wide area network data interaction process, increasing the speed of WAN transmission.

下面提供相应的系统实施例,该系统实施例与上述相应的方法实施例和装置实施例相对应。Corresponding system embodiments are provided below, and the system embodiments correspond to the above-mentioned corresponding method embodiments and device embodiments.

本实施例提供一种异常断链的处理系统,如图14所示,可以包括:This embodiment provides a processing system for abnormal link disconnection, as shown in Figure 14, which may include:

第一控制设备141和第二控制设备142,第一控制设备141通过局域网与客户端连接,通过广域网与第二控制设备142连接,第二控制设备142通过局域网和广域网与服务器连接;The first control device 141 and the second control device 142, the first control device 141 is connected to the client through the local area network, connected to the second control device 142 through the wide area network, and the second control device 142 is connected to the server through the local area network and the wide area network;

第一控制设备141,用于当第一控制设备141与所述客户端之间的局域网断链时,通过广域网向第二控制设备142发送第一控制设备141存储的第一数据块,以便第二控制设备142存储第一数据块;当第一控制设备141与客户端之间的局域网连接恢复正常后,向第二控制设备142发送第一数据的索引,第一数据为第一数据块中的数据;The first control device 141 is configured to send the first data block stored by the first control device 141 to the second control device 142 through the wide area network when the local area network link between the first control device 141 and the client is disconnected, so that the second The second control device 142 stores the first data block; when the LAN connection between the first control device 141 and the client returns to normal, it sends the index of the first data to the second control device 142, and the first data is in the first data block The data;

第二控制设备142,用于通过广域网接收并存储第一数据块;接收第一控制设备141在第一控制设备141所在的局域网连接恢复后发送的第一数据的索引;根据第一数据的索引获取第一数据。The second control device 142 is configured to receive and store the first data block through the wide area network; receive the index of the first data sent by the first control device 141 after the connection of the local area network where the first control device 141 is located is restored; according to the index of the first data Get the first data.

作为本实施例的一种实施方式,客户端可以获取客户端与第一控制设备之间的局域网连接状态,客户端与第一控制设备之间的局域网连接状态可以用于表征客户端与第一控制设备之间的局域网是处于正常连接状态,还是处于断链状态。As an implementation of this embodiment, the client can obtain the connection status of the local area network between the client and the first control device, and the connection status of the local area network between the client and the first control device can be used to represent the status of the connection between the client and the first control device. Control whether the LAN between devices is in a normal connection state or in a disconnected state.

进一步的,客户端可以每隔预设时间获取客户端与第一控制设备之间的局域网连接状态。Further, the client terminal may acquire the connection status of the local area network between the client terminal and the first control device every preset time.

当第一控制设备与客户端之间的局域网连接断链时,为了使在第一控制设备与客户端之间的局域网恢复连接后,第二控制设备存储有第一控制设备中存储的第一数据块,则第一控制设备可以通过广域网向第二控制设备发送第一数据块,以便第二控制设备将第一数据块存储至第二控制设备中,这样,当在后续连接恢复后,客户端向服务器发送第一数据块中第一数据的索引时,由于第二控制设备中存储有第一数据块,因此,服务器可以对第一数据的索引进行解码,进而从第二控制设备中得到第一数据,其中,第一数据为第一数据块中的数据。When the local area network connection between the first control device and the client is disconnected, in order to restore the connection of the local area network between the first control device and the client, the second control device stores the first data block, the first control device can send the first data block to the second control device through the wide area network, so that the second control device can store the first data block in the second control device, so that when the subsequent connection is restored, the client When the end sends the index of the first data in the first data block to the server, since the first data block is stored in the second control device, the server can decode the index of the first data, and then obtain from the second control device The first data, wherein the first data is the data in the first data block.

作为本实施例的一种实施方式,客户端可以指示第一控制设备向第二控制设备发送第一数据块,具体可以包括:As an implementation of this embodiment, the client may instruct the first control device to send the first data block to the second control device, which may specifically include:

客户端向第一控制设备发送第一数据块发送请求,该请求可以用于指示第一控制设备通过广域网向第二控制设备发送自身存储的第一数据块;第一控制设备向客户端发送第一数据块发送相应,同时还可以通过广域网向第二控制设备发送第一控制设备中存储的第一数据块。The client sends the first data block sending request to the first control device, and the request can be used to instruct the first control device to send the first data block stored by itself to the second control device through the wide area network; the first control device sends the first data block to the client. A data block is sent correspondingly, and at the same time, the first data block stored in the first control device can be sent to the second control device through the wide area network.

进一步的,当第一控制设备141与客户端之间的局域网断链时,Further, when the local area network link between the first control device 141 and the client is disconnected,

第一控制设备141,还用于通过广域网向第二控制设备142发送第一断链指令,以使所述第二控制设备142根据所述第一断链指令的指示,将所述第二控制设备存储的第二数据块发送给所述第一控制设备141,然后断开所述第二控制设备142的广域网连接;接收并存储第二控制设备142发送的自身存储的第二数据块;当第一控制设备141的局域网连接恢复正常后,接收第二控制设备142发送的第二数据的索引,第二数据为第二数据块中的数据;The first control device 141 is further configured to send a first link disconnection instruction to the second control device 142 through the wide area network, so that the second control device 142 The second data block stored by the device is sent to the first control device 141, and then the wide area network connection of the second control device 142 is disconnected; the second data block stored by the second control device 142 is received and stored; when After the local area network connection of the first control device 141 returns to normal, the index of the second data sent by the second control device 142 is received, and the second data is the data in the second data block;

第二控制设备142,还用于接收第一断链指令;根据第一断链指令的指示,断开第二控制设备142的局域网连接,将第二数据块发送至第一控制设备141;断开第二控制设备142的广域网连接;当第一控制设备141的局域网连接恢复正常后,向第一控制设备141发送第二数据的索引。The second control device 142 is also configured to receive the first link disconnection instruction; disconnect the LAN connection of the second control device 142 according to the instruction of the first link disconnection instruction, and send the second data block to the first control device 141; Open the wide area network connection of the second control device 142; when the LAN connection of the first control device 141 returns to normal, send the index of the second data to the first control device 141.

作为本实施例的一种实施方式,当第一控制设备的局域网连接断链时,为了使第一控制设备与第二控制设备之间、第二控制设备与服务器之间不再进行数据传输,则第一控制设备通过广域网向第二控制设备发送第一断链指令,以使第二控制设备根据第一断链指令的指示,将自身存储的第二数据块发送给第一控制设备,并根据第一断链指令的指示,在第二控制设备发送第二数据块后,断开第二控制设备与第一控制设备之间的广域网连接。As an implementation of this embodiment, when the LAN connection of the first control device is disconnected, in order to stop data transmission between the first control device and the second control device, and between the second control device and the server, Then the first control device sends the first link disconnection instruction to the second control device through the wide area network, so that the second control device sends the second data block stored by itself to the first control device according to the instruction of the first link disconnection instruction, and According to the instruction of the first link breaking instruction, after the second control device sends the second data block, disconnect the wide area network connection between the second control device and the first control device.

为了使第一控制设备与第二控制设备中存储的数据相同,则在第一控制设备向第二控制设备发送第一数据块后,第一控制设备还可以接收第二控制设备发送的第二控制设备存储的第二数据块,并可以将接收到的第二数据块存储在第一控制设备中。In order to make the data stored in the first control device and the second control device the same, after the first control device sends the first data block to the second control device, the first control device can also receive the second data block sent by the second control device. The second data block stored by the control device may store the received second data block in the first control device.

进一步的,第一控制设备141,还用于在第一控制设备141将第一数据块发送至第二控制设备142后,接收第二控制设备142发送的第二断链指令;根据第二断链指令的指示,断开与广域网的连接;Further, the first control device 141 is also configured to receive the second link disconnection instruction sent by the second control device 142 after the first control device 141 sends the first data block to the second control device 142; Instructions of the chain command, disconnect the connection with the wide area network;

第二控制设备142,还用于在第二控制设备142通过广域网接收并存储第一控制设备141发送的第一控制设备141中存储的第一数据块之后,向第一控制设备141发送第二断链指令。The second control device 142 is further configured to send the second Disconnect command.

进一步的,第一控制设备141,具体用于直接存储第二数据块;或者,存储第二数据块中与第一数据块不同的数据;Further, the first control device 141 is specifically configured to directly store the second data block; or store data different from the first data block in the second data block;

第二控制设备142,具体用于直接存储第一数据块;或者,存储第一数据块中与第二数据块不同的数据。The second control device 142 is specifically configured to directly store the first data block; or, store data different from the second data block in the first data block.

进一步的,当第一控制设备141所在的局域网断链,且第二控制设备142所在的局域网也断链时,Further, when the link of the local area network where the first control device 141 is located is disconnected, and the link of the local area network where the second control device 142 is located is also disconnected,

第一控制设备141,还用于接收并存储第二控制设备142发送的自身存储的第二数据块;在第一控制设备141所在的局域网与第二控制设备142所在的局域网均恢复正常后,接收第二控制设备142发送的第二数据的索引,第二数据的索引为第二数据块中的数据;The first control device 141 is further configured to receive and store the second data block stored by itself sent by the second control device 142; after the local area network where the first control device 141 is located and the local area network where the second control device 142 is located both return to normal, receiving the index of the second data sent by the second control device 142, where the index of the second data is the data in the second data block;

第二控制设备142,还用于向第一控制设备141发送第二数据块;在第一控制设备141所在的局域网与第二控制设备142所在的局域网均恢复正常后,向第一控制设备141发送第二数据的索引。The second control device 142 is also used for sending the second data block to the first control device 141; Send the index of the second data.

采用上述方案后,当第一控制设备的局域网连接断链时,第一控制设备通过广域网将第一数据块发送至第二控制设备存储,这样,第二控制设备中存储有第一控制设备中的所有数据块,另外,在连接恢复后,第一控制设备与第二控制设备之间可以传输待传输数据的索引,由于,第一控制设备与第二控制设备中均存储有相同的数据(可以包括第一数据块和第二数据块),因此,第一控制设备与第二控制设备可以对相应数据的索引进行解码后得到待传输数据(可以包括第一数据或第二数据),避免了第一控制设备与第二控制设备之间传输第一数据或第二数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above solution, when the LAN connection of the first control device is disconnected, the first control device sends the first data block to the second control device for storage through the wide area network. In addition, after the connection is restored, the index of the data to be transmitted can be transmitted between the first control device and the second control device, because the first control device and the second control device both store the same data ( may include the first data block and the second data block), therefore, the first control device and the second control device may decode the index of the corresponding data to obtain the data to be transmitted (which may include the first data or the second data), avoiding The transmission of the first data or the second data between the first control device and the second control device is reduced, the data interaction process of the wide area network is reduced, and the transmission speed of the wide area network is increased.

下面提供一种实体的装置实施例,该装置实施是与上述提供的相应的方法实施例相对应的。A physical device embodiment is provided below, and the device implementation corresponds to the corresponding method embodiment provided above.

图15示出了本发明实施例提供的一种网络设备的示意图,如图15所示,网络设备15包括:至少一个处理器1501、存储器1502、通信接口1503和总线1504。FIG. 15 shows a schematic diagram of a network device provided by an embodiment of the present invention. As shown in FIG. 15 , the network device 15 includes: at least one processor 1501 , a memory 1502 , a communication interface 1503 and a bus 1504 .

处理器1501、存储器1502和通信接口1503通过总线1504连接并完成相互间的通信。总线1504可以是工业标准体系结构(Industry StandardArchitecture,简称为ISA)总线、外部设备互连(Peripheral Component,简称为PCI)总线或扩展工业标准体系结构(Extended Industry StandardArchitecture,简称为EISA)总线等。所述总线可以分为地址总线、数据总线、控制总线等。方便起见,图15中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。通信接口1503可以为网口、USB接口、射频单元、天线、Wi-Fi通信模块等可以实现数据收发功能的器件或单元;其中:The processor 1501 , the memory 1502 and the communication interface 1503 are connected through a bus 1504 to complete mutual communication. The bus 1504 may be an Industry Standard Architecture (ISA for short) bus, a Peripheral Component Interconnect (PCI for short) bus or an Extended Industry Standard Architecture (EISA for short) bus, etc. The bus can be divided into address bus, data bus, control bus and so on. For convenience, only one thick line is used in FIG. 15 , but it does not mean that there is only one bus or one type of bus. The communication interface 1503 can be a network port, a USB interface, a radio frequency unit, an antenna, a Wi-Fi communication module, and other devices or units that can realize data sending and receiving functions; wherein:

存储器1502用于存储可执行程序181代码,该程序代码包括计算机操作指令。存储器1502可能包含高速RAM存储器,也可能还包括非易失性存储器(non-volatile memory),例如至少一个磁盘存储器。存储器1502可选的可以包含至少一个位于远离前述处理器1501的存储装置。The memory 1502 is used for storing executable program 181 codes, and the program codes include computer operation instructions. The memory 1502 may include a high-speed RAM memory, and may also include a non-volatile memory (non-volatile memory), such as at least one disk memory. The memory 1502 may optionally include at least one storage device located away from the aforementioned processor 1501 .

在一个实施例中,处理器1501通过读取并执行存储器1502中存储的可执行程序181,以用于:In one embodiment, the processor 1501 reads and executes the executable program 181 stored in the memory 1502 to:

当网络设备15所在的局域网断链时,控制通信接口1503通过广域网向控制设备发送网络设备15存储的第一数据块,以便该控制设备存储第一数据块;When the local area network where the network device 15 is located is disconnected, the control communication interface 1503 sends the first data block stored by the network device 15 to the control device through the wide area network, so that the control device stores the first data block;

当网络设备15所在的局域网连接恢复正常后,控制通信接口1503向该控制设备发送第一数据的索引,以便该控制设备根据第一数据的索引获取第一数据,其中,第一数据为所述第一数据块中的数据。When the local area network connection where the network device 15 is located returns to normal, the control communication interface 1503 sends the index of the first data to the control device, so that the control device obtains the first data according to the index of the first data, wherein the first data is the Data in the first data block.

进一步的,处理器1501,还用于当网络设备15所在的局域网断链时,通过广域网向该控制设备发送第一断链指令,以使该控制设备根据第一断链指令的指示,将该控制设备存储的第二数据块发送给网络设备15,然后断开该控制设备与广域网的连接;Further, the processor 1501 is also configured to send a first link disconnection instruction to the control device through the wide area network when the local area network where the network device 15 is located is disconnected, so that the control device sends the The second data block stored by the control device is sent to the network device 15, and then the control device is disconnected from the wide area network;

通过通信接口1503接收该控制设备发送的第二数据块,并将该第二数据块存储到存储器1502或其它的存储介质中;Receive the second data block sent by the control device through the communication interface 1503, and store the second data block in the memory 1502 or other storage media;

当网络设备15的局域网连接恢复正常后,接收该控制设备发送的第二数据的索引,该第二数据为上述第二数据块中的数据。After the LAN connection of the network device 15 returns to normal, the index of the second data sent by the control device is received, and the second data is the data in the above-mentioned second data block.

进一步的,处理器1501,还用于在网络设备15将第一数据块发送至该控制设备后,接收该控制设备发送的第二断链指令;Further, the processor 1501 is also configured to receive a second link disconnection instruction sent by the control device after the network device 15 sends the first data block to the control device;

根据所述第二断链指令的指示,断开网络设备15与所述广域网的连接。Disconnect the network device 15 from the wide area network according to the instruction of the second link disconnection instruction.

进一步的,处理器1501,具体用于存储第二数据块中与第一数据块不同的数据。Further, the processor 1501 is specifically configured to store data in the second data block that is different from the first data block.

进一步的,处理器1501,还用于当网络设备15所在的局域网断链,且该控制设备所在的局域网也断链时,接收并存储该控制设备发送的该控制设备存储的第二数据块;Further, the processor 1501 is also configured to receive and store the second data block sent by the control device and stored by the control device when the local area network where the network device 15 is located is disconnected and the local area network where the control device is located is also disconnected;

在网络设备15所在的局域网与该控制设备所在的局域网均恢复正常后,接收该控制设备发送的第二数据的索引,第二数据为第二数据块中的数据。After the local area network where the network device 15 is located and the local area network where the control device is located both return to normal, the index of the second data sent by the control device is received, and the second data is the data in the second data block.

可以理解的是,本发明实施例提供的网络设备15,也可以充当控制设备,即网络设备15的处理器1501通过执行应用程序,以实现上述与上述控制设备相同的功能。It can be understood that the network device 15 provided in the embodiment of the present invention can also serve as a control device, that is, the processor 1501 of the network device 15 executes an application program to realize the same functions as the above-mentioned control device.

其中,上述流程的具体细节,可以参照上述方法及装置实施例,此处不再赘述。Wherein, for the specific details of the above-mentioned process, reference may be made to the above-mentioned method and device embodiments, which will not be repeated here.

处理器1501可能是一个中央处理器(Central Processing Unit,简称为CPU),或者是特定集成电路(Application Specific Integrated Circuit,简称为ASIC),或者是被配置成实施本发明实施例的一个或多个集成电路。Processor 1501 may be a central processing unit (Central Processing Unit, referred to as CPU), or a specific integrated circuit (Application Specific Integrated Circuit, referred to as ASIC), or configured to implement one or more of the embodiments of the present invention integrated circuit.

需说明的是,上述处理器1501除了具有上述功能之外,还可用于执行上述方法实施例中的其他流程,It should be noted that, in addition to having the above-mentioned functions, the above-mentioned processor 1501 can also be used to execute other processes in the above-mentioned method embodiments,

在本申请所提供的几个实施例中,应该理解到,所揭露业务调度装置和方法,以及网络设备可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的。In the several embodiments provided in this application, it should be understood that the disclosed service scheduling apparatus and method, and network equipment may be implemented in other ways. For example, the device embodiments described above are illustrative only.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

另外,在本发明各个实施例提供的网络设备中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in the network device provided by each embodiment of the present invention may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

采用上述方案后,当第一控制设备的局域网连接断链时,第一控制设备通过广域网将第一数据块发送至第二控制设备存储,这样,第二控制设备中存储有第一控制设备中的所有数据块,另外,在连接恢复后,第一控制设备与第二控制设备之间可以传输待传输数据的索引,由于,第一控制设备与第二控制设备中均存储有相同的数据(可以包括第一数据块和第二数据块),因此,第一控制设备与第二控制设备可以对相应数据的索引进行解码后得到待传输数据(可以包括第一数据或第二数据),避免了第一控制设备与第二控制设备之间传输第一数据或第二数据,减少了广域网数据交互过程,增加了广域网传输的速度。After adopting the above solution, when the LAN connection of the first control device is disconnected, the first control device sends the first data block to the second control device for storage through the wide area network. In addition, after the connection is restored, the index of the data to be transmitted can be transmitted between the first control device and the second control device, because the first control device and the second control device both store the same data ( may include the first data block and the second data block), therefore, the first control device and the second control device may decode the index of the corresponding data to obtain the data to be transmitted (which may include the first data or the second data), avoiding The transmission of the first data or the second data between the first control device and the second control device is reduced, the data interaction process of the wide area network is reduced, and the transmission speed of the wide area network is increased.

通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到本发明可借助软件加必需的通用硬件的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在可读取的存储介质中,如计算机的软盘,硬盘或光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本发明各个实施例所述的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the present invention can be realized by means of software plus necessary general-purpose hardware, and of course also by hardware, but in many cases the former is a better embodiment . Based on this understanding, the essence of the technical solution of the present invention or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product is stored in a readable storage medium, such as a floppy disk of a computer , a hard disk or an optical disk, etc., including several instructions for enabling a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in various embodiments of the present invention.

以上所述,仅为本发明的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应所述以权利要求的保护范围为准。The above is only a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Anyone skilled in the art can easily think of changes or substitutions within the technical scope disclosed in the present invention. Should be covered within the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.

Claims (25)

Described first control appliance, also be used for sending first chain rupture instruction by described wide area network to described second control appliance, so that described second control appliance is according to the indication of described first chain rupture instruction, second data block of described second control appliance storage is sent to described first control appliance, and the wide area network that disconnects described second control appliance then connects; Receive and store described second data block that described second control appliance sends; After the local area network (LAN) of described first control appliance connects recovery normally, receive the index of second data of described second control appliance transmission, described second data are the data in described second data block;
CN201310293884.XA2013-07-122013-07-12The processing method of abnormal chain scission, device and systemActiveCN103338124B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN201310293884.XACN103338124B (en)2013-07-122013-07-12The processing method of abnormal chain scission, device and system

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201310293884.XACN103338124B (en)2013-07-122013-07-12The processing method of abnormal chain scission, device and system

Publications (2)

Publication NumberPublication Date
CN103338124Atrue CN103338124A (en)2013-10-02
CN103338124B CN103338124B (en)2016-12-28

Family

ID=49246228

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201310293884.XAActiveCN103338124B (en)2013-07-122013-07-12The processing method of abnormal chain scission, device and system

Country Status (1)

CountryLink
CN (1)CN103338124B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN103618714A (en)*2013-11-262014-03-05华为技术有限公司Method, relative device and system for data transmission

Citations (4)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN101325478A (en)*2008-08-062008-12-17北京北纬通信科技股份有限公司Method and system for data synchronization
CN101827020A (en)*2010-03-032010-09-08深圳市深信服电子科技有限公司Method and system for speeding up built persistent connection without disconnection
CN101945103A (en)*2010-08-092011-01-12中国电子科技集团公司第五十四研究所IP (Internet Protocol) network application accelerating system
US20110191442A1 (en)*2010-01-292011-08-04Michael OvsiannikovSystems and methods of using ssl pools for wan acceleration

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN101325478A (en)*2008-08-062008-12-17北京北纬通信科技股份有限公司Method and system for data synchronization
US20110191442A1 (en)*2010-01-292011-08-04Michael OvsiannikovSystems and methods of using ssl pools for wan acceleration
CN101827020A (en)*2010-03-032010-09-08深圳市深信服电子科技有限公司Method and system for speeding up built persistent connection without disconnection
CN101945103A (en)*2010-08-092011-01-12中国电子科技集团公司第五十四研究所IP (Internet Protocol) network application accelerating system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
YUJIE: "Riverbed广域网优化、应用加速技术白皮书", 《HTTP://NETWORK.CHINABYTE.COM/170/9032170.SHTML》, 27 July 2009 (2009-07-27), pages 1 - 6*

Cited By (2)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN103618714A (en)*2013-11-262014-03-05华为技术有限公司Method, relative device and system for data transmission
CN103618714B (en)*2013-11-262017-01-18华为技术有限公司Method, relative device and system for data transmission

Also Published As

Publication numberPublication date
CN103338124B (en)2016-12-28

Similar Documents

PublicationPublication DateTitle
JP7029471B2 (en) Uplink data decompression, compression method and equipment
CN107005428B (en) System and method for state replication of virtual network function instances
KR20200087231A (en) Method and apparatus for processing asynchronous buffer
US11863370B2 (en)High availability using multiple network elements
WO2017219779A1 (en)Device active/standby switchover method and apparatus based on link protocol, and storage medium
CN106576108B (en)Communication method, equipment and system in communication system
CN107465613B (en)Link aggregation interface communication state switching method and device
WO2018137720A1 (en)Method and device for data synchronization
CN102970172B (en)A kind of method that communication link switches, equipment and communication system
CN112969244B (en)Session recovery method and device
CN104683130B (en)A kind of method and apparatus of configuring stacking port
CN111385068B (en)Data transmission method, device, electronic equipment and communication system
CN103607311B (en)System and method for reestablishing TCP connection seamlessly
CN103338124B (en)The processing method of abnormal chain scission, device and system
CN109714135B (en)Data packet transmission method and device
CN107154861B (en)A kind of data transmission method and device of stacking system
JP6221498B2 (en) Information processing system and control method of information processing system
CN106209733B (en) A data processing method and device
CN107801218B (en)Control method and device for aggregating frames in access point switching
CN118473908B (en) Port determination method, device, electronic device and storage medium
JP2019165317A (en)Communication device, communication method and communication program
CN105379222A (en)State synchronization method and device based on TCP proxy
JP6268027B2 (en) COMMUNICATION SYSTEM, TRANSMISSION DEVICE, AND COMMUNICATION METHOD
WO2015196473A1 (en)Method, device, intelligent terminal and system for data sending/receiving
CN116074364A (en) Signaling transmission method, device and system

Legal Events

DateCodeTitleDescription
C06Publication
PB01Publication
C10Entry into substantive examination
SE01Entry into force of request for substantive examination
C14Grant of patent or utility model
GR01Patent grant

[8]ページ先頭

©2009-2025 Movatter.jp