CN113822485A - A method and system for optimizing distribution network scheduling tasks - Google Patents

A method and system for optimizing distribution network scheduling tasks Download PDF

Info

Publication number
CN113822485A
CN113822485A CN202111137762.2A CN202111137762A CN113822485A CN 113822485 A CN113822485 A CN 113822485A CN 202111137762 A CN202111137762 A CN 202111137762A CN 113822485 A CN113822485 A CN 113822485A
Authority
CN
China
Prior art keywords
server
distribution network
scheduling
slave
power distribution
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
CN202111137762.2A
Other languages
Chinese (zh)
Other versions
CN113822485B (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.)
Sishui Power Supply Co Of State Grid Shandong Electric Power Co
State Grid Corp of China SGCC
Jining Power Supply Co
Original Assignee
Sishui Power Supply Co Of State Grid Shandong Electric Power Co
State Grid Corp of China SGCC
Jining Power Supply Co
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 Sishui Power Supply Co Of State Grid Shandong Electric Power Co, State Grid Corp of China SGCC, Jining Power Supply Co filed Critical Sishui Power Supply Co Of State Grid Shandong Electric Power Co
Priority to CN202111137762.2A priority Critical patent/CN113822485B/en
Publication of CN113822485A publication Critical patent/CN113822485A/en
Application granted granted Critical
Publication of CN113822485B publication Critical patent/CN113822485B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/3024Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a central processing unit [CPU]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/3037Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a memory, e.g. virtual memory, cache
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/3041Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is an input/output interface
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/06Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling
    • G06Q10/063Operations research, analysis or management
    • G06Q10/0631Resource planning, allocation, distributing or scheduling for enterprises or organisations
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
    • G06Q50/06Energy or water supply

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Human Resources & Organizations (AREA)
  • Economics (AREA)
  • Computing Systems (AREA)
  • General Physics & Mathematics (AREA)
  • Quality & Reliability (AREA)
  • Strategic Management (AREA)
  • Tourism & Hospitality (AREA)
  • General Engineering & Computer Science (AREA)
  • Entrepreneurship & Innovation (AREA)
  • General Business, Economics & Management (AREA)
  • Mathematical Physics (AREA)
  • Marketing (AREA)
  • Health & Medical Sciences (AREA)
  • Development Economics (AREA)
  • Game Theory and Decision Science (AREA)
  • Operations Research (AREA)
  • Primary Health Care (AREA)
  • Public Health (AREA)
  • General Health & Medical Sciences (AREA)
  • Water Supply & Treatment (AREA)
  • Educational Administration (AREA)
  • Power Sources (AREA)

Abstract

本发明提供了一种配电网调度任务优化方法及系统,其中包括:调度服务器与主服务器和从服务器建立通信链接;调度服务器接收所下发的配电网的调度任务;调度服务器获取主服务器和从服务器当前的负载状况;所述的负载状况包括CPU使用率、内存使用率、IO消耗率;判断主服务器的当前的负载情况是否超过预设的第一阈值,如果主服务器当前的负载情况超过预设的第一阈值但是未超过预设的第二阈值,则调度服务器将所接收的配电网的调度任务按照当前的主服务器和从服务器的负载状况分配给主服务器和从服务器。

Figure 202111137762

The invention provides a method and system for optimizing distribution network scheduling tasks, which include: a scheduling server establishes a communication link with a master server and a slave server; the scheduling server receives the dispatched distribution network scheduling tasks; the scheduling server obtains the master server and the current load status of the slave server; the load status includes CPU usage, memory usage, and IO consumption rate; determine whether the current load status of the master server exceeds the preset first threshold, if the current load status of the master server If the preset first threshold is exceeded but the preset second threshold is not exceeded, the scheduling server allocates the received scheduling task of the power distribution network to the master server and the slave server according to the current load conditions of the master server and the slave server.

Figure 202111137762

Description

一种配电网调度任务优化方法及系统A method and system for optimizing distribution network scheduling tasks

技术领域technical field

本发明属于电力相关技术领域,尤其涉及一种配电网调度任务优化方法及系统。The invention belongs to the technical field of electric power, and in particular relates to a method and system for optimizing dispatching tasks of a distribution network.

背景技术Background technique

本部分的陈述仅仅是提供了与本发明相关的背景技术信息,不必然构成在先技术。The statements in this section merely provide background information related to the present invention and do not necessarily constitute prior art.

随着智能配电网建设的推进,对配电网资源优化配置的要求不断地增强,对配电网的调度运行和调度优化提出了更高的要求。With the advancement of the construction of intelligent distribution network, the requirements for the optimal allocation of distribution network resources are constantly increasing, and higher requirements are put forward for the dispatching operation and dispatching optimization of the distribution network.

