Embodiment
For make goal of the invention of the present invention, characteristic, advantage can be clearer, understandable; To combine the accompanying drawing in the embodiment of the invention below; Technical scheme in the embodiment of the invention is carried out clear, intactly description; Obviously, described embodiment only is the present invention's part embodiment, but not whole embodiment.Based on the embodiment among the present invention, those of ordinary skills are not making the every other embodiment that is obtained under the creative work prerequisite, all belong to the scope of the present invention's protection.
With reference to Fig. 1, a kind of flow chart that triggers the method for bypass equipment switching that Fig. 1 provides for the embodiment of the invention one.As shown in the figure, this method comprises:
Step S101: the real-time traffic that detects forthright equipment;
Preferably, can regularly detect the incoming interface flow of said forthright equipment and the tactful packet loss flow of outgoing interface flow and said forthright equipment; Concrete, the incoming interface flow of said forthright equipment can be meant the total amount of the packet that in sense cycle, flows through said forthright equipment incoming interface; Said outgoing interface flow can be meant the total amount of the packet that in proof cycle, flows through said forthright equipment outgoing interface; Said tactful packet loss flow is meant the packet loss flow that the forthright equipment self disposes in order to carry out present flow rate control, so in the application embodiment, said tactful packet loss flow can directly read.
Preferably, also can regularly detect the incoming interface flow of said forthright equipment and the mistake bag number of said forthright device interior statistics.Those skilled in the art can know; Each chip of forthright device interior is when the transmission data; Unavoidably have packet and pass wrong situation,, be referred to as wrong bag passing wrong packet here in order to narrate conveniently; Concrete, the mistake bag number of said forthright device interior statistics can be meant the summation of the mistake bag number of each chip statistics of said forthright device interior.
Step S102: judge whether said forthright equipment Traffic Anomaly takes place;
Concrete; Judge said forthright equipment whether take place Traffic Anomaly method can for; According to the incoming interface flow and the outgoing interface flow of said forthright equipment, and the tactful packet loss flow and the sense cycle of said forthright equipment, calculate the packet loss of said forthright equipment;
Concrete, said packet loss can be through calculating the difference of said incoming interface flow and said outgoing interface flow and said tactful packet loss flow, said difference and said sense cycle done division arithmetic obtain, and promptly packet loss can be by following formula calculating:
Packet loss=(incoming interface flow-outgoing interface flow-tactful packet loss flow)/sense cycle
Behind the packet loss that obtains said forthright equipment; Said packet loss and preset packet loss threshold value are compared; When said packet loss during, confirm said forthright equipment generation Traffic Anomaly, otherwise think that Traffic Anomaly does not take place said forthright equipment greater than said preset packet loss threshold value.
Wherein, said packet loss threshold value can be provided with according to the practical experience value, and for example, when said forthright equipment did not have collocation strategy packet loss flow, said packet loss threshold value can be 20%; In said forthright equipment disposition during tactful packet loss flow, said packet loss threshold value can be 30%, can also be set to other value according to actual needs certainly, does not do concrete qualification here.
Certainly, judge said forthright equipment whether take place Traffic Anomaly method can also for, calculate the Packet Error Rate of said forthright equipment according to the summation of the mistake bag number of said forthright device interior statistics and said incoming interface flow and sense cycle.The computational methods of said Packet Error Rate can comprise: the product that calculates sense cycle and said incoming interface flow (just flowing through the total amount of the packet of incoming interface in the sense cycle); With the merchant of the mistake bag number (summation of the mistake bag number of each chip of internal system just) of said forthright device interior statistics and the said product Packet Error Rate as said forthright equipment, promptly said Packet Error Rate can calculate by following formula:
Mistake bag number/(the incoming interface flow * sense cycle) of Packet Error Rate=forthright device interior statistics
Said Packet Error Rate and preset Packet Error Rate threshold value are compared,, confirm said forthright equipment generation Traffic Anomaly, otherwise think that Traffic Anomaly does not take place said forthright equipment when said Packet Error Rate during greater than said Packet Error Rate threshold value.
Said Packet Error Rate threshold value can be set according to the practical experience value, for example, can be set to 5%, certainly other value can also be set according to the actual requirements, does not do concrete qualification here.
Preferably; The method whether above-mentioned two kinds of detection forthright equipment Traffic Anomaly takes place can only exist a kind of; Also can exist simultaneously, promptly calculate packet loss, and also calculate Packet Error Rate when packet loss compared with preset packet loss threshold value; And Packet Error Rate and preset Packet Error Rate threshold value compared; When above-mentioned two kinds of methods exist simultaneously,, packet loss sent out Traffic Anomaly if, just explaining forthright equipment greater than said preset packet loss threshold value and/or said Packet Error Rate during greater than said Packet Error Rate threshold value.
Step S103: when said forthright equipment generation Traffic Anomaly, send and be used to trigger the indication message that said bypass equipment switches to communication link in the protection path; Otherwise return execution in step S101.
When detecting said forthright equipment generation Traffic Anomaly, send indication message to said bypass equipment, after said bypass equipment receives said indication message, communication link is switched to the protection path, improved the reliability that bypass equipment switches.
Preferably, in order further to optimize the foregoing description, said method also comprises:
Monitor the warning information of each module in the said forthright equipment, when module is sent warning information, send switching indication to said bypass equipment and switch to the protection path to trigger said bypass equipment.
Concrete, said warning information can be power alarm information, as, when supply voltage fell, forthright equipment can produce power alarm information, at this moment, sent indication message to said bypass equipment, triggered said bypass equipment and switched to the protection path; Said warning information can also be the communication between plates abnormality alarming, for example, and in the time can not communicating by letter between mainboard and the slave plate; When just mainboard can not be managed slave plate; Though still have flow on the slave plate, system can send the management abnormality alarming, at this moment; Also can send and switch indication, trigger said bypass equipment and switch to the protection path to said bypass equipment.Certainly, said warning information is not limited to above two kinds, can also be other system warning information or system exception information.
Need to prove; The method that the triggering bypass equipment that the application embodiment provides switches; Can run on forthright equipment, realize, also can run on outside the forthright equipment at the main control module of forthright equipment; Be that the back partition that forthright equipment communicates realizes, so long as can get access to forthright equipment outgoing interface flow, can like the place of wrong package informatin of interface flow and system and tactful packet loss flow.
Can know by such scheme; The method that the triggering bypass equipment that the application embodiment provides switches; Detect through forthright device interior system being carried out real-time traffic, in the inner fault of forthright device systems itself, but interface still has under the situation of light; In time trigger bypass equipment and switch to the protection path; Avoid the outgoing interface of forthright equipment that light signal is arranged, and the problem of the interrupted communication link that the module of forthright device interior causes when breaking down, improved the possibility that reliability that bypass equipment switches and communication are normally carried out.
Method flow diagram as shown in Figure 2, that a kind of bypass equipment that Fig. 2 provides for the embodiment of the invention switches.This method comprises: S201: detect the light signal strength of forthright equipment outgoing interface, and the monitoring indication message;
S202: whether the light signal strength of judging said forthright equipment outgoing interface is lower than preset light intensity threshold value or does not receive indication message; When the luminous intensity of said outgoing interface is lower than preset light intensity threshold value or receives said indication message; Execution in step S203, otherwise return execution in step S201;
S203: communication link is switched to the protection path.
That is to say that bypass equipment not only self detects the optical interface information of forthright equipment,, also communicate link switchover simultaneously through receiving indication message to judge whether to communicate link switchover.
After bypass equipment switches to the protection path; The technical staff overhauls forthright equipment; After the forthright equipment fault is got rid of, make bypass equipment switch back former communication link through manual mode, and make mode of operation change automatic mode into; Recover the optical signal detecting of bypass equipment, and whether monitoring receives indication message to the forthright equipment interface.
Can know by such scheme; The bypass equipment changing method that the application embodiment provides on the basis of the light signal strength that detects forthright equipment outgoing interface, can also communicate the switching of link through received communication link switchover indication information; The outgoing interface of having avoided bypass equipment to detect forthright equipment has light signal; But can not detect the forthright device interior and break down, can not communicate link switchover and the problem of the interrupted communication link that causes, improve the reliability that bypass equipment switches.
A kind of triggering bypass equipment device for switching structural representation that Fig. 3 provides for the embodiment of the invention, as shown in Figure 3, this device comprises: detection module 301, judge module 302 and trigger module 303;
Detection module 301 is used to detect the real-time traffic of forthright equipment 305;
Judge module 302 is used for judging according to said detection module 301 detected real-time traffics whether said forthright equipment 305 Traffic Anomaly takes place;
Trigger module 303 is used for when Traffic Anomaly takes place said forthright equipment 305, sends to be used to trigger the indication message that bypass equipment 304 switches to communication link in the protection path.
A kind of bypass equipment device for switching that triggers that the embodiment of the invention provides can be through detecting the real-time traffic of forthright equipment; And when judging said forthright equipment generation Traffic Anomaly; Send and switch indication to said bypass equipment, trigger bypass equipment communication link is switched to the protection path, avoided the outgoing interface of forthright equipment that light signal is arranged; And the interruption of the communication link that the module of forthright device interior causes when breaking down has improved the reliability that bypass equipment switches.
Fig. 4 provide for the embodiment of the invention another trigger the structural representation of bypass equipment device for switching, as shown in Figure 4, this device comprises:
Detection module 301 is used to detect the real-time traffic of forthright equipment 305;
Concrete, the real-time traffic of the forthright equipment 305 that detection module 301 detects can comprise: incoming interface flow, outgoing interface flow and tactful packet loss flow; Concrete, the incoming interface flow of said forthright equipment can be meant the total amount of the packet that in sense cycle, flows through said forthright equipment incoming interface; Said outgoing interface flow can be meant the total amount of the packet that in proof cycle, flows through said forthright equipment outgoing interface; Said tactful packet loss flow is meant the packet loss flow that the forthright equipment self disposes in order to carry out present flow rate control, so in the application embodiment, said tactful packet loss flow can directly read.
Judge module 302 is used for judging according to said detection module 301 detected real-time traffics whether said forthright equipment 305 Traffic Anomaly takes place; Wherein, judge module 301 can comprise first computing unit 401 and first comparing unit 402; First computing unit 401 is used for incoming interface flow, outgoing interface flow, tactful packet loss flow and preset sense cycle according to said forthright equipment 305, calculates the packet loss of said forthright equipment 305;
Concrete, said packet loss can be through calculating the difference of said incoming interface flow and said outgoing interface flow and said tactful packet loss flow, said difference and said sense cycle done division arithmetic obtain, and promptly packet loss can be by following formula calculating:
Packet loss=(incoming interface flow-outgoing interface flow-tactful packet loss flow)/sense cycle.
First comparing unit 402; Be used for said packet loss and preset packet loss threshold value are compared; When said packet loss during, confirm that Traffic Anomalies take place said forthright equipment 305, and send the Traffic Anomaly signal to trigger module 303 greater than said packet loss threshold value; Otherwise, think that Traffic Anomaly does not take place said forthright equipment.
Wherein, said packet loss threshold value can be provided with according to the practical experience value, and for example, when said forthright equipment did not have collocation strategy packet loss flow, said packet loss threshold value can be 20%; In said forthright equipment disposition during tactful packet loss flow, said packet loss threshold value can be 30%, can also be set to other value according to actual needs certainly, does not do concrete qualification here.
Trigger module 303 is used for behind the Traffic Anomaly signal that receives 402 transmissions of said first comparing unit, sends to be used to trigger the indication message that bypass equipment 304 switches to communication link in the protection path.
The triggering bypass equipment device for switching that the embodiment of the invention provides can judge whether the real-time traffic of forthright equipment is abnormal flow through the packet loss that detects and calculate forthright equipment; And when appearance is unusual; Trigger bypass equipment communication link is switched to the protection path, therefore, can avoid the outgoing interface of forthright equipment that light signal is arranged; And the module of forthright device interior breaks down and causes packet loss; And then the interruption of the communication link that causes, improved the reliability that bypass equipment switches, improved the possibility that communication is normally carried out.
Fig. 5 provide for the embodiment of the invention another trigger the structural representation of bypass equipment device for switching, as shown in Figure 5, this device comprises:
Detection module 301 is used to detect the real-time traffic of forthright equipment 305;
Concrete, the real-time traffic of the forthright equipment 305 that detection module 301 detects can also comprise: the mistake bag number of incoming interface flow and said forthright device interior statistics.
Judge module 302 is used for judging according to said detection module 301 detected real-time traffics whether said forthright equipment 305 Traffic Anomaly takes place;
Wherein, judge module 302 can comprise second computing unit 501 and second comparing unit 502;
Second computing unit 501, the incoming interface flow, wrong bag number and the preset sense cycle that are used for the forthright equipment 305 of said detection module 301 detections of foundation are calculated the Packet Error Rate of said forthright equipment;
The computational methods of said Packet Error Rate can comprise: the product that calculates sense cycle and said incoming interface flow (just flowing through the total amount of the packet of incoming interface in the sense cycle); With the merchant of the mistake bag number (summation of the mistake bag number of each chip of internal system just) of said forthright device interior statistics and the said product Packet Error Rate as said forthright equipment, promptly said Packet Error Rate can calculate by following formula:
Mistake bag number/(the incoming interface flow * sense cycle) of Packet Error Rate=forthright device interior statistics.
Second comparing unit 502 is used for said Packet Error Rate and preset Packet Error Rate threshold value are compared, and when said Packet Error Rate during greater than said Packet Error Rate threshold value, thinks said forthright equipment generation Traffic Anomaly, and sends the Traffic Anomaly signal; Otherwise think that Traffic Anomaly does not take place said forthright equipment;
Wherein, said Packet Error Rate threshold value can be set according to the practical experience value, for example, can be set to 5%, certainly other value can also be set according to the actual requirements, does not do concrete qualification here.
Trigger module 303 is behind the Traffic Anomaly signal that receives 502 transmissions of said second comparing unit, and transmission is used to trigger the indication message that bypass equipment 304 switches to communication link in the protection path.
The triggering bypass equipment device for switching that the embodiment of the invention provides can judge whether the real-time traffic of forthright equipment is abnormal flow through the Packet Error Rate that detects and calculate forthright equipment; And when appearance is unusual; Trigger bypass equipment communication link is switched to the protection path, therefore, can avoid the outgoing interface of forthright equipment that light signal is arranged; And the module of forthright device interior breaks down and causes wrong bag; And then cause the interruption of communication link, and improved the reliability that bypass equipment switches, improved the possibility that communication is normally carried out.
Need to prove; Above-mentioned judge module 302 can comprise first computing unit 401 and second computing unit 501 simultaneously, and with first computing unit, 401 corresponding first comparing units 402 and with second computing unit, 501 corresponding second comparing units 502.
When the real-time traffic that detects when detection module 301 is incoming interface flow, outgoing interface flow and tactful packet loss flow, detected real-time traffic is sent to first computing unit 401; The real-time traffic that detects when detection module 301 is the mistake bag of incoming interface flow and said forthright device interior statistics when counting, and detected real-time traffic is sent to second computing unit 501.
Second comparing unit 502 of first comparing unit 402 can send same Traffic Anomaly signal, also can send different Traffic Anomaly signals, does not do concrete qualification here.
Accordingly; Trigger module 303 is when receiving the Traffic Anomaly signal; No matter be that first comparing unit 402 sends; Still second comparing unit 502 sends, as long as what receive is the Traffic Anomaly signal, just sends and is used to trigger the indication message that bypass equipment 304 switches to communication link in the protection path.
In order further to optimize the foregoing description, the structural representation of another triggering bypass equipment device for switching that Fig. 6 provides for the embodiment of the invention, as shown in Figure 6, this installs on the basis like the described embodiment of Fig. 3, also comprises:
Monitoring modular 601 is used to monitor the warning information of each modules in the said forthright equipment 305, switches indication to said bypass equipment 304 and switches to the protection path to trigger said bypass equipment 304 when having monitored to send when module is sent warning information.
The embodiment of the invention is on basis embodiment illustrated in fig. 3; Further trigger bypass equipment communication link is switched to the protection path through the warning information of each module in the monitoring forthright equipment; Further improve the reliability that bypass equipment switches, guaranteed normally carrying out of communication.
Fig. 7 provides a kind of structural representation of bypass equipment for the embodiment of the invention, and as shown in Figure 7, this equipment comprises:
Detection module 701 is used to detect the light signal strength of forthright equipment outgoing interface, and monitors whether receive indication message; Handover module 702 is used for when the light signal strength of said forthright equipment outgoing interface is lower than preset light intensity threshold value or receives said indication message, communication link being switched to the protection path.
Concrete, said bypass equipment can be a bypass circuit, that is to say it can is the circuit that can realize above-mentioned handoff functionality.Can certainly be other devices that to realize above-mentioned handoff functionality.
The bypass equipment that the embodiment of the invention provides; Can in the light signal strength that detects forthright equipment outgoing interface, monitoring whether receive indication message; And when the light signal strength of forthright equipment outgoing interface is lower than preset light intensity threshold value or receives said indication message; Communication link is switched to the protection path, avoided the outgoing interface of forthright equipment that light signal is arranged, and the problem of the interrupted communication link that the module of forthright device interior causes when breaking down; Improve the reliability that bypass equipment switches, ensured normally carrying out of communication.
The Organization Chart of a kind of communication system that Fig. 8 provides for the embodiment of the invention, as shown in Figure 8, this system comprises: forthright equipment 801, bypass equipment 802 and trigger bypass equipment device for switching 803, wherein:
Forthright equipment 801 is used to set up communication link;
Trigger bypass equipment device for switching 803, be used to detect the real-time traffic of said forthright equipment 801, and transmission is used to trigger the indication message that said bypass equipment switches to communication link in the protection path when Traffic Anomaly appears in said forthright equipment;
Bypass equipment 802; Be used to detect the light signal strength of said forthright equipment outgoing interface; And whether monitoring receives indication message; When the light signal strength of said forthright equipment outgoing interface is lower than preset light intensity threshold value or receives said indication message, communication link is switched to the protection path.
Concrete, said triggering bypass equipment device for switching 803 can be arranged in the said forthright equipment 801, also can be the equipment that is independent of outside the said forthright equipment 801; When triggering bypass equipment device for switching 803 is arranged in the said forthright equipment 801; Forthright equipment 801 both can be used to set up communication link; Also can detect the real-time traffic of said forthright equipment 801, and transmission is used to trigger the indication message that said bypass equipment 801 switches to communication link in the protection path when Traffic Anomaly appears in said forthright equipment 801.
Concrete, said bypass equipment can be a bypass circuit, that is to say it can is the circuit that can realize above-mentioned handoff functionality.Can certainly be other devices that to realize above-mentioned handoff functionality.In forthright equipment the implementation that example is explained the communication system that the embodiment of the invention provides to trigger the bypass equipment switching device shifter below.As shown in Figure 9, the Organization Chart of another communication system that Fig. 9 provides for the application embodiment.
Under the normal condition, communicating by letter between device A and the equipment B accomplished through forthright equipment, that is to say, the communication link of device A between equipment B is the active channel among the figure; When internal module unglazed when the outgoing interface of forthright equipment or forthright equipment breaks down; Just need communication link be switched to the protection path through bypass equipment; Device A is directly linked to each other without forthright equipment with equipment B, keep device A normally to carry out with communicating by letter of equipment B.
Concrete; Forthright equipment triggers bypass equipment through inspection side self flow situation and switches; Wherein, Trigger process that bypass equipment switches can for: forthright equipment regularly detects the tactful packet loss flow of incoming interface flow, outgoing interface flow and this forthright equipment of this forthright equipment, and calculates the packet loss of this forthright equipment, that is: packet loss=(incoming interface flow-outgoing interface flow-tactful packet loss flow)/sense cycle according to the flow value that records.Then packet loss that calculates and preset packet loss threshold value are compared,, send indication message to said bypass equipment when said packet loss during greater than said preset packet loss threshold value.
Trigger process that bypass equipment switches can also for: forthright equipment regularly detects the incoming interface flow of this forthright equipment and the mistake bag number of this forthright device interior statistics, and calculates the Packet Error Rate of this forthright equipment according to flow value that records and wrong bag number, that is:
Mistake bag number/(the incoming interface flow * sense cycle) of Packet Error Rate=forthright device interior statistics; Then Packet Error Rate that calculates and preset Packet Error Rate threshold value are compared; When said Packet Error Rate during, send indication message to said bypass equipment greater than said preset Packet Error Rate threshold value.
Trigger process that bypass equipment switches can also for: monitor the warning information of each module in the said forthright equipment, switch indication to said bypass equipment and switch to the protection path to trigger said bypass equipment when having monitored to send when module is sent warning information.
Bypass equipment is checked the outgoing interface light signal strength of forthright equipment on the one hand, when the light signal strength of said outgoing interface is lower than preset light intensity threshold value, communication link is switched to the protection path; On the other hand, bypass equipment is monitored the indication message that forthright equipment sends simultaneously, and when monitoring receives indication message, communication link is switched to the protection path.Need to prove; The said scheme that provides of the application embodiment is not limited at the main control module of forthright equipment and realizes; Also can realize at the back partition that communicates with forthright equipment, can as long as can get access to the place of wrong package informatin in outgoing interface flow, incoming interface flow and the forthright system of forthright equipment.
In addition, described forthright equipment also is not limited to a physical equipment, the forthright system that also can be made up of many physical equipments.
The communication system that the embodiment of the invention provides; On the one hand through forthright equipment active detecting real-time traffic; And when the real-time traffic generation Traffic Anomaly of forthright equipment, initiatively trigger bypass equipment and switch, by bypass equipment communication link is switched to the protection path; Through forthright monitoring of equipment internal module whether warning information is arranged on the other hand, when warning information appears in its internal module, initiatively trigger bypass equipment and switch; Simultaneously; Bypass equipment in the embodiment of the invention; Whether monitoring receives indication message in monitoring forthright equipment outgoing interface light signal strength, when the light signal strength of said forthright equipment outgoing interface is lower than preset light intensity threshold value and/or monitoring and receives indication message, communication link is switched to the protection path; Thereby further improved the reliability that bypass equipment switches, ensured normally carrying out of communication.
One of ordinary skill in the art will appreciate that all or part of step in the whole bag of tricks of the foregoing description is to instruct relevant hardware to accomplish through program; This program can be stored in the computer-readable recording medium, and storage medium can comprise: read-only memory, random asccess memory, disk or CD etc.Above-described embodiment of the present invention does not constitute the qualification to protection range of the present invention.Any modification of within spirit of the present invention and principle, being done, be equal to replacement and improvement etc., all should be included within the claim protection range of the present invention.