CN118819864A - Resource unified scheduling method and system for multiple types of loads - Google Patents

Resource unified scheduling method and system for multiple types of loads Download PDF

Info

Publication number
CN118819864A
CN118819864A CN202411295538.XA CN202411295538A CN118819864A CN 118819864 A CN118819864 A CN 118819864A CN 202411295538 A CN202411295538 A CN 202411295538A CN 118819864 A CN118819864 A CN 118819864A
Authority
CN
China
Prior art keywords
application
server
resource
target
current target
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
CN202411295538.XA
Other languages
Chinese (zh)
Other versions
CN118819864B (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.)
Beijing Jh Innovation Software Co ltd
Original Assignee
Beijing Jh Innovation Software 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 Beijing Jh Innovation Software Co ltd filed Critical Beijing Jh Innovation Software Co ltd
Priority to CN202411295538.XA priority Critical patent/CN118819864B/en
Publication of CN118819864A publication Critical patent/CN118819864A/en
Application granted granted Critical
Publication of CN118819864B publication Critical patent/CN118819864B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • G06F9/505Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals considering the load
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/4881Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5061Partitioning or combining of resources
    • G06F9/5072Grid computing
    • 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
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mathematical Physics (AREA)
  • Computer And Data Communications (AREA)
  • Multi Processors (AREA)

Abstract

The application discloses a unified scheduling method and a unified scheduling system for resources of multiple types of loads, which relate to the field of data processing, and the method comprises the following steps: receiving application tasks of different types of target workload types and resource demand information corresponding to the application tasks of each target workload type, wherein the application tasks of the different types of target workload types at least comprise graphic application session tasks; searching candidate servers meeting the resource requirement information corresponding to the application task of the current target job load type in a cluster resource information table according to the resource requirement information corresponding to the application task of the current target job load type; and sending the application task of the current target workload type and the resource demand information corresponding to the application task of the current target workload type to the server with the lowest load selected from the candidate servers. The application can improve the efficiency of connecting the terminal equipment with the server and the overall utilization rate of the server resources in the cluster.

Description

多类型负载的资源统一调度方法及系统Resource unified scheduling method and system for multiple types of loads

技术领域Technical Field

本申请涉及数据处理领域,特别是涉及一种多类型负载的资源统一调度方法及系统。The present application relates to the field of data processing, and in particular to a method and system for unified resource scheduling of multiple types of loads.

背景技术Background Art

用户通过终端设备使用应用时,往往是需要启用服务器来进行相关操作的。When users use applications through terminal devices, they often need to enable the server to perform related operations.

目前,用户会通过终端设备在服务器集群中自找一台服务器进行尝试连接以启动图形应用,如果尝试连接的服务器的所有资源均已被其他终端设备占用,那么,表明终端设备尝试失败,然后终端设备会再去尝试着连接其他的服务器,直至与某一个服务器连接成功,以让该服务器启动终端设备的图形应用。Currently, users will use terminal devices to find a server in the server cluster and try to connect to it to start the graphics application. If all resources of the server being connected are occupied by other terminal devices, it means that the terminal device's attempt has failed. The terminal device will then try to connect to other servers until it successfully connects to a server, allowing the server to start the terminal device's graphics application.

但该种方式,由于终端设备可能需要多次尝试着去连接服务器,从而使得终端设备的连接时间过长,启动服务器效率较低,并且还会出现不同的终端设备使用同一台服务器来运行应用任务,从而导致有些服务器很忙,有些服务器闲置,集群中服务器资源负载不均衡。However, in this way, since the terminal device may need to try to connect to the server multiple times, the connection time of the terminal device is too long, the efficiency of starting the server is low, and different terminal devices may use the same server to run application tasks, resulting in some servers being very busy and some servers being idle, and the server resource load in the cluster is unbalanced.

发明内容Summary of the invention

本申请的目的是提供一种多类型负载的资源统一调度方法及系统,可提升终端设备连接服务器的效率以及集群中服务器资源的整体利用率。The purpose of this application is to provide a method and system for unified resource scheduling of multiple types of loads, which can improve the efficiency of terminal devices connecting to servers and the overall utilization of server resources in a cluster.

为实现上述目的,本申请提供了如下方案:To achieve the above objectives, this application provides the following solutions:

第一方面,本申请提供了一种多类型负载的资源统一调度方法,所述多类型负载的资源统一调度方法 包括:In a first aspect, the present application provides a method for unified resource scheduling of multiple types of loads, and the method for unified resource scheduling of multiple types of loads includes:

接收不同类型的目标作业负载类型的应用任务,以及各个所述目标作业负载类型的应用任务对应的资源需求信息,其中,所述不同类型的目标作业负载类型的应用任务至少包括图形应用会话任务;Receiving application tasks of different types of target workload types and resource requirement information corresponding to each of the application tasks of the target workload types, wherein the application tasks of the different types of target workload types at least include a graphics application session task;

根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;所述集群资源信息表中包括:集群中,各个服务器的属性信息、已用资源信息和空闲资源信息;According to the resource demand information corresponding to the application task of the current target workload type, searching the cluster resource information table for a candidate server that meets the resource demand information corresponding to the application task of the current target workload type; the cluster resource information table includes: attribute information, used resource information and idle resource information of each server in the cluster;

在所述候选服务器中选择负载最低的服务器作为第一目标服务器;Selecting a server with the lowest load among the candidate servers as the first target server;

将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第一目标服务器,以使所述第一目标服务器运行所述当前目标作业负载类型的应用任务。The application tasks of the current target workload type and resource requirement information corresponding to the application tasks of the current target workload type are sent to the first target server, so that the first target server runs the application tasks of the current target workload type.

第二方面,本申请提供了一种多类型负载的资源统一调度系统,所述多类型负载的资源统一调度系统包括:In a second aspect, the present application provides a unified resource scheduling system for multiple types of loads, and the unified resource scheduling system for multiple types of loads includes:

终端设备、调度服务器和包括多个服务器的集群,其中,多个所述服务器包括第一目标服务器;A terminal device, a scheduling server and a cluster including a plurality of servers, wherein the plurality of servers include a first target server;

所述终端设备,用于向所述调度服务器发送不同类型的目标作业负载类型的应用任务,以及各个所述目标作业负载类型的应用任务对应的资源需求信息,其中,所述不同类型的目标作业负载类型的应用任务至少包括图形应用会话任务;The terminal device is used to send application tasks of different types of target workload types and resource demand information corresponding to each application task of the target workload type to the scheduling server, wherein the application tasks of different types of target workload types at least include graphic application session tasks;

所述调度服务器,用于根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;所述集群资源信息表中包括:集群中,各个服务器的属性信息、已用资源信息和空闲资源信息;The scheduling server is used to search for a candidate server that meets the resource demand information corresponding to the application task of the current target workload type in the cluster resource information table according to the resource demand information corresponding to the application task of the current target workload type; the cluster resource information table includes: attribute information, used resource information and idle resource information of each server in the cluster;

所述调度服务器,用于在所述候选服务器中选择负载最低的服务器作为第一目标服务器,并将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第一目标服务器;The scheduling server is used to select the server with the lowest load from the candidate servers as the first target server, and send the application tasks of the current target workload type and the resource demand information corresponding to the application tasks of the current target workload type to the first target server;

所述第一目标服务器,用于在接收到所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息后,根据所述当前目标作业负载类型的应用任务对应的资源需求信息运行所述当前目标作业负载类型的应用任务。The first target server is used to run the application task of the current target job load type according to the resource requirement information corresponding to the application task of the current target job load type after receiving the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type.

根据本申请提供的具体实施例,本申请公开了以下技术效果:According to the specific embodiments provided in this application, this application discloses the following technical effects:

本申请提供了一种多类型负载的资源统一调度方法及系统,所述方法包括:接收不同类型的目标作业负载类型的应用任务,以及各个所述目标作业负载类型的应用任务对应的资源需求信息,其中,所述不同类型的目标作业负载类型的应用任务至少包括图形应用会话任务;根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;所述集群资源信息表中包括:集群中,各个服务器的属性信息、已用资源信息和空闲资源信息;在所述候选服务器中选择负载最低的服务器作为第一目标服务器;将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第一目标服务器,以使所述第一目标服务器运行所述当前目标作业负载类型的应用任务。这样,在为终端设备分配服务器时,调度服务器可以直接从集群资源信息表查找可以满足目标作业的资源需求信息服务器,这样终端设备就可以直接与该目标服务器连接,以让该目标服务器为终端设备处理目标作业,而无需像相关技术中,需要通过终端设备逐一去尝试与集群中的每一个服务器进行连接,直至成功建立连接,从而提升了终端设备连接服务器的效率,再者,调度服务器选择的服务器是集群中负载最低的服务器,从而可以提升集群中服务器资源的整体利用率。The present application provides a method and system for unified resource scheduling of multiple types of loads, the method comprising: receiving application tasks of different types of target job load types, and resource requirement information corresponding to each of the application tasks of the target job load types, wherein the application tasks of the different types of target job load types include at least a graphic application session task; searching a cluster resource information table for a candidate server that meets the resource requirement information corresponding to the application task of the current target job load type according to the resource requirement information corresponding to the application task of the current target job load type; the cluster resource information table comprising: attribute information, used resource information and idle resource information of each server in the cluster; selecting a server with the lowest load from the candidate servers as a first target server; and sending the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type to the first target server, so that the first target server runs the application task of the current target job load type. In this way, when allocating a server to a terminal device, the scheduling server can directly search the cluster resource information table for a server that can meet the resource demand information of the target job, so that the terminal device can directly connect to the target server to allow the target server to process the target job for the terminal device. There is no need, as in the related technology, for the terminal device to try to connect to each server in the cluster one by one until a successful connection is established, thereby improving the efficiency of the terminal device connecting to the server. Furthermore, the server selected by the scheduling server is the server with the lowest load in the cluster, thereby improving the overall utilization of server resources in the cluster.

附图说明BRIEF DESCRIPTION OF THE DRAWINGS

为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

图1为本申请一实施例示出的多类型负载的资源统一调度方法的流程图;FIG1 is a flow chart of a method for unified resource scheduling of multiple types of loads shown in an embodiment of the present application;

图2为本申请一实施例示出的相关技术中启动图形应用会话任务的流程图;FIG2 is a flowchart of starting a graphics application session task in a related art according to an embodiment of the present application;

图3为本申请一实施例示出的本公开中启动图形应用会话任务的流程图;FIG3 is a flow chart of starting a graphics application session task in the present disclosure, shown in one embodiment of the present application;

图4为本申请一实施例提供的多类型负载的资源统一调度系统功能模块架构图;FIG4 is a functional module architecture diagram of a resource unified scheduling system for multiple types of loads provided in an embodiment of the present application;

图5为本申请一实施例提供的一种多类型负载的资源统一调度装置的功能模块示意图;FIG5 is a schematic diagram of functional modules of a resource unified scheduling device for multiple types of loads provided by an embodiment of the present application;

图6为本申请一实施例提供的一种计算机设备的结构示意图。FIG6 is a schematic diagram of the structure of a computer device provided in an embodiment of the present application.

具体实施方式DETAILED DESCRIPTION

下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

使本申请的上述目的、特征和优点能够更加明显易懂,下面结合附图和具体实施方式对本申请作进一步详细的说明。In order to make the above-mentioned objects, features and advantages of the present application more obvious and easy to understand, the present application is further described in detail below with reference to the accompanying drawings and specific implementation methods.

图1为本申请一实施例示出的多类型负载的资源统一调度方法的流程图,该多类型负载的资源统一调度方法包括以下步骤S101-S102:FIG1 is a flow chart of a method for unified resource scheduling of multiple types of loads shown in an embodiment of the present application. The method for unified resource scheduling of multiple types of loads includes the following steps S101-S102:

在步骤S101中,接收不同类型的目标作业负载类型的应用任务,以及各个目标作业负载类型的应用任务对应的资源需求信息,其中,不同类型的目标作业负载类型的应用任务至少包括图形应用会话任务。In step S101, application tasks of different target workload types and resource requirement information corresponding to the application tasks of each target workload type are received, wherein the application tasks of different target workload types at least include graphic application session tasks.

其中,图形应用会话任务包括数字孪生类应用及图形渲染类应用。Among them, graphics application session tasks include digital twin applications and graphics rendering applications.

目标作业负载类型的应用任务还可以包括:HPC并行计算任务、批处理计算任务、AI模型训练任务和AI模型推理任务。Application tasks of the target workload type may also include: HPC parallel computing tasks, batch computing tasks, AI model training tasks, and AI model reasoning tasks.

资源需求信息包括:CPU数量、内存大小、操作系统版本、GPU的型号、GPU数量、GPU模式和图形渲染库类型。Resource requirement information includes: CPU quantity, memory size, operating system version, GPU model, GPU quantity, GPU mode, and graphics rendering library type.