目前在配电网的调度过程中一般是一个主服务器实现接收所下发的调度任务并进行计算后分配给各个执行单元,另外一个从服务器作为备用服务器,实现在主服务器发生故障时使用。但是在主服务器任务繁忙时,从服务器作为备用服务器处于闲置状态,资源的利用率低。而且主服务器的性能一般是高于从服务器的性能的,那么如何实现对配电网调度任务的合理的配置,以充分的利用主服务器的高性能的同时提高从服务器资源的利用率,显得尤为重要。At present, in the scheduling process of the distribution network, a master server is generally used to receive the dispatched scheduling tasks and distribute them to each execution unit after calculation, and another slave server is used as a backup server to be used when the master server fails. However, when the master server is busy, the slave server is in an idle state as a backup server, and the utilization of resources is low. Moreover, the performance of the master server is generally higher than that of the slave server, so how to achieve a reasonable configuration of the distribution network scheduling tasks to make full use of the high performance of the master server and improve the utilization of the resources of the slave server is particularly important. important.

发明内容SUMMARY OF THE INVENTION

为了解决上述问题,本发明提供一种配电网调度任务优化方法及系统,通过判断主服务器的负载情况是否超过预设的阈值,并结合从服务器的负载状况,实现对配电网调度任务的合理的分配,既能够实现对主服务器的高性能的充分的利用,又可以在主服务器的负载较高的情况下实现对从服务器的资源的合理的使用,提高资源利用率。In order to solve the above problems, the present invention provides a method and system for optimizing distribution network scheduling tasks. By judging whether the load condition of the master server exceeds a preset threshold, and combining the load conditions of the slave servers, the distribution network scheduling tasks can be optimized. Reasonable allocation can not only fully utilize the high performance of the master server, but also realize the rational use of the resources of the slave server under the condition of high load of the master server, and improve the resource utilization rate.

为了实现上述目的,本发明的第一个方面提供,采用如下技术方案:In order to achieve the above object, a first aspect of the present invention provides, adopts the following technical solutions:

调度服务器与主服务器和从服务器建立通信链接;The scheduling server establishes a communication link with the master server and the slave server;

调度服务器接收所下发的配电网的调度任务;The dispatching server receives the dispatched dispatching tasks of the distribution network;

调度服务器获取主服务器和从服务器当前的负载状况;所述的负载状况包括CPU使用率、内存使用率、IO消耗率;The scheduling server obtains the current load status of the master server and the slave server; the load status includes CPU usage, memory usage, and IO consumption rate;

判断主服务器的当前的负载情况是否超过预设的第一阈值,如果主服务器当前的负载情况超过预设的第一阈值但是未超过预设的第二阈值,则调度服务器将所接收的配电网的调度任务按照当前的主服务器和从服务器的负载状况分配给主服务器和从服务器。Determine whether the current load condition of the main server exceeds the preset first threshold, and if the current load condition of the main server exceeds the preset first threshold but does not exceed the preset second threshold, the scheduling server will receive the power distribution The scheduling task of the network is distributed to the master server and the slave server according to the current load status of the master server and the slave server.

进一步地,还包括,如果当前的主服务器的负载状况没有超过预设的第一阈值,则调度服务器将所接收的配电网的调度任务下发给主服务器。Further, it also includes, if the current load condition of the main server does not exceed the preset first threshold, the scheduling server sends the received scheduling task of the power distribution network to the main server.

进一步地,还包括,如果主服务器当前的负载情况超过预设的第二阈值,则调度服务器将所接收的配电网的调度任务分配给从服务器。Further, it also includes, if the current load condition of the master server exceeds a preset second threshold, the scheduling server assigns the received scheduling task of the power distribution network to the slave server.

进一步地,所述的主服务器当前的负载情况超过预设的第一阈值但是未超过预设的第二阈值时,进而判断从服务器的负载状况是否超过预设的第一阈值,若从服务器的负载状况没有超过预设的第一阈值,调度服务器根据主服务器的和从服务器的负载状况实现配电网调度任务的分配。Further, when the current load condition of the master server exceeds the preset first threshold but does not exceed the preset second threshold, it is further judged whether the load condition of the slave server exceeds the preset first threshold, and if the slave server's load condition exceeds the preset first threshold, If the load condition does not exceed the preset first threshold, the scheduling server realizes the distribution of the distribution network scheduling task according to the load conditions of the master server and the slave server.

进一步地,所述的调度服务器根据主服务器的和从服务器的负载状况实现配电网调度任务的分配的具体步骤为:Further, the specific steps for the scheduling server to realize the distribution of the distribution network scheduling tasks according to the load conditions of the master server and the slave server are:

确定所下发的配电网的调度任务量,判断所述的配电网的调度任务量是否不小于2,若配电网的调度任务量小于2,则将配电网的调度任务分配给主服务器;Determine the dispatching task amount of the distribution network issued, and judge whether the dispatching task amount of the distribution network is not less than 2. If the dispatching task amount of the distribution network is less than 2, assign the dispatching task of the distribution network to the distribution network. main server;

