Search

CN-122019160-A - Service load balancing method, equipment and storage medium of power system

CN122019160ACN 122019160 ACN122019160 ACN 122019160ACN-122019160-A

Abstract

The invention discloses a service load balancing method, equipment and a storage medium of an electric power system, wherein the method comprises the steps of constructing a feature vector for a data stream when the data stream related to an electric power service is received; the method comprises the steps of calculating load values of all resources of a server in the future, screening out servers with load values capable of bearing feature vectors to obtain candidate sets, calculating matching degrees of the servers and data streams according to the feature vectors and the load values for the candidate sets, calculating load cost of the server clusters when the servers simulate and execute data stream distribution for the candidate sets, calculating scheduling value of the servers according to the matching degrees and the load cost for the candidate sets, and distributing the data streams to the servers with the largest scheduling value for processing. The embodiment gives consideration to individual suitability and global optimization of the clusters, ensures high-efficiency processing of data streams, improves the utilization rate of the whole resources of the clusters, and achieves the dual effects of prospective balanced load and accurate distribution.

Inventors

  • LIN KEQUAN
  • XU DI
  • Liao Wendan
  • WEN GUOLIN
  • ZHAO LEI
  • CAO XUEYAN

Assignees

  • 中国南方电网有限责任公司

Dates

Publication Date
20260512
Application Date
20260127