也即,目标作业所需资源信息除了常见的CPU数量、内存大小和操作系统版本之外,还包括GPU的型号、GPU数量(分为流处理器数量和显存数量)、GPU模式(渲染/计算/平衡模式),以及图形渲染库类型,如DirectX、OpenGL、Vulkan。That is, in addition to the common CPU quantity, memory size, and operating system version, the resource information required for the target job also includes the GPU model, the number of GPUs (divided into the number of stream processors and the number of video memories), the GPU mode (rendering/computing/balanced mode), and the type of graphics rendering library, such as DirectX, OpenGL, and Vulkan.

本公开给出几个应用任务以及应用任务对应的资源需求信息的例子,Siemens UGNX,Unreal Engine,PyTorch模型训练,matlab并行计算。This disclosure provides several examples of application tasks and the resource requirement information corresponding to the application tasks, including Siemens UGNX, Unreal Engine, PyTorch model training, and MATLAB parallel computing.

1)应用任务为图形应用会话任务(图形渲染类),以工业设计应用Siemens UG NX的图形会话为例,其对应的资源需求信息如下:1) The application task is a graphics application session task (graphics rendering class). Taking the graphics session of the industrial design application Siemens UG NX as an example, its corresponding resource requirement information is as follows:

CPU型号:“x86, amd64”;CPU model: "x86, amd64";

CPU核数:4;Number of CPU cores: 4

内存数量:32GB;Memory: 32GB

操作系统:“Windows Server 2016”;Operating system: "Windows Server 2016"

GPU型号:“Quadro M4000”;GPU model: "Quadro M4000";

GPU数量:“gmem=8GB, cuda_core=1000”;Number of GPUs: “gmem=8GB, cuda_core=1000”;

GPU模式:“渲染”;GPU mode: "Rendering";

渲染库类型:“DirectX 12”。Rendering library type: "DirectX 12".

2)应用任务为图形应用会话任务(数字孪生类),以游戏引擎Unreal Engine的图形会话为例,其对应的资源需求信息如下:2) The application task is a graphics application session task (digital twin class). Taking the graphics session of the game engine Unreal Engine as an example, its corresponding resource requirement information is as follows:

CPU型号:“x86, amd64”;CPU model: "x86, amd64";

CPU核数:8;Number of CPU cores: 8

内存数量:128GB;Memory quantity: 128GB

操作系统:“Ubuntu 22.04”;Operating system: “Ubuntu 22.04”;

GPU型号:“RTX A40”;GPU model: "RTX A40";

GPU数量:“gmem=48GB, cuda_core=10000”;Number of GPUs: “gmem=48GB, cuda_core=10000”;

GPU模式:“渲染”;GPU mode: "Rendering";

渲染库类型:“Vulkan 1.3”。Rendering library type: "Vulkan 1.3".

3)应用任务为并行计算应用,以气候预测的科学计算应用WRF为例,其对应的资源需求信息如下:3) The application task is a parallel computing application. Taking the scientific computing application WRF for climate prediction as an example, its corresponding resource demand information is as follows:

CPU型号:“aarch64”;CPU model: "aarch64";

CPU核数:256;Number of CPU cores: 256;

内存数量:512GB;Memory: 512GB

操作系统:“Kylin Linux Server V10 SP1”。Operating system: “Kylin Linux Server V10 SP1”.

4)应用任务为批处理计算应用,以芯片设计的EDA应用Cadence Virtuoso为例,其对应的资源需求信息如下:4) The application task is a batch computing application. Taking Cadence Virtuoso, an EDA application for chip design, as an example, its corresponding resource requirement information is as follows:

CPU型号:“x86, amd64”;CPU model: "x86, amd64";

CPU核数:64;Number of CPU cores: 64;

内存数量:256GB;Memory: 256GB

操作系统:“CentOS 7”;Operating system: "CentOS 7";

GPU型号:“RTX A4000”;GPU model: "RTX A4000";

GPU数量:“gmem=4GB, cuda_core=500”;Number of GPUs: "gmem=4GB, cuda_core=500";

GPU模式:“平衡”;GPU Mode: "Balanced";

渲染库类型:“OpenGL 2.1”。Rendering library type: "OpenGL 2.1".

5)应用任务为AI模型训练,以大模型训练框架Deepspeed为例,其对应的资源需求信息如下:5) The application task is AI model training. Taking the large model training framework Deepspeed as an example, its corresponding resource demand information is as follows:

CPU型号:“aarch64”;CPU model: "aarch64";

CPU核数:8;Number of CPU cores: 8

内存数量:1024GB;Memory: 1024GB

操作系统:“Ubuntu 22.04”;Operating system: “Ubuntu 22.04”;

GPU型号:“NVIDIA A800”;GPU model: “NVIDIA A800”;

GPU数量:“gmem=640GB, cuda_core=100000”;Number of GPUs: “gmem=640GB, cuda_core=100000”;

GPU模式:“计算”。GPU Mode: "Compute".

6)应用任务为AI模型推理,以深度学习框架Pytorch为例,其对应的资源需求信息如下:6) The application task is AI model reasoning. Taking the deep learning framework Pytorch as an example, the corresponding resource requirement information is as follows:

CPU型号:“aarch64”;CPU model: "aarch64";

CPU核数:4;Number of CPU cores: 4

内存数量:128GB;Memory quantity: 128GB

操作系统:“Ubuntu 20.04”;Operating system: “Ubuntu 20.04”;

GPU型号:“Ascend 310b”;GPU model: "Ascend 310b";

GPU数量:“gmem=10GB, cuda_core=2000”;Number of GPUs: “gmem=10GB, cuda_core=2000”;

GPU模式:“计算”。GPU Mode: "Compute".

现有的HPC集群资源调度软件,比如IBM Spectrum LSF和Slurm调度软件,只能调度并行计算任务和批处理计算任务,不能调度数字孪生类应用任务、图形渲染类应用任务、AI模型训练任务或者AI模型推理任务。容器集群最常用的K8S开源管理软件只能按pod来编排和调度管理经过容器封装的计算任务和AI模型训练任务或者AI模型推理任务,不能调度HPC并行计算作业任务,更不能调度管理数字孪生应用任务和图形渲染类应用任务。云桌面系统软件,比如世界最领先的Citrix和VMware中,只有云桌面会话和远程图形应用会话的管理功能,没有按GPU资源来调度云桌面或图形应用会话任务,更不支持其他类型的计算任务或AI模型训练推理任务的管理和资源调度。本公开可以在公有云和私有云的服务器集群中统一调度Windows和Linux数字孪生类应用、图形渲染类应用和AI模型训练任务及AI模型推理任务,还有传统的并行计算任务和批处理计算任务,进一步的,本公开可以将云端集群中运行的数字孪生类应用任务或图形渲染类应用任务作为一种GPU资源的负载任务抽象出来,作为远程图形会话作业,跟其他负载类型一起进行调度和管理。Existing HPC cluster resource scheduling software, such as IBM Spectrum LSF and Slurm scheduling software, can only schedule parallel computing tasks and batch computing tasks, but cannot schedule digital twin application tasks, graphics rendering application tasks, AI model training tasks, or AI model reasoning tasks. The most commonly used K8S open source management software for container clusters can only orchestrate and schedule container-encapsulated computing tasks and AI model training tasks or AI model reasoning tasks by pod, but cannot schedule HPC parallel computing tasks, let alone digital twin application tasks and graphics rendering application tasks. Cloud desktop system software, such as the world's leading Citrix and VMware, only has the management function of cloud desktop sessions and remote graphics application sessions, but does not schedule cloud desktop or graphics application session tasks by GPU resources, and does not support the management and resource scheduling of other types of computing tasks or AI model training and reasoning tasks. The present disclosure can uniformly schedule Windows and Linux digital twin applications, graphics rendering applications, AI model training tasks, AI model reasoning tasks, and traditional parallel computing tasks in server clusters of public clouds and private clouds. Furthermore, the present disclosure can abstract digital twin application tasks or graphics rendering application tasks running in a cloud cluster as a load task of a GPU resource, and schedule and manage them together with other load types as remote graphics session jobs.

在本公开中,将数字孪生类应用任务及图形渲染类应用任务、AI模型训练任务、AI模型推理任务、HPC并行计算任务、批处理计算任务都抽象为“作业”对象,终端设备使用调度服务器中调度系统的命令行或者通过图形界面调用调度系统的API,来向调度服务器提交一个作业,通过命令行参数或者作业描述文件说明目标作业的负载类型和目标作业所需资源信息,可以包括:操作系统版本,该图形应用需要的资源,主要是GPU型号、GPU数量、GPU模式和图形渲染库类型和版本。In the present disclosure, digital twin application tasks and graphics rendering application tasks, AI model training tasks, AI model reasoning tasks, HPC parallel computing tasks, and batch computing tasks are all abstracted as "job" objects. The terminal device uses the command line of the scheduling system in the scheduling server or calls the API of the scheduling system through a graphical interface to submit a job to the scheduling server. The load type of the target job and the resource information required for the target job are described through command line parameters or a job description file, which may include: operating system version, resources required by the graphics application, mainly GPU model, number of GPUs, GPU mode, and graphics rendering library type and version.

例如:用户可以通过调度系统的命令行jsub来提交作业,将作业对象描述文件作为命令行参数提交给调度系统:"jsub-jobfile myjob.json";For example, users can submit jobs through the scheduling system's command line jsub, and submit the job object description file to the scheduling system as a command line parameter: "jsub-jobfile myjob.json";

在myjob.json中说明该作业的资源需求和应用启动路径及参数,如:Describe the resource requirements, application startup path, and parameters of the job in myjob.json, such as:

App_start_cmd="/opt/unreal-engine/Engine/Binaries/Linux/UnrealEditor–graphic"。App_start_cmd="/opt/unreal-engine/Engine/Binaries/Linux/UnrealEditor–graphic".

在步骤S102中,根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;集群资源信息表中包括:集群中,各个服务器的属性信息、已用资源信息和空闲资源信息。In step S102, based on the resource demand information corresponding to the application task of the current target job load type, a candidate server that meets the resource demand information corresponding to the application task of the current target job load type is searched in the cluster resource information table; the cluster resource information table includes: attribute information, used resource information and idle resource information of each server in the cluster.

其中,在集群资源信息表中查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器可以理解为:为每一个应用任务找到适合的候选服务器,这里的候选服务器可以同时服务于多个应用任务,在服务于多个应用任务时,候选服务器的空闲资源满足该些应用任务的资源需求信息的要求。Among them, searching the cluster resource information table for candidate servers that meet the resource demand information corresponding to the application tasks of the current target workload type can be understood as: finding a suitable candidate server for each application task. The candidate server here can serve multiple application tasks at the same time. When serving multiple application tasks, the idle resources of the candidate server meet the requirements of the resource demand information of these application tasks.

服务器的属性信息包括:操作系统版本、GPU的型号、GPU模式(渲染/计算/平衡模式)和图形渲染库类型,如DirectX、OpenGL、Vulkan;各个服务器的已用资源信息和各个服务器的空闲资源信息可以包括:已使用的CPU数量、已使用的内存大小、已使用的GPU数量,空闲的CPU数量、空闲的内存大小和空闲的GPU数量。The attribute information of the server includes: operating system version, GPU model, GPU mode (rendering/computing/balanced mode) and graphics rendering library type, such as DirectX, OpenGL, Vulkan; the used resource information of each server and the idle resource information of each server may include: the number of used CPUs, the used memory size, the number of used GPUs, the number of idle CPUs, the idle memory size and the number of idle GPUs.

在步骤S103中,在候选服务器中选择负载最低的服务器作为第一目标服务器。In step S103, a server with the lowest load is selected from the candidate servers as the first target server.

为了均衡集群中的各个服务器的利用率,不至于使得某些服务器过载而某些服务器空闲,本公开中会在候选服务器中选择负载最低的服务器作为第一目标服务器。In order to balance the utilization of each server in the cluster and avoid overloading some servers while idling some servers, the present disclosure selects the server with the lowest load as the first target server from the candidate servers.

在步骤S104中,将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息发送给第一目标服务器,以使第一目标服务器运行当前目标作业负载类型的应用任务。In step S104, the application tasks of the current target workload type and resource requirement information corresponding to the application tasks of the current target workload type are sent to the first target server, so that the first target server runs the application tasks of the current target workload type.

在为当前的应用任务选择了第一目标服务器后,便可以将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息发送给第一目标服务器,这样,第一目标服务器就可以基于接收到的信息去运行当前目标作业负载类型的应用任务。After selecting the first target server for the current application task, the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type can be sent to the first target server. In this way, the first target server can run the application task of the current target job load type based on the received information.