若配电网的调度任务量不小于2,则将待分配的配电网的调度任务分为两组,每组至少包括一个待分配的配电网的调度任务,其中配电网的调度任务的分组根据当前的主服务器和从服务器的负载状况预设公式进行分组。If the amount of dispatching tasks of the distribution network is not less than 2, the dispatching tasks of the distribution network to be allocated are divided into two groups, and each group includes at least one dispatching task of the distribution network to be allocated, among which the dispatching tasks of the distribution network The groups are grouped according to the preset formula of the current load conditions of the master server and the slave server.

进一步地,所述的预设公式为:Further, the preset formula is:

Figure BDA0003282721080000031
Figure BDA0003282721080000031

Figure BDA0003282721080000032
Figure BDA0003282721080000032

其中,T1为主服务器待接收的配电网的调度任务量,T2为从服务器待接收的配电网的调度任务的任务量,S1为主服务器当前的负载数值,S2为从服务器当前的负载数值,T为当前待分配的配电网的调度任务总量,T1、T2为整数。Among them, T1 is the task amount of the distribution network scheduling task to be received by the master server, T2 is the task amount of the distribution network scheduling task to be received by the slave server, S1 is the current load value of the master server, and S2 is the slave server. The current load value of the server, T is the total amount of scheduling tasks of the distribution network currently to be allocated, and T 1 and T 2 are integers.

进一步地,所述的负载数值计算公式为:Further, the described load numerical calculation formula is:

Score=A*cpu%+B*IO%+C*men%Score=A*cpu%+B*IO%+C*men%

其中,cpu%表示CPU的使用率,IO%表示IO的消耗率,men%表示内存的使用率,A、B、C分别表示CPU的使用率、IO的消耗率和内存的使用率的权重。Among them, cpu% represents the CPU usage rate, IO% represents the IO consumption rate, men% represents the memory usage rate, and A, B, and C represent the weights of the CPU usage rate, IO consumption rate, and memory usage rate, respectively.

一个或多个实施例提供了一种配电网调度任务优化系统,包括:One or more embodiments provide a distribution network scheduling task optimization system, including:

调度服务器,其被配置为:建立与主服务器和从服务器的通信链接;接收调度中心所下发的配电网的调度任务;获取主服务器和从服务器当前的负载状况;并对主服务器和从服务器的负载状况进行阈值的判断;The scheduling server is configured to: establish a communication link with the master server and the slave server; receive the scheduling task of the distribution network issued by the scheduling center; obtain the current load status of the master server and the slave server; The load status of the server is judged by the threshold;

主服务器,其被配置为:接收调度服务器所下发的配电网的调度任务并执行;The main server, which is configured to: receive and execute the scheduling task of the distribution network issued by the scheduling server;

从服务器,其被配置为:接收调度服务器所下发的配电网的调度任务并执行。The slave server is configured to: receive and execute the scheduling task of the distribution network issued by the scheduling server.

一种电子设备,包括存储器和处理器以及存储在存储器上并在处理器上运行的计算机指令,所述计算机指令被处理器运行时,完成上述方法所述的步骤。An electronic device includes a memory, a processor, and computer instructions stored on the memory and executed on the processor, and when the computer instructions are executed by the processor, the steps described in the above method are completed.

一种计算机可读存储介质,用于存储计算机指令,所述计算机指令被处理器执行时,完成上述方法所述的步骤。A computer-readable storage medium is used to store computer instructions, and when the computer instructions are executed by a processor, the steps described in the above method are completed.

本发明的有益效果是:The beneficial effects of the present invention are:

通过判断主服务器的负载情况是否超过预设的阈值,并结合从服务器的负载状况,实现对配电网调度任务的合理的分配,既能够实现对主服务器的高性能的充分的利用,又可以在主服务器的负载较高的情况下实现对从服务器的资源的合理的使用,提高资源利用率。By judging whether the load condition of the master server exceeds the preset threshold, and combining with the load condition of the slave servers, a reasonable distribution of the distribution network scheduling tasks can be realized, which can not only fully utilize the high performance of the master server, but also Under the condition that the load of the master server is high, the reasonable use of the resources of the slave server is realized, and the resource utilization rate is improved.

附图说明Description of drawings

构成本发明的一部分的说明书附图用来提供对本发明的进一步理解,本发明的示意性实施例及其说明用于解释本发明,并不构成对本发明的不当限定。The accompanying drawings forming a part of the present invention are used to provide further understanding of the present invention, and the exemplary embodiments of the present invention and their descriptions are used to explain the present invention, and do not constitute an improper limitation of the present invention.

图1是本发明的流程图;Fig. 1 is the flow chart of the present invention;

具体实施方式Detailed ways

下面结合附图与实施例对本发明作进一步说明。The present invention will be further described below with reference to the accompanying drawings and embodiments.

应该指出,以下详细说明都是例示性的,旨在对本发明提供进一步的说明。除非另有指明,本文使用的所有技术和科学术语具有与本发明所属技术领域的普通技术人员通常理解的相同含义。It should be noted that the following detailed description is exemplary and intended to provide further explanation of the invention. Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.