Claims (10)

  1. 1. A method for traffic load balancing of an electrical power system, wherein a server cluster is deployed in the electrical power system, the server cluster including a plurality of servers, the method comprising: When a data stream related to power service is received, constructing a feature vector for the data stream; calculating the load value of each resource of the server in the future; Screening the server of which the load value can bear the characteristic vector to obtain a candidate set; Calculating the matching degree of the server and the data stream according to the characteristic vector and the load value aiming at the candidate set; calculating the load cost of the server cluster when the server simulation execution distributes the data stream aiming at the candidate set; calculating the scheduling value of the server according to the matching degree and the load cost aiming at the candidate set; And distributing the data stream to the server with the largest scheduling value for processing.
  2. 2. The method of claim 1, wherein said constructing feature vectors for said data stream comprises: extracting an identifier of the data stream, wherein the identifier comprises a source protocol address, a destination protocol address, a source port number, a destination port number and a transport layer protocol of the data stream; Screening a plurality of candidate service protocols for the data flow according to the source port number and the destination port number; Extracting a payload field of the data stream; If the load field comprises a protocol header field corresponding to the candidate service protocol, the service type mapped by the protocol header field is used as the service type of the data flow; extracting data packet characteristics of the data stream, wherein the data packet characteristics comprise average packet size of data packets of the data stream and average transmission rate of the data packets; Determining a complexity level of the data stream according to the service type, the average packet size and the average transmission rate; The identifier, the traffic type, the average packet size, the average transmission rate, the complexity level and the traffic priority are constructed as feature vectors of the data stream.
  3. 3. The method of claim 1, wherein said calculating a load value for each resource of said server in the future comprises: The method comprises the steps of collecting resource utilization rate indexes of each resource in the current state for a server, wherein the resource utilization rate indexes comprise central processing unit utilization rate, memory bandwidth occupancy rate, storage input/output waiting queue depth and coprocessor occupancy rate; And inputting each item of the resource utilization index into a corresponding time sequence prediction model so as to predict each item of the resource utilization index to obtain a load value of each future resource, wherein the load value comprises the future CPU utilization rate, the future memory bandwidth occupancy rate, the future storage input/output waiting queue depth and the future coprocessor occupancy rate.
  4. 4. The method of claim 1, wherein the screening the server for which the load value can accept the feature vector to obtain a candidate set comprises: dividing the servers of which the load values are lower than the corresponding preset safety threshold values into initial sets; In the initial set, if the service priority of the data flow is a first priority, dividing the servers with the load values lower than a corresponding preset first threshold into candidate sets; and in the initial set, if the service priority of the data flow is a second priority, dividing the servers with the load values lower than a corresponding preset second threshold into candidate sets, wherein the first priority is higher than the second priority, and the first threshold is lower than the second threshold.
  5. 5. A method according to claim 3, wherein said calculating, for said candidate set, a degree of matching of said server to said data stream in dependence on said feature vector and said load value comprises: Calculating a first residual load value of each resource in the future according to the load value for each server, wherein the first residual load value comprises a residual utilization rate of a central processing unit, a residual occupancy rate of a memory bandwidth, a residual proportion of a storage input/output waiting queue, a depth of the future storage input/output waiting queue and a residual utilization rate of a coprocessor; calculating the matching degree of the server and the data stream according to the characteristic vector and the first residual load value aiming at the candidate set; The degree of matching is expressed by the following formula: Wherein, the For said degree of matching of the j-th of said servers in said candidate set, Matching a value for the cpu of the j-th said server in said candidate set, As a first weight to be used, A memory bandwidth match value for the j-th of the servers in the candidate set, As a result of the second weight being set, A matching value is input and output for the storage of the j-th said server in said candidate set, As a result of the third weight being given, A processing delay matching value for a j-th of said servers in said candidate set, For the fourth weight to be the fourth weight, For the hardware affinity match value of the j-th said server in said candidate set, As a result of the fifth weight being given, As a factor of the steepness of the product, For the remaining utilization of the central processing unit, To perform the strength requirements of the central processor of the data stream, For a reference requirement of the central processor corresponding to the complexity level of the data stream, alpha is a central processor tuning parameter, In order for the transmission rate to be an average, As a normalization factor for the average transmission rate, For the remaining occupancy of the memory bandwidth, To enforce the memory bandwidth requirements of the data stream, Is a preset positive number, and the number of the positive numbers is equal to the preset positive number, For the purpose of adjusting the parameters of the bandwidth of the memory, In order for the packet size to be an average, For a memory bandwidth sensitivity factor corresponding to the traffic type of the data stream, The remaining proportion of the queue is waited for the storage input output, To perform the store input output waiting queue requirements for the data stream, For storing input-output sensitivity coefficients corresponding to said traffic type of said data stream, To convert the byte rate of the data stream to a factor that stores the input-output pressure scale, For a delay-sensitive coefficient corresponding to the traffic priority of the data stream, To store the input-output wait queue penalty value, The input-output waiting queue depth is stored for the future, And storing the average rate of the tasks of the input-output waiting queue for the processing of the jth server in the candidate set.
  6. 6. The method of claim 1, further comprising, prior to said calculating a degree of matching of said server to said data stream for said candidate set from said feature vector and said load value: for the candidate set, if the server has no coprocessor, the hardware affinity matching value of the server is a first numerical value; For the candidate set, on the basis that the coprocessor is arranged on the server and the type of the coprocessor is matched with the service type of the data flow, if the residual utilization rate of the coprocessor of the server is greater than or equal to a utilization rate threshold value, the hardware affinity matching value is a second numerical value; for the candidate set, on the basis that the coprocessor is arranged on the server and the type of the coprocessor is matched with the service type of the data flow, if the residual utilization rate of the coprocessor of the server is smaller than a utilization rate threshold value, the hardware affinity matching value is a third numerical value; And aiming at the candidate set, if the server has the coprocessor and the type of the coprocessor is not matched with the service type of the data flow, the hardware affinity matching value is a fourth value, the second value is larger than the first value, the first value is larger than the fourth value, and the fourth value is larger than the third value.
  7. 7. The method of claim 1, wherein calculating the load cost of the server cluster for the candidate set when the server simulation execution allocates the data stream comprises: For the candidate set, acquiring load residual values of the resources after the server simulation execution of the data stream as second residual load values; calculating the load cost of the server cluster according to the second residual load value aiming at the candidate set; The load cost is expressed by the following formula: Wherein, the The load cost of the server cluster when executing the data stream for the j-th server in the candidate set, The weight coefficient of the d-th item for the second residual load value, A d-th item of a second remaining load value for a j-th one of said servers of said candidate set, A maximum available value of a resource utilization index corresponding to a d-th item of a second residual load value of a j-th one of the servers of the candidate set, Is the mean value of the d-th item of the first residual load value of each server.
  8. 8. The method according to any of claims 1-7, wherein said calculating a scheduling value of said server for said candidate set in dependence of said degree of matching and said load cost comprises: Calculating a product between the matching degree and the matching degree weight as a target matching value of the server for the candidate set; Calculating, for the candidate set, a product between the load cost and the load cost weight as a target load cost for the server; For the candidate set, a difference between a target match value and a target load cost is calculated as a scheduling value for the server.
  9. 9. A computer device, the computer device comprising: one or more processors; a storage means for storing one or more programs; when the one or more programs are executed by the one or more processors, the one or more processors are caused to implement the method of traffic load balancing of a power system of any of claims 1-8.
  10. 10. A computer readable storage medium, on which a computer program is stored, characterized in that the program, when executed by a processor, implements a method for traffic load balancing of an electrical power system according to any one of claims 1-8.