以当前目标作业负载类型的应用任务为图形应用会话任务为例,第一目标服务器为图形服务器为例,调度服务器根据图形应用的资源需求信息和集群中各图形服务器的资源负载情况(上述的集群资源信息表),如果当前有符合图形应用会话任务的资源需求信息要求的候选服务器,便从该些候选服务器中选择负载最低的图形服务器作为第一目标服务器,调度服务器就根据作业描述文件中的应用启动命令行及参数,通过其在该图形服务器上的作业启动程序立即在服务器上启动这个图形应用会话任务,并将图形服务器IP地址和Linux图形DISPLAY号或Windows远程会话号返回给当前目标作业负载类型的应用任务对应的终端设备,供终端设备连接使用;如果当前没有空闲的图形服务器,那么该图形应用会话任务将在调度队列中排队,等待资源满足后再启动。也即,在本公开中,如果调度服务器中的作业较多,此时,终端设备提交的应用任务可以先放置在调度服务器的队列中,然后由调度服务器来调度和派发。Taking the current target job load type application task as a graphics application session task, and the first target server as a graphics server, the scheduling server selects the graphics server with the lowest load from the candidate servers as the first target server according to the resource demand information of the graphics application and the resource load of each graphics server in the cluster (the above-mentioned cluster resource information table), if there is a candidate server that meets the resource demand information requirements of the graphics application session task, and the scheduling server immediately starts the graphics application session task on the server through its job startup program on the graphics server according to the application startup command line and parameters in the job description file, and returns the graphics server IP address and Linux graphics DISPLAY number or Windows remote session number to the terminal device corresponding to the application task of the current target job load type for the terminal device to connect and use; if there is no idle graphics server at present, then the graphics application session task will be queued in the scheduling queue and wait for resources to be met before starting. That is, in the present disclosure, if there are many jobs in the scheduling server, at this time, the application task submitted by the terminal device can be placed in the queue of the scheduling server first, and then scheduled and dispatched by the scheduling server.

其中,目标作业在服务器资源不足时可以在调度服务器中排队等待,不会因为争用相同的服务器资源而启动失败或运行缓慢。Among them, when the server resources are insufficient, the target job can queue up in the scheduling server and will not fail to start or run slowly due to competition for the same server resources.

其中,在图形服务器上启动图形应用会话任务时,根据图形应用会话任务所需的图形渲染库类型和版本,预先安装或通过系统环境变量及Windows注册表将图形渲染库切换到应用需要的版本,并启动图形应用会话任务对应的图形应用;在启动图形应用前,根据调度分配的具体GPU卡号和CPU核数,会通过系统API和底层资源隔离机制将图形应用会话任务的进程树绑定到分配的GPU卡和CPU核上面去,比如linux系统的cgroup,Windows系统的job object。Among them, when starting a graphics application session task on a graphics server, according to the type and version of the graphics rendering library required by the graphics application session task, the graphics rendering library is pre-installed or switched to the version required by the application through system environment variables and Windows registry, and the graphics application corresponding to the graphics application session task is started; before starting the graphics application, according to the specific GPU card number and CPU core number assigned by the scheduler, the process tree of the graphics application session task will be bound to the allocated GPU card and CPU core through the system API and the underlying resource isolation mechanism, such as the cgroup of the Linux system and the job object of the Windows system.

相关技术中,如图2所示,用户在终端设备中启动一个数字孪生类应用或者图形渲染类应用时,都是登录到图形服务器以获取图形界面或远程图形会话,然后在图形桌面启动图形应用,如果该服务器被其他终端设备占用,那么就需要重新去登录其他的终端设备,比如:有10台服务器,终端设备去登录其中的第4台服务器,如果第4台服务器被其他终端设备所占用,那么就会导致登录失败,终端设备需要去尝试着连接其他服务器。In the related technology, as shown in Figure 2, when a user starts a digital twin application or a graphics rendering application in a terminal device, he logs in to the graphics server to obtain a graphical interface or a remote graphics session, and then starts the graphics application on the graphics desktop. If the server is occupied by other terminal devices, it is necessary to log in to other terminal devices again. For example, there are 10 servers, and the terminal device logs in to the 4th server. If the 4th server is occupied by other terminal devices, it will cause login failure, and the terminal device needs to try to connect to other servers.

而本公开中,将数字孪生类应用及图形渲染类应用、AI模型训练及推理任务、HPC并行计算任务、批处理计算任务都抽象为“作业”对象,以终端设备使用调度服务器中调度系统的命令行或者通过图形界面调用调度系统的API,来向调度服务器提交一个作业,通过命令行参数或者作业描述文件说明目标作业的负载类型和目标作业所需资源信息,可以包括:操作系统版本,该图形应用会话任务需要的资源,主要是GPU型号、GPU数量、GPU模式和图形渲染库类型和版本。In the present disclosure, digital twin applications and graphics rendering applications, AI model training and reasoning tasks, HPC parallel computing tasks, and batch computing tasks are abstracted as "job" objects. The terminal device uses the command line of the scheduling system in the scheduling server or calls the API of the scheduling system through a graphical interface to submit a job to the scheduling server. The load type of the target job and the resource information required for the target job are described through command line parameters or a job description file, which may include: operating system version, resources required for the graphics application session task, mainly GPU model, number of GPUs, GPU mode, and graphics rendering library type and version.

例如:用户可以通过调度系统的命令行jsub来提交作业,将作业对象描述文件作为命令行参数提交给调度系统:"jsub-jobfile myjob.json";For example, users can submit jobs through the scheduling system's command line jsub, and submit the job object description file to the scheduling system as a command line parameter: "jsub-jobfile myjob.json";

在myjob.json中说明该作业的资源需求和应用启动路径及参数,如:Describe the resource requirements, application startup path, and parameters of the job in myjob.json, such as:

App_start_cmd="/opt/unreal-engine/Engine/Binaries/Linux/UnrealEditor–graphic"。App_start_cmd="/opt/unreal-engine/Engine/Binaries/Linux/UnrealEditor–graphic".

如图3所示,以目标作业的负载类型为图形应用会话任务为例,终端设备通过命令行或者API向调度服务器提交图形应用会话任务,调度服务器调度分配图形服务器上的资源,然后调度服务器启动图形应用会话任务,并返回图形界面或远程图形会话。As shown in Figure 3, taking the target job load type as a graphics application session task as an example, the terminal device submits the graphics application session task to the scheduling server through a command line or API, the scheduling server schedules and allocates resources on the graphics server, and then the scheduling server starts the graphics application session task and returns the graphical interface or remote graphics session.

本申请提供了一种多类型负载的资源统一调度方法,包括:接收不同类型的目标作业负载类型的应用任务,以及各个目标作业负载类型的应用任务对应的资源需求信息,其中,不同类型的目标作业负载类型的应用任务至少包括图形应用会话任务;根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;集群资源信息表中包括:集群中,各个服务器的属性信息、已用资源信息和空闲资源信息;在候选服务器中选择负载最低的服务器作为第一目标服务器;将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息发送给第一目标服务器,以使第一目标服务器运行当前目标作业负载类型的应用任务。这样,在为终端设备分配服务器时,调度服务器可以直接从集群资源信息表查找可以满足目标作业的资源需求信息服务器,这样终端设备就可以直接与该目标服务器连接,以让该目标服务器为终端设备处理目标作业,而无需像相关技术中,需要通过终端设备逐一去尝试与集群中的每一个服务器进行连接,直至成功建立连接,从而提升了终端设备连接服务器的效率,再者,调度服务器选择的服务器是集群中负载最低的服务器,从而可以提升集群中服务器资源的整体利用率。The present application provides a method for unified resource scheduling of multiple types of loads, including: receiving application tasks of different types of target job load types, and resource demand information corresponding to the application tasks of each target job load type, wherein the application tasks of different types of target job load types include at least a graphic application session task; searching a cluster resource information table for a candidate server that meets the resource demand information corresponding to the application task of the current target job load type according to the resource demand information corresponding to the application task of the current target job load type; the cluster resource information table includes: attribute information, used resource information, and idle resource information of each server in the cluster; selecting a server with the lowest load among the candidate servers as the first target server; and sending the application task of the current target job load type and the resource demand information corresponding to the application task of the current target job load type to the first target server, so that the first target server runs the application task of the current target job load type. In this way, when allocating a server to a terminal device, the scheduling server can directly search the cluster resource information table for a server that can meet the resource demand information of the target job, so that the terminal device can directly connect to the target server to allow the target server to process the target job for the terminal device. There is no need, as in the related technology, for the terminal device to try to connect to each server in the cluster one by one until a successful connection is established, thereby improving the efficiency of the terminal device connecting to the server. Furthermore, the server selected by the scheduling server is the server with the lowest load in the cluster, thereby improving the overall utilization of server resources in the cluster.

针对跨类型应用,尤其是图形渲染类应用任务而设计了新的调度策略。为了最大化利用集群中的服务器资源,并保证新方式下图形渲染类应用任务的用户使用体验,本公开在调度系统中增加了互补调度策略、时间窗口调度策略、资源抢占式调度策略、以及会话重用调度策略,以下详细介绍。A new scheduling strategy is designed for cross-type applications, especially graphics rendering application tasks. In order to maximize the use of server resources in the cluster and ensure the user experience of graphics rendering application tasks in the new way, the present disclosure adds complementary scheduling strategy, time window scheduling strategy, resource preemptive scheduling strategy, and session reuse scheduling strategy to the scheduling system, which are described in detail below.

一、互补调度策略1. Complementary Scheduling Strategy

当前目标作业负载类型的应用任务为接收的不同类型的目标作业负载类型的应用任务中当前进行处理的应用任务,可以为一个应用任务,也可以为多个应用任务。The application task of the current target workload type is an application task currently being processed among the received application tasks of different types of target workload types, and may be one application task or multiple application tasks.

以当前目标作业负载类型的应用任务为多个应用任务为例进行说明。The following description is made by taking the case where the application tasks of the current target workload type are multiple application tasks.

在一种可实现方式中,在当前目标作业负载类型的应用任务分配的第一目标服务器为正在运行应用任务但有空闲资源的服务器,此时服务器的空闲资源可以满足当前目标作业负载类型的应用任务对应的资源需求信息,且第一目标服务器正在运行的应用任务与当前目标作业负载类型的应用任务不相同,在运行了当前目标作业负载类型的应用任务后,第一目标服务器中运行了不同类型的应用任务。In one implementable method, the first target server assigned to the application task of the current target job load type is a server that is running the application task but has idle resources. At this time, the idle resources of the server can meet the resource demand information corresponding to the application task of the current target job load type, and the application task running on the first target server is different from the application task of the current target job load type. After running the application task of the current target job load type, different types of application tasks run in the first target server.

在获取到第一目标服务器有剩余资源时,可以从接收到的各个目标作业负载类型的应用任务对应的资源需求信息中获取多个目标资源需求信息,其中,多个目标资源需求信息之和小于或等于第一目标服务器有剩余资源,且第一目标服务器中正在运行的应用任务的类型要与各个目标资源需求信息对应的应用任务的类型不相同,这样就可以将多个目标资源需求信息以及各个目标资源需求信息对应的应用任务发送给第一目标服务器,以让第一目标服务器同时运行该些应用任务。When it is obtained that the first target server has remaining resources, multiple target resource demand information can be obtained from the resource demand information corresponding to the application tasks of each target workload type received, wherein the sum of the multiple target resource demand information is less than or equal to the remaining resources of the first target server, and the type of application tasks running in the first target server is different from the type of application tasks corresponding to each target resource demand information. In this way, multiple target resource demand information and application tasks corresponding to each target resource demand information can be sent to the first target server, so that the first target server can run these application tasks simultaneously.

在另一种可实现方式中,在检测到集群中有空闲服务器时,可以从接收到的各个目标作业负载类型的应用任务对应的资源需求信息中获取多个目标资源需求信息,其中,多个目标资源需求信息之和小于或等于第一目标服务器的资源,且各个目标资源需求信息对应的应用任务的类型不相同,这样就可以将多个目标资源需求信息以及各个目标资源需求信息对应的应用任务发送给第一目标服务器,以让第一目标服务器同时运行该些应用任务。In another possible implementation, when an idle server is detected in the cluster, multiple target resource demand information can be obtained from the resource demand information corresponding to the application tasks of each target workload type received, wherein the sum of the multiple target resource demand information is less than or equal to the resources of the first target server, and the types of application tasks corresponding to each target resource demand information are different. In this way, multiple target resource demand information and application tasks corresponding to each target resource demand information can be sent to the first target server to allow the first target server to run these application tasks simultaneously.

具体的,目前存在的作业调度系统一般都是按作业排队顺序将作业逐个派发到服务器上去执行,作业批量派发时也是将同一应用类型的一批作业派发出去,没有考虑过将不同应用类型的作业按资源互补而组合起来批量派发。本发明提出的互补调度策略,当调度队列中有不同应用类型的负载作业排队,而且资源互补时,调度程序可以根据服务器资源配置,将2个或多个完全不同应用类型的作业一次性派发到同一个服务器上面去执行。例如,集群中空闲出了一台服务器A,该服务器配置了32核CPU和2块GPU卡;在排队队列中有一个并行计算作业需要24核CPU,还有一个图形类作业需要2核CPU核+1块GPU卡,恰好还有一个AI模型推理作业需要6核CPU+1块GPU卡;那么调度系统将为这3个作业“拼车”,一次性派发这3个作业到服务器A上启动,保证服务器A的资源最大化利用,实现集群服务器的“一机多用”。Specifically, the existing job scheduling systems generally dispatch jobs one by one to the server for execution in the order of job queuing. When batch dispatching jobs, a batch of jobs of the same application type are also dispatched. It has not been considered to combine jobs of different application types according to resource complementarity and dispatch them in batches. The complementary scheduling strategy proposed by the present invention can dispatch two or more jobs of completely different application types to the same server at one time for execution according to the server resource configuration when there are load jobs of different application types queued in the scheduling queue and the resources are complementary. For example, a server A is idle in the cluster, and the server is configured with a 32-core CPU and 2 GPU cards; there is a parallel computing job in the queue that requires a 24-core CPU, and a graphics job that requires a 2-core CPU core + 1 GPU card, and there happens to be an AI model reasoning job that requires a 6-core CPU + 1 GPU card; then the scheduling system will "carpool" for these three jobs, dispatch these three jobs to server A at one time to start, ensure the maximum utilization of server A's resources, and realize the "one machine for multiple uses" of the cluster server.