实施例一Example 1

如图1所示,本发明一种配电网调度任务优化方法,包括以下步骤:As shown in FIG. 1 , a method for optimizing a distribution network scheduling task of the present invention includes the following steps:

调度服务器与主服务器和从服务器建立通信链接;The scheduling server establishes a communication link with the master server and the slave server;

调度服务器接收所下发的配电网的调度任务并存储;The dispatching server receives and stores the dispatched dispatching tasks of the distribution network;

调度服务器获取主服务器和从服务器当前的负载状况;The scheduling server obtains the current load status of the master server and the slave server;

判断主服务器的当前的负载情况是否超过预设的第一阈值,如果没有超过预设的第一阈值,则调度服务器将所接收的配电网的调度任务下发给主服务器;Determine whether the current load condition of the main server exceeds the preset first threshold, and if it does not exceed the preset first threshold, the scheduling server sends the received scheduling task of the distribution network to the main server;

如果主服务器当前的负载情况超过预设的第一阈值但是未超过预设的第二阈值,则调度服务器将所接收的配电网的调度任务按照当前的主服务器和从服务器的负载状况分配给主服务器和从服务器;If the current load condition of the master server exceeds the preset first threshold but does not exceed the preset second threshold, the scheduling server assigns the received scheduling task of the power distribution network to the current load conditions of the master server and the slave server. master server and slave server;

如果主服务器当前的负载情况超过预设的第二阈值,则调度服务器将所接收的配电网的调度任务分配给从服务器;If the current load condition of the master server exceeds the preset second threshold, the scheduling server assigns the received scheduling task of the power distribution network to the slave server;

具体的,调度服务器接收管理员的启动信号;根据启动信号生成注册指令,并将注册指令发送给主服务器和从服务器,主服务器和从服务器在接收到注册指令后,与调度服务器建立通信链接;其中,所述的注册指令中包括含IP地址,IP地址为服务器唯一的标识。Specifically, the scheduling server receives an administrator's activation signal; generates a registration instruction according to the activation signal, and sends the registration instruction to the master server and the slave server, and the master server and the slave server establish a communication link with the scheduling server after receiving the registration instruction; Wherein, the registration instruction includes an IP address, and the IP address is a unique identifier of the server.

另外,所述的调度服务器通过发送指令的方式将配电网的调度任务分配给主服务器和或从服务器。所述的指令中包含配电网的调度任务和服务器的IP地址。In addition, the scheduling server assigns the scheduling tasks of the distribution network to the master server and/or the slave servers by sending instructions. The instruction includes the scheduling task of the distribution network and the IP address of the server.

调度服务器实时获取主服务器和从服务器的负载状况,其中,包括CPU使用、内存使用、IO消耗,调度服务器根据所获取的主/从服务器的CPU使用、内存使用、IO消耗的情况,根据预存的计算公式计算当前的主服务器的总体的负载情况,所述的预存的计算公式为:The scheduling server obtains the load status of the master server and the slave server in real time, including CPU usage, memory usage, and IO consumption. The calculation formula calculates the overall load of the current primary server, and the pre-stored calculation formula is:

Score=A*cpu%+B*IO%+C*men%Score=A*cpu%+B*IO%+C*men%

其中,Score表示负载数值,cpu%表示CPU的使用率,IO%表示IO的消耗率,men%表示内存的使用率,A、B、C分别表示CPU的使用率、IO的消耗率和内存的使用率的权重,其中A、B、C相加和为1,权重越高代表优先级越高,例如,CPU的使用率的情况相比较IO的消耗率而言,CPU的使用率越能够代表服务器的总体的负载情况,则权重系数A则大于B。在本实施例中,对于权重系数不做具体的限定,具体的可按照实际进行设置。例如A、B、C分别为0.5、0.3和0.2,也可以为0.3、0.4和0.3。Among them, Score represents the load value, cpu% represents the CPU usage rate, IO% represents the IO consumption rate, men% represents the memory usage rate, A, B, and C represent the CPU usage rate, IO consumption rate and memory usage respectively. The weight of the usage rate, where the sum of A, B, and C is 1. The higher the weight, the higher the priority. For example, in the case of the CPU usage rate compared to the IO consumption rate, the more representative the CPU usage rate is The overall load of the server, the weight coefficient A is greater than B. In this embodiment, the weight coefficient is not specifically limited, and the specific weight can be set according to the actual situation. For example, A, B, and C are 0.5, 0.3, and 0.2, respectively, or 0.3, 0.4, and 0.3.

