With rapid development of the Internet mid continuous increase of demand for network services, there has been a significant increase of network data traffic. For example, for data centres, large-scale enterprises and portal websites, data traffic is estimated to have reached 10 GB/s which leads to the risk of server overload. Since the growth in processor speed and memory access is generally slower than that of network bandwidth and application service, servers have become a network bottleneck, especially in stand-alone network models where multiple client terminals are connected to a single server.
On the other hand, network technologies based on Internet Protocol version four (IPv4) have been a success, but the shortage of IPv4 addresses limits future development of IP-based applications. For example, although 80% of Class A network addresses, 50% of Class B network addresses and 10% of Class C network addresses had been allocated by 1996, the demand for IP addresses continues to increase rapidly as mobile and broadband technologies develop. Next-generation Internet Protocol version six (IPv6) was first proposed in the 1990s to serve as an upgrade version of IPv4. IPv6 provides almost unlimited address space, where address length is increased from 32-bit to 128-bit to provide 340 undecillion addresses and 67 quadrillion addresses per square meter of the Earth's surface.
Non-limiting example(s) will now be described with reference to the accompanying drawings, in which:
A data store 120 at the load balancing device 110 stores information associated with load balancing, such as information associated with configured IP addresses 122, a persistence table 124 and message characteristics 126; see also
A server 130 may be a web server, database server, application server, proxy server, gateway server, mail server, or file server etc. A client terminal 140 may be any suitable computing equipment, such as a desktop computer, laptop computer, tablet computer and mobile communications device etc. The network 150 may be a local area network (LAN) such as a company virtual private network (VPN), a metropolitan area network (MAN), or a wide area network (WAN) such as the Internet etc.
The load balancing device 110 provides a load balancing service to the group of servers 130. In one application, for example, the load balancing device 110 serves as a front-end virtual server to client terminals 140, which do not have any awareness of the back-end servers 130. Compared with a stand-alone network model where a single server supports multiple terminals, the load balancing model in
The load balancing device 110 provides to the client terminals 140 a virtual service address for sending service access request messages. When a service access request message is received from a client terminal 130, the load balancing device 110 selects a server from the group of servers 130, and sends the request message to the selected server 130. After processing the request message, a service access response message is sent by the selected server 130 to the load balancing device 110. The response message is then forwarded by the load balancing device 110 to the client terminal 130.
The server 130 selected by the load balancing device 110 may use an Internet Protocol (IP) address of a protocol version that is same as or different to the protocol version of the client terminal 140, such as in the following examples:
The protocol version numbers four and six each identify an addressing type of the request message. In particular, an IPv4 address such as 224.1.1.1 is a 32-bit address, whereas an IPv6 address such as 2001:0410:0:1::45ff is a 128-bit address. The term “IPv4” refers to 32-bit addressing and the term “IPv6” refers to 128-bit addressing, or any variations thereof.
If the protocol version of the selected server's IP address is different to the protocol version of the client terminal's IP address, the load balancing device 110 performs network address translation on the request message from the client terminal 140 before sending the request message to the selected server 130. After network address translation, a source IP address of the request message is a load balancing address configured on the interface 112 between the load balancing device 110 and the group of servers 130. The interface 112 may be a single interface or multiple sub-interfaces for sending messages to, and receiving messages from, the group of servers 130.
The load balancing device 110 is able to provide load balancing services to an IPv4 server group, an IPv6 server group or a mixed IPv4 and IPv6 server group. For example, in the case of mixed IPv4 and IPv6 server group 130, the load balancing device 110 might only receive IPv4 request messages during a particular period. If the IPv4 request messages were simply directed to the IPv4 servers, the risk of the IPv4 server overloading might increase while the IPv6 servers remain idle. By contrast, according to the present disclosure, the server group 130 is no longer limited to a particular protocol version as the load balancing device 110 is able to support both versions. This provides greater flexibility for networking applications while the transition from IPv4 to IPv6 addressing type is still ongoing.
The load balancing device 110 may be applicable to both layer-4 and layer-7 technologies. Layer-4 technology is used to distribute service load based on transport layer characteristics. For example, the load may be distributed according to streams or sessions, where all service messages in the same connection are sent to the same server. The layer-7 technology generally refers to load balancing based on HTTP service, which generally needs to identify transmission contents to determine the load sharing strategy.
An example load balancing method by the load balancing device 110 will now be explained in further detail with reference to
Load Balancing Addresses
At block 210 in
For example, if the group of servers 130 is an IPv4 server group, the configured load balancing IP addresses are IPv4 addresses. If the group of servers 130 is an IPv6 server group, the configured load balancing addresses are IPv6 addresses. If the group 130 is a mixed IPv4 and IPv6 server group, both IPv4 and IPv6 addresses are configured to correspond to the IP version used by the servers.
The configuration process assigns the IPv4 and/or IPv6 addresses to the interface 112 to facilitate communication between the load balancing device 110 and the respective IPv4 and/or IPv6 servers 130. Any suitable methods for IP address configuration may be used, such as manual configuration, dynamic host configuration protocol (DHCP) and point-to-point protocol (PPP) etc.
Service Access Request Message
At block 220 in
The protocol version of the client terminal's 140 IP address corresponds to the protocol version of the virtual service access address of the load balancing device 110, as exemplified below:
(a) If the source IP address of the request message is an IPv4 address of the client terminal 140 and the destination address an IPv4 virtual service address of the load balancing device 110.
(b) If the source IP address of the request message is an IPv6 address of the client terminal 140 and the destination address an IPv6 virtual service address of the load balancing device 110.
In one example, the load balancing device 110 has a dual-protocol address for the same service, in that request messages may be directed to either an IPv4 or an IPv6 virtual service address of the load balancing device 110. In this case, a request message from a client terminal's 140 IPv4 address is sent to the IPv4 virtual service address, while a request message from a client terminal's 140 IPv6 address is sent to the IPv6 virtual service address.
Selection of a Server
At block 230 in
At block 232 in
At block 234, if persistence function is disabled, the load balancing device 110 selects the server using a predetermined load balancing algorithm, which may be one of the following:
In one example, each server 130 is assigned a unique identifier, such as in the form of a sequence number etc., and the load balancing algorithm calculates an identifier of a server 130 selected for processing the request message.
If persistence function is enabled, the load balancing device 110 selects the server based on information stored in a persistence table 124 in the data store 120. Each entry of the persistence table 124 includes an identifier of a server 130, and one or more characteristics of a request message previously processed by the server 130.
The load balancing device 110 first matches one or more characteristics of the request message with one of the entries in the persistence table 124; see block 236. Depending on the requirements in practice, the characteristics in the persistence table entry may include one or more of the following: source IP address, destination IP address, source port number, and destination port number of the message.
If a match is found at block 236, the load balancing device 110 determines a server identifier from the matching entry, and selects the server having the identifier to send the request message; see block 238.
Otherwise, if there is no match, a predetermined load balancing algorithm is used to select the server 130 to which the message should be sent and a new entry is created in the persistence table; see block 239. The new entry includes one or more characteristics of the message and the identifier of the server selected using the predetermined load balancing algorithm.
Protocol Version
At block 240 in
If the first protocol version is the same as the second protocol version, the load balancing device 110 forwards the request message to the selected server 130; see block 270. In this case, if both the client terminal and the selected server 130 use IPv4 or IPv6 addressing, the request message is sent to the selected server 130.
Otherwise, if the first and second protocol versions are not the same, the load balancing device 110 selects, from the load balancing IP addresses configured at 210, a load balancing IP address of the second protocol version to correspond to the IP address of the selected server 130; see block 250.
In this case, if the client terminal uses an IPv6 address but the selected server 130 uses an IPv4 address, the selected IP address is an IPv4 load balancing address configured on the interface 112 between the load balancing device 110 and the group of servers 130. If the client terminal uses an IPv4 address but the selected server 130 uses IPv6, the selected IP address is an IPv6 load balancing address configured on the interface 112.
Address Translation
At block 260 in
The load balancing device 110 performs source network address translation (SNAT) processing on the request message; see block 262. The source IP address of the request message is changed from the IP address of the client terminal to the load balancing IP address selected at block 250. A source port number of the request message may be replaced with a port number, which may be randomly allocated for example.
The load balancing device 110 performs destination network address translation (DNAT) processing on the request message; see block 264. The destination IP address of the request message is changed to the IP address of the selected server. If port numbers are also configured, a destination port number of the request message may also be changed to a configured port number.
The load balancing device 110 also stores one or more characteristics of the request message before and after network address translation in the data store 120; see block 266. The message characteristics 126 stored include the source IP address and the destination IP address of the request message. The characteristics relate to stream characteristics of the request message, such as the source port number and the destination port number of the request message before and after SNAT and DNAT may also be stored. Information of the corresponding transport protocol, such as transport control protocol (TCP), user datagram protocol (UDP) and raw IP etc. may also be stored.
If the selected server 130 uses an IPv4 address but the request message is sent by an IPv6 client terminal 140, the source IP address of the request message is converted from the IPv6 address of the client terminal 140 to an IPv4 load balancing address configured on the interface 112 between the load balancing device 110 and the servers 130.
On the other hand, if the selected server 130 uses an IPv6 address but the request message is sent by an IPv4 client terminal 140, the source IP address of the request message is converted from the client terminal's IPv4 address to an IPv6 load balancing address configured on the interface 112 between the load balancing device 110 and the servers 130.
After performing network address translation, the load balancing device 110 sends the request message to the selected server 130; see block 270 in
Service Access Response Message
At block 280 in
The source IP address of the response message is the IP address of the selected server 130. The destination IP address of the response message is the IP address of the load balancing device 110, which is the same as the source IP address of the service access request message sent by the load balancing device 110.
At block 290, the load balancing device 110 performs network address translation on the response message, after which the source IP address of response message is the virtual service address of the load balancing device 110 and its destination address the IP address of the client terminal 140 that sent the corresponding request message.
In one example, the load balancing device 110 searches the message characteristics 126 before and after SNAT and DNAT in the data store 120, and modifies the characteristics of the response message based on the characteristics of the corresponding request message before SNAT and DNAT.
After network address translation, the load balancing 110 sends the response message to the client terminal 140 via the interface 111 between the load balancing 110 and the client terminal 140.
In a first example 500 shown in
In a second example 600 shown in
At block 660, the response message is sent to the client terminal 130. The source address of the response message is the load balancing device's IPv4 virtual service address, and the destination address is the client terminal's IPv4 address.
In a third example, the load balancing device 110 provides a dual-protocol address for the same service, in which both IPv4 and IPv6 virtual service addresses are provided. In this case, the load balancing device 110 are able to handle request messages from IPv4 and IPv6 client terminals 130. If the client terminal uses an IPv6 address but the selected server uses an IPv4 address, the load balancing device 110 performs the process exemplified with the second scenario in
An example structure of the load balancing device 110 is shown in
The first and second interfaces 111, 112 facilitate communication between the load balancing device 110 and the client terminals 140 and the group of servers 130, respectively. Each interface 111, 112 may be an I/O device or switching module etc., and comprises hardware and/or software components, such as an interface card (high density or low density), bus connections, encoders, decoders, modulators etc.
The term ‘processor’ is to be interpreted broadly to include a central processing unit (CPU), processing unit, application-specific integrated circuit (ASIC), logic unit, or programmable gate array etc. In one example (not shown in
The processes, methods and functional units may all be performed by a single processor 120 or split between several processors; reference in this disclosure or the claims to a ‘processor’ should thus be interpreted to mean ‘one or more processors’. Similarly, the functionality of the first 111 and second 112 interfaces may be each split between several sub-interfaces, and therefore the term ‘interface’ in this disclosure should be interpreted to mean ‘one or more interfaces’. Although the data store 120 is shown as an internal data store, the data store 120 may be external to, but accessible by, the load balancing device 110. The term ‘data store’ should also be interpreted broadly to mean ‘one or more data stores’.
Further, the processes, methods and functional units described in this disclosure may be implemented in the form of a computer program product. The computer program product is stored in a computer-readable storage medium and comprises computer-readable instructions to cause the processor 116 of the load balancing device to implement the methods, processes and functional units recited in the examples of the present disclosure.
The figures are only illustrations of an example, wherein the methods, processes and functional units in the figures are not necessarily essential for implementing the present disclosure. Those skilled in the art will understand that the functional units in the device in the example can be arranged in the device in the examples as described, or can be alternatively located in one or more devices different from that in the examples. The functional units in the examples described can be combined into one module or further divided into a plurality of sub-units.
Although the flowcharts described show a specific order of execution, the order of execution may differ from that which is depicted. For example, the order of execution of two or more blocks may be changed relative to the order shown. Also, two or more blocks shown in succession may be executed concurrently or with partial concurrence. All such variations are within the scope of the present disclosure.
It will be appreciated that numerous variations and/or modifications may be made to the examples without departing from the scope of the disclosure. The present examples are, therefore, to be considered in all respects as illustrative and not restrictive.
| Number | Date | Country | Kind |
|---|---|---|---|
| 201110047724.8 | Feb 2011 | CN | national |
| Filing Document | Filing Date | Country | Kind | 371c Date |
|---|---|---|---|---|
| PCT/CN2012/071559 | 2/24/2012 | WO | 00 | 6/28/2013 |