由于某些图形应用会话任务重度使用GPU进行图形渲染,而只用很少量的CPU资源,按传统方法分配的物理服务器或者虚拟机,CPU计算资源往往被浪费。本公开可以达到“一机多用”的目的,同一台服务器上可以同时混合运行并行计算任务、批处理计算任务、图形应用会话任务,以及AI模型训练及推理任务,充分利用服务器的CPU和GPU资源。Since some graphics application session tasks heavily use GPU for graphics rendering and only use a small amount of CPU resources, the CPU computing resources of physical servers or virtual machines allocated by traditional methods are often wasted. The present disclosure can achieve the purpose of "one machine for multiple uses". Parallel computing tasks, batch computing tasks, graphics application session tasks, and AI model training and reasoning tasks can be mixed and run on the same server at the same time, making full use of the server's CPU and GPU resources.

目前存在的作业调度系统一般都是按作业排队顺序将作业逐个派发到服务器上去执行,作业批量派发时也是将同一应用类型的一批作业派发出去,没有考虑过将不同应用类型的作业按资源互补而组合起来批量派发,而本公开中提出了互补调度策略,在互补调度策略中,可以几个终端设备同时使用集群中的同一个服务器,比如:第一目标服务器已经为其他终端设备进行作业,但第一目标服务器还有空闲资源,而该空闲资源可以满足目标作业的资源需求信息的要求,且第一目标服务器已经进行的作业的负载类型与目标作业的负载类型各不相同,那么它们就可以共用这一台第一目标服务器,这样就可以最大化利用第一目标服务器的资源。The existing job scheduling systems generally dispatch jobs one by one to the server for execution in the order of job queuing. When dispatching jobs in batches, a batch of jobs of the same application type are dispatched. It has not been considered to combine jobs of different application types according to resource complementarity and dispatch them in batches. The present disclosure proposes a complementary scheduling strategy. In the complementary scheduling strategy, several terminal devices can use the same server in the cluster at the same time. For example, the first target server has been performing jobs for other terminal devices, but the first target server still has idle resources, and the idle resources can meet the resource demand information requirements of the target job, and the load type of the job already performed by the first target server is different from the load type of the target job. In this way, they can share the first target server, so as to maximize the utilization of the resources of the first target server.

二、时间窗口调度策略2. Time Window Scheduling Strategy

在一个实施例中,上述步骤S102包括以下子步骤A1-A3:In one embodiment, the above step S102 includes the following sub-steps A1-A3:

A1、获取当前目标作业负载类型的应用任务对应的运行时间,将其放入对应的目标时间窗口中,其中,不同的时间窗口对应不同的运行时间段,且不同类型的目标作业负载类型的应用任务对应不同的运行时间段。A1. Obtain the running time corresponding to the application task of the current target workload type, and put it into the corresponding target time window, wherein different time windows correspond to different running time periods, and application tasks of different types of target workload types correspond to different running time periods.

A2、若当前时间满足目标时间窗口对应的时间段要求,则根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器。A2. If the current time meets the time period requirement corresponding to the target time window, then according to the resource requirement information corresponding to the application task of the current target workload type, search the cluster resource information table for a candidate server that meets the resource requirement information corresponding to the application task of the current target workload type.

A3、若当前时间不满足目标时间窗口对应的时间段要求,向当前目标作业负载类型的应用任务对应的终端设备发送拒绝处理指令,拒绝处理指令指示当前时间不满足当前目标作业负载类型的应用任务对应的运行时间;或者,将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息放入对应的等待队列中排队,并在检测到满足目标时间窗口对应的时间段要求时,根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中重新查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器。A3. If the current time does not meet the time period requirement corresponding to the target time window, a rejection processing instruction is sent to the terminal device corresponding to the application task of the current target job load type, and the rejection processing instruction indicates that the current time does not meet the running time corresponding to the application task of the current target job load type; alternatively, the application task of the current target job load type and the resource demand information corresponding to the application task of the current target job load type are placed in a corresponding waiting queue, and when it is detected that the time period requirement corresponding to the target time window is met, the candidate server that meets the resource demand information corresponding to the application task of the current target job load type is searched again in the cluster resource information table according to the resource demand information corresponding to the application task of the current target job load type.

在调度服务器中设置若干时间窗口,比如白天工作时段对应的时间窗口、夜晚时段对应的时间窗口及周末休息时段对应的时间窗口。在调度服务器中为每一类应用任务指定运行时间窗口,例如,将需要用户交互操作的图形应用会话任务作业分配到白天工作时段对应的时间窗口,而把批处理计算作业或者AI模型训练作业分配到夜晚时段对应的时间窗口或周末休息时段对应的时间窗口。这种策略可以称之为时间窗口调度策略。当白天工作时段结束时,调度服务器将把在服务器上运行的图形应用环境保存检查点并清理释放资源,自动准备好批处理计算和AI模型训练所需要的运行环境,供计算作业夜间使用资源;当夜晚时段对应的时间窗口或周末休息时段对应的时间窗口结束时,又把计算作业环境保存并清理释放资源,将服务器自动恢复成图形应用环境,供上班人员交互使用。通过时间窗口调度策略可以实现图形应用会话任务和批处理计算任务在相同服务器的分时使用,充分利用服务器上的GPU资源和CPU资源,达到“一机两用”的效果。Several time windows are set in the scheduling server, such as the time window corresponding to the daytime working period, the time window corresponding to the night period, and the time window corresponding to the weekend rest period. In the scheduling server, a running time window is specified for each type of application task. For example, the graphics application session task job that requires user interaction is assigned to the time window corresponding to the daytime working period, and the batch computing job or AI model training job is assigned to the time window corresponding to the night period or the time window corresponding to the weekend rest period. This strategy can be called a time window scheduling strategy. When the daytime working period ends, the scheduling server will save the checkpoint of the graphics application environment running on the server and clean up and release resources, automatically prepare the operating environment required for batch computing and AI model training, and provide computing jobs with resources for nighttime use; when the time window corresponding to the night period or the time window corresponding to the weekend rest period ends, the computing job environment is saved and cleaned up and released, and the server is automatically restored to the graphics application environment for interactive use by office workers. The time window scheduling strategy can realize the time-sharing use of graphics application session tasks and batch computing tasks on the same server, making full use of the GPU resources and CPU resources on the server, and achieving the effect of "one machine for two uses".

数字孪生类应用及图形渲染类应用一般是在用户交互操作时才大量使用GPU资源,当晚上用户下班后GPU资源往往就闲置,而无法让AI模型训练及推理任务使用。本公开中的“一机两用”,白天将GPU卡设置为渲染模式,供用户交互使用数字孪生类应用及图形渲染类应用,而在晚上自动将GPU卡切换成计算模式,供AI模型训练及推理任务使用。Digital twin applications and graphics rendering applications generally use a large amount of GPU resources when users interact with them. When users get off work at night, GPU resources are often idle and cannot be used for AI model training and reasoning tasks. The "one machine for two uses" in this disclosure sets the GPU card to rendering mode during the day for users to interact with digital twin applications and graphics rendering applications, and automatically switches the GPU card to computing mode at night for AI model training and reasoning tasks.

具体的,在为目标作业分配服务器时,首先可以获取当前目标作业负载类型的应用任务对应的运行时间,并将其放入对应的目标时间窗口中;然后检查当前时间是否满足目标时间窗口对应的时间段要求,若当前时间满足时间窗口对应的时间段要求,则根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;若当前时间不满足目标时间窗口对应的时间段要求,向当前目标作业负载类型的应用任务对应的终端设备发送拒绝处理指令,拒绝处理指令指示当前时间不满足当前目标作业负载类型的应用任务对应的运行时间;或者,将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息放入对应的等待队列中排队,并在检测到满足目标时间窗口对应的时间段要求时,根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中重新查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,这样就可以实现“一机两用”的效果。Specifically, when allocating a server for a target job, first, the running time corresponding to the application task of the current target job load type can be obtained and placed in the corresponding target time window; then, it is checked whether the current time meets the time period requirement corresponding to the target time window; if the current time meets the time period requirement corresponding to the time window, then, according to the resource demand information corresponding to the application task of the current target job load type, a candidate server that meets the resource demand information corresponding to the application task of the current target job load type is searched in the cluster resource information table; if the current time does not meet the time period requirement corresponding to the target time window, a rejection processing instruction is sent to the terminal device corresponding to the application task of the current target job load type, and the rejection processing instruction indicates that the current time does not meet the running time corresponding to the application task of the current target job load type; alternatively, the application task of the current target job load type and the resource demand information corresponding to the application task of the current target job load type are placed in a corresponding waiting queue, and when it is detected that the time period requirement corresponding to the target time window is met, according to the resource demand information corresponding to the application task of the current target job load type, a candidate server that meets the resource demand information corresponding to the application task of the current target job load type is searched in the cluster resource information table again, so that the effect of "one machine for two uses" can be achieved.

三、资源抢占式调度策略3. Resource Preemptive Scheduling Strategy

在一个实施例中,本公开中的多类型负载的资源统一调度方法,还包括以下子步骤B1- B5:In one embodiment, the method for unified resource scheduling of multiple types of loads in the present disclosure further includes the following sub-steps B1-B5:

B1、若在集群资源信息表中未查找到满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,获取当前目标作业负载类型的应用任务的优先级。B1. If no candidate server that meets the resource requirement information corresponding to the application task of the current target workload type is found in the cluster resource information table, the priority of the application task of the current target workload type is obtained.

B2、检测集群的各个服务器中是否有第二目标服务器,其中,第二目标服务器中正在运行的第一应用任务的负载类型的优先级低于当前目标作业负载类型的应用任务的优先级,且第二目标服务器在释放了为正在运行的第一应用任务分配的资源后,第二目标服务器中的空闲资源满足当前目标作业负载类型的应用任务对应的资源需求信息。B2. Detect whether there is a second target server among the servers in the cluster, wherein the priority of the load type of the first application task running in the second target server is lower than the priority of the application task of the current target job load type, and after the second target server releases the resources allocated to the running first application task, the idle resources in the second target server meet the resource demand information corresponding to the application task of the current target job load type.

B3、控制第二目标服务器将正在运行的第一应用任务挂起或终止,以使第二目标服务器释放为第一应用任务分配的资源。B3. Control the second target server to suspend or terminate the running first application task, so that the second target server releases the resources allocated to the first application task.

B4、将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息发送给第二目标服务器,以让第二目标服务器运行当前目标作业负载类型的应用任务。B4. Sending the application tasks of the current target workload type and the resource requirement information corresponding to the application tasks of the current target workload type to the second target server, so that the second target server runs the application tasks of the current target workload type.

B5、在检测到当前目标作业负载类型的应用任务运行完成后,控制第二目标服务器继续运行第一应用任务。B5. After detecting that the application task of the current target workload type has completed execution, control the second target server to continue executing the first application task.

在实际使用场景中,并行计算和AI模型训练往往需要长时间持续使用CPU和GPU服务器资源,当用户急需资源使用某款图形应用会话任务或者使用AI模型进行推理时,需要立即获得所需资源并启动相关应用。调度服务器可以通过抢占式作业调度策略来应对上述场景。在调度服务器中可以为不同的负载类型配置不同的优先级,优先级越高,应用运行的紧急程度越高,当遇到优先级高的紧急任务时,调度服务器将在集群中找到可被抢占运行低优先级作业的服务器,并将该低优先级作业挂起或终止该低优先级作业以释放资源,供该紧急的图形应用会话任务使用。当该图形应用会话任务使用完毕后,调度系统将服务器环境自动还原,恢复低优先级作业从检查点继续运行。In actual usage scenarios, parallel computing and AI model training often require long-term continuous use of CPU and GPU server resources. When users urgently need resources to use a certain graphics application session task or use AI models for reasoning, they need to immediately obtain the required resources and start related applications. The scheduling server can deal with the above scenarios through a preemptive job scheduling strategy. Different priorities can be configured for different load types in the scheduling server. The higher the priority, the more urgent the application operation. When encountering a high-priority urgent task, the scheduling server will find a server in the cluster that can be preempted to run a low-priority job, and suspend or terminate the low-priority job to release resources for the urgent graphics application session task. When the graphics application session task is used up, the scheduling system will automatically restore the server environment and resume the low-priority job from the checkpoint.