进一步的,根据服务器的负载状况的计算公式得到服务器负载数值,一般情况,主服务器的性能是好于从服务器的性能,为了能够充分的利用的主服务器优越的性能,设定第一阈值,根据主服务器的的负载数值与第一阈值进行比较,如果主服务器的当前的负载数值没有超过所预设的第一阈值,则代表主服务器目前为低负载状况,可以接收处理新的配电网的调度任务,则调度服务器将调度中心所下发的调度任务分配给主服务器。在本实施例中,对于第一阈值不做具体的限定,可以按照实际情况进行相应的设置。Further, the server load value is obtained according to the calculation formula of the load condition of the server. In general, the performance of the master server is better than that of the slave server. In order to fully utilize the superior performance of the master server, the first threshold is set according to The load value of the main server is compared with the first threshold value. If the current load value of the main server does not exceed the preset first threshold value, it means that the main server is currently in a low load state and can receive and process the new power distribution network. When scheduling tasks, the scheduling server assigns the scheduling tasks issued by the scheduling center to the main server. In this embodiment, the first threshold is not specifically limited, and may be set accordingly according to actual conditions.

当调度服务器接收到的主服务器的负载数值大于第一预设值但小于第二预设阈值时,则代表当前的主服务器处于中负载状况,则表示主服务器可以接收一定量的调度任务。在本实施例中,第二预设阈值的数值不做具体的限定,可以按照实际的情况进行相应的设置,第二预设阈值大于第一预设阈值。When the load value of the master server received by the scheduling server is greater than the first preset value but smaller than the second preset threshold, it means that the current master server is in a medium load state, which means that the master server can receive a certain amount of scheduling tasks. In this embodiment, the value of the second preset threshold is not specifically limited, and may be set according to actual conditions, and the second preset threshold is greater than the first preset threshold.

调度服务器获取当前的从服务器的负载情况,若此时的从服务器的负载情况小于第一预设值,则将配电网的调度任务分配给从服务器。The scheduling server obtains the current load situation of the slave server, and if the load situation of the slave server at this time is less than the first preset value, the scheduling task of the power distribution network is allocated to the slave server.

若此时的从服务器的负载情况不小于第一预设阈值,则调度服务器根据此时的主服务器和从服务器的负载情况以及当前配电网的调度任务量进行调度任务的分配,具体为:If the load situation of the slave server at this time is not less than the first preset threshold, the scheduling server will allocate the scheduling tasks according to the load situation of the master server and the slave server at this time and the amount of scheduling tasks of the current distribution network, specifically:

确定配电网的调度任务的任务量Z,判断所述的调度任务量Z是否不小于2,若配电网的调度任务量Z小于2,因为主服务器的性能好于从服务器,因此调度服务器将配电网的调度任务分配给主服务器;Determine the task volume Z of the scheduling task of the distribution network, and judge whether the scheduling task volume Z is not less than 2. If the scheduling task volume Z of the distribution network is less than 2, because the performance of the master server is better than that of the slave server, so the scheduling server Allocate the scheduling tasks of the distribution network to the main server;

若配电网的调度任务量Z不小于2,则将待分配的配电网的调度任务分为两组,每组至少包括一个所述的待分配的配电网的调度任务,其中配电网的调度任务的分组根据当前的主服务器和从服务器的负载状态进行分组。If the amount of dispatching tasks Z of the distribution network is not less than 2, the dispatching tasks of the distribution network to be allocated are divided into two groups, and each group includes at least one dispatching task of the distribution network to be allocated. The scheduling tasks of the network are grouped according to the current load status of the master server and the slave server.

具体的配电网的调度任务的分组为:The specific grouping of the scheduling tasks of the distribution network is as follows:

Figure BDA0003282721080000071
Figure BDA0003282721080000071

Figure BDA0003282721080000072
Figure BDA0003282721080000072

其中,T1为主服务器待接收的配电网的调度任务量,T2为从服务器待接收的配电网的调度任务的任务量,S1为主服务器当前的负载数值,S2为从服务器当前的负载数值,T为当前待分配的配电网的调度任务总量,,T1、T2为整数,具体的取舍规则不做具体的限定,例如,可以根据四舍五入的方式进行取舍。Among them, T1 is the task amount of the distribution network scheduling task to be received by the master server, T2 is the task amount of the distribution network scheduling task to be received by the slave server, S1 is the current load value of the master server, and S2 is the slave server. The current load value of the server, T is the total amount of scheduling tasks of the distribution network currently to be allocated, and T 1 and T 2 are integers.

进一步的,当调度服务器获取的当前的主服务器的负载状态超过预设的第二阈值,则将配电网的调度任务分配给从服务器。Further, when the current load state of the primary server obtained by the scheduling server exceeds the preset second threshold, the scheduling task of the power distribution network is allocated to the secondary server.

另外,需要说明的是,调度服务器在进行配电网的调度任务的分配时对每一个调度任务生成调度指令,所述的调度指令包含服务器的IP地址,根据所述的IP地址发送给相应的服务器进行处理。In addition, it should be noted that the scheduling server generates a scheduling instruction for each scheduling task when allocating the scheduling tasks of the distribution network, and the scheduling instruction includes the IP address of the server, and is sent to the corresponding server for processing.

另外,还包括上述调度服务器的对配电网的调度任务的分配生是在主服务器和从服务器未发生故障的情况的进行的。In addition, the assignment of the scheduling tasks to the distribution network, which also includes the above-mentioned scheduling server, is performed when the master server and the slave server are not faulty.

