CN104506359B - A kind of route pattern knows method for distinguishing and router - Google Patents

A kind of route pattern knows method for distinguishing and router Download PDF

Info

Publication number
CN104506359B
CN104506359B CN201410829025.2A CN201410829025A CN104506359B CN 104506359 B CN104506359 B CN 104506359B CN 201410829025 A CN201410829025 A CN 201410829025A CN 104506359 B CN104506359 B CN 104506359B
Authority
CN
China
Prior art keywords
outgoing interface
router
bandwidth
bandwidth ratio
mode threshold
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.)
Active
Application number
CN201410829025.2A
Other languages
Chinese (zh)
Other versions
CN104506359A (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.)
Maipu Communication Technology Co Ltd
Original Assignee
Maipu Communication Technology 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 Maipu Communication Technology Co Ltd filed Critical Maipu Communication Technology Co Ltd
Priority to CN201410829025.2A priority Critical patent/CN104506359B/en
Publication of CN104506359A publication Critical patent/CN104506359A/en
Application granted granted Critical
Publication of CN104506359B publication Critical patent/CN104506359B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The embodiment of the present invention provides a kind of route pattern and knows method for distinguishing and router, can reduce the difficulty and cost of network operation.Method includes:Router obtains in the mode threshold of n outgoing interface corresponding to route and the n outgoing interface each actual bandwidth of outgoing interface, wherein, n is the integer more than or equal to 2;Router calculates the ratio of actual bandwidth is maximum in the n outgoing interface outgoing interface and the actual bandwidth of other 1 outgoing interface of n in n outgoing interface respectively, obtains 1 bandwidth ratio of n;If the bandwidth ratio less than or equal to mode threshold in 1 bandwidth ratio of n be present, the route pattern of outgoing interface corresponding to the bandwidth ratio less than or equal to mode threshold is defined as load model by router;If the bandwidth ratio more than mode threshold in 1 bandwidth ratio of n be present, the route pattern that router will be greater than outgoing interface corresponding to the bandwidth ratio of mode threshold is defined as active-standby mode.The present invention is applied to the communications field.

Description