示例的,调度服务器可以配置多个排队队列,不同排队队列可以设置不同的优先级,当遇到紧急任务时,比如:图形应用会话任务,调度服务器可以将图形应用会话任务提交到高优先级的可抢占队列中,调度服务器将在集群中可被抢占的低优先级队列中找到符合要求的低优先级作业和服务器,并将该低优先级作业挂起或终止该低优先级作业以释放资源,供该紧急的图形应用会话任务使用。当该图形应用会话任务使用完毕后,调度系统将服务器环境自动还原,恢复低优先级作业从检查点继续运行。For example, the scheduling server can be configured with multiple queues, and different queues can be set with different priorities. When encountering an urgent task, such as a graphics application session task, the scheduling server can submit the graphics application session task to a high-priority preemptible queue. The scheduling server will find a low-priority job and server that meets the requirements in the preemptible low-priority queue in the cluster, and suspend or terminate the low-priority job to release resources for the urgent graphics application session task. When the graphics application session task is used up, the scheduling system will automatically restore the server environment and resume the low-priority job to continue running from the checkpoint.

四、会话重用调度策略4. Session Reuse Scheduling Strategy

在一个实施例中,在目标作业负载类型的应用任务为图形应用会话任务时,本公开中的多类型负载的资源统一调度方法,还包括以下子步骤C1- C2:In one embodiment, when the application task of the target workload type is a graphics application session task, the resource unified scheduling method for multiple types of workloads in the present disclosure further includes the following sub-steps C1-C2:

C1、若在集群资源信息表中未查找到满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,检测集群中是否有第三目标服务器,其中,第三目标服务器中正在运行与当前目标作业负载类型的应用任务属于同一终端设备的其他应用任务,其他应用任务的负载类型与当前目标作业负载类型相同;C1. If no candidate server that meets the resource requirement information corresponding to the application task of the current target job load type is found in the cluster resource information table, detect whether there is a third target server in the cluster, wherein the third target server is running other application tasks belonging to the same terminal device as the application task of the current target job load type, and the load type of the other application tasks is the same as the current target job load type;

C2、若有,将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息发送给第三目标服务器。C2. If yes, the application tasks of the current target workload type and the resource demand information corresponding to the application tasks of the current target workload type are sent to the third target server.

当集群中各个服务器的GPU资源紧张时,为每个图形会话类任务创建一个单独的会话或分配一个单独的GPU显卡会加重集群的资源负担。为此,调度服务器可以提供一种会话重用的调度策略,即对同一个终端设备启动的多个同类型图形应用会话任务,调度分配到同一个会话作业中,使用同一张GPU显卡。因为同一个终端设备在交互操作过程中,同一时间一般只会操作其中一个应用,这样该终端设备的其他图形应用会话任务占用的GPU资源就比较低,不会影响当前操作的图形应用会话任务的交互性能,通过终端设备级别的会话重用调度策略,不会引起各个终端设备之间的资源冲突和协调工作,既保证了各个终端设备之间的安全隔离,又充分利用了GPU资源。When the GPU resources of each server in the cluster are tight, creating a separate session or assigning a separate GPU graphics card to each graphics session task will increase the resource burden of the cluster. To this end, the scheduling server can provide a scheduling strategy for session reuse, that is, for multiple graphics application session tasks of the same type started by the same terminal device, they are scheduled and assigned to the same session job and use the same GPU graphics card. Because the same terminal device generally only operates one application at a time during the interactive operation process, the GPU resources occupied by other graphics application session tasks of the terminal device are relatively low, which will not affect the interactive performance of the currently operating graphics application session task. The session reuse scheduling strategy at the terminal device level will not cause resource conflicts and coordination work between the terminal devices, which not only ensures the security isolation between the terminal devices, but also makes full use of GPU resources.

由于集群中各个服务器的资源是动态变化的,因此,还需要去更新集群资源信息表,此时,多类型负载的资源统一调度方法,还包括以下子步骤D1- D2:Since the resources of each server in the cluster are dynamically changing, it is necessary to update the cluster resource information table. At this time, the unified resource scheduling method for multi-type loads also includes the following sub-steps D1-D2:

D1、接收集群中的各个服务器发送的集群资源更新信息,集群资源更新信息中包括:当前时间点对应的各个服务器的已用资源信息和空闲资源信息。D1. Receive cluster resource update information sent by each server in the cluster, where the cluster resource update information includes: used resource information and idle resource information of each server corresponding to the current time point.

D2、根据集群资源更新信息更新集群资源信息表。D2. Update the cluster resource information table according to the cluster resource update information.

在集群中的各类服务器上识别当前时间点已用资源信息和空闲资源信息,上报给调度服务器,供调度服务器更新集群资源信息表所用,从而在调度服务器为终端设备的目标作业分配服务器时,可以更加准确。The used resource information and idle resource information at the current time point are identified on various servers in the cluster, and reported to the scheduling server for the scheduling server to update the cluster resource information table, so that the scheduling server can be more accurate when allocating servers for target jobs of terminal devices.

本公开还提供一种多类型负载的资源统一调度系统,多类型负载的资源统一调度系统包括:The present disclosure also provides a unified resource scheduling system for multiple types of loads, and the unified resource scheduling system for multiple types of loads includes:

终端设备、调度服务器和包括多个服务器的集群,其中,多个服务器包括第一目标服务器;A terminal device, a scheduling server, and a cluster including a plurality of servers, wherein the plurality of servers include a first target server;

终端设备,用于向调度服务器发送不同类型的目标作业负载类型的应用任务,以及各个目标作业负载类型的应用任务对应的资源需求信息,其中,不同类型的目标作业负载类型的应用任务至少包括图形应用会话任务;The terminal device is used to send application tasks of different types of target workload types and resource demand information corresponding to the application tasks of each target workload type to the scheduling server, wherein the application tasks of different types of target workload types at least include graphic application session tasks;

调度服务器,用于根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;集群资源信息表中包括:集群中,各个服务器的属性信息、已用资源信息和空闲资源信息;The scheduling server is used to search for a candidate server that meets the resource demand information corresponding to the application task of the current target workload type in the cluster resource information table according to the resource demand information corresponding to the application task of the current target workload type; the cluster resource information table includes: attribute information, used resource information and idle resource information of each server in the cluster;

调度服务器,用于在候选服务器中选择负载最低的服务器作为第一目标服务器,并将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息发送给第一目标服务器;A scheduling server, configured to select a server with the lowest load from the candidate servers as a first target server, and send application tasks of the current target job load type and resource demand information corresponding to the application tasks of the current target job load type to the first target server;

第一目标服务器,用于在接收到当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息后,根据当前目标作业负载类型的应用任务对应的资源需求信息运行当前目标作业负载类型的应用任务。The first target server is used to run the application task of the current target workload type according to the resource demand information corresponding to the application task of the current target workload type after receiving the application task of the current target workload type and the resource demand information corresponding to the application task of the current target workload type.

在一个实施例中,第一目标服务器为正在运行应用任务但有空闲资源的服务器,空闲资源可以满足当前目标作业负载类型的应用任务对应的资源需求信息,且第一目标服务器正在运行的应用任务与当前目标作业负载类型的应用任务不相同,在运行了当前目标作业负载类型的应用任务后,第一目标服务器中运行了不同类型的应用任务。In one embodiment, the first target server is a server that is running application tasks but has idle resources. The idle resources can meet the resource demand information corresponding to the application tasks of the current target job load type, and the application tasks running on the first target server are different from the application tasks of the current target job load type. After running the application tasks of the current target job load type, different types of application tasks run in the first target server.

在一个实施例中,调度服务器,具体用于:In one embodiment, the scheduling server is specifically configured to:

获取当前目标作业负载类型的应用任务对应的运行时间,将其放入对应的目标时间窗口中,其中,不同的时间窗口对应不同的运行时间段,且不同类型的目标作业负载类型的应用任务对应不同的运行时间段;Obtain the running time corresponding to the application task of the current target workload type, and put it into the corresponding target time window, where different time windows correspond to different running time periods, and application tasks of different types of target workload types correspond to different running time periods;

若当前时间满足目标时间窗口对应的时间段要求,则根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;If the current time meets the time period requirement corresponding to the target time window, then according to the resource requirement information corresponding to the application task of the current target workload type, search the cluster resource information table for a candidate server that meets the resource requirement information corresponding to the application task of the current target workload type;

若当前时间不满足目标时间窗口对应的时间段要求,向当前目标作业负载类型的应用任务对应的终端设备发送拒绝处理指令,拒绝处理指令指示当前时间不满足当前目标作业负载类型的应用任务对应的运行时间;或者,将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息存入缓存中,并在检测到满足目标时间窗口对应的时间段要求时,根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中重新查找满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器。If the current time does not meet the time period requirement corresponding to the target time window, a rejection processing instruction is sent to the terminal device corresponding to the application task of the current target job load type, and the rejection processing instruction indicates that the current time does not meet the running time corresponding to the application task of the current target job load type; alternatively, the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type are stored in the cache, and when it is detected that the time period requirement corresponding to the target time window is met, the candidate server that meets the resource requirement information corresponding to the application task of the current target job load type is re-searched in the cluster resource information table according to the resource requirement information corresponding to the application task of the current target job load type.

在一个实施例中,调度服务器,还用于:若在集群资源信息表中未查找到满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,获取当前目标作业负载类型的应用任务的优先级;检测集群的各个服务器中是否有第二目标服务器,其中,第二目标服务器中正在运行的第一应用任务的负载类型的优先级低于当前目标作业负载类型的应用任务的优先级,且第二目标服务器在释放了为正在运行的第一应用任务分配的资源后,第二目标服务器中的空闲资源满足当前目标作业负载类型的应用任务对应的资源需求信息;控制第二目标服务器将正在运行的第一应用任务挂起或终止,以使第二目标服务器释放为第一应用任务分配的资源;将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息发送给第二目标服务器,以让第二目标服务器运行当前目标作业负载类型的应用任务;在检测到当前目标作业负载类型的应用任务运行完成后,控制第二目标服务器继续运行第一应用任务;In one embodiment, the scheduling server is also used to: if a candidate server that meets the resource requirement information corresponding to the application task of the current target job load type is not found in the cluster resource information table, obtain the priority of the application task of the current target job load type; detect whether there is a second target server among the servers in the cluster, wherein the priority of the load type of the first application task running in the second target server is lower than the priority of the application task of the current target job load type, and after the second target server releases the resources allocated to the running first application task, the idle resources in the second target server meet the resource requirement information corresponding to the application task of the current target job load type; control the second target server to suspend or terminate the running first application task so that the second target server releases the resources allocated to the first application task; send the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type to the second target server, so that the second target server runs the application task of the current target job load type; after detecting that the application task of the current target job load type has completed running, control the second target server to continue running the first application task;

或者,or,

调度服务器,还用于:在目标作业负载类型的应用任务为图形应用会话任务时,若在集群资源信息表中未查找到满足当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,检测集群中是否有第三目标服务器,其中,第三目标服务器中正在运行与当前目标作业负载类型的应用任务属于同一终端设备的其他应用任务,其他应用任务的负载类型与当前目标作业负载类型相同; 若有,将当前目标作业负载类型的应用任务和当前目标作业负载类型的应用任务对应的资源需求信息发送给第三目标服务器。The scheduling server is also used for: when the application task of the target job load type is a graphic application session task, if a candidate server that meets the resource requirement information corresponding to the application task of the current target job load type is not found in the cluster resource information table, detecting whether there is a third target server in the cluster, wherein the third target server is running other application tasks belonging to the same terminal device as the application task of the current target job load type, and the load type of the other application tasks is the same as the current target job load type; if so, sending the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type to the third target server.

在现有的公有云和私有云中,用户使用数字孪生及图形渲染类应用时,所需的图形服务器资源往往按GPU服务器整机分配,或者使用虚拟化技术将服务器隔离成多个虚拟机,利用GPU穿透或者vGPU技术将Windows和linux虚拟机固定分配给不同的用户来交互使用。这样就容易造成服务器的GPU资源利用率低下的问题,而且图形类应用的交互性能也受到虚拟化的影响而大幅损耗。In existing public and private clouds, when users use digital twins and graphics rendering applications, the required graphics server resources are often allocated as a whole GPU server, or virtualization technology is used to isolate the server into multiple virtual machines, and GPU penetration or vGPU technology is used to allocate Windows and Linux virtual machines to different users for interactive use. This can easily lead to low utilization of the server's GPU resources, and the interactive performance of graphics applications is also greatly affected by virtualization and degraded.

某些数字孪生及图形类应用重度使用GPU进行图形渲染,而只用很少量的CPU资源,按传统方法分配的物理服务器或者虚拟机,CPU计算资源往往被浪费。Some digital twins and graphics applications heavily use GPUs for graphics rendering and only use a small amount of CPU resources. In physical servers or virtual machines allocated using traditional methods, CPU computing resources are often wasted.

有些公有云和私有云通过使用容器化技术和Kubernetes(K8S)来解决Linux应用和资源的动态匹配问题,但数字孪生及图形渲染类应用多数使用Windows操作系统,而Windows容器中不支持图形界面的应用,这样Windows图形类应用就只能使用集群中的Windows物理服务器或者云桌面虚拟机。Some public and private clouds use containerization technology and Kubernetes (K8S) to solve the problem of dynamic matching of Linux applications and resources. However, most digital twin and graphics rendering applications use the Windows operating system, and Windows containers do not support graphical interface applications. Therefore, Windows graphics applications can only use Windows physical servers or cloud desktop virtual machines in the cluster.