当调度服务器检测到主服务器发生故障,则将当前的配电网的调度任务全部分配给从服务器;When the scheduling server detects that the primary server is faulty, it will assign all the scheduling tasks of the current distribution network to the secondary server;

当调度服务器检测到从服务器发生故障时,则当前的配电网的调度任务的分配则全部分配给主服务器。When the scheduling server detects that the slave server is faulty, the current distribution network scheduling tasks are all allocated to the master server.

当调度服务器检测到主从服务器均发生故障,则调度服务器存储待分配的配电网的调度任务并都等待主/从服务器故障解除。When the scheduling server detects that both the master and the slave servers are faulty, the scheduling server stores the scheduling tasks of the distribution network to be allocated and waits for the master/slave server to resolve the fault.

还包括所述的主服务器和从服务器执行调度服务器所分配的配电网的调度任务。It also includes that the master server and the slave server perform scheduling tasks of the distribution network assigned by the scheduling server.

实施例二Embodiment 2

本实施例提供了一种配电网调度任务优化系统,其包括:This embodiment provides a distribution network scheduling task optimization system, which includes:

调度服务器,其被配置为:建立与主服务器和从服务器的通信链接;接收调度中心所下发的配电网的调度任务;获取主服务器和从服务器当前的负载状况;并对主服务器和从服务器的负载状况进行阈值的判断;The scheduling server is configured to: establish a communication link with the master server and the slave server; receive the scheduling task of the distribution network issued by the scheduling center; obtain the current load status of the master server and the slave server; The load status of the server is judged by the threshold;

主服务器,其被配置为:接收调度服务器所下发的配电网的调度任务并执行;The main server, which is configured to: receive and execute the scheduling task of the distribution network issued by the scheduling server;

从服务器,其被配置为:接收调度服务器所下发的配电网的调度任务并执行。The slave server is configured to: receive and execute the scheduling task of the distribution network issued by the scheduling server.

实施例三Embodiment 3

本实施例提供了一种计算机可读存储介质,其上存储有计算机程序,该程序被处理器执行时实现如实施例一所述的一种配电网调度任务优化方法中的步骤。This embodiment provides a computer-readable storage medium on which a computer program is stored, and when the program is executed by a processor, implements the steps in the method for optimizing a distribution network scheduling task as described in the first embodiment.

实施例四Embodiment 4

本实施例提供了一种计算机设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述程序时实现如实施例一所述的一种配电网调度任务优化方法的步骤。This embodiment provides a computer device, including a memory, a processor, and a computer program stored in the memory and running on the processor, where the processor implements the one described in the first embodiment when the processor executes the program Steps of an optimization method for distribution network scheduling tasks.

本领域内的技术人员应明白,本发明的实施例可提供为方法、系统、或计算机程序产品。因此,本发明可采用硬件实施例、软件实施例、或结合软件和硬件方面的实施例的形式。而且,本发明可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器和光学存储器等)上实施的计算机程序产品的形式。As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the invention may take the form of a hardware embodiment, a software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media having computer-usable program code embodied therein, including but not limited to disk storage, optical storage, and the like.

本发明是参照根据本发明实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block in the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to the processor of a general purpose computer, special purpose computer, embedded processor or other programmable data processing device to produce a machine such that the instructions executed by the processor of the computer or other programmable data processing device produce Means for implementing the functions specified in a flow or flow of a flowchart and/or a block or blocks of a block diagram.

以上所述仅为本发明的优选实施例而已,并不用于限制本发明,对于本领域的技术人员来说,本发明可以有各种更改和变化。凡在本发明的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。The above descriptions are only preferred embodiments of the present invention, and are not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and changes. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included within the protection scope of the present invention.

Claims (10)