A kind of route pattern knows method for distinguishing and router
Technical field
The present invention relates to the communications field, more particularly to a kind of route pattern to know method for distinguishing and router.
Background technology
In existing customer application network, to realize circuit reliability, client would generally use two or more circuits.When When wherein a circuit occurs abnormal, customer traffic will be switched on an other circuit and forwarded, so as to realize that circuit can By property.
The route pattern configured according to client in three-layer routing equipment, above-mentioned two and Above Transmission Lines can be used for active and standby mould Formula, it can also be used to load model.Wherein, for three-layer routing equipment, master spare circuit corresponds to active-standby mode, in active-standby mode Under, there was only an outgoing interface and corresponding next-hop for same route prefix.Prefix, outgoing interface, the information quilt of next-hop Kernel route table is write, and the outgoing interface of corresponding spare line and the information of corresponding next-hop are then not written into kernel route table. When main line exception, such as the outgoing interface of corresponding main line is closed, then the routing iinformation for corresponding to main line is then deleted, now The information of the outgoing interface of spare line and corresponding next-hop can be write into kernel route table to work instead of main line.In load model Under, spare line and main line are all simultaneously for forwarding, i.e., for being embroidered with two outgoing interfaces and corresponding next-hop before same.
Generally, on a routing device, if reaching same destination has mulitpath, and the circuit on every paths When bandwidth is equal or is more or less the same, now client wishes that this paths is to wait in consumption multi-path mode, namely load model Equal cost load-balancing pattern;If every line bandwidth difference is larger, now client wishes that this mulitpath is active/standby mode, or Person wishes the consumption multi-path modes such as part circuit formation, and the circuit of other low bandwidth is active/standby mode.However, prior art In, either which kind of mode, it is required for first by manually going to configure the overhead value on line route, and then according in master/slave data The flow path of the heart adjusts the overhead value, then changes overhead value again to reach desired route pattern, i.e. needs are manually gone Safeguard route pattern during a plurality of circuit.This artificial maintenance not only increases the difficulty of network operation, and adds network The cost of maintenance.
The content of the invention
Embodiments of the invention provide a kind of route pattern and know method for distinguishing and router, at least to solve in the prior art The problem of difficulty of network operation caused by route pattern when needing manually to go to safeguard a plurality of circuit increases with cost, drop The low difficulty and cost of network operation.
To reach above-mentioned purpose, embodiments of the invention adopt the following technical scheme that:
In a first aspect, the embodiment of the present invention, which provides a kind of route pattern, knows method for distinguishing, methods described includes:
Router obtains in the mode threshold of n outgoing interface corresponding to route and the n outgoing interface each outgoing interface Actual bandwidth, wherein, n is the integer more than or equal to 2;
The router calculates the outgoing interface and the n outgoing interface that actual bandwidth is maximum in the n outgoing interface respectively In other n-1 outgoing interfaces actual bandwidth ratio, obtain n-1 bandwidth ratio;
If the bandwidth ratio less than or equal to the mode threshold in the n-1 bandwidth ratio be present, the router will The route pattern of outgoing interface is defined as load model corresponding to the bandwidth ratio less than or equal to the mode threshold;
If the bandwidth ratio more than the mode threshold in the n-1 bandwidth ratio be present, the router is by described in Route pattern more than outgoing interface corresponding to the bandwidth ratio of the mode threshold is defined as active-standby mode.
Second aspect, the embodiment of the present invention provide a kind of router, and the router includes:Acquiring unit, computing unit, Determining unit;
The acquiring unit, for obtaining in the mode threshold of n outgoing interface corresponding to route and the n outgoing interface often The actual bandwidth of individual outgoing interface, wherein, n is the integer more than or equal to 2;
The computing unit, it is individual for calculating the maximum outgoing interface of actual bandwidth and the n in the n outgoing interface respectively The ratio of the actual bandwidth of other n-1 outgoing interfaces in outgoing interface, obtain n-1 bandwidth ratio;
The determining unit, if for the bandwidth less than or equal to the mode threshold in the n-1 bandwidth ratio be present Ratio, the route pattern of outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold is defined as to load mould Formula;
The determining unit, if being additionally operable to the bandwidth ratio for having more than the mode threshold in the n-1 bandwidth ratio Value, is defined as active-standby mode by the route pattern of outgoing interface corresponding to the bandwidth ratio more than the mode threshold.
Based on such scheme, because the embodiment of the present invention is not as the same in the prior art, it is necessary to manually go to safeguard a plurality of Route pattern during circuit, but can as router according to corresponding to the route of acquisition the mode threshold of n outgoing interface and institute The actual bandwidth of each outgoing interface in n outgoing interface is stated, calculates the outgoing interface that actual bandwidth is maximum in the n outgoing interface respectively With the ratio of the actual bandwidth of other n-1 outgoing interface in the n outgoing interface, n-1 bandwidth ratio is obtained;And then according to this The route pattern of outgoing interface corresponding to the determination of bandwidth ratio.I.e., it is possible to according to the bandwidth ratio automatic identification route pattern of configuration, Therefore, the difficulty and cost of network operation are reduced.
Brief description of the drawings
Fig. 1 is the method flow schematic diagram one of route pattern provided in an embodiment of the present invention identification;
Fig. 2 is the method flow schematic diagram two of route pattern provided in an embodiment of the present invention identification;
Fig. 3 is the method flow schematic diagram three of route pattern provided in an embodiment of the present invention identification;
Fig. 4 is the method flow schematic diagram four of route pattern provided in an embodiment of the present invention identification;
Fig. 5 is the method flow schematic diagram five of route pattern provided in an embodiment of the present invention identification;
Fig. 6 is route system configuration diagram one provided in an embodiment of the present invention;
Fig. 7 is route system configuration diagram two provided in an embodiment of the present invention;
Fig. 8 is router topology schematic diagram one provided in an embodiment of the present invention;
Fig. 9 is router topology schematic diagram two provided in an embodiment of the present invention.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete Site preparation describes, it is clear that described embodiment is only part of the embodiment of the present invention, rather than whole embodiments.It is based on Embodiment in the present invention, those of ordinary skill in the art are obtained every other under the premise of creative work is not made Embodiment, belong to the scope of protection of the invention.
Embodiment one,
The embodiment of the present invention provides a kind of route pattern and knows method for distinguishing, as shown in figure 1, including:
S101, router obtain each outgoing interface in the mode threshold and n outgoing interface of n outgoing interface corresponding to route Actual bandwidth, wherein, n is the integer more than or equal to 2.
S102, router calculate other n- in the outgoing interface and n outgoing interface that actual bandwidth is maximum in n outgoing interface respectively The ratio of the actual bandwidth of 1 outgoing interface, obtain n-1 bandwidth ratio.
If the bandwidth ratio less than or equal to mode threshold in S103, n-1 bandwidth ratios be present, this is less than by router etc. The route pattern of outgoing interface is defined as load model corresponding to bandwidth ratio in mode threshold.
If the bandwidth ratio more than mode threshold in S104, n-1 bandwidth ratios be present, this is more than pattern threshold by router The route pattern of outgoing interface is defined as active-standby mode corresponding to the bandwidth ratio of value.
Specifically, the router in the embodiment of the present invention is specially customer router.
Specifically, in the embodiment of the present invention, corresponding n outgoing interface is route, n bars circuit middle part corresponding to the n outgoing interface Separated time road may be operated in load model, and part circuit may be operated in active-standby mode.The embodiment of the present invention is not made specifically to this Limit.
Active-standby mode:Because circuit lease expenses is very expensive, client would generally rent a high bandwidth and a low strap Wide circuit, the easy congestion of low bandwidth circuit, therefore to avoid unnecessary line congestion from causing packet loss problem, client generally adopts With an one standby mode of master, i.e., high bandwidth is only used to be worked as main line, a circuit uses as backup in addition.Client's industry After data of being engaged in enter three-layer routing device, forwarded due to being active-standby mode from main line, only when main line exception Forwarded from spare line.For three-layer routing equipment, master spare circuit corresponds to active-standby mode, under active-standby mode, for same One route prefix only has an outgoing interface and corresponding next-hop.Prefix, outgoing interface, the information of next-hop are written into core road By table, and the outgoing interface of corresponding spare line and the information of corresponding next-hop are then not written into kernel route table.When main line is different Chang Shi, such as the outgoing interface of corresponding main line are closed, then the routing iinformation for corresponding to main line is then deleted, now can be by spare wire The information of the outgoing interface on road and corresponding next-hop writes kernel route table and worked instead of main line.
Load model:Spare line and main line are all simultaneously for forwarding, i.e., for being embroidered with two outgoing interfaces before same With corresponding next-hop.Load model can be divided into equal cost load-balancing pattern and non-equivalence load-sharing mode.
Specifically, in the embodiment of the present invention, the reality of each outgoing interface in the mode threshold and n outgoing interface of n outgoing interface Border bandwidth is probably the advance manual configuration of user, it is also possible in the case of no manual configuration, the default value of use, and this hair Bright embodiment is not especially limited to this.Wherein, mode threshold is mainly used in load model and active-standby mode etc., typically complete Configuration mode threshold value under office's pattern.
Further, if as shown in Fig. 2 in n-1 bandwidth ratio exist less than or equal to mode threshold bandwidth ratio, The route pattern that this is less than or equal to outgoing interface corresponding to the bandwidth ratio of mode threshold by router is defined as load model (step S103 after), can also include:
This is less than or equal to outgoing interface and corresponding next-hop corresponding to the bandwidth ratio of mode threshold by S105, router In the kernel route table of information write-in router.
Further, if as shown in figure 3, the bandwidth ratio more than mode threshold, route in n-1 bandwidth ratio be present Device by this be more than mode threshold bandwidth ratio corresponding to outgoing interface route pattern be defined as active-standby mode (step S104) it Afterwards, can also include:
This is more than the information of outgoing interface and corresponding next-hop corresponding to the bandwidth ratio of mode threshold by S106, router Write in the kernel route table of router.
That is, in the embodiment of the present invention, after it can complete the identification of route pattern without manual intervention, can also complete The correct installation of route table items, so as to it is correct and fully, reasonably utilize line bandwidth, reach the investment for protecting user, simultaneously The cost of manual maintenance can be saved.
Further, as shown in figure 4, router by this be less than or equal to mode threshold bandwidth ratio corresponding to outgoing interface and In the kernel route table of the information write-in router of corresponding next-hop (step S105), it can specifically include:
S105a, router determine that this whether is stored in kernel route table corresponds to less than or equal to the bandwidth ratio of mode threshold Outgoing interface and corresponding next-hop information.
If S105b, not storing, router this is more than outgoing interface corresponding to the bandwidth ratio of mode threshold and it is corresponding under In the kernel route table of the one information write-in router jumped.
Further, as shown in figure 5, this is more than outgoing interface corresponding to the bandwidth ratio of mode threshold and corresponding by router Next-hop information write-in router kernel route table in (step S106), can specifically include:
S106a, router determine whether to store the outgoing interface that actual bandwidth is maximum in the n outgoing interface in kernel route table And the information of corresponding next-hop.
If S106b, not storing, router this is more than outgoing interface corresponding to the bandwidth ratio of mode threshold and it is corresponding under In the kernel route table of the one information write-in router jumped.
That is, in the embodiment of the present invention, when carrying out the installation of route table items, if some outgoing interface is corresponding to router Installation, then the outgoing interface and corresponding next hop information then without installing again.In this way, system resource can be saved, save Expense.
The embodiment of the present invention is further described below in conjunction with specific example.
Scene one:The processing mode of two outgoing interfaces be present in route
As shown in fig. 6, customer router distinguishes two carrier routers of the first line of a couplet, two carrier routers are remembered respectively ISP (Internet Service Provider, referred to as:ISP) A and ISPB, is deposited on customer router In prefix 10.0.0.0/8 route, there are two outgoing interfaces, be designated as interface g0 and interface g1 respectively in this route.It is realized Step is as follows:
Step 1:Actual bandwidth value, the configuration mode threshold value under global configuration mode are configured on interface g0 and interface g1. Such as g0 band a width of 100M, the g1 a width of 50M of band are configured in the present embodiment, the mode threshold of configuration is 5.So, Yong Hulu Band a width of 100M, g1 that the mode threshold of 2 outgoing interfaces corresponding to the route obtained as device is 5, the g0 a width of 50M of band.
Step 2:Calculate the bandwidth ratio between multiple outgoing interfaces corresponding to route.
Due to there was only two outgoing interfaces in this example, now maximum bandwidth interface is g0, therefore need to only calculate interface g0 and connect Bandwidth ratio between mouth g1, wherein, bandwidth ratio=100 between interface g0 and interface g1:50=2.
Step 3:Judge the size of bandwidth ratio and mode threshold.
Because the mode threshold in this example is 5, the bandwidth ratio between interface g0 and interface g1 that step 2 obtains is 2, it is clear that bandwidth ratio 2 is less than mode threshold 5, therefore is load model between interface g0 and interface g1, so as to by outgoing interface g0 Corresponding next hop information is fitted into the kernel route table of customer router with interface g1 and respectively.
Step 4:When link corresponding to interface g0 breaks down, route 10.0.0.0/8 only has an interface g1, then will Interface g1 is installed in the kernel route table of customer router.
In addition, it is necessary to explanation, if the bandwidth for the interface g1 that above-mentioned steps one configure is revised as 10M, mode threshold It is still 5 to keep constant, then the bandwidth ratio that route 10.0.0.0/8 is calculated in step 2 is 10, and then judge in step 3 Bandwidth ratio 10 is more than mode threshold 5, is active-standby mode between such a situation interface g0 and interface g1, so as to only by interface g0 with And its next hop information is installed in the kernel route table of customer router.
Scene two:The processing mode of three outgoing interfaces be present in route
As shown in fig. 7, customer router distinguishes three carrier routers of the first line of a couplet, three carrier routers are remembered respectively For ISPA, router ISPB and ISPC, prefix 10.0.0.0/8 route on customer router be present, this, which route, is present 3 outgoing interfaces, interface g0, interface g1 and g2 are designated as respectively.Implementation step is as follows:
Step 1:Actual bandwidth value is configured on interface g0, interface g1 and interface g2, mould is configured under global configuration mode Formula threshold value.Such as g0 band a width of 100M, g1 band a width of 50M, the g2 a width of 10M of band, mode threshold are configured in the present embodiment For 5.So, a width of 100M of band that the mode threshold of 3 outgoing interfaces corresponding to the route that customer router obtains is 5, g0, g1's With a width of 50M, the g2 a width of 10M of band.
Step 2:Calculate the bandwidth ratio between multiple outgoing interfaces corresponding to route.
G0 interfaces are the interface of maximum bandwidth in this example, can calculate the bandwidth between outgoing interface g0 and interface g1 respectively Ratio=100:50=2, the bandwidth ratio between outgoing interface g0 and interface g2 are 100:10=10.
Step 3:Judge the size of bandwidth ratio and mode threshold.
Because the mode threshold in this example is 5, the bandwidth ratio between interface g0 and interface g1 that step 2 obtains is 2, it is clear that bandwidth ratio 2 is less than mode threshold 5, therefore is load model between interface g0 and interface g1, so as to by outgoing interface g0 Corresponding next hop information is fitted into the kernel route table of customer router with interface g1 and respectively.
Because the mode threshold in this example is 5, the bandwidth ratio between interface g0 and interface g2 that step 2 obtains is 10, it is clear that bandwidth ratio 10 is more than mode threshold, therefore is active-standby mode between interface g0 and interface g1, so as to only by interface G0 and its next hop information are installed in the kernel route table of customer router.Because g0 interfaces have been installed in this step, Without installing g0 interfaces and next hop information again.
Step 4:When link corresponding to interface g0 breaks down, route 10.0.0.0/8 exist two outgoing interface g1 and G2, now maximum bandwidth interface is g1, and bandwidth ratio=50 between interface g1 and interface g2:10=5, this bandwidth ratio etc. It is load model in mode threshold, therefore between interface g1 and interface g2, so as to by outgoing interface g1 and outgoing interface g2 and correspondingly Next hop information fit into the kernel route table of customer router.
It should be noted that the example of above-mentioned scene two is referred to when route has more than three outgoing interfaces, the present invention This is no longer going to repeat them for embodiment.
The embodiment of the present invention provides a kind of route pattern and knows method for distinguishing, including:N go out corresponding to router acquisition route The actual bandwidth of each outgoing interface in the mode threshold of interface and n outgoing interface, wherein, n is the integer more than or equal to 2;Route Device calculates the actual band of actual bandwidth is maximum in n outgoing interface outgoing interface and other n-1 outgoing interfaces in n outgoing interface respectively Wide ratio, obtain n-1 bandwidth ratio;If the bandwidth ratio less than or equal to the mode threshold in n-1 bandwidth ratio be present The route pattern of outgoing interface corresponding to bandwidth ratio less than or equal to mode threshold is defined as load model by value, router;If The bandwidth ratio more than mode threshold in n-1 bandwidth ratio be present, the bandwidth ratio that router will be greater than mode threshold is corresponding The route pattern of outgoing interface be defined as active-standby mode.Based on such scheme, because the embodiment of the present invention is not as prior art In it is the same, it is necessary to route pattern when manually going to safeguard a plurality of circuit, but can be corresponding according to the route of acquisition by router The mode threshold of n outgoing interface and the actual bandwidth of each outgoing interface in the n outgoing interface, calculate the n respectively and go out The maximum outgoing interface of actual bandwidth and the ratio of the actual bandwidth of other n-1 outgoing interfaces in the n outgoing interface, are obtained in interface Obtain n-1 bandwidth ratio;And then according to the bandwidth ratio determine corresponding to outgoing interface route pattern.I.e., it is possible to according to configuration Bandwidth ratio automatic identification route pattern, therefore, reduce the difficulty and cost of network operation.
Embodiment two,
The embodiment of the present invention provides a kind of router 80, specifically as shown in figure 8, the router 80 includes:Acquiring unit 801st, acquiring unit 801, determining unit 803.
The acquiring unit 801, for obtaining the mode threshold of n outgoing interface and the n outgoing interface corresponding to route In each outgoing interface actual bandwidth, wherein, n is the integer more than or equal to 2.
The acquiring unit 801, for calculate respectively the maximum outgoing interface of actual bandwidth in the n outgoing interface with it is described The ratio of the actual bandwidth of other n-1 outgoing interfaces in n outgoing interface, obtain n-1 bandwidth ratio.
The determining unit 803, if for the band less than or equal to the mode threshold in the n-1 bandwidth ratio be present Wide ratio, the route pattern of outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold is defined as to load mould Formula.
The determining unit 803, if being additionally operable to the bandwidth for having more than the mode threshold in the n-1 bandwidth ratio Ratio, the route pattern of outgoing interface corresponding to the bandwidth ratio more than the mode threshold is defined as active-standby mode.
Further, as shown in figure 9, the router 80 also includes writing unit 804.
Said write unit 804, if being less than or equal to the pattern threshold for existing in the n-1 bandwidth ratio The bandwidth ratio of value, the determining unit 803 is by outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold Route pattern be defined as after load model, by outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold And the information of corresponding next-hop is write in the kernel route table of the router 80.
Further, as shown in figure 9, the router 80 also includes writing unit 804.
Said write unit 804, if for existing in the n-1 bandwidth ratio more than the mode threshold Bandwidth ratio, the determining unit 803 is by the route mould of outgoing interface corresponding to the bandwidth ratio more than the mode threshold Formula is defined as after active-standby mode, by the maximum outgoing interface of actual bandwidth in the n outgoing interface and the letter of corresponding next-hop Breath is write in the kernel route table of the router 80.
Further, said write unit 804 is specifically used for:
Determine whether stored in the kernel route table corresponding to the bandwidth ratio less than or equal to the mode threshold The information of outgoing interface and corresponding next-hop.
If not storing, by outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold and corresponding next The information of jump is write in the kernel route table of the router 80.
Further, said write unit 804 is specifically used for:
Determine whether to store the maximum outgoing interface of actual bandwidth in the n outgoing interface and corresponding in the kernel route table Next-hop information.
If not storing, the information of the maximum outgoing interface of actual bandwidth in the n outgoing interface and corresponding next-hop is write In the kernel route table for entering the router 80.
Specifically, the method that route pattern selection is carried out by router 80 provided in an embodiment of the present invention refers to implement The description of example one, the embodiment of the present invention will not be repeated here.
The embodiment of the present invention provides a kind of router, including:Acquiring unit obtains the pattern of n outgoing interface corresponding to route The actual bandwidth of each outgoing interface in threshold value and n outgoing interface, wherein, n is the integer more than or equal to 2;Computing unit is counted respectively Calculate the ratio of actual bandwidth is maximum in n outgoing interface outgoing interface and the actual bandwidth of other n-1 outgoing interfaces in n outgoing interface Value, obtain n-1 bandwidth ratio;If the bandwidth ratio less than or equal to the mode threshold in n-1 bandwidth ratio be present, it is determined that The route pattern of outgoing interface corresponding to bandwidth ratio less than or equal to mode threshold is defined as load model by unit;If n-1 The bandwidth ratio more than mode threshold in bandwidth ratio be present, determining unit will be greater than going out corresponding to the bandwidth ratio of mode threshold The route pattern of interface is defined as active-standby mode.Based on such scheme, because the embodiment of the present invention is not as in the prior art one Sample, but can be as router n according to corresponding to the route of acquisition, it is necessary to route pattern when manually going to safeguard a plurality of circuit The actual bandwidth of each outgoing interface, is calculated in the n outgoing interface respectively in the mode threshold of outgoing interface and the n outgoing interface The ratio of the maximum outgoing interface of actual bandwidth and the actual bandwidth of other n-1 outgoing interfaces in the n outgoing interface, obtains n-1 Individual bandwidth ratio;And then according to the bandwidth ratio determine corresponding to outgoing interface route pattern.I.e., it is possible to the bandwidth according to configuration Ratio automatic identification route pattern, therefore, reduce the difficulty and cost of network operation.
The foregoing is only a specific embodiment of the invention, but protection scope of the present invention is not limited thereto, any Those familiar with the art the invention discloses technical scope in, change or replacement can be readily occurred in, should all be contained Cover within protection scope of the present invention.Therefore, protection scope of the present invention described should be defined by scope of the claims.