数字孪生及图形渲染类应用一般是在用户交互操作时才大量使用GPU资源,当晚上用户下班后GPU资源往往就闲置,而无法让AI模型训练及推理任务使用。Digital twin and graphics rendering applications generally use a large amount of GPU resources during user interaction. When users get off work at night, GPU resources are often idle and cannot be used for AI model training and inference tasks.

现有的HPC集群资源调度软件,比如IBM Spectrum LSF和Slurm调度软件,只能调度并行计算和批处理计算任务,不能调度数字孪生应用、图形渲染应用或者AI模型训练推理任务。容器集群最常用的K8S开源管理软件只能按pod来编排和调度管理经过容器封装的计算任务和AI模型训练推理任务,不能调度HPC并行计算作业,更不能调度管理数字孪生和图形应用。云桌面系统软件,比如世界最领先的Citrix和VMware中,只有云桌面会话和远程图形应用会话的管理功能,没有按GPU资源来调度云桌面或图形应用会话,更不支持其他类型的计算任务或AI模型训练推理任务的管理和资源调度。Existing HPC cluster resource scheduling software, such as IBM Spectrum LSF and Slurm scheduling software, can only schedule parallel computing and batch computing tasks, but cannot schedule digital twin applications, graphics rendering applications, or AI model training and reasoning tasks. The most commonly used K8S open source management software for container clusters can only orchestrate and schedule container-encapsulated computing tasks and AI model training and reasoning tasks by pod, but cannot schedule HPC parallel computing jobs, let alone digital twin and graphics applications. Cloud desktop system software, such as the world's leading Citrix and VMware, only has the management function of cloud desktop sessions and remote graphics application sessions, but does not schedule cloud desktop or graphics application sessions by GPU resources, and does not support the management and resource scheduling of other types of computing tasks or AI model training and reasoning tasks.

本公开的效果和优点:Effects and advantages of the present invention:

1. 本公开可以在公有云和私有云的服务器集群中统一调度Windows和Linux数字孪生应用、图形渲染应用和AI模型训练及推理任务,还有传统的并行计算任务和批处理计算任务。1. The present invention can uniformly schedule Windows and Linux digital twin applications, graphics rendering applications, AI model training and reasoning tasks, as well as traditional parallel computing tasks and batch computing tasks in server clusters of public clouds and private clouds.

2. 将云端集群中运行的数字孪生应用或图形渲染应用作为一种GPU资源的负载任务抽象出来,作为远程图形会话作业,跟其他类型的计算作业一起进行调度和管理。2. Abstract the digital twin application or graphics rendering application running in the cloud cluster as a load task of GPU resources and schedule and manage it as a remote graphics session job together with other types of computing jobs.

3. 图形类应用的作业在服务器GPU资源不足时可以在资源调度系统中排队等待,不会因为争用相同的GPU资源而启动失败或运行缓慢。3. When the server GPU resources are insufficient, graphics application jobs can queue up in the resource scheduling system and will not fail to start or run slowly due to competition for the same GPU resources.

4. 不依赖虚拟化技术,数字孪生和图形渲染应用可以和AI模型训练及推理任务共享使用同一块GPU卡,性能更好。4. Without relying on virtualization technology, digital twins and graphics rendering applications can share the same GPU card with AI model training and inference tasks, achieving better performance.

5. “一机多用”,同一台服务器上可以同时混合运行并行计算任务、批处理计算任务、数字孪生和图形渲染应用,以及AI模型训练及推理任务,充分利用服务器的CPU和GPU资源。5. "One machine for multiple uses": parallel computing tasks, batch computing tasks, digital twins and graphics rendering applications, as well as AI model training and inference tasks can be mixed and run on the same server at the same time, making full use of the server's CPU and GPU resources.

6. “一机两用”,白天将GPU卡设置为渲染模式,供用户交互使用数字孪生及图形渲染类应用,而在晚上自动将GPU卡切换成计算模式,供AI模型训练及推理任务使用。6. "One machine for two purposes": set the GPU card to rendering mode during the day for users to interactively use digital twins and graphics rendering applications, and automatically switch the GPU card to computing mode at night for use in AI model training and inference tasks.

图4为本申请一实施例提供的多类型负载的资源统一调度系统的功能模块架构图,如图4所示,包括:终端设备、调度服务器和包括多个服务器的集群,其中,集群中的服务器可以为应用/计算服务器,多个服务器包括第一目标服务器;FIG4 is a functional module architecture diagram of a unified resource scheduling system for multiple types of loads provided by an embodiment of the present application. As shown in FIG4 , the system includes: a terminal device, a scheduling server, and a cluster including multiple servers, wherein the servers in the cluster may be application/computing servers, and the multiple servers include a first target server;

其中,调度命令行程序为一组命令行程序,包括作业提交、作业查询、作业控制等命令行程序。终端设备可以在操作系统中手工调用这些命令行进行作业提交、作业查询和作业控制操作,命令行程序给终端设备返回作业计算结果或者图形应用的远程界面连接信息。终端设备提交作业前,将该应用程序需要的资源类别、资源数量、渲染库类型版本、应用程序启动路径和参数写在一个作业描述文件中,在提交作业时指定作业描述文件。调度命令行程序一般运行在终端设备上,也可以运行在调度服务器上。Among them, the scheduling command line program is a group of command line programs, including command line programs such as job submission, job query, and job control. The terminal device can manually call these command lines in the operating system to perform job submission, job query, and job control operations. The command line program returns the job calculation results or the remote interface connection information of the graphics application to the terminal device. Before the terminal device submits a job, the resource category, resource quantity, rendering library type version, application startup path, and parameters required by the application are written in a job description file, and the job description file is specified when submitting the job. The scheduling command line program generally runs on the terminal device, and can also run on the scheduling server.

调度服务器中的调度引擎程序,用于接受调度命令行提交的作业提交、作业查询、作业控制等请求,将作业数据或图形界面连接信息返回给调度命令行程序。调度引擎程序内部有配置文件,管理员可以预先设置调度策略相关的参数,例如:互补调度策略开关参数、每一类负载类型的时间窗口设置、抢占式调度策略的排队队列,或者会话重用调度测试开关等。调度引擎程序定时(比如每隔15秒)接收每个应用/计算服务器上的资源监控程序上报的当前时间点对应的已用资源信息和空闲资源信息,根据目标作业的资源需求信息、当前集群中各个应用/计算服务器的资源状况、以及管理员配置的调度策略,将目标作业调度到合适的应用/计算服务器上。调度引擎程序将根据该应用/计算服务器的资源设备情况为目标作业指定服务器上可用的CPU、GPU设备号和资源数量,这些信息将随同作业对象通过网络通讯发送给应用/计算服务器上的作业启动程序,实现目标作业的派发。调度引擎程序运行在调度服务器上。The scheduling engine program in the scheduling server is used to accept job submission, job query, job control and other requests submitted by the scheduling command line, and return job data or graphical interface connection information to the scheduling command line program. There is a configuration file inside the scheduling engine program, and the administrator can pre-set parameters related to the scheduling strategy, such as: complementary scheduling strategy switch parameters, time window settings for each type of load, queuing queues for preemptive scheduling strategies, or session reuse scheduling test switches, etc. The scheduling engine program periodically receives the used resource information and idle resource information corresponding to the current time point reported by the resource monitoring program on each application/computing server (for example, every 15 seconds), and schedules the target job to the appropriate application/computing server based on the resource demand information of the target job, the resource status of each application/computing server in the current cluster, and the scheduling strategy configured by the administrator. The scheduling engine program will specify the CPU, GPU device number and resource quantity available on the server for the target job based on the resource equipment status of the application/computing server. This information will be sent to the job launcher on the application/computing server through network communication along with the job object to realize the dispatch of the target job. The scheduling engine program runs on the scheduling server.

资源监控程序运行在每一个应用/计算服务器上,通过操作系统命令、系统API和IPMI等各种方法对所在的应用/计算服务器系统进行扫描,自动识别应用/计算服务器上的CPU、内存和GPU等设备和资源使用情况,以及应用/计算服务器上运行的各类作业实际使用的资源数量(也即上述实施例中的各个应用/计算服务器的属性信息、已用资源信息和空闲资源信息),通过网络通讯定时上报给调度服务器上的调度引擎程序。The resource monitoring program runs on each application/computing server, scans the application/computing server system through various methods such as operating system commands, system API and IPMI, automatically identifies the CPU, memory, GPU and other devices and resource usage on the application/computing server, as well as the actual amount of resources used by various jobs running on the application/computing server (that is, the attribute information, used resource information and idle resource information of each application/computing server in the above embodiment), and reports it to the scheduling engine program on the scheduling server through network communication at regular intervals.

作业启动程序运行在每一个应用/计算服务器上,当收到调度引擎程序通过网络通讯派发来的作业对象信息(上述实施例中的目标作业的资源需求信息)后,根据作业对象信息中的渲染库类型及版本要求,通过设置操作系统的环境变量和注册表的方式,将当前程序运行环境的渲染库切换成作业要求的类型和版本,如果切换过程中系统因为缺少相关依赖库而报错,作业启动程序会自动从网上下载安装。运行环境准备完毕后,作业启动程序将执行作业对象中的应用启动路径和启动参数来启动目标作业,并调用操作系统的API来设置应用程序的进程属性,从而按作业对象中的资源配额来限制该目标作业能够使用的CPU、内存、GPU等设备和数量。目标作业启动后,作业启动程序将对每个作业的进程树进行跟踪扫描,后续可以根据调度引擎程序发来的作业控制指令来挂起、恢复或终止作业进程。The job startup program runs on each application/computing server. After receiving the job object information (the resource requirement information of the target job in the above embodiment) sent by the scheduling engine program through network communication, the rendering library type and version requirements in the job object information are set by setting the operating system's environment variables and registry to switch the rendering library of the current program running environment to the type and version required by the job. If the system reports an error due to the lack of relevant dependent libraries during the switching process, the job startup program will automatically download and install it from the Internet. After the operating environment is prepared, the job startup program will execute the application startup path and startup parameters in the job object to start the target job, and call the operating system's API to set the application's process properties, thereby limiting the CPU, memory, GPU and other devices and quantities that the target job can use according to the resource quota in the job object. After the target job is started, the job startup program will track and scan the process tree of each job, and can subsequently suspend, resume or terminate the job process according to the job control instructions sent by the scheduling engine program.

相关技术中,有些公有云和私有云通过使用容器化技术和Kubernetes(K8S)来解决Linux应用和资源的动态匹配问题,但数字孪生类应用及图形渲染类应用多数使用Windows操作系统,而Windows容器中不支持图形界面的应用,这样Windows图形类应用就只能使用集群中的Windows物理服务器或者云桌面虚拟机。而本公开不依赖虚拟化技术,数字孪生类应用和图形渲染类应用可以和AI模型训练及推理任务共享使用同一块GPU卡,性能更好。In the related technologies, some public and private clouds use containerization technology and Kubernetes (K8S) to solve the dynamic matching problem of Linux applications and resources, but most digital twin applications and graphics rendering applications use the Windows operating system, and Windows containers do not support graphical interface applications, so Windows graphics applications can only use Windows physical servers or cloud desktop virtual machines in the cluster. However, the present disclosure does not rely on virtualization technology, and digital twin applications and graphics rendering applications can share the same GPU card with AI model training and reasoning tasks, with better performance.

基于同样的发明构思,本申请实施例还提供了一种用于实现上述所涉及的多类型负载的资源统一调度方法的多类型负载的资源统一调度装置。该装置所提供的解决问题的实现方案与上述方法中所记载的实现方案相似,故下面所提供的一个或多个多类型负载的资源统一调度装置实施例中的具体限定可以参见上文中对于多类型负载的资源统一调度方法的限定,在此不再赘述。Based on the same inventive concept, the embodiment of the present application also provides a device for unified resource scheduling of multiple types of loads for implementing the method for unified resource scheduling of multiple types of loads involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in the embodiments of one or more devices for unified resource scheduling of multiple types of loads provided below can refer to the limitations of the method for unified resource scheduling of multiple types of loads above, and will not be repeated here.

在一个示例性的实施例中,如图5所示,提供了一种多类型负载的资源统一调度装置,所述多类型负载的资源统一调度装置包括:In an exemplary embodiment, as shown in FIG5 , a device for unified resource scheduling of multiple types of loads is provided, and the device for unified resource scheduling of multiple types of loads includes:

接收模块11,用于接收不同类型的目标作业负载类型的应用任务,以及各个所述目标作业负载类型的应用任务对应的资源需求信息,其中,所述不同类型的目标作业负载类型的应用任务至少包括图形应用会话任务;The receiving module 11 is used to receive application tasks of different types of target workload types and resource demand information corresponding to the application tasks of each target workload type, wherein the application tasks of different types of target workload types at least include graphic application session tasks;