1. A power distribution network scheduling task optimization method is characterized by comprising the following steps:
the dispatching server establishes communication links with the master server and the slave server;
the dispatching server receives the dispatched dispatching task of the power distribution network;
the scheduling server acquires the current load conditions of the master server and the slave server; the load condition comprises CPU utilization rate, memory utilization rate and IO consumption rate;
and judging whether the current load condition of the master server exceeds a preset first threshold value or not, and if the current load condition of the master server exceeds the preset first threshold value but does not exceed a preset second threshold value, the scheduling server distributes the received scheduling tasks of the power distribution network to the master server and the slave server according to the current load conditions of the master server and the slave server.
2. The method as claimed in claim 1, further comprising the step of sending the received scheduling task of the distribution network to the main server by the scheduling server if the current load condition of the main server does not exceed the preset first threshold.
3. The method as claimed in claim 1, further comprising the step of the dispatch server allocating the received dispatch task for the distribution network to the slave server if the current load condition of the master server exceeds a second predetermined threshold.
4. The method according to claim 1, wherein when the current load condition of the master server exceeds a preset first threshold but does not exceed a preset second threshold, the master server further determines whether the load condition of the slave server exceeds the preset first threshold, and if the load condition of the slave server does not exceed the preset first threshold, the dispatch server allocates the dispatching tasks of the distribution network according to the load conditions of the master server and the slave server.
5. The method as claimed in claim 5, wherein the step of the dispatch server distributing the dispatching task of the distribution network according to the load conditions of the master server and the slave servers comprises the following steps:
determining the dispatched scheduling task quantity of the power distribution network, judging whether the scheduling task quantity of the power distribution network is not less than 2, and if the scheduling task quantity of the power distribution network is less than 2, distributing the scheduling task of the power distribution network to a main server;
if the scheduling task amount of the power distribution network is not less than 2, the scheduling tasks of the power distribution network to be distributed are divided into two groups, each group at least comprises one scheduling task of the power distribution network to be distributed, and the groups of the scheduling tasks of the power distribution network are grouped according to a preset formula of the load conditions of the current master server and the slave server.
6. The method according to claim 1, wherein the predetermined formula is:
Figure FDA0003282721070000021
Figure FDA0003282721070000022
wherein ,T1Scheduling task volume, T, of the distribution network to be received for the primary server2For the task volume of scheduling tasks of the distribution network to be received from the server, S1Is the current load value of the primary server, S2The current load value of the slave server, T is the total scheduling task amount of the power distribution network to be distributed currently, T1、T2Are integers.
7. The method as claimed in claim 6, wherein the load value calculation formula is:
Score=A*cpu%+B*IO%+C*men%
where CPU% represents a usage rate of the CPU, IO% represents a consumption rate of the IO, men% represents a usage rate of the memory, and A, B, C represents weights of the usage rate of the CPU, the consumption rate of the IO, and the usage rate of the memory, respectively.
8. A power distribution network scheduling task optimization system is characterized by comprising:
a dispatch server configured to: establishing a communication link with a master server and a slave server; receiving a scheduling task of the power distribution network issued by a scheduling center; acquiring the current load conditions of a master server and a slave server; judging the threshold value of the load conditions of the main server and the slave server;
a primary server configured to: receiving and executing a scheduling task of the power distribution network issued by a scheduling server;
a slave server configured to: and receiving and executing the scheduling task of the power distribution network issued by the scheduling server.
9. A computer-readable storage medium, on which a computer program is stored, which program, when being executed by a processor, carries out the steps of a method for scheduling task optimization of an electric distribution network according to any one of claims 1 to 7.
10. A processing apparatus comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor when executing the program performs the steps of a method of scheduling task optimization for a power distribution network according to any of claims 1-7.
CN202111137762.2A 2021-09-27 2021-09-27 Power distribution network scheduling task optimization method and system Active CN113822485B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111137762.2A CN113822485B (en) 2021-09-27 2021-09-27 Power distribution network scheduling task optimization method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111137762.2A CN113822485B (en) 2021-09-27 2021-09-27 Power distribution network scheduling task optimization method and system

Publications (2)

Publication Number Publication Date
CN113822485A true CN113822485A (en) 2021-12-21
CN113822485B CN113822485B (en) 2023-10-20

Family

ID=78921330

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111137762.2A Active CN113822485B (en) 2021-09-27 2021-09-27 Power distribution network scheduling task optimization method and system

Country Status (1)

Country Link
CN (1) CN113822485B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115348322A (en) * 2022-07-11 2022-11-15 深圳市九洲电器有限公司 Data processing method, networking device and computer readable storage medium

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005190133A (en) * 2003-12-25 2005-07-14 Nippon Telegr & Teleph Corp <Ntt> Method for allocating task, method for allocating resource, device for allocating task, device for allocating resource, program, and recording medium having the program recorded thereon
US20070233866A1 (en) * 2006-03-28 2007-10-04 Karen Appleby Method and system for dynamically allocating servers to compute-resources using capacity thresholds
US20090222544A1 (en) * 2008-03-03 2009-09-03 Microsoft Corporation Framework for joint analysis and design of server provisioning and load dispatching for connection-intensive server
CN104009932A (en) * 2014-04-30 2014-08-27 易云捷讯科技(北京)有限公司 Traffic any-ratio load method based on Openflow rule
US20170019300A1 (en) * 2015-07-13 2017-01-19 Senao Networks, Inc. Method and system for auto distribution of workload among a plurality of servers which run web services
CN106411971A (en) * 2015-07-29 2017-02-15 腾讯科技(深圳)有限公司 Load regulation method and device
CN107026907A (en) * 2017-03-30 2017-08-08 上海斐讯数据通信技术有限公司 A kind of load-balancing method, load equalizer and SiteServer LBS
CN107426109A (en) * 2017-06-27 2017-12-01 上海华为技术有限公司 A kind of traffic scheduling method, VNF modules and flow scheduling server
US20190050036A1 (en) * 2017-08-09 2019-02-14 Equinix, Inc. Rack level power control
CN109408227A (en) * 2018-09-19 2019-03-01 平安科技(深圳)有限公司 Load-balancing method, device and storage medium
US20200050485A1 (en) * 2018-08-13 2020-02-13 Twitter, Inc. Load balancing deterministically-subsetted processing resources using fractional loads
CN110955524A (en) * 2019-11-27 2020-04-03 北京网聘咨询有限公司 Optimized scheduling method for server
CN111367693A (en) * 2020-03-13 2020-07-03 苏州浪潮智能科技有限公司 Method, system, device and medium for scheduling plug-in tasks based on message queue

