CN104468147B - A kind of load-balancing method and device - Google Patents
A kind of load-balancing method and device Download PDFInfo
- Publication number
- CN104468147B CN104468147B CN201410764800.0A CN201410764800A CN104468147B CN 104468147 B CN104468147 B CN 104468147B CN 201410764800 A CN201410764800 A CN 201410764800A CN 104468147 B CN104468147 B CN 104468147B
- Authority
- CN
- China
- Prior art keywords
- multicast group
- group set
- mapping
- multicast
- flow
- 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.)
- Expired - Fee Related
Links
Abstract
The embodiment of the present invention, which provides a kind of load-balancing method and device, method, to be included:Obtain the first mapping and the second mapping, first mapping is for the correspondence between the first RP of expression and the first multicast group set, for representing the correspondence between the 2nd RP and the second multicast group set, the first multicast group set and the second multicast group set include different multicast groups for second mapping;The multicast group that the multicast group and the second multicast group set include to the first multicast group set includes, is grouped again, obtains the 3rd multicast group set and the 4th multicast group set;Utilize the 3rd multicast group set and the 4th multicast group set, generate the 3rd mapping and the 4th mapping, for representing the correspondence between the first RP and the 3rd multicast group set, the 4th mapping is used to represent the correspondence between the 2nd RP and the 4th multicast group set for 3rd mapping;Broadcast the 3rd mapping and the 4th mapping.The RP of overload can be so avoided the occurrence of, helps to improve the message forward efficiency of RP.
Description
Technical field
The present invention relates to fields of communication technology, and in particular to a kind of load-balancing method and device.
Background technology
In general, in catenet and the more scattered scene of user distribution, using sparse mode Protocol Independent Multicast
(English:Protocol Independent Multicast-Sparse Mode, referred to as:PIM-SM point-to-multipoint report) is carried out
Text transmission.
Based on PIM-SM, when having message transmissions demand, multicast member can be to convergent point (English:Rendezvous Point,
Referred to as:RP) initiate to add in request, (*, G) list item is created on RP, build the shared tree (English using RP as root:Rendezvous
Point Tree, referred to as:RPT).Wherein, * is default parameter, and G is the multicast address of multicast group, and (*, G) represents multicast address mark
The multicast group of knowledge can receive the message that any multicast source is sent.Accordingly, multicast source can initiate registration request to RP, on RP
Create (S, G) list item.Wherein, S is the address of multicast source, and (S, G) represents the multicast group that multicast source can be identified to multicast address
Send message.So treated, when carrying out cast communication, message can be sent to RP by multicast source, and by RP by the report
Text is handed down to the multicast member of multicast group.
In general, there may be multiple RP in network, each RP may be root of multiple multicast groups on RPT again, if RP
It breaks down or the reasons such as heavier loads of RP carryings, may influence the message forward efficiency of RP, and then influence multicast
Communication efficiency.
The content of the invention
Load-balancing method and device provided in an embodiment of the present invention help to lead to by load-balancing technique raising multicast
Believe efficiency.
For this purpose, the embodiment of the present invention provides following technical solution:
In a first aspect, a kind of load-balancing method is provided, the described method includes:
Controller obtains the first mapping and the second mapping, and described first maps to represent the first convergent point RP and first group
The correspondence between group set is broadcast, second mapping is for the corresponding pass between the 2nd RP of expression and the second multicast group set
System, the first multicast group set and the second multicast group set include different multicast groups;
What the multicast group and the second multicast group set that the controller includes the first multicast group set included
Multicast group is grouped again, obtains the 3rd multicast group set and the 4th multicast group set;
The controller utilizes the 3rd multicast group set and the 4th multicast group set, the 3rd mapping of generation and the
Four mappings, correspondence of the 3rd mapping for representing between the first RP and the 3rd multicast group set are described
4th maps to represent the correspondence between the 2nd RP and the 4th multicast group set;
Controller broadcast the 3rd mapping and the described 4th mapping.
With reference to first aspect, in the first possible realization method of first aspect, the controller is to described first
The multicast group that the multicast group and the second multicast group set that multicast group set includes include, is grouped again, obtains the 3rd
Multicast group set and the 4th multicast group set include:
The controller obtains the first number and the second number, and first number includes for the first multicast group set
Multicast group number, the number for the multicast group that second number includes for the second multicast group set;
The controller utilizes first number and second number, the group that the first multicast group set is included
Broadcast group and the multicast group that includes of the second multicast group set, balance is grouped into the 3rd multicast group set and 4th group described
Broadcast a group set.
With reference to first aspect, in second of possible realization method of first aspect, the first multicast group set is also
Including the corresponding flow information of each multicast group, the second multicast group set further includes the corresponding flow letter of each multicast group
Breath, the multicast that the multicast group and the second multicast group set that the controller includes the first multicast group set include
Group is grouped again, and obtaining the 3rd multicast group set and the 4th multicast group set includes:
The controller obtains first flow and second flow, and the first flow includes for the first multicast group set
The sum of the flow of multicast group, the sum of flow of multicast group that the second flow includes for the second multicast group set;
The controller utilizes the first flow and the second flow, the group that the first multicast group set is included
Broadcast group and the multicast group that includes of the second multicast group set, balance is grouped into the 3rd multicast group set and 4th group described
Broadcast a group set.
With reference to first aspect, in the third possible realization method of first aspect, the controller is to described first
The multicast group that the multicast group and the second multicast group set that multicast group set includes include, is grouped again, obtains the 3rd
Multicast group set and the 4th multicast group set include:
The controller determines to whether there is failure RP in the first RP and the 2nd RP;
If it is determined that the first RP is failure RP, the multicast group that the controller includes the first multicast group set
The multicast group included with the second multicast group set is grouped into the 4th multicast group set, the 3rd multicast group set
For empty set;
If it is determined that the 2nd RP is failure RP, the multicast group that the controller includes the first multicast group set
The multicast group included with the second multicast group set is grouped into the 3rd multicast group set, the 4th multicast group set
For empty set.
With reference to first aspect or first aspect the first to the third any possible realization method, in first aspect
The 4th kind of possible realization method in, the method further includes:
When the described first mapping and/or second mapping change, controller update the 3rd mapping
And/or the 4th mapping.
Second aspect, provides a kind of load balancing apparatus, and described device includes:
Obtaining unit, for obtaining the first mapping and the second mapping, described first maps to represent the first convergent point RP
With the correspondence between the first multicast group set, second mapping is between the 2nd RP of expression and the second multicast group set
Correspondence, the first multicast group set and the second multicast group set include different multicast groups;
Grouped element, multicast group and the second multicast group set for including to the first multicast group set include
Multicast group, be grouped again, obtain the 3rd multicast group set and the 4th multicast group set;
Generation unit, for utilizing the 3rd multicast group set and the 4th multicast group set, the 3rd mapping of generation
The correspondence for representing between the first RP and the 3rd multicast group set is mapped with the 4th mapping, the described 3rd,
Correspondence of 4th mapping for representing between the 2nd RP and the 4th multicast group set;
Radio unit, for broadcasting the 3rd mapping and the described 4th mapping.
With reference to second aspect, in the first possible realization method of second aspect, the grouped element includes:
Number obtaining unit, for obtaining the first number and the second number, first number is first multicast group
Gather the number of the multicast group included, the number for the multicast group that second number includes for the second multicast group set;
First grouping subelement, for utilizing first number and second number, by the first multicast group collection
Close the multicast group that the multicast group that includes and the second multicast group set include, balance be grouped into the 3rd multicast group set and
The 4th multicast group set.
With reference to second aspect, in second of possible realization method of second aspect, the first multicast group set is also
Including the corresponding flow information of each multicast group, the second multicast group set further includes the corresponding flow letter of each multicast group
Breath, the grouped element include:
Flow obtaining unit, for obtaining first flow and second flow, the first flow is first multicast group
Gather the sum of flow of multicast group included, the flow for the multicast group that the second flow includes for the second multicast group set
The sum of;
Second packet subelement, for utilizing the first flow and the second flow, by the first multicast group collection
Close the multicast group that the multicast group that includes and the second multicast group set include, balance be grouped into the 3rd multicast group set and
The 4th multicast group set.
With reference to second aspect, in the third possible realization method of second aspect, the grouped element includes:
Determination unit, for determining to whether there is failure RP in the first RP and the 2nd RP;
3rd grouping subelement, for the determination unit determine the first RP be failure RP when, by described first
The multicast group that the multicast group and the second multicast group set that multicast group set includes include, is grouped into the 4th multicast group collection
It closes, the 3rd multicast group collection is combined into empty set;
4th grouping subelement, for the determination unit determine the 2nd RP be failure RP when, by described first
The multicast group that the multicast group and the second multicast group set that multicast group set includes include, is grouped into the 3rd multicast group collection
It closes, the 4th multicast group collection is combined into empty set.
With reference to the first of second aspect or second aspect to the third any possible realization method, in second aspect
The 4th kind of possible realization method in, described device further includes:
Updating block, for when the described first mapping and/or second mapping change, update the described 3rd to be reflected
It penetrates and/or the described 4th maps.
The third aspect, provides a kind of load-balancing device, and the equipment includes:Processor and memory;
The memory, for storing program instruction and data;
The processor for reading the program instruction stored in the memory and data, performs following operation:
The processor obtains the first mapping and the second mapping, and first mapping is for representing the first convergent point RP and the
Correspondence between one multicast group set, second mapping is for pair between the 2nd RP of expression and the second multicast group set
It should be related to, the first multicast group set and the second multicast group set include different multicast groups;
What the multicast group and the second multicast group set that the processor includes the first multicast group set included
Multicast group is grouped again, obtains the 3rd multicast group set and the 4th multicast group set;
The processor utilizes the 3rd multicast group set and the 4th multicast group set, the 3rd mapping of generation and the
Four mappings, correspondence of the 3rd mapping for representing between the first RP and the 3rd multicast group set are described
4th maps to represent the correspondence between the 2nd RP and the 4th multicast group set;
Processor broadcast the 3rd mapping and the described 4th mapping.
With reference to the third aspect, in the first possible realization method of the third aspect, the processor is to described first
The multicast group that the multicast group and the second multicast group set that multicast group set includes include, is grouped again, obtains the 3rd
Multicast group set and the 4th multicast group set include:
The processor obtains the first number and the second number, and first number includes for the first multicast group set
Multicast group number, the number for the multicast group that second number includes for the second multicast group set;
The processor utilizes first number and second number, the group that the first multicast group set is included
Broadcast group and the multicast group that includes of the second multicast group set, balance is grouped into the 3rd multicast group set and 4th group described
Broadcast a group set.
With reference to the third aspect, in second of possible realization method of the third aspect, the first multicast group set is also
Including the corresponding flow information of each multicast group, the second multicast group set further includes the corresponding flow letter of each multicast group
Breath, the multicast that the multicast group and the second multicast group set that the processor includes the first multicast group set include
Group is grouped again, and obtaining the 3rd multicast group set and the 4th multicast group set includes:
The processor obtains first flow and second flow, and the first flow includes for the first multicast group set
The sum of the flow of multicast group, the sum of flow of multicast group that the second flow includes for the second multicast group set;
The processor utilizes the first flow and the second flow, the group that the first multicast group set is included
Broadcast group and the multicast group that includes of the second multicast group set, balance is grouped into the 3rd multicast group set and 4th group described
Broadcast a group set.
With reference to the third aspect, in the third possible realization method of the third aspect, the processor is to described first
The multicast group that the multicast group and the second multicast group set that multicast group set includes include, is grouped again, obtains the 3rd
Multicast group set and the 4th multicast group set include:
The processor determines to whether there is failure RP in the first RP and the 2nd RP;
If it is determined that the first RP is failure RP, the multicast group that the processor includes the first multicast group set
The multicast group included with the second multicast group set is grouped into the 4th multicast group set, the 3rd multicast group set
For empty set;
If it is determined that the 2nd RP is failure RP, the multicast group that the processor includes the first multicast group set
The multicast group included with the second multicast group set is grouped into the 3rd multicast group set, the 4th multicast group set
For empty set.
With reference to the first of the third aspect or the third aspect to the third any possible realization method, in the third aspect
The 4th kind of possible realization method in, the processor also performs following operation:
When the described first mapping and/or second mapping change, the 3rd mapping described in the update processor
And/or the 4th mapping.
The load-balancing method and device of the embodiment of the present invention, controller obtain the corresponding first multicast group set of the first RP
The second multicast group set corresponding with the 2nd RP, and the multicast group included to the first multicast group set and the second multicast group set bag
The multicast group included, is grouped again, is obtained the 3rd multicast group set and the 4th multicast group set, is resettled the first RP and the 3rd
The 3rd mapping between multicast group set and the 4th mapping between the 2nd RP and the 4th multicast group set, finally will be updated
3rd mapping and the 4th mapping broadcast make the multicast group in network according to the updated 3rd mapping and the 4th mapping into network
Build RPT.In this way, the RP of overload can be avoided the occurrence of, the message forward efficiency of RP is helped to improve, and then improves multicast
The efficiency of communication.
Description of the drawings
It in order to illustrate the technical solutions in the embodiments of the present application or in the prior art more clearly, below will be to embodiment or existing
There is attached drawing needed in technology description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this
Some embodiments described in application for those of ordinary skill in the art, can also be obtained according to these attached drawings other
Attached drawing.
Fig. 1 is the flow chart of load-balancing method of the embodiment of the present invention;
Fig. 2 is a kind of network diagram in the embodiment of the present invention;
Fig. 3 is the schematic diagram of load balancing apparatus of the embodiment of the present invention;
Fig. 4 is that the hardware of load-balancing device of the embodiment of the present invention forms schematic diagram.
Specific embodiment
In order to which those skilled in the art is made to more fully understand the present invention program, below in conjunction with the accompanying drawings with embodiment to this
Inventive embodiments are described in further detail.
The controller that load balancing is used in the embodiment of the present invention can be an independent equipment;Alternatively, controller
Can be the BootStrap Router (English for being integrated with controller function:Bootstrap Router, referred to as:BSR);Furthermore it controls
Device can also be the common multiple devices for realizing controller function, i.e. the function of controller is split on the multiple devices,
The function of controller is realized by distributed way.The embodiment of the present invention does not do specifically the existence form of controller in a network
It limits.
Referring to Fig. 1, the load-balancing method of the embodiment of the present invention is shown, it may include:
101, controller obtains the first mapping and the second mapping, and first mapping is for representing the first convergent point RP and the
Correspondence between one multicast group set, second mapping is for pair between the 2nd RP of expression and the second multicast group set
It should be related to, the first multicast group set and the second multicast group set include different multicast groups.
For example, the mapping in the embodiment of the present invention can be understood as the correspondence between RP and multicast group, pass through
The mapping, belonging to the multicast member of the multicast group can ask to add in the RP, create the RPT using the RP as root, so as to
The use when subsequently carrying out cast communication.
By taking the first mapping as an example, first mapping can be at least obtained in the following manner:
Mode one, the mode manually configured are established the correspondence between the first RP and the first multicast group set, are obtained
Obtain the first mapping.
Mode two passes through the Hash (English specified in PIM-SM agreements:Hash) algorithm establishes the first RP and the first multicast
Correspondence between group set obtains the first mapping.In general, multicast group can utilize formula Value (G, M, C (i))=
(1103515245* ((1103515245* (G&M)+12345) XOR C (i))+12345) mod 2^31, determine that this multicast group is reflected
The RP penetrated, wherein, G represents the multicast address of multicast group, and M represents Hash masks, and C (i) represents the address of RP.For example, group
The RP of Value values maximum can be determined as the RP of this multicast group mapping by broadcasting group;Alternatively, if there are at least two Value values are identical
RP when, multicast group the RP of C (i) maximums can be determined as this multicast group mapping RP.For example, in the embodiment of the present invention
First multicast group set refers to the multicast group of all RP that first RP is determined as to the mapping of this multicast group.
The mode of the second mapping is obtained, can refer to the mode for obtaining the first mapping above, details are not described herein again.
For example, controller periodically can obtain the first mapping and from second according to predetermined period from the first RP
RP obtains the second mapping.Alternatively, controller periodically can obtain the first mapping and second from BSR and reflect according to predetermined period
It penetrates, wherein, BSR can collect the first mapping and the second mapping after PIM-SM network startups from network.Alternatively, controller
When the first mapping changes the first mapping can be obtained from the first RP or BSR.Alternatively, controller can be in the second mapping
When changing, the second mapping is obtained from the 2nd RP or BSR.The embodiment of the present invention obtains controller the first mapping and second and reflects
The mode penetrated can be not specifically limited.
By taking network shown in Fig. 2 as an example, the first mapping expression of controller acquisition is corresponding between RP1 and multicast group G1
Relation, i.e. the first RP is RP1, and the first multicast group set includes multicast group G1;Controller obtain second mapping represent be
Correspondence between RP2 and multicast group G2, G3, G4, i.e. the 2nd RP be RP2, the second multicast group set include multicast group G2,
G3 and G4.
102, the multicast group and the second multicast group set bag that the controller includes the first multicast group set
The multicast group included, is grouped again, obtains the 3rd multicast group set and the 4th multicast group set.
103, the controller utilizes the 3rd multicast group set and the 4th multicast group set, the 3rd mapping of generation
The correspondence for representing between the first RP and the 3rd multicast group set is mapped with the 4th mapping, the described 3rd,
Correspondence of 4th mapping for representing between the 2nd RP and the 4th multicast group set.
104, controller broadcast the 3rd mapping is mapped with the described 4th.
After controller obtains the first mapping and the second mapping, it can determine whether to need to carry out load balance process,
If it is required, then obtain the 3rd multicast group set and the 4th multicast group set, and establish the first RP and the 3rd multicast group set it
Between the 3rd mapping and the 4th mapping between the 2nd RP and the 4th multicast group set, then by the 3rd mapping and the 4th reflect
Broadcast is penetrated into network, the equipment in the network is made to know updated mapping, and RPT is built using updated mapping.
By taking network shown in Fig. 2 as an example, for example, the 3rd multicast group set includes multicast group G1 and G2, and the 4th multicast group set includes
Multicast group G3 and G4, i.e. what the 3rd mapping represented is the correspondence between RP1 and multicast group G1 and G2, and the 4th mapping represents
Be correspondence between RP2 and multicast group G3 and G4.
For example, if before the mapping of controller broadcast is received, each multicast group does not add in RPT, then this hair
In bright embodiment, RPT, Ke Yiwei are built using updated mapping:The multicast member of G1 and the multicast member of G2 are initiated to RP1
Request is added in, adds in the PRT1 using RP1 as root;The multicast member of G3 and the multicast member of G4 initiate to add in request to RP2, add in
Using RP2 as the PRT2 of root.
For example, if before the mapping of controller broadcast is received, each multicast group has added in corresponding
Then in the embodiment of the present invention, RPT, Ke Yiwei are built using updated mapping by RPT:The multicast member of G2 initiates to add in RP1
Request, adds in the PRT1 using RP1 as root;Meanwhile the multicast member of G2 also initiates beta pruning (English to RP2:Prune) ask, from
It is exited in using RP2 as the PRT2 of root.
For example, if before the mapping of controller broadcast is received, partaof group has added in corresponding RPT,
And partaof group does not add in RPT, then can refer to introduction made above, by adding in request, beta pruning is asked, and is realized and is utilized update
The purpose of mapping structure RPT afterwards, no longer illustrates herein.
To sum up, the embodiment of the present invention can adjust the load that RP is carried in network, avoided the occurrence of negative by load-balancing technique
Overweight RP is carried, the message forward efficiency of RP is helped to improve, and then improves the efficiency of cast communication.
For example, the load in the embodiment of the present invention can be the number of the multicast group of RP carryings, corresponding to this, the
During the number imbalance of the multicast group of one RP and the 2nd RP carryings, controller can determine currently to need to carry out at load balancing
Reason.For example, the number of the multicast group of the first RP and the 2nd RP carryings is uneven, Ke Yiwei:The multicast group of first RP carryings
Number and the 2nd RP carrying multicast group number difference, be more than the first preset value.For example, the first preset value can be with
For 1, as described above for Fig. 2 examples cited, the multicast group number of RP1 carryings be that the multicast group number that 1, RP2 is carried is 3, the two
Difference be more than the first preset value 1, therefore controller determines currently to need to carry out load balance process.
Specifically, load balancing process can be presented as:Controller first number of acquisition and the second number, described first
The number for the multicast group that number includes for the first multicast group set, second number are the second multicast group set bag
The number of the multicast group included;The controller utilizes first number and second number, by the first multicast group collection
Close the multicast group that the multicast group that includes and the second multicast group set include, balance be grouped into the 3rd multicast group set and
The 4th multicast group set.
Controller by adjusting the RP multicast groups carried number, realize the first RP and the 2nd RP between balance, in this way,
The RP of overload can be avoided the occurrence of, helps to improve the message forward efficiency of RP.For example, controller is held using RP1
The multicast group number 3 of multicast group number 1 and the RP2 carrying of load, adjusts the grouping of G1, G2, G3 and G4, G1 and G2 is adjusted to one
A multicast group set obtains the 3rd multicast group set;G3 and G4 are adjusted to a multicast group set, obtain the 4th multicast group collection
It closes.At this point, the difference for the multicast group number that multicast group number and the 4th multicast group set that the 3rd multicast group set includes include, not
More than the first preset value, i.e. the multicast group number of the first RP and the 2nd RP carryings has reached balance.
For example, the load in the embodiment of the present invention can be the message flow of RP carryings, corresponding to this, in the first RP
During the message flow imbalance carried with the 2nd RP, controller can determine currently to need to carry out load balance process.Citing comes
It says, the message flow of the first RP and the 2nd RP carryings is uneven, Ke Yiwei:The message flow and the 2nd RP of first RP carryings carry
Message flow difference, be more than the second preset value.For example, the second preset value can be 30kbps, as described above for Fig. 2
Examples cited, the message flow of RP1 carryings is 50kbps, wherein, the corresponding flow information W1=50kbps of multicast group G1;RP2
The message flow of carrying is (20+30+40)=90kbps, wherein, the corresponding flow information W2=20kbps of multicast group G2, multicast
Group G3 corresponding flow information W3=30kbps, the corresponding flow information W4=40kbps of multicast group G4;The message flow of RP1 carryings
The difference 40kbps of the message flow 90kbps of 50kbps and RP2 carryings is measured, has been more than the second preset value 30kbps, therefore controller is true
It needs to carry out load balance process before settled.
For example, flow information can be carried in the first multicast set and the second multicast set, i.e. described first group
Broadcasting a group set includes at least one multicast group and the corresponding flow information of each multicast group;The second multicast group set bag
Include at least one multicast group and the corresponding flow information of each multicast group.
Specifically, load balancing process can be presented as:The controller acquisition first flow and second flow, described first
The sum of flow of multicast group that flow includes for the first multicast group set, the second flow are the second multicast group collection
Close the sum of flow of multicast group included;The controller utilizes the first flow and the second flow, by described first
The multicast group that the multicast group and the second multicast group set that multicast group set includes include, balance are grouped into the 3rd multicast
Group set and the 4th multicast group set.
The message flow that controller carries by adjusting RP realizes the balance between the first RP and the 2nd RP, in this way,
The RP of overload is avoided the occurrence of, helps to improve the message forward efficiency of RP.For example, based on the corresponding stream of each multicast group
Amount information, the message flow 90kbps that the message flow 50kbps and RP2 that controller can utilize RP1 to carry are carried, adjustment G1,
G1 and G2 are adjusted to a multicast group set, obtain the 3rd multicast group set by the grouping of G2, G3 and G4;G3 and G4 is adjusted
To a multicast group set, the 4th multicast group set is obtained.At this point, the corresponding message flow (50+20) of the 3rd multicast group set
The difference 0kbps of=70kbps and corresponding message flow (the 30+40)=70kbps of the 4th multicast group set, it is default not less than second
Value, i.e. the message flow of the first RP and the 2nd RP carryings has reached balance.
In examples cited above, the multicast group number and message flow of RP carryings have reached balance, for example, base
In the scheme for carrying out load balancing in message flow, it is also possible to which there are situations below:The message flow of RP1 carryings is 10kbps,
Wherein, the corresponding flow information W1=10kbps of multicast group G1;The message flow of RP2 carryings is (20+20+40)=80kbps,
Wherein, the corresponding flow information W3=20kbps of the corresponding flow information W2=20kbps of multicast group G2, multicast group G3, multicast group
The corresponding flow information W4=40kbps of G4.Controller is carried out after being grouped again, and G1, G2 and G3 are adjusted to the 3rd multicast group collection
It closes, G4 is adjusted to the 4th multicast group set.At this point, the corresponding message flow (10+20+20) of the 3rd multicast group set=
The difference 10kbps of 50kbps and the corresponding message flow 40kbps of the 4th multicast group set, not less than the second preset value, i.e. first
The message flow of RP and the 2nd RP carryings has reached balance.
Optionally, it is contemplated that RP failures may influence the message forward efficiency of RP, the embodiment of the present invention additionally provide as
Lower load balancing scheme:The controller determines to whether there is failure RP in the first RP and the 2nd RP;If it is determined that
First RP is failure RP, the multicast group and second multicast group that the controller includes the first multicast group set
Gather the multicast group included, be grouped into the 4th multicast group set, the 3rd multicast group collection is combined into empty set;If it is determined that institute
The 2nd RP is stated as failure RP, the multicast group and the second multicast group collection that the controller includes the first multicast group set
The multicast group included is closed, is grouped into the 3rd multicast group set, the 4th multicast group collection is combined into empty set.
Controller is using mode described above, by multicast group number or message flow, before re-starting grouping,
It can first determine that, if one of RP is failure RP, controller can be by failure with the presence or absence of failure RP in the first RP and the 2nd RP
The corresponding multicast groups of RP are migrated to non-faulting RP.As described above for Fig. 2 examples cited, if RP1 is failure RP, controller can incite somebody to action
G1, G2, G3 and G4 are adjusted to a multicast group set, obtain the 4th multicast group set, accordingly, the 3rd multicast group collection is combined into sky
Collection.If RP2 is failure RP, G1, G2, G3 and G4 can be adjusted to a multicast group set by controller, obtain the 3rd multicast group
Set, accordingly, the 4th multicast group collection is combined into empty set.Such load balancing scheme, so that it may when RP breaks down, pass through multicast
The mode of group migration, ensures the normal forwarding of message.
For example, controller can at least obtain the state of RP in the following manner:Receive the work for this RP that each RP is reported
Make state, alternatively, receiving the working condition for each RP that BSR is reported, the embodiment of the present invention can be not specifically limited this.Citing comes
It says, the working condition of RP can be normal or failure.
Optionally, can lead to if there is no failure RP, controller in the first RP and the 2nd RP according to mode described above
Multicast group number or message flow are crossed, re-starts grouping.
For example, a kind of realization method as the embodiment of the present invention, the first multicast group set can be empty set or the
Two multicast groups can be empty set, corresponding to this, if controller determines that the first RP and the 2nd RP is normal RP, can still be situated between according to above
The mode to continue by multicast group number or message flow, re-starts grouping, obtains the 3rd multicast group set and the 4th multicast
Group set.It is to be appreciated that this realization method, is that the fractional load of a RP carrying is moved to another free time RP, in this way,
Also the message forward efficiency of RP is helped to improve, and then improves the efficiency of cast communication.
Optionally, based on embodiment illustrated in fig. 1, the embodiment of the present invention also provides a kind of scheme of load balancing, is specially:
When the described first mapping and/or second mapping change, controller update the 3rd mapping and/or described
4th mapping.For example, if the first mapping changes, first after controller can utilize the second mapping and change reflects
It penetrates, re-starts grouping, obtain updated 3rd mapping and/or the 4th mapping.If alternatively, second mapping change,
Controller can utilize the second mapping after the first mapping and variation, re-start grouping, obtain updated 3rd mapping with/
Or the 4th mapping.Alternatively, if the first mapping and the second mapping change, controller can utilize the first mapping after variation
The second mapping with after variation, re-starts grouping, obtains updated 3rd mapping and/or the 4th mapping.Specific grouping side
Formula can refer to introduction made above, no longer illustrate herein.
Accordingly, the embodiment of the present invention additionally provides a kind of load balancing apparatus, and the load balancing apparatus can be arranged on BSR
On, alternatively, the load balancing apparatus may also be disposed on an autonomous device, no longer illustrate one by one herein.It is described negative
It carries balancer and can perform the method that the corresponding embodiments of Fig. 1 provide.Schematic diagram shown in Figure 3, described device may include:
Obtaining unit 201, for obtaining the first mapping and the second mapping, described first maps to represent the first convergent point
Correspondence between RP and the first multicast group set, second mapping for represent the 2nd RP and the second multicast group set it
Between correspondence, the first multicast group set and the second multicast group set include different multicast groups;
Grouped element 202, for the multicast group included to the first multicast group set and the second multicast group set
Including multicast group, be grouped again, obtain the 3rd multicast group set and the 4th multicast group set;
Generation unit 203, for utilizing the 3rd multicast group set and the 4th multicast group set, generation the 3rd is reflected
It penetrates and maps to represent the corresponding pass between the first RP and the 3rd multicast group set with the 4th mapping, the described 3rd
System, correspondence of the 4th mapping for representing between the 2nd RP and the 4th multicast group set;
Radio unit 204, for broadcasting the 3rd mapping and the described 4th mapping.
To sum up, the load balancing apparatus of the embodiment of the present invention, using load-balancing technique, RP is carried negative in adjustment network
It carries, avoids the occurrence of the RP of overload, help to improve the message forward efficiency of RP, and then improve the efficiency of cast communication.
Optionally, the grouped element includes:
Number obtaining unit, for obtaining the first number and the second number, first number is first multicast group
Gather the number of the multicast group included, the number for the multicast group that second number includes for the second multicast group set;
First grouping subelement, for utilizing first number and second number, by the first multicast group collection
Close the multicast group that the multicast group that includes and the second multicast group set include, balance be grouped into the 3rd multicast group set and
The 4th multicast group set.
Optionally, the first multicast group set further includes the corresponding flow information of each multicast group, second multicast
Group set further includes the corresponding flow information of each multicast group, and the grouped element includes:
Flow obtaining unit, for obtaining first flow and second flow, the first flow is first multicast group
Gather the sum of flow of multicast group included, the flow for the multicast group that the second flow includes for the second multicast group set
The sum of;
Second packet subelement, for utilizing the first flow and the second flow, by the first multicast group collection
Close the multicast group that the multicast group that includes and the second multicast group set include, balance be grouped into the 3rd multicast group set and
The 4th multicast group set.
Optionally, the grouped element includes:
Determination unit, for determining to whether there is failure RP in the first RP and the 2nd RP;
3rd grouping subelement, for the determination unit determine the first RP be failure RP when, by described first
The multicast group that the multicast group and the second multicast group set that multicast group set includes include, is grouped into the 4th multicast group collection
It closes, the 3rd multicast group collection is combined into empty set;
4th grouping subelement, for the determination unit determine the 2nd RP be failure RP when, by described first
The multicast group that the multicast group and the second multicast group set that multicast group set includes include, is grouped into the 3rd multicast group collection
It closes, the 4th multicast group collection is combined into empty set.
Optionally, described device further includes:
Updating block, for when the described first mapping and/or second mapping change, update the described 3rd to be reflected
It penetrates and/or the described 4th maps.
Accordingly, the embodiment of the present invention additionally provides a kind of load-balancing device, and the load-balancing device can be arranged on BSR
On, alternatively, the load-balancing device may also be disposed on an autonomous device, no longer illustrate one by one herein.It is described negative
It carries equalizing equipment and can perform the method that the corresponding embodiments of Fig. 1 provide.Schematic diagram shown in Figure 4, the load-balancing device
300 may include:Processor 301, memory 302 and communication interface 303.Wherein, processor 301, memory 302 and communication interface
303 can be connected by communication bus 304.For storing program, processor 301 is read memory 302 according to from memory 302
Program included by executable instruction perform concrete operations.
Optionally, the obtaining unit 201 in Fig. 3, grouped element 202, generation unit 203 and radio unit 204 can be by Fig. 4
In the executable instruction that is stored according to memory 302 of processor 301 realize that processor 301 can include at least one physics
Processor.
It should be noted that load balancing apparatus shown in Fig. 3 and load-balancing device shown in Fig. 4 can be same
Device, it is believed that Fig. 3 is to show content that a load balancing apparatus includes from the angle of physics, and Fig. 4 is then from patrolling
The angle collected shows the content that a load-balancing device includes.
In load-balancing device shown in Fig. 4, the processor 301, for reading the instruction sum number stored in memory 302
According to the following operation of execution:
The processor obtains the first mapping and the second mapping, and first mapping is for representing the first convergent point RP and the
Correspondence between one multicast group set, second mapping is for pair between the 2nd RP of expression and the second multicast group set
It should be related to, the first multicast group set and the second multicast group set include different multicast groups;
What the multicast group and the second multicast group set that the processor includes the first multicast group set included
Multicast group is grouped again, obtains the 3rd multicast group set and the 4th multicast group set;
The processor utilizes the 3rd multicast group set and the 4th multicast group set, the 3rd mapping of generation and the
Four mappings, correspondence of the 3rd mapping for representing between the first RP and the 3rd multicast group set are described
4th maps to represent the correspondence between the 2nd RP and the 4th multicast group set;
Processor broadcast the 3rd mapping and the described 4th mapping.
As seen through the above description of the embodiments, those skilled in the art can be understood that above-mentioned implementation
All or part in example method can add the mode of general hardware platform to realize by software.Based on such understanding, this hair
Bright technical solution substantially in other words can be embodied the part that the prior art contributes in the form of software product,
The computer software product can be stored in storage medium, such as ROM/RAM, magnetic disc, CD, including some instructions making
Computer equipment (can be personal computer, the network communication equipments such as server or Media Gateway) performs
Method described in some parts of each embodiment of the present invention or embodiment.
It should be noted that each embodiment in this specification is described by the way of progressive, each embodiment it
Between just to refer each other for identical similar part, the highlights of each of the examples are difference from other examples.
For device and apparatus embodiments, since it is substantially similar to embodiment of the method, so describe fairly simple,
The relevent part can refer to the partial explaination of embodiments of method.Equipment and system embodiment described above is only schematic
, wherein may or may not be as the unit that separating component illustrates physically separate, shown as unit
Component may or may not be physical location, you can be located at a place or can also be distributed to multiple networks
On unit.Some or all of module therein can be selected to realize the purpose of this embodiment scheme according to the actual needs.
Those of ordinary skill in the art are without creative efforts, you can to understand and implement.
The above is only the optional embodiment of the present invention, is not intended to limit the scope of the present invention.It should refer to
Go out, for those skilled in the art, without departing from the principle of the present invention, can also make several
Improvements and modifications, these improvements and modifications also should be regarded as protection scope of the present invention.
Claims (10)
1. a kind of load-balancing method, which is characterized in that the described method includes:
Controller obtains the first mapping and the second mapping, and described first maps to represent the first convergent point RP and the first multicast group
Correspondence between set, second mapping are used to represent the correspondence between the 2nd RP and the second multicast group set,
The first multicast group set and the second multicast group set include different multicast groups;
The multicast that the multicast group and the second multicast group set that the controller includes the first multicast group set include
Group is grouped again, obtains the 3rd multicast group set and the 4th multicast group set;
The controller utilizes the 3rd multicast group set and the 4th multicast group set, and the 3rd mapping of generation and the 4th are reflected
It penetrates, correspondence of the 3rd mapping for representing between the first RP and the 3rd multicast group set, the described 4th
It maps to represent the correspondence between the 2nd RP and the 4th multicast group set;
Controller broadcast the 3rd mapping and the described 4th mapping.
2. according to the method described in claim 1, it is characterized in that, what the controller included the first multicast group set
The multicast group that multicast group and the second multicast group set include, is grouped again, obtains the 3rd multicast group set and the 4th
Multicast group set includes:
The controller obtains the first number and the second number, and first number is the group that the first multicast group set includes
Broadcast the number of group, the number for the multicast group that second number includes for the second multicast group set;
The controller utilizes first number and second number, the multicast group that the first multicast group set is included
The multicast group included with the second multicast group set, balance are grouped into the 3rd multicast group set and the 4th multicast group
Set.
3. according to the method described in claim 1, it is characterized in that, the first multicast group set further includes first multicast
The corresponding flow information of each multicast group in group set, the second multicast group set further include the second multicast group set
In the corresponding flow information of each multicast group, multicast group that the controller includes the first multicast group set and described
The multicast group that second multicast group set includes, is grouped again, obtains the 3rd multicast group set and the 4th multicast group set bag
It includes:
The controller obtains first flow and second flow, and the first flow is the group that the first multicast group set includes
Broadcast the sum of the sum of flow of group, the flow of multicast group that the second flow includes for the second multicast group set;
The controller utilizes the first flow and the second flow, the multicast group that the first multicast group set is included
The multicast group included with the second multicast group set, balance are grouped into the 3rd multicast group set and the 4th multicast group
Set.
4. according to the method described in claim 1, it is characterized in that, what the controller included the first multicast group set
The multicast group that multicast group and the second multicast group set include, is grouped again, obtains the 3rd multicast group set and the 4th
Multicast group set includes:
The controller determines to whether there is failure RP in the first RP and the 2nd RP;
If it is determined that the first RP is failure RP, multicast group and institute that the controller includes the first multicast group set
The multicast group that the second multicast group set includes is stated, is grouped into the 4th multicast group set, the 3rd multicast group collection is combined into sky
Collection;
If it is determined that the 2nd RP is failure RP, multicast group and institute that the controller includes the first multicast group set
The multicast group that the second multicast group set includes is stated, is grouped into the 3rd multicast group set, the 4th multicast group collection is combined into sky
Collection.
5. method according to any one of claims 1 to 4, which is characterized in that the method further includes:
When the described first mapping and/or second mapping change, controller update the 3rd mapping and/or
4th mapping.
6. a kind of load balancing apparatus, which is characterized in that described device includes:
Obtaining unit, for obtaining the first mapping and the second mapping, first mapping is for representing the first convergent point RP and the
Correspondence between one multicast group set, second mapping is for pair between the 2nd RP of expression and the second multicast group set
It should be related to, the first multicast group set and the second multicast group set include different multicast groups;
Grouped element, the group included for the multicast group included to the first multicast group set and the second multicast group set
Group is broadcast, is grouped again, obtains the 3rd multicast group set and the 4th multicast group set;
Generation unit, for utilizing the 3rd multicast group set and the 4th multicast group set, the 3rd mapping of generation and the
Four mappings, correspondence of the 3rd mapping for representing between the first RP and the 3rd multicast group set are described
4th maps to represent the correspondence between the 2nd RP and the 4th multicast group set;
Radio unit, for broadcasting the 3rd mapping and the described 4th mapping.
7. device according to claim 6, which is characterized in that the grouped element includes:
Number obtaining unit, for obtaining the first number and the second number, first number is the first multicast group set
Including multicast group number, the number for the multicast group that second number includes for the second multicast group set;
First grouping subelement, for utilizing first number and second number, by the first multicast group set bag
The multicast group that the multicast group and the second multicast group set included includes, balance are grouped into the 3rd multicast group set and described
4th multicast group set.
8. device according to claim 6, which is characterized in that the first multicast group set further includes first multicast
The corresponding flow information of each multicast group in group set, the second multicast group set further include the second multicast group set
In the corresponding flow information of each multicast group, the grouped element includes:
Flow obtaining unit, for obtaining first flow and second flow, the first flow is the first multicast group set
Including the sum of the flow of multicast group, the flow of the multicast group that the second flow includes for the second multicast group set it
With;
Second packet subelement, for utilizing the first flow and the second flow, by the first multicast group set bag
The multicast group that the multicast group and the second multicast group set included includes, balance are grouped into the 3rd multicast group set and described
4th multicast group set.
9. device according to claim 6, which is characterized in that the grouped element includes:
Determination unit, for determining to whether there is failure RP in the first RP and the 2nd RP;
3rd grouping subelement, for the determination unit determine the first RP be failure RP when, by first multicast
The multicast group that the multicast group and the second multicast group set that group set includes include, is grouped into the 4th multicast group set,
The 3rd multicast group collection is combined into empty set;
4th grouping subelement, for the determination unit determine the 2nd RP be failure RP when, by first multicast
The multicast group that the multicast group and the second multicast group set that group set includes include, is grouped into the 3rd multicast group set,
The 4th multicast group collection is combined into empty set.
10. according to claim 6 to 9 any one of them device, which is characterized in that described device further includes:
Updating block, for when the described first mapping and/or second mapping change, update the described 3rd to map
And/or the 4th mapping.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410764800.0A CN104468147B (en) | 2014-12-11 | 2014-12-11 | A kind of load-balancing method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410764800.0A CN104468147B (en) | 2014-12-11 | 2014-12-11 | A kind of load-balancing method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104468147A CN104468147A (en) | 2015-03-25 |
CN104468147B true CN104468147B (en) | 2018-05-18 |
Family
ID=52913576
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410764800.0A Expired - Fee Related CN104468147B (en) | 2014-12-11 | 2014-12-11 | A kind of load-balancing method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104468147B (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106161268A (en) * | 2015-03-27 | 2016-11-23 | 华为技术有限公司 | Multicast Group Assignment method, centralized control point and multicast router |
US11431635B2 (en) | 2020-03-09 | 2022-08-30 | Vmware, Inc. | Load balancing designated routers for multicast groups |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101227430A (en) * | 2008-02-19 | 2008-07-23 | 中兴通讯股份有限公司 | Multicast data forwarding method |
CN101651609A (en) * | 2008-08-14 | 2010-02-17 | 华为技术有限公司 | Method and device for realizing multicast load sharing |
WO2010139115A1 (en) * | 2009-06-03 | 2010-12-09 | 上海贝尔股份有限公司 | Method and device for multiple rendezvous points processing multicast services of mobile multicast source jointly |
CN102281204A (en) * | 2011-09-08 | 2011-12-14 | 杭州华三通信技术有限公司 | Method and routing equipment for implementing rendezvous point (RP) load sharing of multicast group and routing equipment |
CN103457776A (en) * | 2013-09-04 | 2013-12-18 | 杭州华三通信技术有限公司 | Method and device for dynamically deploying rendezvous points in two-way protocol independent multicast |
-
2014
- 2014-12-11 CN CN201410764800.0A patent/CN104468147B/en not_active Expired - Fee Related
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101227430A (en) * | 2008-02-19 | 2008-07-23 | 中兴通讯股份有限公司 | Multicast data forwarding method |
CN101651609A (en) * | 2008-08-14 | 2010-02-17 | 华为技术有限公司 | Method and device for realizing multicast load sharing |
WO2010139115A1 (en) * | 2009-06-03 | 2010-12-09 | 上海贝尔股份有限公司 | Method and device for multiple rendezvous points processing multicast services of mobile multicast source jointly |
CN102281204A (en) * | 2011-09-08 | 2011-12-14 | 杭州华三通信技术有限公司 | Method and routing equipment for implementing rendezvous point (RP) load sharing of multicast group and routing equipment |
CN103457776A (en) * | 2013-09-04 | 2013-12-18 | 杭州华三通信技术有限公司 | Method and device for dynamically deploying rendezvous points in two-way protocol independent multicast |
Also Published As
Publication number | Publication date |
---|---|
CN104468147A (en) | 2015-03-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP3355538B1 (en) | Method, apparatus and system for controlling service transmission rate | |
EP3526939B1 (en) | Virtual router with dynamic flow offload capability | |
CN106416197B (en) | For carrying out the method and system of load balancing to anycast's data service | |
CN103929368B (en) | Load balance method and device for multiple service units | |
KR20190091558A (en) | Method, apparatus, and communication system for transmitting a service flow based on flexible ethernet | |
CN110324159B (en) | Link configuration method, controller and storage medium | |
CN108809847A (en) | Realize the method, apparatus and network system of load balancing | |
CN113328936B (en) | Route control method, system, device and computer readable storage medium | |
CN113542051B (en) | Monitoring flow load balancing method based on software defined network | |
CN106130920A (en) | A kind of message forwarding method and device | |
CN105049262B (en) | Adjust the method and device of port flow load | |
CN103312607A (en) | Transmission path selection method and device | |
EP3298735A1 (en) | Method and apparatus for self-tuned adaptive routing | |
CN104468147B (en) | A kind of load-balancing method and device | |
JP6131203B2 (en) | Device selection network system, device selection server and program | |
KR20110122947A (en) | Communication method of herb and transmitting, receiving terminal included in virtual group | |
CN107231318A (en) | Switching at runtime control to providing multiple Internet services for home network | |
CA2976798C (en) | Method for dynamically adjusting packet transmission timing | |
CN109474523B (en) | Networking method and system based on SDN | |
JP5212503B2 (en) | COMMUNICATION CONTROL DEVICE, COMMUNICATION CONTROL METHOD, AND COMMUNICATION CONTROL PROGRAM | |
CN102388585A (en) | Network optimization flow control method, device and system | |
CN103368841A (en) | Message forwarding method and device thereof | |
CN105933239A (en) | Method and device for setting network flow transmission link | |
CN104734984B (en) | A kind of message forwarding method and device | |
CN108696437A (en) | A kind of flow forwarding method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20180518 Termination date: 20211211 |