查找模块12,用于根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;所述集群资源信息表中包括:集群中,各个服务器的属性信息、已用资源信息和空闲资源信息;A search module 12 is used to search for a candidate server that meets the resource demand information corresponding to the application task of the current target workload type in the cluster resource information table according to the resource demand information corresponding to the application task of the current target workload type; the cluster resource information table includes: attribute information, used resource information and idle resource information of each server in the cluster;

选择模块13,用于在所述候选服务器中选择负载最低的服务器作为第一目标服务器;A selection module 13, configured to select a server with the lowest load from among the candidate servers as a first target server;

发送模块14,用于将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第一目标服务器,以使所述第一目标服务器运行所述当前目标作业负载类型的应用任务。The sending module 14 is used to send the application tasks of the current target workload type and the resource requirement information corresponding to the application tasks of the current target workload type to the first target server, so that the first target server runs the application tasks of the current target workload type.

在一示例性的实施例中,提供了一种计算机设备,该计算机设备可以是服务器或者终端,其内部结构图可以如图6所示。该计算机设备包括处理器、存储器、输入/输出接口(Input/Output,简称I/O)和通信接口。其中,处理器、存储器和输入/输出接口通过系统总线连接,通信接口通过输入/输出接口连接到系统总线。其中,该计算机设备的处理器用于提供计算和控制能力。该计算机设备的存储器包括非易失性存储介质和内存储器。该非易失性存储介质存储有操作系统、计算机程序和数据库。该内存储器为非易失性存储介质中的操作系统和计算机程序的运行提供环境。该计算机设备的数据库用于存储多类型负载的资源统一调度所需的数据。该计算机设备的输入/输出接口用于处理器与外部设备之间交换信息。该计算机设备的通信接口用于与外部的终端通过网络连接通信。该计算机程序被处理器执行时以实现一种多类型负载的资源统一调度方法。In an exemplary embodiment, a computer device is provided, which may be a server or a terminal, and its internal structure diagram may be shown in FIG6. The computer device includes a processor, a memory, an input/output interface (Input/Output, referred to as I/O) and a communication interface. Among them, the processor, the memory and the input/output interface are connected through a system bus, and the communication interface is connected to the system bus through the input/output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data required for the unified scheduling of resources of multiple types of loads. The input/output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a method for unified scheduling of resources of multiple types of loads is implemented.

本领域技术人员可以理解,图6中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。Those skilled in the art will understand that the structure shown in FIG. 6 is merely a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different arrangement of components.

在一个示例性的实施例中,还提供了一种计算机设备,包括存储器和处理器,存储器中存储有计算机程序,该处理器执行计算机程序时实现上述各方法实施例中的步骤。In an exemplary embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above-mentioned method embodiments when executing the computer program.

在一个示例性的实施例中,提供了一种计算机可读存储介质,存储有计算机程序,该计算机程序被处理器执行时实现上述各方法实施例中的步骤。In an exemplary embodiment, a computer-readable storage medium is provided, storing a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.

在一个示例性的实施例中,提供了一种计算机程序产品,包括计算机程序,该计算机程序被处理器执行时实现上述各方法实施例中的步骤。In an exemplary embodiment, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.

需要说明的是,本申请所涉及的用户信息(包括但不限于用户设备信息、用户个人信息等)和数据(包括但不限于用于分析的数据、存储的数据、展示的数据等),均为经用户授权或者经过各方充分授权的信息和数据,且相关数据的收集、使用和处理需要符合相关规定。It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.

本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一非易失性计算机可读取存储介质中,该计算机程序在执行时,可包括如上述各方法的实施例的流程。其中,本申请所提供的各实施例中所使用的对存储器、数据库或其它介质的任何引用,均可包括非易失性和易失性存储器中的至少一种。非易失性存储器可包括只读存储器(Read-OnlyMemory,ROM)、磁带、软盘、闪存、光存储器、高密度嵌入式非易失性存储器、阻变存储器(ReRAM)、磁变存储器(Magnetoresistive Random Access Memory,MRAM)、铁电存储器(Ferroelectric Random Access Memory,FRAM)、相变存储器(Phase Change Memory,PCM)、石墨烯存储器等。易失性存储器可包括随机存取存储器(Random Access Memory,RAM)或外部高速缓冲存储器等。作为说明而非局限,RAM可以是多种形式,比如静态随机存取存储器(Static Random Access Memory,SRAM)或动态随机存取存储器(DynamicRandomAccess Memory,DRAM)等。Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM may be in various forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM).

本申请所提供的各实施例中所涉及的数据库可包括关系型数据库和非关系型数据库中至少一种。非关系型数据库可包括基于区块链的分布式数据库等,不限于此。本申请所提供的各实施例中所涉及的处理器可为通用处理器、中央处理器、图形处理器、数字信号处理器、可编程逻辑器、基于量子计算的数据处理逻辑器等,不限于此。The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. The non-relational database may include a distributed database based on blockchain, etc., but is not limited thereto. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but is not limited thereto.

以上实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

本文中应用了具体个例对本申请的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本申请的方法及其核心思想;同时,对于本领域的一般技术人员,依据本申请的思想,在具体实施方式及应用范围上均会有改变之处。综上所述,本说明书内容不应理解为对本申请的限制。This article uses specific examples to illustrate the principles and implementation methods of this application. The description of the above embodiments is only used to help understand the method and core ideas of this application. At the same time, for those skilled in the art, according to the ideas of this application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting this application.

Claims (10)