Claims (10)

1. a kind of route pattern knows method for distinguishing, it is characterised in that methods described includes:
Router obtains in the mode threshold of n outgoing interface corresponding to route and the n outgoing interface each reality of outgoing interface Bandwidth, wherein, n is the integer more than or equal to 2;
The router calculates the outgoing interface and its in the n outgoing interface that actual bandwidth is maximum in the n outgoing interface respectively The ratio of the actual bandwidth of its n-1 outgoing interface, obtain n-1 bandwidth ratio;
If the bandwidth ratio less than or equal to the mode threshold in the n-1 bandwidth ratio be present, the router is by described in Route pattern less than or equal to outgoing interface corresponding to the bandwidth ratio of the mode threshold is defined as load model;
If the bandwidth ratio more than the mode threshold in the n-1 bandwidth ratio be present, the router is more than by described in The route pattern of outgoing interface is defined as active-standby mode corresponding to the bandwidth ratio of the mode threshold.
2. according to the method for claim 1, it is characterised in that be less than if existing in the n-1 bandwidth ratio Equal to the bandwidth ratio of the mode threshold, the router is corresponding by the bandwidth ratio less than or equal to the mode threshold The route pattern of outgoing interface be defined as after load model, in addition to:
The router is by outgoing interface and corresponding next-hop corresponding to the bandwidth ratio less than or equal to the mode threshold Information write in the kernel route table of the router.
3. method according to claim 1 or 2, it is characterised in that if existing in the n-1 bandwidth ratio big In the bandwidth ratio of the mode threshold, the router will go out to connect corresponding to the bandwidth ratio more than the mode threshold The route pattern of mouth is defined as after active-standby mode, in addition to:
The information of the maximum outgoing interface of actual bandwidth in the n outgoing interface and corresponding next-hop is write institute by the router In the kernel route table for stating router.
4. according to the method for claim 2, it is characterised in that the router is less than or equal to the mode threshold by described in Bandwidth ratio corresponding to the information of outgoing interface and corresponding next-hop write in the kernel route table of the router, including:
The router determines the bandwidth ratio for being less than or equal to the mode threshold whether is stored in the kernel route table The information of corresponding outgoing interface and corresponding next-hop;
If not storing, the router is by outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold and accordingly The information of next-hop write in the kernel route table of the router.
5. according to the method for claim 3, it is characterised in that the router is by actual bandwidth in the n outgoing interface Maximum outgoing interface and the information of corresponding next-hop are write in the kernel route table of the router, including:
The router determines whether to store the outgoing interface that actual bandwidth is maximum in the n outgoing interface in the kernel route table And the information of corresponding next-hop;
If not storing, the router is by the maximum outgoing interface of actual bandwidth in the n outgoing interface and corresponding next-hop Information is write in the kernel route table of the router.
6. a kind of router, it is characterised in that the router includes:Acquiring unit, computing unit, determining unit;
The acquiring unit, for obtaining in the mode threshold of n outgoing interface and the n outgoing interface corresponding to route each to go out The actual bandwidth of interface, wherein, n is the integer more than or equal to 2;
The computing unit, go out to connect with the n for calculating the outgoing interface that actual bandwidth is maximum in the n outgoing interface respectively The ratio of the actual bandwidth of other n-1 outgoing interfaces in mouthful, obtains n-1 bandwidth ratio;
The determining unit, if for the bandwidth ratio less than or equal to the mode threshold in the n-1 bandwidth ratio be present, The route pattern of outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold is defined as load model;
The determining unit, will if being additionally operable to the bandwidth ratio for having more than the mode threshold in the n-1 bandwidth ratio The route pattern of outgoing interface is defined as active-standby mode corresponding to the bandwidth ratio more than the mode threshold.
7. router according to claim 6, it is characterised in that the router also includes writing unit;
Said write unit, if for the band less than or equal to the mode threshold in the n-1 bandwidth ratio be present Wide ratio, the determining unit is by the route pattern of outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold Be defined as after load model, by outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold and it is corresponding under One information jumped is write in the kernel route table of the router.
8. the router according to claim 6 or 7, it is characterised in that the router also includes writing unit;
Said write unit, if for the bandwidth ratio more than the mode threshold in the n-1 bandwidth ratio be present Value, the determining unit is by based on the determination of the route pattern of outgoing interface corresponding to the bandwidth ratio more than the mode threshold After standby pattern, by described in the information write-in of the maximum outgoing interface of actual bandwidth in the n outgoing interface and corresponding next-hop In the kernel route table of router.
9. router according to claim 7, it is characterised in that said write unit is specifically used for:
Determine whether to store in the kernel route table and go out to connect corresponding to the bandwidth ratio less than or equal to the mode threshold The information of mouth and corresponding next-hop;
If not storing, by outgoing interface corresponding to the bandwidth ratio less than or equal to the mode threshold and corresponding next-hop Information is write in the kernel route table of the router.
10. router according to claim 8, it is characterised in that said write unit is specifically used for:
Determine whether to store in the kernel route table the maximum outgoing interface of actual bandwidth in the n outgoing interface and it is corresponding under One information jumped;
If not storing, the information of the maximum outgoing interface of actual bandwidth in the n outgoing interface and corresponding next-hop is write into institute In the kernel route table for stating router.
CN201410829025.2A 2014-12-25 2014-12-25 A kind of route pattern knows method for distinguishing and router Active CN104506359B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410829025.2A CN104506359B (en) 2014-12-25 2014-12-25 A kind of route pattern knows method for distinguishing and router

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410829025.2A CN104506359B (en) 2014-12-25 2014-12-25 A kind of route pattern knows method for distinguishing and router