Patent Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005190133A (en) * 2003-12-25 2005-07-14 Nippon Telegr & Teleph Corp <Ntt> Method for allocating task, method for allocating resource, device for allocating task, device for allocating resource, program, and recording medium having the program recorded thereon
US20070233866A1 (en) * 2006-03-28 2007-10-04 Karen Appleby Method and system for dynamically allocating servers to compute-resources using capacity thresholds
US20090222544A1 (en) * 2008-03-03 2009-09-03 Microsoft Corporation Framework for joint analysis and design of server provisioning and load dispatching for connection-intensive server
CN104009932A (en) * 2014-04-30 2014-08-27 易云捷讯科技(北京)有限公司 Traffic any-ratio load method based on Openflow rule
US20170019300A1 (en) * 2015-07-13 2017-01-19 Senao Networks, Inc. Method and system for auto distribution of workload among a plurality of servers which run web services
CN106411971A (en) * 2015-07-29 2017-02-15 腾讯科技(深圳)有限公司 Load regulation method and device
CN107026907A (en) * 2017-03-30 2017-08-08 上海斐讯数据通信技术有限公司 A kind of load-balancing method, load equalizer and SiteServer LBS
CN107426109A (en) * 2017-06-27 2017-12-01 上海华为技术有限公司 A kind of traffic scheduling method, VNF modules and flow scheduling server
US20190050036A1 (en) * 2017-08-09 2019-02-14 Equinix, Inc. Rack level power control
US20200050485A1 (en) * 2018-08-13 2020-02-13 Twitter, Inc. Load balancing deterministically-subsetted processing resources using fractional loads
CN109408227A (en) * 2018-09-19 2019-03-01 平安科技(深圳)有限公司 Load-balancing method, device and storage medium
CN110955524A (en) * 2019-11-27 2020-04-03 北京网聘咨询有限公司 Optimized scheduling method for server
CN111367693A (en) * 2020-03-13 2020-07-03 苏州浪潮智能科技有限公司 Method, system, device and medium for scheduling plug-in tasks based on message queue

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
张哲宇;周润林;孙斌;胡燕;: "XMPP协议的数据分发网络的负载均衡算法", 北京邮电大学学报, no. 1 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115348322A (en) * 2022-07-11 2022-11-15 深圳市九洲电器有限公司 Data processing method, networking device and computer readable storage medium
CN115348322B (en) * 2022-07-11 2023-07-18 深圳市九洲电器有限公司 Data processing method, networking equipment and computer readable storage medium

Also Published As

Publication number Publication date
CN113822485B (en) 2023-10-20

Similar Documents

Publication Publication Date Title
CN102724277B (en) The method of live migration of virtual machine and deployment, server and group system
CN101447939B (en) Functional distribution method and load balancer
US9703610B2 (en) Extensible centralized dynamic resource distribution in a clustered data grid
CN102075425B (en) Business allocation method and load balancer
CN113064712B (en) Micro-service optimization deployment control method, system and cluster based on cloud edge environment
CN103401947A (en) Method and device for allocating tasks to multiple servers
CN110221920B (en) Deployment method, device, storage medium and system
CN104253850A (en) Distributed task scheduling method and system
CN105159775A (en) Load balancer based management system and management method for cloud computing data center
CN112817728B (en) Task scheduling method, network device and storage medium
CN107222531A (en) A kind of container cloud resource dispatching method
CN101951411A (en) Cloud scheduling system and method and multistage cloud scheduling system
CN104615498A (en) Dynamic load balancing method of trunking system based on task immigration
CN108282526B (en) Dynamic allocation method and system for servers between double clusters
US20120233313A1 (en) Shared scaling server system
CN111614735B (en) Novel fog computing architecture based on weighted round robin algorithm and task scheduling method thereof
CN104268007A (en) Distributed event request scheduling method and system
CN113822485A (en) A method and system for optimizing distribution network scheduling tasks
CN105207856A (en) Load balancing system and method based on SDN virtual switch
CN108347341A (en) A kind of acceleration capacity method of adjustment and device for adjusting virtual machine acceleration capacity
CN112882827A (en) Method, electronic device and computer program product for load balancing
CN102819458B (en) A kind of processing method and system of distributed operation order
CN106302249B (en) A kind of Dynamic Bandwidth Allocation system and distribution method
CN104899097A (en) Thread allocation quantity calculating method and apparatus
CN113590294B (en) Self-adaptive and rule-guided distributed scheduling method

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