1.一种多类型负载的资源统一调度方法,其特征在于,所述多类型负载的资源统一调度方法包括:1. A method for unified resource scheduling of multiple types of loads, characterized in that the method for unified resource scheduling of multiple types of loads comprises: 接收不同类型的目标作业负载类型的应用任务,以及各个所述目标作业负载类型的应用任务对应的资源需求信息,其中,所述不同类型的目标作业负载类型的应用任务至少包括图形应用会话任务;Receiving application tasks of different types of target workload types and resource requirement information corresponding to each of the application tasks of the target workload types, wherein the application tasks of the different types of target workload types at least include a graphics application session task; 根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;所述集群资源信息表中包括:集群中,各个服务器的属性信息、已用资源信息和空闲资源信息;According to the resource demand information corresponding to the application task of the current target workload type, searching the cluster resource information table for a candidate server that meets the resource demand information corresponding to the application task of the current target workload type; the cluster resource information table includes: attribute information, used resource information and idle resource information of each server in the cluster; 在所述候选服务器中选择负载最低的服务器作为第一目标服务器;Selecting a server with the lowest load among the candidate servers as the first target server; 将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第一目标服务器,以使所述第一目标服务器运行所述当前目标作业负载类型的应用任务。The application tasks of the current target workload type and resource requirement information corresponding to the application tasks of the current target workload type are sent to the first target server, so that the first target server runs the application tasks of the current target workload type. 2.根据权利要求1所述的多类型负载的资源统一调度方法,其特征在于,2. The method for unified resource scheduling of multiple types of loads according to claim 1, characterized in that: 所述第一目标服务器为正在运行应用任务但有空闲资源的服务器,所述空闲资源可以满足所述当前目标作业负载类型的应用任务对应的资源需求信息,且所述第一目标服务器正在运行的应用任务与所述当前目标作业负载类型的应用任务不相同,在运行了所述当前目标作业负载类型的应用任务后,所述第一目标服务器中运行了不同类型的应用任务。The first target server is a server that is running application tasks but has idle resources. The idle resources can meet the resource demand information corresponding to the application tasks of the current target job load type, and the application tasks running on the first target server are different from the application tasks of the current target job load type. After running the application tasks of the current target job load type, different types of application tasks run in the first target server. 3.根据权利要求1所述的多类型负载的资源统一调度方法,其特征在于,所述根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,包括:3. The method for unified resource scheduling of multiple types of loads according to claim 1, characterized in that searching the cluster resource information table for a candidate server that meets the resource demand information corresponding to the application task of the current target workload type according to the resource demand information corresponding to the application task of the current target workload type comprises: 获取所述当前目标作业负载类型的应用任务对应的运行时间,将其放入对应的目标时间窗口中,其中,不同的时间窗口对应不同的运行时间段,且不同类型的目标作业负载类型的应用任务对应不同的运行时间段;Obtaining the running time corresponding to the application task of the current target workload type, and placing it into the corresponding target time window, wherein different time windows correspond to different running time periods, and application tasks of different types of target workload types correspond to different running time periods; 若当前时间满足所述目标时间窗口对应的时间段要求,则根据所述当前目标作业负载类型的应用任务对应的资源需求信息,在所述集群资源信息表中查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的所述候选服务器;If the current time meets the time period requirement corresponding to the target time window, searching the cluster resource information table for the candidate server that meets the resource requirement information corresponding to the application task of the current target workload type according to the resource requirement information corresponding to the application task of the current target workload type; 若当前时间不满足所述目标时间窗口对应的时间段要求,向所述当前目标作业负载类型的应用任务对应的终端设备发送拒绝处理指令,所述拒绝处理指令指示当前时间不满足所述当前目标作业负载类型的应用任务对应的运行时间;或者,将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息放入对应的等待队列中排队,并在检测到满足所述目标时间窗口对应的时间段要求时,根据所述当前目标作业负载类型的应用任务对应的资源需求信息,在所述集群资源信息表中重新查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的所述候选服务器。If the current time does not meet the time period requirement corresponding to the target time window, a rejection processing instruction is sent to the terminal device corresponding to the application task of the current target job load type, and the rejection processing instruction indicates that the current time does not meet the running time corresponding to the application task of the current target job load type; or, the application task of the current target job load type and the resource demand information corresponding to the application task of the current target job load type are placed in a corresponding waiting queue, and when it is detected that the time period requirement corresponding to the target time window is met, the candidate server that meets the resource demand information corresponding to the application task of the current target job load type is re-searched in the cluster resource information table according to the resource demand information corresponding to the application task of the current target job load type. 4.根据权利要求1所述的多类型负载的资源统一调度方法,其特征在于,所述多类型负载的资源统一调度方法,还包括:4. The method for unified resource scheduling of multiple types of loads according to claim 1, characterized in that the method for unified resource scheduling of multiple types of loads further comprises: 若在所述集群资源信息表中未查找到满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,获取所述当前目标作业负载类型的应用任务的优先级;If no candidate server that meets the resource requirement information corresponding to the application task of the current target workload type is found in the cluster resource information table, obtaining the priority of the application task of the current target workload type; 检测所述集群的各个所述服务器中是否有第二目标服务器,其中,所述第二目标服务器中正在运行的第一应用任务的负载类型的优先级低于所述当前目标作业负载类型的应用任务的优先级,且所述第二目标服务器在释放了为正在运行的第一应用任务分配的资源后,所述第二目标服务器中的空闲资源满足所述当前目标作业负载类型的应用任务对应的资源需求信息;Detecting whether there is a second target server among the servers of the cluster, wherein the priority of the load type of the first application task running in the second target server is lower than the priority of the application task of the current target workload type, and after the second target server releases the resources allocated to the running first application task, the idle resources in the second target server meet the resource demand information corresponding to the application task of the current target workload type; 控制所述第二目标服务器将正在运行的第一应用任务挂起或终止,以使所述第二目标服务器释放为所述第一应用任务分配的资源;Controlling the second target server to suspend or terminate the running first application task, so that the second target server releases the resources allocated to the first application task; 将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第二目标服务器,以让所述第二目标服务器运行所述当前目标作业负载类型的应用任务;Sending the application tasks of the current target workload type and resource requirement information corresponding to the application tasks of the current target workload type to the second target server, so that the second target server runs the application tasks of the current target workload type; 在检测到所述当前目标作业负载类型的应用任务运行完成后,控制所述第二目标服务器继续运行所述第一应用任务。After detecting that the application task of the current target workload type has finished running, controlling the second target server to continue running the first application task. 5.根据权利要求1所述的多类型负载的资源统一调度方法,其特征在于,在所述目标作业负载类型的应用任务为图形应用会话任务时,所述多类型负载的资源统一调度方法,还包括:5. The method for unified resource scheduling of multiple types of loads according to claim 1, characterized in that when the application task of the target workload type is a graphic application session task, the method for unified resource scheduling of multiple types of loads further comprises: 若在集群资源信息表中未查找到满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,检测所述集群中是否有第三目标服务器,其中,所述第三目标服务器中正在运行与所述当前目标作业负载类型的应用任务属于同一终端设备的其他应用任务,所述其他应用任务的负载类型与所述当前目标作业负载类型相同;If no candidate server that satisfies the resource requirement information corresponding to the application task of the current target job load type is found in the cluster resource information table, detecting whether there is a third target server in the cluster, wherein the third target server is running other application tasks belonging to the same terminal device as the application task of the current target job load type, and the load type of the other application tasks is the same as the current target job load type; 若有,将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第三目标服务器。If yes, the application tasks of the current target workload type and the resource demand information corresponding to the application tasks of the current target workload type are sent to the third target server. 6.根据权利要求1-5任一项所述的多类型负载的资源统一调度方法,其特征在于,所述多类型负载的资源统一调度方法,还包括:6. The method for unified resource scheduling of multiple types of loads according to any one of claims 1 to 5, characterized in that the method for unified resource scheduling of multiple types of loads further comprises: 接收集群中的各个所述服务器发送的集群资源更新信息,所述集群资源更新信息中包括:当前时间点对应的各个所述服务器的已用资源信息和空闲资源信息;Receiving cluster resource update information sent by each of the servers in the cluster, wherein the cluster resource update information includes: used resource information and idle resource information of each of the servers corresponding to a current time point; 根据所述集群资源更新信息更新所述集群资源信息表。The cluster resource information table is updated according to the cluster resource update information. 7.一种多类型负载的资源统一调度系统,其特征在于,所述多类型负载的资源统一调度系统包括:7. A unified resource scheduling system for multiple types of loads, characterized in that the unified resource scheduling system for multiple types of loads comprises: 终端设备、调度服务器和包括多个服务器的集群,其中,多个所述服务器包括第一目标服务器;A terminal device, a scheduling server and a cluster including a plurality of servers, wherein the plurality of servers include a first target server; 所述终端设备,用于向所述调度服务器发送不同类型的目标作业负载类型的应用任务,以及各个所述目标作业负载类型的应用任务对应的资源需求信息,其中,所述不同类型的目标作业负载类型的应用任务至少包括图形应用会话任务;The terminal device is used to send application tasks of different types of target workload types and resource requirement information corresponding to each application task of the target workload type to the scheduling server, wherein the application tasks of different types of target workload types at least include graphic application session tasks; 所述调度服务器,用于根据当前目标作业负载类型的应用任务对应的资源需求信息,在集群资源信息表中查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;所述集群资源信息表中包括:集群中,各个服务器的属性信息、已用资源信息和空闲资源信息;The scheduling server is used to search for a candidate server that meets the resource demand information corresponding to the application task of the current target workload type in the cluster resource information table according to the resource demand information corresponding to the application task of the current target workload type; the cluster resource information table includes: attribute information, used resource information and idle resource information of each server in the cluster; 所述调度服务器,用于在所述候选服务器中选择负载最低的服务器作为第一目标服务器,并将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第一目标服务器;The scheduling server is used to select the server with the lowest load from the candidate servers as the first target server, and send the application tasks of the current target workload type and the resource demand information corresponding to the application tasks of the current target workload type to the first target server; 所述第一目标服务器,用于在接收到所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息后,根据所述当前目标作业负载类型的应用任务对应的资源需求信息运行所述当前目标作业负载类型的应用任务。The first target server is used to run the application task of the current target job load type according to the resource requirement information corresponding to the application task of the current target job load type after receiving the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type. 8.根据权利要求7所述的多类型负载的资源统一调度系统,其特征在于,8. The resource unified scheduling system for multiple types of loads according to claim 7, characterized in that: 所述第一目标服务器为正在运行应用任务但有空闲资源的服务器,所述空闲资源可以满足所述当前目标作业负载类型的应用任务对应的资源需求信息,且所述第一目标服务器正在运行的应用任务与所述当前目标作业负载类型的应用任务不相同,在运行了所述当前目标作业负载类型的应用任务后,所述第一目标服务器中运行了不同类型的应用任务。The first target server is a server that is running application tasks but has idle resources. The idle resources can meet the resource demand information corresponding to the application tasks of the current target job load type, and the application tasks running on the first target server are different from the application tasks of the current target job load type. After running the application tasks of the current target job load type, different types of application tasks run in the first target server. 9.根据权利要求7所述的多类型负载的资源统一调度系统,其特征在于,所述调度服务器,具体用于:9. The unified resource scheduling system for multiple types of loads according to claim 7, wherein the scheduling server is specifically used to: 获取所述当前目标作业负载类型的应用任务对应的运行时间,将其放入对应的目标时间窗口中,其中,不同的时间窗口对应不同的运行时间段,且不同类型的目标作业负载类型的应用任务对应不同的运行时间段;Obtaining the running time corresponding to the application task of the current target workload type, and placing it into the corresponding target time window, wherein different time windows correspond to different running time periods, and application tasks of different types of target workload types correspond to different running time periods; 若当前时间满足所述目标时间窗口对应的时间段要求,则根据所述当前目标作业负载类型的应用任务对应的资源需求信息,在所述集群资源信息表中查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器;If the current time meets the time period requirement corresponding to the target time window, then according to the resource requirement information corresponding to the application task of the current target workload type, search the cluster resource information table for a candidate server that meets the resource requirement information corresponding to the application task of the current target workload type; 若当前时间不满足所述目标时间窗口对应的时间段要求,向所述当前目标作业负载类型的应用任务对应的终端设备发送拒绝处理指令,所述拒绝处理指令指示当前时间不满足所述当前目标作业负载类型的应用任务对应的运行时间;或者,将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息存入缓存中,并在检测到满足所述目标时间窗口对应的时间段要求时,根据所述当前目标作业负载类型的应用任务对应的资源需求信息,在所述集群资源信息表中重新查找满足所述当前目标作业负载类型的应用任务对应的资源需求信息的所述候选服务器。If the current time does not meet the time period requirement corresponding to the target time window, a rejection processing instruction is sent to the terminal device corresponding to the application task of the current target job load type, and the rejection processing instruction indicates that the current time does not meet the running time corresponding to the application task of the current target job load type; or, the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type are stored in the cache, and when it is detected that the time period requirement corresponding to the target time window is met, the candidate server that meets the resource requirement information corresponding to the application task of the current target job load type is re-searched in the cluster resource information table according to the resource requirement information corresponding to the application task of the current target job load type. 10.根据权利要求7所述的多类型负载的资源统一调度系统,其特征在于,10. The resource unified scheduling system for multiple types of loads according to claim 7, characterized in that: 所述调度服务器,还用于:若在集群资源信息表中未查找到满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,获取所述当前目标作业负载类型的应用任务的优先级;检测所述集群的各个所述服务器中是否有第二目标服务器,其中,所述第二目标服务器中正在运行的第一应用任务的负载类型的优先级低于所述当前目标作业负载类型的应用任务的优先级,且所述第二目标服务器在释放了为正在运行的第一应用任务分配的资源后,所述第二目标服务器中的空闲资源满足所述当前目标作业负载类型的应用任务对应的资源需求信息;控制所述第二目标服务器将正在运行的第一应用任务挂起或终止,以使所述第二目标服务器释放为所述第一应用任务分配的资源;将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第二目标服务器,以让所述第二目标服务器运行所述当前目标作业负载类型的应用任务;在检测到所述当前目标作业负载类型的应用任务运行完成后,控制所述第二目标服务器继续运行所述第一应用任务;The scheduling server is further used for: if a candidate server that satisfies the resource requirement information corresponding to the application task of the current target job load type is not found in the cluster resource information table, obtaining the priority of the application task of the current target job load type; detecting whether there is a second target server in each of the servers in the cluster, wherein the priority of the load type of the first application task running in the second target server is lower than the priority of the application task of the current target job load type, and after the second target server releases the resources allocated to the running first application task, the idle resources in the second target server meet the resource requirement information corresponding to the application task of the current target job load type; controlling the second target server to suspend or terminate the running first application task so that the second target server releases the resources allocated to the first application task; sending the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type to the second target server, so that the second target server runs the application task of the current target job load type; after detecting that the application task of the current target job load type has completed running, controlling the second target server to continue running the first application task; 或者,or, 所述调度服务器,还用于:在所述目标作业负载类型的应用任务为图形应用会话任务时,若在集群资源信息表中未查找到满足所述当前目标作业负载类型的应用任务对应的资源需求信息的候选服务器,检测所述集群中是否有第三目标服务器,其中,所述第三目标服务器中正在运行与所述当前目标作业负载类型的应用任务属于同一终端设备的其他应用任务,所述其他应用任务的负载类型与所述当前目标作业负载类型相同; 若有,将所述当前目标作业负载类型的应用任务和所述当前目标作业负载类型的应用任务对应的资源需求信息发送给所述第三目标服务器。The scheduling server is also used for: when the application task of the target job load type is a graphic application session task, if a candidate server that meets the resource requirement information corresponding to the application task of the current target job load type is not found in the cluster resource information table, detecting whether there is a third target server in the cluster, wherein the third target server is running other application tasks belonging to the same terminal device as the application task of the current target job load type, and the load type of the other application tasks is the same as the current target job load type; if so, sending the application task of the current target job load type and the resource requirement information corresponding to the application task of the current target job load type to the third target server.
CN202411295538.XA 2024-09-18 2024-09-18 Unified scheduling method and system for resources of multiple types of loads Active CN118819864B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202411295538.XA CN118819864B (en) 2024-09-18 2024-09-18 Unified scheduling method and system for resources of multiple types of loads

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202411295538.XA CN118819864B (en) 2024-09-18 2024-09-18 Unified scheduling method and system for resources of multiple types of loads

Publications (2)

Publication Number Publication Date
CN118819864A true CN118819864A (en) 2024-10-22
CN118819864B CN118819864B (en) 2024-12-20

Family

ID=93066006

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202411295538.XA Active CN118819864B (en) 2024-09-18 2024-09-18 Unified scheduling method and system for resources of multiple types of loads

Country Status (1)

Country Link
CN (1) CN118819864B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN119537032A (en) * 2025-01-21 2025-02-28 北京亿安天下科技股份有限公司 Large model reasoning scheduling method based on off-grid computing server
CN119718688A (en) * 2025-02-28 2025-03-28 北京涵鑫盛科技有限公司 Cluster load balancing processing method based on cloud computing

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110333939A (en) * 2019-06-17 2019-10-15 腾讯科技(成都)有限公司 Task mixed scheduling method, device, dispatch server and Resource Server
CN111488210A (en) * 2020-04-02 2020-08-04 腾讯科技(深圳)有限公司 Task scheduling method and device based on cloud computing and computer equipment
CN116467053A (en) * 2022-01-11 2023-07-21 中国移动通信有限公司研究院 Resource scheduling method and device, equipment, storage medium
CN118394468A (en) * 2024-04-16 2024-07-26 北京车智慧信息技术有限公司 Task scheduling method, system and computing device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110333939A (en) * 2019-06-17 2019-10-15 腾讯科技(成都)有限公司 Task mixed scheduling method, device, dispatch server and Resource Server
CN111488210A (en) * 2020-04-02 2020-08-04 腾讯科技(深圳)有限公司 Task scheduling method and device based on cloud computing and computer equipment
CN116467053A (en) * 2022-01-11 2023-07-21 中国移动通信有限公司研究院 Resource scheduling method and device, equipment, storage medium
CN118394468A (en) * 2024-04-16 2024-07-26 北京车智慧信息技术有限公司 Task scheduling method, system and computing device

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN119537032A (en) * 2025-01-21 2025-02-28 北京亿安天下科技股份有限公司 Large model reasoning scheduling method based on off-grid computing server
CN119537032B (en) * 2025-01-21 2025-05-20 北京亿安天下科技股份有限公司 Large model reasoning scheduling method based on off-network computing power server
CN119718688A (en) * 2025-02-28 2025-03-28 北京涵鑫盛科技有限公司 Cluster load balancing processing method based on cloud computing

Also Published As

Publication number Publication date
CN118819864B (en) 2024-12-20

Similar Documents

Publication Publication Date Title
CN112463709B (en) Configurable heterogeneous AI processor
CN112465129B (en) On-chip heterogeneous artificial intelligent processor
JP6381956B2 (en) Dynamic virtual machine sizing
CN105893126B (en) A task scheduling method and device
US8914805B2 (en) Rescheduling workload in a hybrid computing environment
US7650601B2 (en) Operating system kernel-assisted, self-balanced, access-protected library framework in a run-to-completion multi-processor environment
CN118819864A (en) Resource unified scheduling method and system for multiple types of loads
CN106897132A (en) The method and device of a kind of server task scheduling
CN118069379B (en) Scheduling realization method based on GPU resources
CN116541134A (en) Method and device for deploying containers in multi-architecture cluster
CN111459622B (en) Method, device, computer equipment and storage medium for scheduling virtual CPU
CN115686805A (en) GPU resource sharing method and device, and GPU resource sharing scheduling method and device
CN109800092A (en) A kind of processing method of shared data, device and server
CN116578416B (en) Signal-level simulation acceleration method based on GPU virtualization
CN114816709A (en) Task scheduling method, device, server and readable storage medium
CN112114958B (en) Resource isolation method, distributed platform, computer device and storage medium
CN114968567A (en) Method, apparatus and medium for allocating computing resources of computing nodes
US20250181385A1 (en) Latency service level agreement based scheduling of operating system threads at cloud services
CN114721818A (en) Kubernetes cluster-based GPU time-sharing method and system
CN117472570A (en) Methods, apparatus, electronic devices and media for scheduling accelerator resources
US11954534B2 (en) Scheduling in a container orchestration system utilizing hardware topology hints
CN115345011A (en) Simulation method and device giving consideration to load balancing and related equipment
CN104598311A (en) Method and device for real-time operation fair scheduling for Hadoop
Chen et al. Improving hadoop monetary efficiency in the cloud using spot instances
US12608220B2 (en) Virtualization method, device, board card and computer readable 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