Publications (2)

Publication Number Publication Date
CN104506359A CN104506359A (en) 2015-04-08
CN104506359B true CN104506359B (en) 2018-01-30

Family

ID=52948074

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410829025.2A Active CN104506359B (en) 2014-12-25 2014-12-25 A kind of route pattern knows method for distinguishing and router

Country Status (1)

Country Link
CN (1) CN104506359B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108173779B (en) * 2017-11-23 2018-11-16 泰山医学院 A kind of router automatic stand-by system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CA2283608A1 (en) * 1999-09-27 2001-03-27 Nortel Networks Corporation Architectures for communication networks
CN101039277A (en) * 2007-04-12 2007-09-19 华为技术有限公司 Load sharing method and its equipment
CN102801623A (en) * 2012-08-15 2012-11-28 杭州华三通信技术有限公司 Multi-access data transmitting method and device
CN103188165A (en) * 2013-03-12 2013-07-03 神州数码网络(北京)有限公司 Intelligent router multipath output load balancing method and router
CN103595649A (en) * 2013-11-21 2014-02-19 迈普通信技术股份有限公司 Method and system for achieving load balance

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CA2283608A1 (en) * 1999-09-27 2001-03-27 Nortel Networks Corporation Architectures for communication networks
CN101039277A (en) * 2007-04-12 2007-09-19 华为技术有限公司 Load sharing method and its equipment
CN102801623A (en) * 2012-08-15 2012-11-28 杭州华三通信技术有限公司 Multi-access data transmitting method and device
CN103188165A (en) * 2013-03-12 2013-07-03 神州数码网络(北京)有限公司 Intelligent router multipath output load balancing method and router
CN103595649A (en) * 2013-11-21 2014-02-19 迈普通信技术股份有限公司 Method and system for achieving load balance

