CN110933182A - Load sharing method, device and system - Google Patents

Load sharing method, device and system Download PDF

Info

Publication number
CN110933182A
CN110933182A CN201911276196.6A CN201911276196A CN110933182A CN 110933182 A CN110933182 A CN 110933182A CN 201911276196 A CN201911276196 A CN 201911276196A CN 110933182 A CN110933182 A CN 110933182A
Authority
CN
China
Prior art keywords
load balancing
server
value
pppoe
information
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.)
Granted
Application number
CN201911276196.6A
Other languages
Chinese (zh)
Other versions
CN110933182B (en
Inventor
肖湘光
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
New H3C Big Data Technologies Co Ltd
Original Assignee
New H3C Big Data Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by New H3C Big Data Technologies Co Ltd filed Critical New H3C Big Data Technologies Co Ltd
Priority to CN201911276196.6A priority Critical patent/CN110933182B/en
Publication of CN110933182A publication Critical patent/CN110933182A/en
Application granted granted Critical
Publication of CN110933182B publication Critical patent/CN110933182B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1004Server selection for load balancing
    • H04L67/1008Server selection for load balancing based on parameters of servers, e.g. available memory or workload
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1004Server selection for load balancing
    • H04L67/101Server selection for load balancing based on network conditions

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Hardware Design (AREA)
  • General Engineering & Computer Science (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The utility model discloses a load sharing method, which comprises a PPPoE server cluster electing a main server; the main server receives first load balancing information from the slave server, determines a first load balancing value of the slave server according to the first load balancing information, acquires second load balancing information of a local PPPoE interface, determines a second load balancing value of the main server according to the second load balancing information, and adjusts the delay of locally sending the PADO packet or the delay of sending the PADO packet by the slave server according to the first load balancing value and the second load balancing value. On the basis of no need of operation of maintenance personnel, the main server is elected from the server cluster, and the main server automatically adjusts the time delay of the server for sending the PADO packet according to the first load balancing information reported by other servers and the local second load balancing information, so that the aim of sharing the PADO packet on each server by a user in a balanced manner is fulfilled, and the maintenance work of equipment is simplified.

Description

Load sharing method, device and system
Technical Field
The present disclosure relates to the field of communications technologies, and in particular, to a load sharing method, apparatus, and system.
Background
Because PPPoE (Point-to-Point Protocol over Ethernet, which carries PPP Protocol over Ethernet) can implement control, authentication and charging functions for users who surf the Internet, it is widely applied to the construction of cell networks. The client access PPPoE procedure includes a discovery phase and a session phase. In the Discovery phase, after a client broadcasts a PADI (PPPoE Active Discovery Initiation packet), all servers in the service range in the network respond to a PADO (PPPoE Active Discovery Offer packet), and usually, the client selects a server with the earliest response as an access server. If all the clients access the server with the earliest response when accessing the PPPoE, the number of the clients accessed by a certain server is large after the server runs for a period of time, and the number of the clients accessed by other servers is small, so that the problem of imbalance is caused.
At present, the imbalance problem is regularly monitored by a maintainer, and when imbalance occurs, the maintainer configures a PADO packet for delayed transmission on a PPPoE interface of a server with a large number of access clients, or kicks off a line a user on the server with the large number of access clients. However, this maintenance method requires manual intervention, and is heavy and complicated to operate.
Disclosure of Invention
The purpose of the present disclosure is to provide a load sharing method, device and system for overcoming the deficiencies in the prior art, and the purpose is achieved by the following technical solutions.
A first aspect of the present disclosure provides a load sharing method, where the method is applied to a master server elected by a PPPoE server cluster of a PPPoE networking, where other servers in the PPPoE server cluster except the master server are slave servers, and the method includes:
receiving first load balancing information from a slave server, and determining a first load balancing value of the slave server according to the first load balancing information; the first load balancing information is information of a PPPoE interface on a slave server;
acquiring second load balancing information of a local PPPoE interface, and determining a second load balancing value of the main server according to the second load balancing information;
and adjusting the delay of locally sending the PADO packet or the delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value.
A second aspect of the present disclosure provides a load sharing system, which includes a master server and a slave server, where the master server and the slave server are located in a PPPoE server cluster of a PPPoE networking;
the slave server is configured to send first load balancing information to the master server, where the first load balancing information is information of a PPPoE interface on the slave server;
the main server is used for determining a first load balancing value of the slave server according to the first load balancing information, acquiring second load balancing information of a local PPPoE interface at the same time, and determining a second load balancing value of the main server according to the second load balancing information; and adjusting the delay of locally sending the PADO packet or the delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value.
A third aspect of the present disclosure provides a load sharing device, where the device is applied to any server in a PPPoE server cluster of a PPPoE networking, and the device includes:
the election module is used for judging whether the server can be used as a main server according to a preset election rule after establishing connection with other servers; if yes, the server is used as a main server; if not, the user serves as a slave server;
the load sharing module is used for receiving first load balancing information from a slave server when the slave server is used as a main server, and determining a first load balancing value of the slave server according to the first load balancing information; the first load balancing information is information of a PPPoE interface on a slave server; acquiring second load balancing information of a local PPPoE interface, and determining a second load balancing value of the main server according to the second load balancing information; and adjusting the delay of locally sending the PADO packet or the delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value.
A fourth aspect of the present disclosure provides a computer device, comprising: memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the method according to the first aspect when executing the program.
A fifth aspect of the present disclosure proposes a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, carries out the steps of the method according to the first aspect as described above.
In the embodiment of the present disclosure, a PPPoE server cluster in a PPPoE networking selects a master server, then the master server receives first load balancing information (which is information of a PPPoE interface on the slave server) from the slave server, determines a first load balancing value of the slave server according to the first load balancing information, obtains second load balancing information of a local PPPoE interface, determines a second load balancing value of the master server according to the second load balancing information, and finally adjusts a delay of locally sending a PADO packet or a delay of sending a PADO packet from the slave server according to the first load balancing value and the second load balancing value.
Based on the above description, on the basis that no operation is required by a maintenance person, the main server is selected from the PPPoE server cluster, the main server calculates the load balancing value of each server according to the first load balancing information reported by the slave server and the second load balancing information of the main server, and automatically adjusts the delay of sending the PADO packet by the server according to the load balancing value of each server, so as to achieve the purpose that the user shares the servers in a balanced manner, and simplify the maintenance work of the device.
Drawings
The accompanying drawings, which are included to provide a further understanding of the disclosure and are incorporated in and constitute a part of this disclosure, illustrate embodiments of the disclosure and together with the description serve to explain the disclosure and not to limit the disclosure. In the drawings:
fig. 1 is a schematic diagram illustrating a PPPoE networking architecture according to an exemplary embodiment of the present disclosure;
FIG. 2 is a flow chart illustrating an embodiment of a method of load sharing according to an exemplary embodiment of the present disclosure;
fig. 3 is a flowchart illustrating an embodiment of a load sharing apparatus according to an exemplary embodiment of the present disclosure.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
The terminology used in the present disclosure is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. As used in this disclosure and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.
It is to be understood that although the terms first, second, third, etc. may be used herein to describe various information, such information should not be limited to these terms. These terms are only used to distinguish one type of information from another. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the present disclosure. The word "if" as used herein may be interpreted as "at … …" or "when … …" or "in response to a determination", depending on the context.
The PPPoE networking structure shown in fig. 1 includes clients (fig. 1 shows a client 1, a client 2, and a client 3), an aggregation switch, a PPPoE server cluster (fig. 1 shows a server 1 and a server 2), and an AAA (Authentication, Authorization, Accounting, Authentication, Authorization, and Accounting) Authentication server.
PPPoE uses a Client/Server model, so that a Client refers to a PPPoE Client, a Server refers to a PPPoE Server, after a session is established between the Client and the Server, the Server provides functions of access control, authentication, charging and the like for the Client, and authentication, authorization and charging are realized by an AAA authentication Server connected with the Server.
The process of establishing a Session between the client and the server includes a Discovery phase (PPPoE Discovery Stage) and a Session phase (PPPoE Session Stage).
The session phase includes LCP phase, Authentication phase (optional), NCP phase and PPP service phase. In the discovery phase, through interaction of four messages (PPPoE discovery initial message PADI, PPPoE discovery offer message PADO, PPPoE discovery request message PADR, PPPoE discovery SESSION confirmation message PADS), an ethernet MAC (media access Control Address) Address of the opposite end is finally obtained, and a PPPoE SESSION _ ID is determined.
As shown in fig. 1, in the networking structure, when the client accesses the network, after broadcasting the PADI packet, if the services provided by the server 1 and the server 2 meet the service type carried by the PADI packet, both the server 1 and the server 2 will respond to the PADO packet to the client, and the client selects a server that responds the earliest PADO packet as the access server.
In practical applications, the delay of the server responding to the client is affected by various factors (including the transmission delay of the PPPoE interface), some servers may have short delay, and some servers may have longer delay, so that the client receives the responses of the servers in a sequence. Based on this, along with the accumulation of the operation time, the number of users connected to the server with short delay time is more than that of the server with long delay time, and the bandwidth utilization rate of the server with short delay time and the aggregation switch is higher than that of the server with long delay time, which may cause the problem of bandwidth utilization imbalance.
Assuming that the bandwidth of the aggregation switch and the server 1 is 10G and the bandwidth of the aggregation switch and the server 2 is 100G, the number of access users of the server 1 and the server 2 should also be 1: 10, if the server 1 is delayed for a short time, the number of users connected to the server 1 is larger than the number of users connected to the server 2, which is different from the theory.
The current solution is that the time delay for sending the PADO packet is configured according to the server running condition by manual timing monitoring, so as to achieve the purpose of enabling new users to access the servers with low bandwidth utilization rate or few users, and ensure that the users are shared on each server in a balanced manner. And under the condition that the load sharing of each server is very unbalanced, even under the condition of congestion and packet loss, maintenance personnel also need to perform the operation of kicking off the user.
However, the maintenance mode needs manual participation, has large workload and complex and tedious operation, and even reduces the experience of online users.
In order to solve the technical problem, the present disclosure provides a load sharing method for PPPoE networking, where a PPPoE server cluster in the PPPoE networking first elects a master server, then the master server receives first load balancing information (which is information of a PPPoE interface on a slave server) from the slave server, determines a first load balancing value of the slave server according to the first load balancing information, and also obtains second load balancing information of a local PPPoE interface, determines a second load balancing value of the master server according to the second load balancing information, and finally adjusts a delay of locally sending a PADO packet or a delay of sending a PADO packet from the slave server according to the first load balancing value and the second load balancing value.
Based on the above description, on the basis that no operation is required by a maintenance person, the main server selected from the PPPoE server cluster calculates the load balancing value of each server according to the first load balancing information reported by the slave server and the local second load balancing information, and automatically adjusts the delay of sending the PADO packet by the server according to the load balancing value of each server, so as to achieve the purpose of sharing the PADO packet on each server by the user in a balanced manner, thereby simplifying the maintenance work of the device.
The process of electing the main server aiming at the PPPoE server cluster comprises the following steps: after the servers in the PPPoE server cluster are connected in pairs, each server judges whether the server can be used as a main server or not according to a preset election rule, if so, the server is used as the main server, and if not, the server is used as a slave server.
The connection between the two servers may be established by using a TCP (Transmission Control Protocol) connection or a UDP (User Datagram Protocol) connection, which is not specifically limited in this disclosure.
In the present disclosure, a connection is established between any two servers through the PPPoE interface dimension, that is, in the connection establishment process, the identifiers of the PPPoE interfaces of both parties are exchanged with each other.
For example, after the connection between the two servers is established, the two servers may use the connection interfaces of the two servers as a set of PEER PEERs for subsequently sending information of the PPPoE interface through the PEER.
When establishing a connection, the two servers also exchange respective loopback addresses, so that the preset election rule can be that the main server is elected according to the condition of meeting the minimum loopback address.
That is, each server compares the local loopback address with the loopback addresses of other servers, and if the local loopback address is the smallest, the server is taken as the master server, otherwise, the server is taken as the slave server.
Certainly, the preset election rule may also be that election is performed as a main server meeting the condition of the maximum loopback address, and the election principle of each server is similar to the election principle described above and is not described again.
It should be noted that after the master server is elected, a keep-alive mechanism may be used between the master server and the slave servers to detect whether the master server is normal, and if the master server is detected to be abnormal, the master server is elected again.
The following describes the load sharing method proposed in the present disclosure in detail with specific embodiments.
Fig. 2 is a flowchart of an embodiment of a load sharing method according to an exemplary embodiment shown in the present disclosure, where the load sharing method may be applied to a primary server elected by a PPPoE server cluster of a PPPoE networking, and as shown in fig. 2, the load sharing method includes the following steps:
step 201: the master server receives first load balancing information from the slave servers, and determines a first load balancing value of the slave servers according to the first load balancing information.
In step 201, the slave server may report first load balancing information of the local PPPoE interface to the master server periodically.
The PPPoE interface refers to an interface for accessing a client, that is, a PPPoE interface exchanged from a server to a main server when two servers establish a connection. The first load balancing information may include a maximum interface bandwidth, an occupied bandwidth, a maximum number of users accessing, a number of users accessing, and a delay time for transmitting the PADO packet.
In an embodiment, for the process of determining the first load balancing value from the server according to the first load balancing information, when the configuration requirement is bandwidth load balancing, the bandwidth utilization rate may be determined by using the maximum interface bandwidth and the occupied bandwidth in the first load balancing information, and the bandwidth utilization rate is used as the first load balancing value, and when the configuration requirement is user number load balancing, the user access utilization rate may be determined by using the maximum access user number and the accessed user number in the first load balancing information, and the user access utilization rate is used as the first load balancing value.
The calculation formula of the bandwidth utilization rate may be: occupied bandwidth/maximum interface bandwidth; the calculation formula of the user access utilization rate can be as follows: number of accessed users/maximum number of accessed users.
Assuming that the user configures bandwidth load balancing, and the maximum interface bandwidth and the occupied bandwidth in the first load balancing information are 10G and 2G, respectively, the load balancing value is the bandwidth utilization rate, specifically 20%.
Further, assuming that the user configures user number load balancing, and the maximum number of users accessing the first load balancing information is 10K users and the number of users already accessing the first load balancing information is 2K, the load balancing value is the user access utilization rate, specifically 20%.
It should be noted that, the user may also configure the load balancing requirement of two dimensions, that is, the bandwidth and the number of users.
Step 202: and acquiring second load balancing information of the local PPPoE interface, and determining a second load balancing value of the main server according to the second load balancing information.
In step 202, the master server may also periodically obtain second load balancing information of the local PPPoE interface, that is, information of the PPPoE interface exchanged from the master server to the slave server, where the second load balancing information also includes a maximum interface bandwidth, an occupied bandwidth, a maximum number of users accessing the local PPPoE interface, a number of users accessing the local PPPoE interface, and a delay of sending a PADO packet.
The calculation principle of the second load balancing value is the same as the calculation principle of the first load balancing value in step 201, and is not described again.
It will be understood by those skilled in the art that the present disclosure does not specifically limit the execution order of step 201 and step 202.
Step 203: and adjusting the delay of locally sending the PADO packet or the delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value.
In an embodiment, a maximum value and a minimum value may be selected from the first load balancing value and the second load balancing value, if a difference between the maximum value and the minimum value is not within a preset range, it is determined whether a delay of sending the PADO packet by the PPPoE interface on the server corresponding to the minimum value is zero, and if not, the delay of sending the PADO packet by the PPPoE interface on the server corresponding to the minimum value is reduced; if yes, increasing the time delay of sending the PADO packet by the PPPoE interface on the server corresponding to the maximum value.
If the difference value between the maximum value and the minimum value is not in the preset range, the problem that the number of the users accessed to the server is unbalanced is shown. The preset range may be set according to practical experience, for example, may be set to ± 5%.
In addition, if the delay of the PPPoE interface on the server corresponding to the minimum value for sending the PADO packet is zero, it means that the delay of the PPPoE interface on the server for sending the PADO packet cannot be reduced any more, and only by increasing the delay of the PPPoE interface on the server corresponding to the maximum value for sending the PADO packet, a new user can access the server corresponding to the minimum value as much as possible.
For example, the manner of each adjustment may be to decrease the preset value or increase the preset value.
Therefore, when the connection is established between the two servers, the identifications of the PPPoE interfaces of the two sides are exchanged, and the adjustment of the delay is also adjusted by the dimensionality of the PPPoE interfaces.
In one example, in order not to affect the access experience of a new user, a maximum delay of sending the PADO packet by the PPPoE interface on each server may be preset, that is, when the adjusted delay is greater than the maximum delay, the server sends an alarm prompt to alert maintenance personnel to check the operation condition of the server.
In another example, the main server may perform the processes of step 203 and step 204 once every preset time period. The time period is configured by a maintenance person according to actual needs, and may be the same as or different from a period for reporting the first load balancing information from the server, which is not limited in this disclosure.
In an exemplary scenario, as in the server 1 and the server 2 in fig. 1, it is assumed that a user configures bandwidth load balancing, the server 1 is a master server, the server 2 is a slave server, a maximum interface bandwidth 10G reported by the slave server is a used bandwidth 2G, then a bandwidth utilization rate of the slave server is 20% at this time, a maximum interface bandwidth 20G of the master server is a used bandwidth 2G, then a bandwidth utilization rate of the master server is 10% at this time, a preset range is ± 5% at this time, and because a bandwidth utilization difference between the two servers is not within ± 5%, if a delay of sending the PADO packet by the master server is not zero, the delay of sending the PADO packet by the master server is reduced. After a period of operation, assuming that the used bandwidth of the master server reaches 6G, the bandwidth utilization of the master server is 30% and the bandwidth utilization of the slave server is still 20%. Because the difference value of the bandwidth utilization rate is not within +/-5%, if the time delay of sending the PADO packet by the slave server is not zero, the slave server is informed to reduce the time delay of sending the PADO packet, and if the time delay of sending the PADO packet by the master server is zero, the time delay of sending the PADO packet by the master server is increased.
So far, accomplish the load sharing flow that above-mentioned fig. 2 shows, can realize sharing the purpose on each server with the user equilibrium automatically through the flow that fig. 2 shows, need not maintainer and monitor, simplified the maintenance work of equipment, also need not maintainer to play the user off the production line simultaneously, promoted user's experience of surfing the net.
On the basis of the above embodiment, the present disclosure further provides a load sharing system, which includes a master server and a slave server, where the master server and the slave server are located in a PPPoE server cluster of a PPPoE networking;
the slave server is used for sending first load balancing information to the master server, wherein the first load balancing information is information of a PPPoE interface on the slave server;
the main server is used for determining a first load balancing value of the slave server according to the first load balancing information, acquiring second load balancing information of a local PPPoE interface at the same time, and determining a second load balancing value of the main server according to the second load balancing information; and adjusting the delay of locally sending the PADO packet or the delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value.
Corresponding to the foregoing embodiments of the load sharing method, the present disclosure also provides embodiments of a load sharing apparatus.
Fig. 3 is a flowchart illustrating an embodiment of a load sharing apparatus according to an exemplary embodiment of the present disclosure, where the load sharing apparatus is applied to any server in the server cluster illustrated in fig. 1, and the load sharing apparatus includes:
the election module 310 is configured to determine whether the server itself can serve as a main server according to a preset election rule after establishing connection with other servers; if yes, the server is used as a main server; if not, the user serves as a slave server;
the load sharing module 320 is configured to receive first load balancing information from a slave server when the slave server is a master server, and determine a first load balancing value of the slave server according to the first load balancing information; the first load balancing information is information of a PPPoE interface on a slave server; acquiring second load balancing information of a local PPPoE interface, and determining a second load balancing value of the main server according to the second load balancing information; and adjusting the delay of locally sending the PADO packet or the delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value.
In an optional implementation manner, the load sharing module 320 is specifically configured to select a maximum value and a minimum value from the first load balancing value and the second load balancing value in a process of adjusting a delay of locally sending the PADO packet or a delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value; if the difference value between the maximum value and the minimum value is not in the preset range, judging whether the time delay of the PPPoE interface on the server corresponding to the minimum value for sending the PADO packet is zero or not; if not, reducing the time delay of sending the PADO packet by the PPPoE interface on the server corresponding to the minimum value; if yes, increasing the time delay of sending the PADO packet by the PPPoE interface on the server corresponding to the maximum value.
In an optional implementation manner, the first load balancing information and the second load balancing information each include a maximum interface bandwidth, an occupied bandwidth, a maximum number of users accessing, a number of users accessing, and a delay of sending a PADO packet.
In an optional implementation manner, the load sharing module 320 is specifically configured to, in the process of determining a first load balancing value of the slave server according to the first load balancing information, when the configuration requirement is bandwidth load balancing, determine a bandwidth utilization rate by using a maximum interface bandwidth and an occupied bandwidth in the first load balancing information, and use the bandwidth utilization rate as the first load balancing value; and when the configuration requirement is user number load balancing, determining the user access utilization rate by using the maximum access user number and the accessed user number in the first load balancing information, and taking the user access utilization rate as a first load balancing value.
The implementation process of the functions and actions of each unit in the above device is specifically described in the implementation process of the corresponding step in the above method, and is not described herein again.
For the device embodiments, since they substantially correspond to the method embodiments, reference may be made to the partial description of the method embodiments for relevant points. The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the disclosed solution. One of ordinary skill in the art can understand and implement it without inventive effort.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This disclosure is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The above description is only exemplary of the present disclosure and should not be taken as limiting the disclosure, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present disclosure should be included in the scope of the present disclosure.

Claims (12)

1. A load sharing method is characterized in that the method is applied to a main server selected by a PPPoE server cluster of PPPoE networking, and other servers except the main server in the PPPoE server cluster are slave servers, and the method comprises the following steps:
receiving first load balancing information from a slave server, and determining a first load balancing value of the slave server according to the first load balancing information; the first load balancing information is information of a PPPoE interface on a slave server;
acquiring second load balancing information of a local PPPoE interface, and determining a second load balancing value of the main server according to the second load balancing information;
and adjusting the delay of locally sending the PADO packet or the delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value.
2. The method of claim 1, wherein the PPPoE server cluster electing a primary server comprises:
after the servers in the PPPoE server cluster are connected in pairs, each server judges whether the server can be used as a main server according to a preset election rule;
if yes, the server is used as a main server.
3. The method of claim 1, wherein adjusting the latency of sending the PADO packet locally or from the server according to the first load balancing value and the second load balancing value comprises:
selecting a maximum value and a minimum value from the first load balancing value and the second load balancing value;
if the difference value between the maximum value and the minimum value is not in the preset range, judging whether the time delay of the PPPoE interface on the server corresponding to the minimum value for sending the PADO packet is zero or not;
if not, reducing the time delay of sending the PADO packet by the PPPoE interface on the server corresponding to the minimum value;
if yes, increasing the time delay of sending the PADO packet by the PPPoE interface on the server corresponding to the maximum value.
4. The method of claim 1, wherein the first load balancing information and the second load balancing information each comprise a maximum interface bandwidth, an occupied bandwidth, a maximum number of users accessing, a number of users accessing, and a delay in sending PADO packets.
5. The method of claim 4, wherein determining a first load balancing value from the server based on the first load balancing information comprises:
when the configuration requirement is bandwidth load balancing, determining a bandwidth utilization rate by using a maximum interface bandwidth and an occupied bandwidth in first load balancing information, and taking the bandwidth utilization rate as a first load balancing value;
and when the configuration requirement is user number load balancing, determining the user access utilization rate by using the maximum access user number and the accessed user number in the first load balancing information, and taking the user access utilization rate as a first load balancing value.
6. A load sharing system, said system comprising a master server and a slave server, said master server and said slave server being located in a PPPoE server cluster of a PPPoE networking;
the slave server is configured to send first load balancing information to the master server, where the first load balancing information is information of a PPPoE interface on the slave server;
the main server is used for determining a first load balancing value of the slave server according to the first load balancing information, acquiring second load balancing information of a local PPPoE interface at the same time, and determining a second load balancing value of the main server according to the second load balancing information; and adjusting the delay of locally sending the PADO packet or the delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value.
7. A load sharing device, wherein the device is applied to any server in a PPPoE server cluster of a PPPoE networking, the device comprises:
the election module is used for judging whether the server can be used as a main server according to a preset election rule after establishing connection with other servers; if yes, the server is used as a main server; if not, the user serves as a slave server;
the load sharing module is used for receiving first load balancing information from a slave server when the slave server is used as a main server, and determining a first load balancing value of the slave server according to the first load balancing information; the first load balancing information is information of a PPPoE interface on a slave server; acquiring second load balancing information of a local PPPoE interface, and determining a second load balancing value of the main server according to the second load balancing information; and adjusting the delay of locally sending the PADO packet or the delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value.
8. The apparatus according to claim 7, wherein the load sharing module is specifically configured to select a maximum value and a minimum value from the first load balancing value and the second load balancing value in a process of adjusting a delay of locally sending the PADO packet or a delay of sending the PADO packet from the server according to the first load balancing value and the second load balancing value; if the difference value between the maximum value and the minimum value is not in the preset range, judging whether the time delay of the PPPoE interface on the server corresponding to the minimum value for sending the PADO packet is zero or not; if not, reducing the time delay of sending the PADO packet by the PPPoE interface on the server corresponding to the minimum value; if yes, increasing the time delay of sending the PADO packet by the PPPoE interface on the server corresponding to the maximum value.
9. The apparatus of claim 7, wherein the first load balancing information and the second load balancing information each comprise a maximum interface bandwidth, an occupied bandwidth, a maximum number of users accessing, a number of users accessing, and a delay in sending PADO packets.
10. The apparatus according to claim 9, wherein the load sharing module is specifically configured to, in the process of determining a first load balancing value of the slave server according to the first load balancing information, when the configuration requirement is bandwidth load balancing, determine a bandwidth utilization rate by using a maximum interface bandwidth and an occupied bandwidth in the first load balancing information, and use the bandwidth utilization rate as the first load balancing value; and when the configuration requirement is user number load balancing, determining the user access utilization rate by using the maximum access user number and the accessed user number in the first load balancing information, and taking the user access utilization rate as a first load balancing value.
11. A computer device, comprising: memory, processor and computer program stored on the memory and executable on the processor, the processor implementing the steps of the method according to any one of claims 1, 3-5 when executing the program.
12. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method according to any one of claims 1, 3-5.
CN201911276196.6A 2019-12-12 2019-12-12 Load sharing method, device and system Active CN110933182B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911276196.6A CN110933182B (en) 2019-12-12 2019-12-12 Load sharing method, device and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911276196.6A CN110933182B (en) 2019-12-12 2019-12-12 Load sharing method, device and system

Publications (2)

Publication Number Publication Date
CN110933182A true CN110933182A (en) 2020-03-27
CN110933182B CN110933182B (en) 2022-06-24

Family

ID=69859271

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911276196.6A Active CN110933182B (en) 2019-12-12 2019-12-12 Load sharing method, device and system

Country Status (1)

Country Link
CN (1) CN110933182B (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6259705B1 (en) * 1997-09-22 2001-07-10 Fujitsu Limited Network service server load balancing device, network service server load balancing method and computer-readable storage medium recorded with network service server load balancing program
US20040103194A1 (en) * 2002-11-21 2004-05-27 Docomo Communicatios Laboratories Usa, Inc. Method and system for server load balancing
CN105262698A (en) * 2015-10-28 2016-01-20 华为技术有限公司 Load sharing method, device and system
CN106453124A (en) * 2016-10-26 2017-02-22 杭州华三通信技术有限公司 Traffic scheduling method and device
CN106506664A (en) * 2016-11-18 2017-03-15 杭州华三通信技术有限公司 A kind of method and apparatus of server load balancing
CN107995125A (en) * 2017-11-17 2018-05-04 新华三技术有限公司 A kind of traffic scheduling method and device
CN109639796A (en) * 2018-12-11 2019-04-16 浪潮电子信息产业股份有限公司 A kind of implementation of load balancing, device, equipment and readable storage medium storing program for executing

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6259705B1 (en) * 1997-09-22 2001-07-10 Fujitsu Limited Network service server load balancing device, network service server load balancing method and computer-readable storage medium recorded with network service server load balancing program
US20040103194A1 (en) * 2002-11-21 2004-05-27 Docomo Communicatios Laboratories Usa, Inc. Method and system for server load balancing
CN105262698A (en) * 2015-10-28 2016-01-20 华为技术有限公司 Load sharing method, device and system
CN106453124A (en) * 2016-10-26 2017-02-22 杭州华三通信技术有限公司 Traffic scheduling method and device
CN106506664A (en) * 2016-11-18 2017-03-15 杭州华三通信技术有限公司 A kind of method and apparatus of server load balancing
CN107995125A (en) * 2017-11-17 2018-05-04 新华三技术有限公司 A kind of traffic scheduling method and device
CN109639796A (en) * 2018-12-11 2019-04-16 浪潮电子信息产业股份有限公司 A kind of implementation of load balancing, device, equipment and readable storage medium storing program for executing

Also Published As

Publication number Publication date
CN110933182B (en) 2022-06-24

Similar Documents

Publication Publication Date Title
US20190149443A1 (en) Apparatus and methods for monitoring and diagnosing a wireless network
US10097645B2 (en) Method and apparatus of performing peer-to-peer communication establishment and connection change-over
CN107454155B (en) Fault processing method, device and system based on load balancing cluster
JP4755280B2 (en) Network verification system
CN103973728B (en) The method and device of load balancing under a kind of multiple data centers environment
US9906422B2 (en) Distributed system to determine a server's health
EP2351330B1 (en) Deterministic session load-balancing and redundancy of access servers in a computer network
KR100977901B1 (en) DIRECTED PPPoE SESSION INITIATION OVER A SWITCHED ETHERNET
US7561587B2 (en) Method and system for providing layer-4 switching technologies
EP2992644A1 (en) Enhancing a mobile backup channel to address a node failure in a wireline network
CN114422571B (en) Quantum communication client disconnection reconnection system and method
US11582113B2 (en) Packet transmission method, apparatus, and system utilizing keepalive packets between forwarding devices
CN108234208A (en) The visualization load balancing dispositions method and system of resource management based on business
US20100039956A1 (en) Method and system for performing keep-alive monitoring on subscriber sessions
WO2017012471A1 (en) Load balance processing method and apparatus
CN110933182B (en) Load sharing method, device and system
WO2013159492A1 (en) Method and system for reporting and downloading information
CN110380981B (en) Flow distribution method and equipment
WO2013026308A1 (en) Service node and inter-service node user protocol message synchronization method
KR101106873B1 (en) Peer to peer communication method between online game clients
Cisco Server Load Balancing
WO2008011253A2 (en) Host posing network device and method thereof
WO2014090194A1 (en) Dialing method of terminal device, and access device
JP2006270680A (en) Layer two switch device
CN113765795A (en) Networking method, device, system and storage medium

Legal Events

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