Summary of the invention
In view of this, the purpose of this invention is to provide a kind of is the method for the accurate configured bandwidth of different queue at the IP network device port, this method is a kind of technological means of supporting to calculate and dispose automatically automatically each queue parameter and weights, the bandwidth resources that can guarantee each formation configuration reach the QoS designing requirement, have solved above-mentioned each problem that exists in the existing operator communication network and the network equipment preferably.
In order to achieve the above object, the invention provides a kind of is the method for the accurate configured bandwidth of different queue at the IP network device port, this method is that to adopt weighting circulation round robin method at the IP network device port be different queue configuration and scheduling bandwidth, promptly all formations that need dispatch are weighted scheduling to its flow successively according to the order of its formation sequence number, all are scheduled once as a dispatching cycle with each formation; Its technical scheme is may further comprise the steps:
(a) determine the design bandwidth ratio and the band width configuration precision parameter of each formation respectively, and according to these design bandwidth ratio selection reference bandwidth ratio and benchmark weights;
(b) calculate the formation weights of each formation respectively according to benchmark weights and reference bandwidth ratio;
(c) according to the formation weights of each formation, calculate the distribution bandwidth ratio of each formation, the actual bandwidth that obtains of i.e. this formation accounts for the ratio of link total bandwidth, and the difference of distributing bandwidth ratio and design bandwidth ratio, whether the difference of judging each formation again is smaller or equal to the band width configuration precision parameter of this formation; If, returning step (a) greater than its band width configuration precision parameter, the difference that a formation is arranged continues operation; The difference of having only all formations is carried out subsequent operation all smaller or equal to its band width configuration precision parameter;
(d) the formation weights of each formation are configured in the port of the network equipment.
It is the port that extracts grouped data and send to the network equipment from formation that described flow to formation is dispatched; The computing formula of the byte quantity of the grouped data flow D that is scheduled in each formation is: D=MTU+512 * (w
i-1); In the formula, MTU is the maximum transfer unit of this port link, w
iBeing natural number, is that sequence number is the formation weighting parameter of i; Formation sequence number i is interval natural number for [1, n], and n is the formation number of device port.
Described design bandwidth ratio α
iBe for sequence number be the bandwidth B that the formation of i is designed or distribute
iPhysics total bandwidth B with network equipment port
TotalRatio, promptly
Described band width configuration precision parameter ε
iBe to require the precision, i.e. the bandwidth ratio of the difference between the bandwidth of this formation actual disposition and its design bandwidth, or its actual allocated and the difference of its design bandwidth ratio that reach when being the queue assignment bandwidth of i for sequence number.
In the described step (a) service quality QoS that definite design bandwidth ratio and band width configuration precision depend on operator is disposed in each formation respectively and guarantee strategy and service level agreement SLA; Wherein, the design bandwidth ratio is to be determined in advance by artificial, or in the network operation process, according to the network traffics monitoring result, and the allocated bandwidth proportion requirement of the different queue of Que Dinging respectively; The band width configuration precision parameter is according to the determined parameter of the actual needs of service level agreement SLA or network O﹠M, requires the difference of the bandwidth ratio of actual allocated and design bandwidth ratio must be less than this parameter.
Described reference bandwidth ratio α
bBe each cohort design bandwidth ratio α in the device port
iIn minimum value, promptly
In the formula, formation sequence number i is interval natural number for [1, n], and n is the formation number of device port; Described benchmark weight w
bBe basic parameter determined according to following selection principle, that be used to calculate other each formation weights, these benchmark weights are natural number, and its selection principle is: if when requiring all queue parameters to minimize, and w
b=1; If require to check band width configuration precision parameter, this benchmark weight w
bSince 1 each natural number of selecting successively thereafter, calculate the difference of the bandwidth ratio of the bandwidth ratio of actual allocated and designing requirement respectively, up to calculate the allocated bandwidth proportional difference less than the band width configuration precision parameter till; Do not requiring when checking the band width configuration precision parameter that these benchmark weights are natural number arbitrarily.
The formation weights of each formation actual disposition in the described step (b)
Computational methods be: earlier calculating sequence number is the formation weights of i
Again to aforementioned calculation w as a result
iRound, round-off error is δ
i, the formation weights of the actual employing that to obtain this formation sequence number be i
, then
In the formula, MTU is the maximum transfer unit of port link, w
bBe the benchmark weights, α
iBe that sequence number is the cohort design bandwidth ratio of i, α
bBe the reference bandwidth ratio, formation sequence number i is interval natural number for [1, n], and n is the formation number of device port.
Described to the formation weight w
iThe method that rounds has multiple: round up or round downwards or round, the different methods of rounding can influence the accuracy of allocated bandwidth, and the different methods that rounds, round-off error δ
iDifferent spans is arranged: adopt when rounding up round-off error δ
iSpan be [0,1), adopt when rounding round-off error δ downwards
iSpan be (1,0], when adopting round, round-off error δ
iSpan be (0.5,0.5).
The bandwidth ratio of each formation actual disposition in the described step (c)
Computing formula be:
In the formula, MTU is the maximum transfer unit of port link,
And w
iBe respectively to be the formation weights and the formation weights that calculate, δ of the formation actual disposition of i for sequence number
iBe parameter w
iRound-off error, and these three parameters satisfy formula
, formation sequence number i is interval natural number for [1, n], n is the formation number of device port.
Calculate the bandwidth ratio of each formation actual allocated in the described step (c)
With design bandwidth ratio α
i, difference, judge again whether the difference of each formation is less than or equal to the band width configuration precision parameter ε of this formation
i, computing formula be:
In the formula, MTU is the maximum transfer unit of this port link,
And α
iBe respectively that sequence number is the bandwidth ratio and the design bandwidth ratio of the formation actual disposition of i, w
iBe the formation weights of this formation of calculating, δ
iIt is this formation weight w
iRound-off error; Formation sequence number i is interval natural number for [1, n], and n is the formation number of device port.
Formation weights in each formation of port arrangement of the network equipment in the described step (d) have two kinds of collocation methods:
(1) network equipment is gathered formation flow information and definite design bandwidth ratio of this device port separately, or directly accepts the design bandwidth ratio of each formation of this device port of configured in advance; Again according to the method for described step (a)~(c), each formation weights that calculate, and these formation weights are configured to each formation of this device port correspondence;
(2) webserver concentrate to be gathered formation flow information and definite design bandwidth ratio of the whole network all devices port, or directly accepts the design bandwidth ratio of each formation of all devices port of configured in advance; According to the method for described step (a)~(c), calculate each formation weights again, and these formation weights are distributed to each network equipment, respectively the formation weights are configured to each formation of this device port correspondence by the network equipment separately.
The present invention be a kind of be the method for the accurate configured bandwidth of different queue at the IP network device port, can calculate automatically and the automatically technological means and the method for deployment queue parameter as a kind of.The invention enables Virtual network operator can define the bandwidth resources collocation strategy, calculate the weighting parameter of individual queue by O﹠M personnel or O﹠M system the method according to this invention, and be configured to the network equipment, realization is to the allocated bandwidth of individual queue, and can assess the allocated bandwidth error, realize the business that has service quality QoS to guarantee for the user.
The present invention supports two kinds of implementations: centralized weighting parameter calculating and configuration mode and distributed weighting parameter calculate and configuration mode.Wherein centralized weighting parameter calculates and configuration mode, does not increase the load of the network equipment, and can improve the responding ability after the network O﹠M system changes to device port different queue flow bandwidth ratio, in time adjusts the weighting parameter of individual queue.Distributed weighting parameter calculates and configuration mode has then been simplified the flow information collecting work of device port and the amount of calculation that focuses on, and, the weight calculation method of each device port is also uncomplicated, can not roll up the load of the network equipment, but relatively to lack be its defective to the whole network notion.
Embodiment
For making the purpose, technical solutions and advantages of the present invention clearer, the present invention is described in further detail below in conjunction with accompanying drawing.
Rule of thumb, in order to realize service quality QoS, queue scheduling mechanism is operator's most widely used a kind of technology in network.The present invention is directed to the dispatcher that is adopted and manufacture following hypothesis:
Scheduling mechanism has n formation, and n is a natural number;
Adopt the dispatching sequence of weighting circulation round robin between the individual queue, promptly in a dispatching cycle, individual queue according to its formation sequence number 1,2 ..., the order of n is weighted scheduling, all be scheduled once as a dispatching cycle with each formation.
In a dispatching cycle, the queue length that each formation can be dispatched is MTU+ (w
i-1) * 512, wherein MTU is the maximum transfer unit of link, w
iBe the weighting parameter of each formation, wherein i is interval natural number for [1, n], and n is the formation number of device port; On the port of the network equipment, MTU is a fixed value.Therefore, the bandwidth resources of individual queue acquisition depend on the weighting parameter w of each formation
i
Queue length MTU+ (the w that above-mentioned each formation can be dispatched
i-1) * 512 be the average queue length of its scheduling.Because block length and MTU+ (w through the formation after the scheduling
i-1) * 512 be not the relation of integral multiple just, therefore, the formation actual schedule length in this dispatching cycle can with MTU+ (w
i-1) there is difference * 512, and need in next dispatching cycle, compensates.Such as, configuration w
1=1, MTU=1500byte, the block length of formation 1 is 400 bytes.In this dispatching cycle, formation 1 has sent 4 groupings, i.e. 1600bytes; In following one-period, formation 1 requirement can only be dispatched 1400 bytes.
Therefore, the present invention as a kind of be the method for the accurate configured bandwidth of different queue, come down to calculate weights and distribute bandwidth resources for each formation of IP network device port.The present invention has solved how to calculate formation weights and accurate configured bandwidth resource preferably, so that guarantee the problem of band width configuration precision.
Weights of the present invention calculate both can adopt hubbed mode, was realized by the webserver, also can adopt distributed mode, was realized voluntarily by each network equipment; Can guarantee the configured bandwidth precision of different queue.
Referring to Fig. 1, the inventive method comprises that step is as follows:
(a) determine the design bandwidth ratio and the band width configuration precision of each formation respectively, and according to these design bandwidth ratio selection reference bandwidth ratio and benchmark weights;
(b) calculate the formation weights of each formation respectively according to benchmark weights and reference bandwidth ratio;
(c) according to the formation weights of each formation, calculate the distribution bandwidth ratio of each formation, the actual bandwidth that obtains of i.e. this formation accounts for the ratio of link total bandwidth, and the difference of distributing bandwidth ratio and design bandwidth ratio, whether the difference of judging each formation again is smaller or equal to the band width configuration precision parameter of this formation; If, returning step (a) greater than its band width configuration precision parameter, the difference that a formation is arranged continues operation; The difference of having only all formations is carried out subsequent operation all smaller or equal to its band width configuration precision parameter;
(d) the formation weights of each formation are configured in the port of the network equipment.
Therefore, according to the principle of design of the present invention and dispatching algorithm, individual queue weighting parameter computing formula is obtained by following Equation for Calculating;
Wherein,
Through directly calculating, have the relation of following formula between the weighting parameter of individual queue:
Wherein, α
1And w
1Be respectively the bandwidth ratio and the weighting parameter of formation 1, can change the bandwidth ratio and the weighting parameter of other any formation into, do not influence the selection and the calculating of weighting parameter.
Fig. 1 has described whole execution flow processs of the inventive method.This flow process comprises 4 steps: step (a), determine the design bandwidth ratio and the band width configuration precision of each formation, and according to these design bandwidth ratio selection reference bandwidth ratio and benchmark weights; Step (b) is calculated the formation weights of individual queue according to benchmark weights and reference bandwidth ratio, and the formation weights that calculate are revised; Step (c) judges whether the bandwidth of individual queue actual allocated and the error of design bandwidth satisfy the band width configuration required precision after adopting these formation weights; Step (d) is carried out the configuration of formation weighting parameter.
In step (a), the common allocated bandwidth strategy that generates of the service level agreement SLA of operator, network operation present situation and operation strategy, thereby the design bandwidth ratio and the band width configuration precision parameter of definite each formation.It is first committed step of the present invention that reference bandwidth ratio and benchmark weights are selected.
In step (b), the formation weights that calculate individual queue are second committed steps of the present invention.In this step, benchmark weights and reference bandwidth ratio are used to calculate the formation weights of individual queue.The present invention requires to determine a pair of benchmark weights and reference bandwidth ratio for each port.Because the flow of the different port formation of heterogeneous networks equipment is formed different, the present invention allows different port to adopt different benchmark weights and reference bandwidth ratio.The computational methods of individual queue weights are described in detail by Fig. 2 A and Fig. 2 B.Because directly the formation weighting parameter that calculates may not be an integer, and the network equipment need dispose the integer weights usually, therefore, the present invention requires operation is revised-rounded to the formation weighting parameter, and round-off error has caused the allocated bandwidth error.
In step (c), according to the formation weights that calculate, determine the bandwidth ratio that individual queue is distributed, the computation bandwidth proportional error, and judge whether to satisfy the error precision of allocated bandwidth.If do not satisfy precision, the reference bandwidth ratio remains unchanged, and need reselect the benchmark weights, and the determining step in calculation procedure in the execution in step (b) and the step (c).If satisfy required precision, enter the step of weights distribution and configuration.
In step (d), weighting parameter is distributed to the network equipment, and the network equipment is responsible for carrying out the configuration of formation weighting parameter, and according to the bandwidth scheduling flow that distributes.
Referring to Fig. 2 A and Fig. 2 B, wherein Fig. 2 A introduces the computational methods flow process of each formation weights when having the band width configuration required precision, and this weighting parameter that calculates can guarantee that the bandwidth resources of individual queue configuration reach initial specified accuracy requirement.Fig. 2 B has then introduced the computational methods flow process of each formation weights that do not have the band width configuration required precision, and at this moment, its weighting parameter is optional, and substantially proportionally distributes bandwidth resources.The flow chart of Fig. 2 B has comprised the minimized situation of weighting parameter simultaneously.
The flow process of further explanatory drawings 2A at first.
Step (110A): design bandwidth ratio or the band width configuration precision of obtaining formation.Operator often considers the band width configuration precision that different queue design bandwidth ratio and requirement reach from the angle of commerce, and directly is configured to the network equipment by O﹠M personnel or management system.This requirement even can be included in the SLA agreement of operator.In the real network operation, the band width configuration precision is by the difference decision of design bandwidth ratio and actual disposition bandwidth ratio.Actual disposition bandwidth ratio is calculated by the ratio that the speed of individual queue actual disposition bandwidth or the actual transmitted traffic of this formation accounts for total bandwidth.Therefore, design bandwidth ratio and band width configuration precision are the parameters of attendant or system configuration, but the present invention does not relate to how defining and select design bandwidth ratio and band width configuration precision.
Step (120A): each parameter of initialization, comprise each cohort design bandwidth ratio of initialization, form design bandwidth ratio S set, the selection reference weight w
bWith reference bandwidth ratio α
bWherein the benchmark weights must be positive integers.If require the ownership value parameter to minimize, then the benchmark weights get 1.If also there is other requirement, the benchmark weights can be selected other positive integer.Reference bandwidth ratio α
bAdopt the minimum value in the design bandwidth ratio S set of all formations.
Does step (130A): the band width configuration precision of the individual queue that calculating and judgement obtain reach requirement? if execution in step (160A): the individual queue weights of determining this moment are exactly needed weights; Otherwise, execution in step (140A): calculate the individual queue weighting parameter according to following formula:
If the weights that calculate this moment are not integers, round these weights.
Step (150A): bandwidth ratio and the allocated bandwidth error of calculating individual queue.Wherein the computing formula of allocated bandwidth ratio is:
In the formula
Be the weighting parameter of individual queue actual allocated, δ
iBe the weights round-off errors, satisfy 0≤| δ
i|<1, if adopt round, 0≤| δ
i|<0.5, formation sequence number i=1 ..., n.
The computing formula of band width configuration error is:
In the formula, formation sequence number i=1 ..., n.
Whether the band width configuration precision meets the requirements of Rule of judgment is whether following equation is set up:
Wherein formation sequence number i=1 ..., n.If do not meet the demands, then the benchmark weights are added 1, return step (130A) and carry out associative operation.
The flow process of following brief description Fig. 2 B.
The task that step (110B) and step (120B) are finished is similar to step (110A) and step (120A): though do not exist the benchmark weights to get 1 requirement, but still need selection reference bandwidth ratio, reference bandwidth ratio α
bAdopt the minimum value of all cohort design bandwidth ratios.
The work that step (130B) is finished is identical with the task that step (140A) is finished, and promptly calculates the individual queue weighting parameter.
Introduce the two kind methods of the present invention below at the formation weights of each formation of port arrangement of the network equipment:
Schematic diagram referring to the system 200A shown in Fig. 3 A.In this system, central server 210A is used to realize that weighting parameter of the present invention calculates.System 200A comprises central server 210A, weights calculator 215A and network equipment 220A
1To 220A
N, these network equipments are to adopt the inventive method to carry out the queue scheduling strategy in the entire I P/MPLS network.Central server 210A comprises weights calculator 215B, weights choice device promptly of the present invention.This weights calculator 215A is according to bandwidth Design ratio and band width configuration required precision, calculates the network equipment port formation weights that all adopt weighting round-robin scheduling algorithm, and the weights that calculate are issued to each network equipment 220A
1To 220A
NEach port queue.
Referring to the schematic diagram of the system 200B shown in Fig. 3 B, in this system, in each network equipment that adopts weighting round-robin scheduling algorithm, realize weights calculation element of the present invention.This system comprises each network equipment 230B
iTo 230B
MThese network equipments are not limited to edge device, comprise the all-network equipment that has adopted weighting round-robin queue dispatching algorithm in the network arbitrarily.Each network equipment has all adopted a local weights calculator 235B
i, i=1 ..., M, weights promptly of the present invention calculate and choice device.This this locality weights calculating and choice device are according to each port queue bandwidth Design ratio and band width configuration accuracy computation individual queue weighting parameter value.Each network equipment is carried out the allocated bandwidth of individual queue according to the formation of result of calculation configured port.
Referring to Fig. 4 is the module diagram of weights calculating of the present invention and choice device 300.These weights calculate and choice device 300 comprises: allocated bandwidth policing parameter generation module 310 is used for generating the allocation strategy parameter according to the allocated bandwidth strategy; Weights computing module 320 is used for according to allocated bandwidth policing parameter and band width configuration required precision selection reference bandwidth ratio and benchmark weights, the weighting parameter of each port queue of computing network equipment; And weights distribution module 330, be used to issue the weighting parameter value.On this weights calculating and choice device 300, carry out weight calculation method of the present invention.
In weights calculating and choice device 300, band width configuration policing parameter generation module 310 generates individual queue design bandwidth and band width configuration precision according to above-mentioned definite allocated bandwidth strategy.The operator can be input to the allocated bandwidth strategy in the allocated bandwidth policing parameter generation module 310 by various input modes, for example by keyboard or the form by graphical interfaces, and the perhaps form by file.
320 of weights computing modules are based on following two kinds of information calculations weights: the actual allocated bandwidth information in the Interface status database; Information such as the design bandwidth of individual queue and band width configuration precision.Weights computing module 320 is selection reference weights and reference bandwidth ratio at first, then calculates each interface queue weights.Weights distribution module 330 is to network equipment distribution rights value parameter.The network equipment is responsible for disposing weights on each port queue, and according to the weighting parameter schedules traffic that disposes, carries out individual queue allocated bandwidth task.
If weights choice device 300 is realized (as shown in Figure 3A) by central server, database of information such as the allocated bandwidth strategy of necessary each port queue of maintaining network equipment of central server and configuration required precision.The relevant informations such as allocated bandwidth strategy of this database storage network equipment port formation.
If weights choice device 300 is realized (shown in Fig. 3 B) by each network equipment, each network equipment need be safeguarded an interface bandwidth collocation strategy database, stores information such as the allocated bandwidth strategy of each interface queue and band width configuration required precision.In the weights calculating and choice device of environment shown in Fig. 3 B, the network equipment is carried out this locality of weights and is calculated, and carries out local weights configuration and allocated bandwidth, and the weights distribution module does not need to carry out concrete operations.
In the present invention, the design bandwidth ratio is that O﹠M system, O﹠M personnel or administrative staff determine according to various historical flow informations.In the more stable network environment of various flow proportion of composing, the design bandwidth ratio does not need frequent renewal, and individual queue can keep than higher band width configuration precision.In the network environment of various flow proportion of composing less stables, the design bandwidth ratio needs to bring in constant renewal in, and causes the band width configuration precision of individual queue lower.In order to improve assignment accuracy, a possible way is exactly the conversion of the various flow proportion of composing of real time monitoring network, and upgrade in time individual queue design bandwidth and weights.
Following mask body is introduced several embodiments of the present invention:
In first embodiment, the weights system of selection that weights of the present invention calculate and choice device is realized has the band width configuration required precision.It below is detailed description to first embodiment.
The band width configuration required precision ε of port individual queue
iThe bandwidth ratio of expression individual queue actual disposition and the difference of design proportion must be less than this numerical value ε
i, formation sequence number i=1 in the formula ...., n, n represent the number of queues of port.
In the present invention, the bandwidth ratio of network equipment port individual queue actual allocated is calculated according to following formula:
Wherein
Be the weights of individual queue actual disposition.This formulate within a dispatching cycle, formation 1 ..., the formation total length that n sends accounts for the ratio of the formation total length that this port sends in this one-period.Though have the long influence that waits various factors of bag, causing individual queue may not be to send length just to be
Flow, but through the circulation in a plurality of cycles, individual queue can guarantee that the average length that sends is MTU+512 (α
i-1), i=1 ..., n.Just can verify through simple calculating.With configuration α
i=1, MTU=1500byte, the block length 400byte of formation 1 are example, and in dispatching cycle 1, formation 1 has sent 4 groupings, i.e. 1600bytes; In the cycle 2, formation 1 requirement can only send 1400bytes, and reality has sent 4 groupings, altogether 1600bytes; In the cycle 3, formation 1 requires only to send 1300bytes, and reality has sent 4 groupings, altogether 1600bytes; In the cycle 4, formation 1 requires only to send 1200bytes, and reality has sent 3 groupings, altogether 1200bytes.4 cycles have sent the flow of 6000bytes altogether, and on average each cycle sends 1500bytes.
Though the design bandwidth ratio is by artificial or alternate manner is given, it can be expressed as the ratio that within the one-period queue length of each queue scheduling accounts for the formation total length of all queue schedulings, that is:
W wherein
iBe the theoretical weights of individual queue.If individual queue disposes this theory weights, just can guarantee the allocated bandwidth ratio of individual queue very exactly.Because the theoretical weighting parameter of individual queue must satisfy formula (1), wherein α
i, i=1......, n and MTU are known parameters, therefore, formula (1) can be used to calculate the theoretical weight w of individual queue conversely
i, i=1 ..., n, this group of equations is as follows:
Wherein,
When finding the solution this equation group, there is following relation between the theoretical weights of individual queue:
Formula (2) shows, if individual queue will accurately be distributed bandwidth, in theory, the weights of individual queue must satisfy formula (2).Therefore, first key of the present invention is to seek the theoretical weights of the individual queue that satisfies formula (2).
As a rule, theoretical weight w
iInteger not necessarily, and prior network device requires these parameters all to adopt integer.Therefore, be necessary theoretical weight w
iRound, promptly suitably revise.Revised theoretical weighting parameter is
, be configured to the network equipment port formation as actual parameter.Weights round-off error δ
iRepresent this theory weight w
iWith the actual disposition weights
Difference promptly
。Support of the present invention rounds up, rounds downwards and correcting mode such as round, and the different modes of rounding causes different round-off error δ
iWhen employing rounds up, round-off error δ
iSpan be [0,1), adopt when rounding round-off error δ downwards
iSpan be (1,0], when adopting round, round-off error δ
iSpan be (0.5,0.5).
Be formation configuration and correction weights
After, round-off error δ
iCan be brought in the flow scheduling of individual queue, and cause the error of allocated bandwidth.This error can be used following formulate:
Through simple computation, and consider the allocated bandwidth required precision of individual queue, below formula must set up:
Formula (3) has determined to whether reaching the allocated bandwidth required precision between the bandwidth of individual queue actual allocated and the design bandwidth.If reach required precision, existing weights
Can be used as configuration parameter uses; Otherwise, need to recomputate the weights of individual queue and revise the operation of recurring formula (3) according to formula (2) again.This process circulation is carried out, up to finding the formation weights that meet the demands.
Therefore, second key point of the present invention is to check between the actual allocated bandwidth of individual queue and the design bandwidth whether satisfy required precision.
In a word, the algorithmic procedure of present embodiment can be summarized as follows: the theoretical weights that at first calculate individual queue; Next judges whether the bandwidth of individual queue actual allocated and the error between the design bandwidth reach required precision.If reach requirement, finish algorithm; Otherwise, recomputate weights, i.e. the operation of front is carried out in circulation, up to finding the parameter that meets the demands.
If the present invention is used to implement the band width configuration of required precision.At first need to determine the design bandwidth or the bandwidth ratio of individual queue.The design bandwidth ratio is the part of operator's resource allocation policy, can be determined by the SLA agreement by operator and client, and perhaps collect the historical information of different queue by the network monitor instrument, prediction is the bandwidth ratio of the different flow of a period of time in the future.Implement the time of the present invention concrete, algorithm of the present invention is carried out by the weights calculator in the network equipment of the webserver of Fig. 3 A and Fig. 3 B respectively.
If adopt the Implementation Modes of the webserver of Fig. 3 A, the webserver is safeguarded the bandwidth Design ratio and the band width configuration precision equiband allocation strategy information of all-network device port formation, and increase, deletion are provided or revise the interface of bandwidth allocation strategy information, and call the weights calculator and calculate weighting parameter, support maintenance personnel or administrative staff's operation.Adopt the Implementation Modes of the webserver can guarantee that attendant or O﹠M system formulate the allocated bandwidth strategy of each network equipment port formation from the angle of the whole network.
If the distributed allocated bandwidth strategy of employing Fig. 3 B, the network equipment lacks the visual angle of the whole network, can only keep the allocated bandwidth strategy of the own port queue of equipment, calculates the formation weights, according to the weights and the execution flow scheduling of configuration.Comparatively speaking, the network equipment only need be safeguarded less information, and amount of calculation is less.
In a second embodiment, the scheduling mechanism at the low time delay formation of strict preference-LLQ formation carries out weights calculating in weights calculating of the present invention and choice device.It below is detailed description to first embodiment.
In the scheduling mechanism of band LLQ formation, if there is grouping to need to send in the LLQ formation, wait for that at most other formation sends the grouping that is sending, LLQ just can send grouping.If the LLQ formation is grouping not, other formation can begin to send grouping.In prior network device, the device bandwidth that LLQ can take can dispose the upper limit.Therefore, in the present embodiment, can do following hypothesis:
Total formation n+1 of this port, LLQ is one of them formation, at first obtains the bandwidth resources that need; The bandwidth resources ratio that LLQ takies is α
i, maximum can reach α
Max
Other sequence number is 1 ..., the formation of n is according to the pro rate remaining bandwidth resource of design, and the actual bandwidth ratio that obtains of individual queue is respectively α
i, and
Weights do not influence the LLQ occupied bandwidth, and the queue length that other formation sends in once dispatching is D=MTU+512 * (w
i-1).
Definition
Being used to describe sequence number is 1 ..., the ratio of the remaining bandwidth of each formation after LLQ takies of n.
。Calculate according to the computational methods of introducing previously:
At first, according to method selection reference weight w of the present invention
bWith reference bandwidth ratio α
b', α wherein
b' be the minimum value among the α, i=1 ..., n.
Secondly, calculate other formation weights according to following formula:
α wherein
bBe weighting parameter α
iIn minimum value, and and α
b' same formation described.If w
iBe not integer, according to method identical among first embodiment to w
iRound.The formation weights of actual disposition adopt the weighting parameter after rounding
At last, the bandwidth accuracy of estimation individual queue distribution:
If formula (5) is all set up each formation, i.e. i=1 ..., above-mentioned formula is all set up during n, finishes to calculate, and the weights of this moment are institute and ask; If formula (5) is false, upgrade the benchmark weight w again
b, the principle of renewal is to increase w
bValue, promptly add 1 or increase other natural number, and the calculating of recurring formula (4) and (5), up to finding the weights that need.
In the 3rd embodiment, consider that weighting parameter minimizes, promptly guarantee to satisfy the weights minimum of all conditions at all.It below is detailed description to the 3rd embodiment.
The purpose that minimizes the formation weights is the delay variation that reduces the individual queue flow.
According to analysis, need only selection reference weighting parameter w in the present embodiment
b=1, the result of calculation of formula (4) is exactly minimized weights.
The present invention has carried out repeatedly implementing test, the result of the test goal of the invention that has been successful realization, and therefore, the present invention has good application prospects.