Also Published As

Publication number Publication date
CN104506359A (en) 2015-04-08

Similar Documents

Publication Publication Date Title
US9049131B2 (en) Network system and load balancing method
CN106464589A (en) Partial software defined network switch replacement in IP networks
US9485172B2 (en) Data transmitting device, data transmitting method and non-transitory computer-readable storage medium
CN101252494B (en) Equipment and method for sharing traffic load
CN103685054A (en) Multipath load balancing method based on service awareness
CN103647711B (en) A kind of satellite network heavy route method based on priority mechanism
US8462636B2 (en) Systems and methods for communication of management traffic over link aggregation group interface for a network element with distributed architecture
EP2467973B1 (en) Method and means for state transition of Ethernet linear protection switching
CN103346979B (en) Flow distribution method and equipment in SPBM network
CN106209669A (en) Towards SDN data center network maximum of probability path stream scheduling method and device
CN103416028B (en) System and method for announcing composite link in gateway protocol internally and/or Interior Gateway Protocol traffic engineering
US20150163133A1 (en) Load sharing of mpls pseudo-wires
US8824488B2 (en) Methods, apparatus and articles of manufacture to select label switched paths (LSPs) for preemption
CN108337179A (en) Link flow control method and device
CA2619468C (en) Method, system and device for implementing traffic engineering
CN101399748A (en) Route computing method and router
CN103281253A (en) Load sharing method of non-equivalent route and equipment
CN109088822B (en) Data flow forwarding method, device, system, computer equipment and storage medium
EP2712131B1 (en) Method and network device for transmitting data stream
CN105262534B (en) A kind of method for routing and device suitable for satellite communication network
CN105745874A (en) Method and device for determining service function path
US20180227207A1 (en) Soft constrained shortest-path tunneling
CN106470165A (en) A kind of load sharing method, system and relevant device
CN108322406A (en) A kind of SDN data plane failure restoration methods based on link performance and flow point class
CN104506359B (en) A kind of route pattern knows method for distinguishing and router

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant