A kind of seamless switching method and apparatus that is used for communication network
Technical field
The present invention relates to a kind of seamless switching method and apparatus that is used for communication network, relate in particular to the seamless switching method and apparatus that is used for the ethernet link under the real-time applied environment.
Background technology
December nineteen eighty-two the IEEE802.3 standard appearance, indicate the starting of ethernet technology standard, also indicate simultaneously the emerging of Ethernet product that meets international standard, has the height interoperability.At first, IEEE802.3 standard code Ethernet is the speed operation with 10Mbps, adopts Carrier Sense Multiple Access/collision detection (abbreviating CSMA/CD as) medium accesses control (abbreviating MAC as) agreement in the technology of sharing the medium transmitting data.1993, FDX Ethernet has appearred, changed the half-duplex mode of operation of previous Ethernet.In March nineteen ninety-five, passed through the IEEE802.3u standard that speed can arrive 100Mbps.In June, 1998, passing through of IEEE802.3z standard makes Ethernet enter the ranks of express network again, and its speed of service has reached 1000Mbps (being 1Gbps).On July 18th, 2002, IEEE has passed through the 802.3ae:10Gbps Ethernet.Ethernet technology has advantages such as cost is low, flexible, and particularly in recent years, because ethernet technology is in the obtained progress in aspects such as QoS, manageability, and the IPization of communication network, make that ethernet technology has obtained using very widely in Modern Communication System.But, when ethernet technology is applied in the real-time applied environment with redundant configuration, on the data link aspect, can there be two ethernet technology problems that produce by the limitation of standard itself according to existing Ethernet standard IEEE 802.3.
In many existing NGN (next generation network) equipment such as media gateway, Ethernet interface generally is used for wrapping side (packet-side) interface.If the physical link of Ethernet interface is 1: 1 a redundant configuration, and adopted automatic negotiation (AN, Atuo-Negotiation) mechanism (in fact, for gigabit Ethernet equipment as 1000Base-T and so on, existing code requirement AN is compulsory, even and equipment allows to force configuration, it also is illegal forcing configuration), then when handoff links, heavy chain connects the time will be greater than 2 seconds, can there be any problem in this in general application, but is unallowed in the real-time application such as VoIP (IP-based voice).In general, can adopt pressure configuration (forbidding is consulted automatically) to avoid this problem.But, in this case, can run into other problem, just following second problem will describing.
In the real time communication device such as media gateway, Ethernet interface need be configured to the full duplex mode of operation.When adopting the pressure configuration,, therefore can there be any problem (, yet can settle a dispute by the parties concerned themselves) even there is some problem because local device is independently developed.But, be difficult to the opposite equip. such as switch or router is configured.In fact, in some cases, can't be configured opposite equip. (such as, the equipment of some old model can not dispose).This will cause another problem, if promptly two ethernet devices (being called local participant (partner) and far-end participant at this) are connected to each other, then wherein a side adopts and forces configuration (as local participant), and the opposing party adopts automatic negotiation configuration (as the far-end participant).According to the existing Ethernet standard, negotiation result will be: local participant is a full duplex, and the far-end participant is semiduplex.This is being unallowed for the real-time application such as VoIP that needs the full duplex mode of operation, and more seriously, this negotiation result might make that data link is not communicated with.Regrettably, nearly all existing switch and router are all realized according to this rule.
Therefore, for now, at the problems referred to above, connect the time except adopting AN mechanism and standing long heavy chain, or to require subscriber equipment be configurable, in addition at subscriber equipment when not configurable, require the user to buy outside the new equipment, other solutions also do not occur.
Above-mentioned solution all is confined to existing ethernet standard IEEE802.3, and promptly negotiation can not determine there is not to use the duplex setting of the link participant of negotiation automatically automatically, therefore must suppose that the link participant is semiduplex.
In fact, above-mentioned ethernet technology is used for non real-time and is developed.Therefore, for real-time application, this technology can not be satisfied the demand far away.
Summary of the invention
The purpose of this invention is to provide a kind of seamless switching technique that is used for the ethernet link under the real-time applied environment, this method can be finished the switching of link in several milliseconds time, can overcome prior art long shortcoming switching time.
For achieving the above object, the present invention proposes a kind of communication network seamless handover method, wherein said communication network comprises first communication unit, the first spare communication unit, the second communication unit and the second spare communication unit, under initial condition, described first communication unit is connected with described second communication unit communication, the described first spare communication unit is connected with the described second spare communication unit communication, described first communication unit and the described first spare communication unit are connected to first terminal equipment, described second communication unit and the described second spare communication unit are connected to second terminal equipment, and the described first spare communication unit and the second spare communication unit are respectively the redundant configuration of described first communication unit and described second communication unit, described changing method comprises: first switch step, make the described first spare communication unit be in state of activation, described second communication unit is set to the loop pattern, and wherein the second communication unit will directly feed back to second terminal equipment from the data that second terminal equipment receives; Second switch step, the described second spare communication unit is set to the loop pattern, the wherein said second spare communication unit will directly feed back to second terminal equipment from the data that second terminal equipment receives, and the first spare communication unit receives data from the second communication unit as input; The 3rd switch step, second communication unit are removed the loop pattern, and receive data from the first spare communication unit as input; After above-mentioned switch step, described first terminal equipment communicates by the described first spare communication unit and second communication unit and described second terminal equipment.
In addition, the present invention also proposes a kind of seamless switching device, wherein said switching device shifter comprises first communication unit, the first spare communication unit, the second communication unit and the second spare communication unit, under initial condition, described first communication unit is connected with described second communication unit communication, the described first spare communication unit is connected with the described second spare communication unit communication, described first communication unit and the described first spare communication unit are connected to first terminal equipment, described second communication unit and the described second spare communication unit are connected to second terminal equipment, and the described first spare communication unit and the second spare communication unit are respectively the redundant configuration of described first communication unit and described second communication unit, the annexation of described switching device shifter each parts in each stage that first communication unit is switched to the first spare communication unit is as follows: the phase I, the second communication unit will directly feed back to second terminal equipment from the data that second terminal equipment receives; Second stage, the described second spare communication unit will directly feed back to second terminal equipment from the data that second terminal equipment receives, and the first spare communication unit receives data from the second communication unit as input; Phase III, the loop pattern is removed in the second communication unit, and receives data from the first spare communication unit as input; Described first terminal equipment communicates by the described first spare communication unit and second communication unit and described second terminal equipment.
The present invention is deferring to the existing communication network standard, ethernet standard (IEEE802.3) for example, prerequisite under, can change the configuration of opposite equip., adopt " virtual " to connect to come " deception " opposite equip., finally realize seamless link switchover.
That is to say that between the transfer period of communication unit, " virtual " that be provided to opposite equip. connects, and keep the state of activation that is linked as of opposite equip. by simple multiplex/demultiplex (MUX/DEMUX) circuit.In fact, this " virtual " connects from opposite equip. and returns opposite equip..
Existing solution does not have " virtual " to connect, and between transfer period, the link that can interrupt opposite equip. connects.Therefore,, then after finishing switching, need weigh automatically and consult if enabled automatic negotiation, and because the limitation of existing communication network standard, heavy automatic negotiation time can be very long ,-in general will be greater than 2 seconds.Solution of the present invention has solved this problem, promptly do not need heavy automatic negotiation time, so switching time can be very short, is about several milliseconds, and is enough this uses in real time for the great majority such as VoIP.
Depend on concrete application scheme, the communication unit of local device inside (as first communication unit and the first spare communication unit) may also need and the identical processing mode in the second communication unit and the second spare communication unit.At this moment, first communication unit and the first spare communication unit need be realized and the identical processing mode in the second communication unit and the second spare communication unit, the i.e. link of local device inside " deception ".Because this implementation is identical with the mode of above-mentioned " deception " opposite equip. link, therefore no longer repeat.
Description of drawings
Fig. 1 is the block diagram according to the network configuration of the embodiment of the invention.
Fig. 2 is the flow chart according to changing method of the present invention.
Fig. 3 is the structure chart according to each communication unit of the embodiment of the invention.
Fig. 4 is the initial condition figure according to each communication unit of the embodiment of the invention.
Fig. 5 is the state diagram according to each communication unit in first switch step of the embodiment of the invention.
Fig. 6 is the state diagram according to each communication unit in second switch step of the embodiment of the invention.
Fig. 7 is the state diagram according to each communication unit in the 3rd switch step of the embodiment of the invention.
Fig. 8 is the state diagram according to each communication unit in the 4th switch step of the embodiment of the invention.
With reference to the detailed description of accompanying drawing to the embodiment of the invention, other features of the present invention, application and advantage will become obvious according to following.
Embodiment
Fig. 1 is the block diagram according to the network configuration of the embodiment of the invention.As shown in FIG., the first communication unit 212-1 is connected with second communication unit 213-1, and the first communication unit 212-1 is connected to other modules 211 of local device 21, and second communication unit 213-1 is connected to opposite equip..The first spare communication unit 212-2 and the second spare communication unit 213-2 are respectively the redundant configuration of the first communication unit 212-1 and second communication unit 213-1, have link characteristics similar and annexation to it, wherein the first spare communication unit 212-2 communicates with the second spare communication unit 213-2 and is connected, the first spare communication unit 212-2 is connected to other modules 211 of local device 21, and the second spare communication unit 213-2 is connected to opposite equip. 22.Also have annexation between the first communication unit 212-1 and the second spare communication unit 213-2 and second communication unit 213-1 and the first spare communication unit 212-2, but not intercommunication mutually under normal circumstances.Solid line among the figure is represented the relation that communicates to connect between each parts under normal circumstances, and dotted line is illustrated in the relation that communicates to connect after switching.
Wherein, comprise the described first communication unit 212-1, second communication unit 213-1, the first spare communication unit 212-2 and the second spare communication unit 213-2 and other control circuit (not shown) by switching device shifter 20.This switching device shifter 20 can carry out link switchover between the first communication unit 212-1 and the first spare communication unit 212-2 or between the second communication unit 213-1 and the second spare communication unit 213-2 by the switching flow shown in the execution graph 2.
In some cases, first communication unit (or being called header board) 212-1 or second communication unit (or being called the back plate) 213-1 might break down or need break-off, to change and to safeguard, therefore need switch to another first spare communication unit 212-2 or another second spare communication unit 213-2.For both of these case, although implementation process difference slightly, from the handoff procedure of ethernet link, both are similar, therefore in the following embodiments, keep operate as normal with hypothesis second communication unit, and first communication unit is switched to example.
Fig. 2 is the flow chart according to changing method of the present invention.
In step 101, owing to breaking down or need to change, the first communication unit 212-1 cause this first communication unit can not operate as normal, need switch to the first spare communication unit 212-2 from the first communication unit 212-1, to take over the work of this first communication unit.In step 102, make the first spare communication unit 212-2 be in state of activation, take over the first communication unit 212-1, and second communication unit 213-1 is set to the loop pattern, loop pattern described here i.e. this communication unit directly feeds back to former link to the signal that receives from link, to keep the continuity of this link.In step 103, the second spare communication unit 213-2 is set to the loop pattern.In step 104, the data link that the first spare communication unit 212-2 switches himself the described second communication unit 213-1 direction of originating.In step 105, first spare communication unit 212-2 control second communication unit 213-1 makes it that peripheral link is connected to this first spare communication unit 212-2.In step 106, after the first communication unit 212-1 recovers normally, remove the loop pattern of the second spare communication unit 213-2, and the opposite equip. link is connected to the first spare communication unit 212-2.At last, handoff procedure ends at step 107.
Fig. 3 is the structure chart according to each communication unit of the embodiment of the invention.Wherein, each communication unit has similar structure and annexation, and they all have the control circuit Ctrl of multiplex/demultiplex circuit (shown in two square frames in each communication unit) and this multiplex/demultiplex circuit of control.What solid line and dotted line representative may be taked in switching communicates to connect communicating to connect after wherein dotted line is represented to switch.As can be seen from the figure each communication unit is broken down into identical three road signals input from the signal that link receives through the multiplex/demultiplex circuit, one road signal outputs to another multiplex/demultiplex circuit of himself, the second road signal outputs to another communication unit relative with it, and the Third Road signal outputs to the spare communication unit relative with it.Another multiplex/demultiplex circuit of each communication unit all receives three road signals simultaneously, and therefrom selects one road signal to be input on the link.
Fig. 4 is the initial condition figure according to each communication unit of the embodiment of the invention.Among the figure, the first communication unit 212-1 and second communication unit 213-1 are in state of activation, and the first spare communication unit 212-2 and the second spare communication unit 213-2 are in redundant state.Wherein, the data that the first communication unit 212-1 will send send to second communication unit 213-1, the second spare communication unit 213-2 and himself simultaneously, also receive data simultaneously from the second communication unit 213-1 and the second spare communication unit 213-2, but by multiselect one switch (the control circuit Ctrl of control multiplex/demultiplex circuit), only select a circuit-switched data wherein to handle, select under the initial condition in the drawings from the input of the data of second communication unit 213-1 as the first communication unit 212-1.
Second communication unit 213-1 will send to the first communication unit 212-1, the first spare communication unit 212-2 and the sending direction of himself simultaneously from the data that opposite equip. receives, receive simultaneously from the first communication unit 212-1, the first spare communication unit 212-2 and the data of himself, but by multiselect one switch, only select a circuit-switched data wherein to send to opposite equip., select under the initial condition in the drawings from the input of the data of the first communication unit 212-1 as second communication unit 213-1.
In initial condition shown in Figure 4, second communication unit 213-1 only receives the signal from the first communication unit 212-1, communicates to connect with its formation, therefore links to each other with solid line and represents.Similar with the first and second communication unit 212-1 and 213-1 between the first and second spare communication unit 212-2 and the 213-2, also formation communicates to connect.
Because the first spare communication unit 212-2 and the second spare communication unit 213-2 are in redundant state, therefore other modules 211 and the opposite equip. 22 of the local device 21 that is not connected with them respectively from the signal of the first spare communication unit 212-2 and the second spare communication unit 213-2 adopt.
Fig. 5 is the state diagram according to each communication unit in first switch step of the embodiment of the invention.Wherein, the first communication unit 212-1 fault occurred or because other reasons can not be worked, need switch to the first spare communication unit 212-2 from the first communication unit 212-1.At first make the first spare communication unit 212-2 be in state of activation, take over the first communication unit 212-1, i.e. data of using from the first spare communication unit 212-2 by other modules 211 of local device 21, and second communication unit 213-1 is set to the loop pattern, be that second communication unit 213-1 will send to the first communication unit 212-1 simultaneously from the data that opposite equip. receives, the communication path of selecting to send to himself in three paths of the first spare communication unit 212-2 and himself feeds back to opposite equip. 22 to the data from the opposite equip. reception again as input.It is constant with communicating to connect of the second spare communication unit 213-2 that the first spare communication unit 212-2 keeps, shown in the solid line among Fig. 5.
Fig. 6 is the state diagram according to each communication unit in second switch step of the embodiment of the invention.Among the figure, the second spare communication unit 213-2 is set to the loop pattern, promptly the second spare communication unit 213-2 will also select to send to himself communication path as input, the data from opposite equip. 22 are fed back to this opposite equip. 22.Simultaneously the first spare communication unit 212-2 gating is from the data of second communication unit 213-1, and it is transferred to other modules 211 of local device 21.At this moment the second communication unit can still keep the loop pattern.
Fig. 7 is the state diagram according to each communication unit in the 3rd switch step of the embodiment of the invention.Remove the loop pattern of second communication unit 213-1, promptly gating communicates to connect with first spare communication unit 212-2 formation from the signal of the first spare communication unit 212-2, and is shown in dotted line.Second switch step shown in Fig. 6 and Fig. 7 and the 3rd switch step can be carried out simultaneously, promptly, in the data of the first spare communication unit 212-2 gating from second communication unit 213-1, the second communication unit also switch to gating from the data of the first spare communication unit 212-2 as input.
Fig. 8 is the state diagram according to each communication unit in the 4th switch step of the embodiment of the invention.Suppose that the first communication unit 212-1 recovers normal, then remove the loop pattern of the second spare communication unit 213-2, promptly by the signal of the first communication unit 212-1 gating from the second spare communication unit 213-2, and this second spare communication unit 213-2 gating communicates to connect with this first communication unit 212-1 formation from the signal of the first communication unit 212-1.Notice that this moment, the first communication unit 212-1 and the second spare communication unit 213-2 were in redundant state, and the first spare communication unit 212-2 and second communication unit 213-1 are in state of activation.Continue to keep between the first spare communication unit 212-2 and the second communication unit 213-1 communicating to connect, when handover operation next time till.At this moment the first communication unit 212-1 is equivalent to the stand-by equipment of the first spare communication unit 212-2.
According to the present invention, the transfer period from the first communication unit 212-1 to the first spare communication unit 212-2, " virtual " that be provided to opposite equip. connects, and keeps the state of activation that is linked as of opposite equip. by multiplex/demultiplex (MUX/DEMUX) circuit.In fact, this " virtual " connects and will turn back to opposite equip. from the data of opposite equip..
In above-mentioned handoff procedure, key is to connect by " virtual " that the data from opposite equip. is turned back to opposite equip., makes opposite equip. link (being connected to second communication unit 213-1) keep state of activation.
Carry out finely if switch the data sync of preceding two header boards, switching time will be shorter.In fact, this time is exactly switching time (the problem to be solved in the present invention) of MUX/DEMUX device to add the data sync time, and with the prior art level, generally can reach the switching time of MUX/DEMUX device in the 1ns, also can be controlled in the 140ns in the worst case.For ethernet link, such deficiency of time carries out the Link State negotiation again to cause its PHY device, and data sync generally just can be finished in the hundreds of millisecond tens.Therefore, total time is tens to the hundreds of millisecond, and is enough this uses in real time for the great majority such as VoIP.
Though described a plurality of preferred embodiment of the present invention, those of ordinary skill in the art should recognize, under the situation that does not break away from essence of the present invention and principle, can make different changes, change and replacement.For example, when second communication unit 213-1 breaks down, also can switch to the second spare communication unit 213-2 to second communication unit 213-1 according to the described mode of similar above.So, claimed any its form and the modification in the proper range of claims of the present invention.For example, without departing from the scope of the invention, can come the feature of subsequently accessory claim is carried out various combinations according to the feature of independent claims.