Description

Service load balancing method, equipment and storage medium of power system Technical Field The embodiment of the invention relates to the field of power system informatization, in particular to a service load balancing method, equipment and a storage medium of a power system. Background Along with the continuous promotion of the construction of a novel power system, the digital and intelligent transformation of a power grid is deepened continuously, and mass intelligent sensing, monitoring and control equipment is deployed in the scenes of a transformer substation, a power distribution room, a distributed energy station and the like. The equipment continuously generates various data streams closely related to the power service, which cover protection control instructions of millisecond-level response, second-level refreshed telemetry data, minute-level metered power utilization information, bursty high-definition video inspection streams and the like, and the different data streams have obvious differences in the aspects of real-time requirements, calculation complexity, data throughput and the like. The data flow needs to be reasonably distributed to a server in the power system for processing, and the stable operation, the business response efficiency and the resource utilization efficiency of the power system are related. At present, the conventional data stream distribution technology is to distribute data streams according to the current time load state of a server. The traditional data flow distribution technology focuses on the current load condition only, and the power service data flow has volatility, the accuracy of data flow distribution is poor only according to the current temporal load state, after the data flow distribution is easy to occur, a server rapidly falls into an overload state due to the future load climbing, the power service processing delay, the data loss and even the server failure are caused, the high-performance server resources are idle, and the overall service processing efficiency and the operation reliability of the power system are affected. Disclosure of Invention The invention provides a business load balancing method, equipment and a storage medium of an electric power system, which are used for improving the accuracy of data stream distribution and realizing prospective balancing load of the electric power system. In a first aspect, an embodiment of the present invention provides a service load balancing method for an electric power system, where a server cluster is deployed in the electric power system, where the server cluster includes a plurality of servers, and the method includes: When a data stream related to power service is received, constructing a feature vector for the data stream; calculating the load value of each resource of the server in the future; Screening the server of which the load value can bear the characteristic vector to obtain a candidate set; Calculating the matching degree of the server and the data stream according to the characteristic vector and the load value aiming at the candidate set; calculating the load cost of the server cluster when the server simulation execution distributes the data stream aiming at the candidate set; calculating the scheduling value of the server according to the matching degree and the load cost aiming at the candidate set; And distributing the data stream to the server with the largest scheduling value for processing. In a second aspect, an embodiment of the present invention further provides a service load balancing apparatus for an electric power system, where a server cluster is deployed in the electric power system, where the server cluster includes a plurality of servers, and the apparatus includes: The system comprises a feature vector construction module, a power service and a power service, wherein the feature vector construction module is used for constructing a feature vector for a data stream related to the power service when the data stream is received; the load value calculation module is used for calculating the load value of each resource of the server in the future; The candidate set acquisition module is used for screening out the servers of which the load values can bear the characteristic vectors to obtain candidate sets; The matching degree calculation module is used for calculating the matching degree of the server and the data stream according to the characteristic vector and the load value aiming at the candidate set; The load cost calculation module is used for calculating the load cost of the server cluster when the server simulation execution distributes the data stream aiming at the candidate set; The scheduling value calculation module is used for calculating the scheduling value of the server according to the matching degree and the load cost aiming at the candidate set; And the data stream distribution module is used for distributing the data stream to the server with the larges