CN111736981A - Container resource configuration method, apparatus, device and storage medium - Google Patents
Container resource configuration method, apparatus, device and storage medium Download PDFInfo
- Publication number
- CN111736981A CN111736981A CN201910708644.9A CN201910708644A CN111736981A CN 111736981 A CN111736981 A CN 111736981A CN 201910708644 A CN201910708644 A CN 201910708644A CN 111736981 A CN111736981 A CN 111736981A
- Authority
- CN
- China
- Prior art keywords
- resource
- target
- container
- resources
- spare
- 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.)
- Pending
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5011—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5011—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
- G06F9/5016—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals the resource being the memory
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5027—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5027—Allocation 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/505—Allocation 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
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Debugging And Monitoring (AREA)
Abstract
Description
技术领域technical field
本发明实施例涉及计算机技术,尤其涉及一种容器资源配置方法、装置、设备和存储介质。Embodiments of the present invention relate to computer technologies, and in particular, to a container resource configuration method, apparatus, device, and storage medium.
背景技术Background technique
诸如互联网服务、电商服务、公有云、私有云和物联网等平台的数据中心通常运行在服务器或服务器集群(称为物理机)上,目前物理机的标准架构多使用容器和微服务技术,以实现服务器资源共享。在容器平台上,一台物理机可以运行多个互相隔离、独立运行的容器;一个业务或应用分成多个逻辑独立的微服务,微服务的实例运行在容器里。Data centers for platforms such as Internet services, e-commerce services, public clouds, private clouds, and the Internet of Things usually run on servers or server clusters (called physical machines). Currently, the standard architecture of physical machines mostly uses container and microservice technologies. to share server resources. On the container platform, a physical machine can run multiple containers that are isolated from each other and run independently; a business or application is divided into multiple logically independent microservices, and instances of microservices run in containers.
为了满足服务性能和优化资源利用率,需要给容器配置合适大小的资源,如中央处理器(Central Processing Unit,CPU)资源、内部存储器(Memory)空间及磁盘(Disk)空间等。配置过多的资源虽然能保证容器或服务的性能,但是会浪费资源;反过来,如果资源配置不足,又不能保证容器或服务的性能。所以,配置合适的容器资源以便既能保证性能又不浪费资源是物理机高效运行的至关重要的问题,尤其对于负载变动很大且性能要求严格的在线服务,比如电商服务。In order to meet service performance and optimize resource utilization, it is necessary to configure the container with resources of appropriate size, such as central processing unit (Central Processing Unit, CPU) resources, internal memory (Memory) space, and disk (Disk) space. Configuring too many resources can guarantee the performance of the container or service, but it will waste resources; conversely, if the resource allocation is insufficient, the performance of the container or service cannot be guaranteed. Therefore, configuring appropriate container resources to ensure performance without wasting resources is a crucial issue for the efficient operation of physical machines, especially for online services with large load changes and strict performance requirements, such as e-commerce services.
目前实现容器资源配置的方法主要有:第一,基于最大值的容器资源配置。该方案可以根据管理员经验来估计一个容器承载服务所需的最大需求资源,或者对一个容器的历史资源使用数据进行分析以确定该容器的最大使用资源,从而根据最大需求资源或最大使用资源比较保守地为该容器配置资源,保证在最大负载时也能满足性能。第二,基于百分位的容器资源配置。该方案是在确定最大值的情况下,根据最大值和某个百分位(如90%百分位)来决定一个容器的资源配置,以保证90%的资源需求能够被满足。第三,动态容器资源配置。该方案需要实时监测一个容器的当前负载,并周期性地调整最大值,以动态地调整该容器的资源配置。At present, the methods for realizing container resource configuration mainly include: first, the container resource configuration based on the maximum value. This solution can estimate the maximum demanded resources required by a container to host services based on the administrator's experience, or analyze the historical resource usage data of a container to determine the maximum used resources of the container, so as to compare the maximum demanded resources or the maximum used resources Conservatively configure resources for this container to ensure that performance can be met under maximum load. Second, percentile-based container resource configuration. The solution is to determine the resource configuration of a container according to the maximum value and a certain percentile (eg, 90% percentile) in the case of determining the maximum value, so as to ensure that 90% of the resource requirements can be satisfied. Third, dynamic container resource configuration. This solution needs to monitor the current load of a container in real time and adjust the maximum value periodically to dynamically adjust the resource configuration of the container.
在实现本发明过程中,发明人发现现有技术中至少存在如下问题:第一,基于最大值的容器资源配置尽管可以保证性能,但是对于负载和需求非常动态的容器和服务,比如互联网服务和在线服务,很多时候并不需要最大资源,因此会浪费很多资源和增加服务器成本。第二,基于百分位的容器资源配置虽然可以在一定程度上节省资源,但是其不能保证满足所有负载和请求的资源需求,会导致一定的性能冲突,而对于重要的在线服务,比如电商业务,甚至1%的性能问题都可能造成很大损失。第三,动态容器资源配置因技术不够成熟,存在稳定性和准确性问题,目前无法进行大规模应用。In the process of implementing the present invention, the inventor found that there are at least the following problems in the prior art: First, although the maximum value-based container resource configuration can guarantee the performance, it is difficult for containers and services whose load and demand are very dynamic, such as Internet services and Online services, many times do not require maximum resources, so it will waste a lot of resources and increase server costs. Second, although the percentile-based container resource configuration can save resources to a certain extent, it cannot guarantee to meet the resource requirements of all loads and requests, which will lead to certain performance conflicts. For important online services, such as e-commerce Business, even a 1% performance issue can cost a lot. Third, dynamic container resource allocation cannot be applied on a large scale due to the immature technology, stability and accuracy problems.
发明内容SUMMARY OF THE INVENTION
本发明实施例提供一种容器资源配置方法、装置、设备和存储介质,以实现更加合理地配置容器资源,提供性能保证的同时节省资源。Embodiments of the present invention provide a container resource configuration method, apparatus, device, and storage medium, so as to realize a more rational configuration of container resources, provide performance assurance, and save resources at the same time.
第一方面,本发明实施例提供了一种容器资源配置方法,包括:In a first aspect, an embodiment of the present invention provides a container resource configuration method, including:
获取目标容器的资源配置最大值,并依据所述资源配置最大值和目标百分位确定所述目标容器的目标私有资源和目标备用资源;Obtain the maximum resource configuration value of the target container, and determine the target private resource and target backup resource of the target container according to the resource configuration maximum value and the target percentile;
依据所述目标备用资源和所述目标容器对应的物理机中除所述目标容器外的至少一个其余容器的其余备用资源,确定所述目标容器对应的共享备用资源;Determine the shared backup resource corresponding to the target container according to the target backup resource and the remaining backup resources of at least one other container except the target container in the physical machine corresponding to the target container;
依据所述目标私有资源和所述共享备用资源配置所述目标容器的资源。The resources of the target container are configured according to the target private resource and the shared spare resource.
第二方面,本发明实施例还提供了一种容器资源配置装置,该装置包括:In a second aspect, an embodiment of the present invention further provides an apparatus for configuring container resources, the apparatus including:
目标私有资源确定模块,用于获取目标容器的资源配置最大值,并依据所述资源配置最大值和目标百分位确定所述目标容器的目标私有资源和目标备用资源;a target private resource determination module, configured to obtain the maximum resource configuration value of the target container, and determine the target private resource and target backup resource of the target container according to the resource configuration maximum value and the target percentile;
共享备用资源确定模块,用于依据所述目标备用资源和所述目标容器对应的物理机中除所述目标容器外的至少一个其余容器的其余备用资源,确定所述目标容器对应的共享备用资源;A shared spare resource determination module, configured to determine the shared spare resource corresponding to the target container according to the target spare resource and the remaining spare resources of at least one other container except the target container in the physical machine corresponding to the target container ;
容器资源配置模块,用于依据所述目标私有资源和所述共享备用资源配置所述目标容器的资源。A container resource configuration module, configured to configure resources of the target container according to the target private resource and the shared backup resource.
第三方面,本发明实施例还提供了一种设备,该设备包括:In a third aspect, an embodiment of the present invention further provides a device, and the device includes:
一个或多个处理器;one or more processors;
存储装置,用于存储一个或多个程序,storage means for storing one or more programs,
当所述一个或多个程序被所述一个或多个处理器执行,使得所述一个或多个处理器实现本发明任意实施例所提供的容器资源配置方法。When the one or more programs are executed by the one or more processors, the one or more processors implement the container resource configuration method provided by any embodiment of the present invention.
第四方面,本发明实施例还提供了一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现本发明任意实施例所提供的容器资源配置方法。In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, implements the container resource configuration method provided by any embodiment of the present invention.
本发明实施例通过获取目标容器的资源配置最大值,并依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源,实现了将一个容器的资源分为两部分,目标私有资源为容器独立使用的资源,以满足容器的大部分性能需求,而目标备用资源将用于确定共享备用资源,以满足超出目标私有资源的额外需求,解决了资源浪费和减少资源导致性能冲突的问题,一定程度上优化了资源利用率且兼顾性能保证。通过依据目标备用资源和目标容器对应的物理机中除目标容器外的至少一个其余容器的其余备用资源,确定目标容器对应的共享备用资源,实现了在配置一个容器的资源时综合考虑物理机上多个容器的资源配置,使得多个容器可以共用共享备用资源,解决了孤立地配置单个容器资源而导致的资源和性能无法兼顾的问题,达到了更加合理地配置容器资源,使得配置的容器资源既能保证性能又能更大程度地节省资源的技术效果。The embodiment of the present invention realizes that the resources of a container are divided into two parts by obtaining the maximum resource configuration value of the target container, and determining the target private resources and target backup resources of the target container according to the maximum resource configuration value and the target percentile. The private resource is the resource used independently by the container to meet most of the performance requirements of the container, and the target spare resource will be used to determine the shared spare resource to meet the additional demand beyond the target private resource, which solves the waste of resources and reduces the performance conflicts caused by resources To a certain extent, the resource utilization is optimized and the performance guarantee is taken into account. By determining the shared spare resource corresponding to the target container according to the target spare resource and the remaining spare resources of at least one other container except the target container in the physical machine corresponding to the target container, it is possible to comprehensively consider the multiple resources on the physical machine when configuring the resources of a container. The resource configuration of each container enables multiple containers to share and share spare resources, solves the problem of inability to balance resources and performance caused by configuring a single container resource in isolation, and achieves a more reasonable configuration of container resources, so that the configured container resources are both The technical effect of ensuring performance and saving resources to a greater extent.
附图说明Description of drawings
图1是本发明实施例一中的一种容器资源配置方法的流程图;FIG. 1 is a flowchart of a container resource configuration method in Embodiment 1 of the present invention;
图2是本发明实施例二中的一种容器资源配置方法的流程图;2 is a flowchart of a container resource configuration method in Embodiment 2 of the present invention;
图3a是本发明实施例三中的一种容器资源配置方法的流程图;3a is a flowchart of a container resource configuration method in Embodiment 3 of the present invention;
图3b是本发明实施例三中的两个容器资源配置结果示意图;FIG. 3b is a schematic diagram of a configuration result of two container resources in Embodiment 3 of the present invention;
图3c是本发明实施例三中的另一种容器资源配置方法的流程图;3c is a flowchart of another container resource configuration method in Embodiment 3 of the present invention;
图3d是本发明实施例三中的分容器类别的资源配置结果示意图;FIG. 3d is a schematic diagram of a resource configuration result of sub-container categories in Embodiment 3 of the present invention;
图3e是本发明实施例三中的基于不同的容器资源配置方法配置容器资源的结果比较示意图;FIG. 3e is a schematic diagram of a comparison of results of configuring container resources based on different container resource configuration methods in Embodiment 3 of the present invention;
图4是本发明实施例四中的一种容器资源配置装置的结构示意图;4 is a schematic structural diagram of a container resource configuration device according to
图5是本发明实施例五中的一种设备的结构示意图。FIG. 5 is a schematic structural diagram of a device in
具体实施方式Detailed ways
下面结合附图和实施例对本发明作进一步的详细说明。可以理解的是,此处所描述的具体实施例仅仅用于解释本发明,而非对本发明的限定。另外还需要说明的是,为了便于描述,附图中仅示出了与本发明相关的部分而非全部结构。The present invention will be further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention, but not to limit the present invention. In addition, it should be noted that, for the convenience of description, the drawings only show some but not all structures related to the present invention.
实施例一Example 1
本实施例提供的容器资源配置方法可适用于数据中心的服务器或服务器集群架构中的容器资源分配。该方法可以由容器资源配置装置来执行,该装置可以由软件和/或硬件的方式实现,该装置可以集成在基于容器技术架构的设备中,例如个人计算机、服务器、服务器集群或智能设备集群等。参见图1,本实施例的方法具体包括如下步骤:The container resource configuration method provided in this embodiment is applicable to container resource allocation in a server of a data center or a server cluster architecture. The method may be performed by a container resource configuration apparatus, which may be implemented in software and/or hardware, and the apparatus may be integrated in a device based on a container technology architecture, such as a personal computer, a server, a server cluster, or a smart device cluster, etc. . Referring to FIG. 1, the method of this embodiment specifically includes the following steps:
S110、获取目标容器的资源配置最大值,并依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源。S110. Acquire the maximum resource configuration value of the target container, and determine the target private resources and target backup resources of the target container according to the maximum resource configuration value and the target percentile.
其中,目标容器是待配置资源的容器,其可以是一个容器,也可以是多个容器。目标容器可以是新创建的容器,也可以是已经创建并运行的容器。这里的资源可以是CPU资源、内部存储器(内存)资源、显卡内存(显存)资源和磁盘资源中的至少一种。资源配置最大值是指需要为目标容器配置的资源最大值,其可以是资源需求最大值,也可以是历史资源使用最大值。资源需求最大值是指容器承载的服务所需要的最大资源,例如根据容器需要承载的服务来经验性地确定该容器需要多少资源。历史资源使用最大值是指容器在运行过程中实际使用的资源中的最大值。目标百分位是一个预先确定的百分位值,其用于确定目标容器的目标私有资源。目标百分位可以是一个预先确定的固定数值,例如经验性的90%,也可以是一个根据容器运行状态动态变化的动态值。目标私有资源是指目标容器私有的资源,其直接分配给目标容器,且只能供目标容器使用。目标备用资源是指为目标容器计算的备用资源,其并不直接分配给目标容器,只是一个概念层面的资源。The target container is a container of resources to be configured, which may be one container or multiple containers. The target container can be a newly created container or an already created and running container. The resources here may be at least one of CPU resources, internal memory (memory) resources, graphics card memory (video memory) resources, and disk resources. The maximum resource configuration refers to the maximum resource that needs to be configured for the target container, which can be the maximum resource requirement or the maximum historical resource usage. The maximum resource requirement refers to the maximum resource required by the service carried by the container, for example, how much resources the container needs is determined empirically according to the service that the container needs to carry. The maximum value of historical resource usage refers to the maximum value of the resources actually used by the container during the running process. The target percentile is a predetermined percentile value used to determine the target private resource for the target container. The target percentile can be a predetermined fixed value, such as an empirical 90%, or a dynamic value that changes dynamically according to the running state of the container. Target private resources refer to resources private to the target container, which are directly allocated to the target container and can only be used by the target container. The target spare resource refers to the spare resource calculated for the target container, which is not directly allocated to the target container, but is only a resource at the conceptual level.
相关技术中在为容器确定配置资源时,要么基于资源配置最大值(可以是固定值或动态值),要么基于百分位的资源值,无论哪一种都会存在一定的缺陷,无法兼顾容器性能保证和资源高利用率,故本发明实施例在为目标容器配置资源时,将所配置的资源分为两个部分,即目标私有资源和目标备用资源,该目标私有资源用于满足容器大部分的性能的资源需求,以保证目标容器大部分的性能;目标备用资源作为可选资源,用于提供超出目标私有资源的资源需求,以保证目标容器额外的性能。这样的设置,既不会为目标容器分配过多的资源,又能为其性能提供足够的保证,很大程度上兼顾资源利用率和性能保证。In the related art, when determining configuration resources for a container, it is either based on the maximum resource configuration value (which can be a fixed value or a dynamic value), or based on a percentile resource value. Either one will have certain defects and cannot take into account the performance of the container. Therefore, when configuring resources for a target container in this embodiment of the present invention, the configured resources are divided into two parts, that is, target private resources and target backup resources, and the target private resources are used to satisfy most of the container’s requirements. The resource requirements for the performance of the target container are used to ensure most of the performance of the target container; the target spare resources are used as optional resources to provide resource requirements beyond the target private resources to ensure the additional performance of the target container. Such a setting will not allocate too many resources to the target container, but also provide sufficient guarantee for its performance, taking into account resource utilization and performance guarantee to a large extent.
示例性地,获取目标容器的资源配置最大值包括:获取目标容器对应的历史资源使用数据,并依据历史资源使用数据确定目标容器的历史资源使用最大值,作为资源配置最大值。Exemplarily, obtaining the maximum resource configuration of the target container includes: obtaining historical resource usage data corresponding to the target container, and determining the maximum historical resource usage of the target container according to the historical resource usage data as the maximum resource configuration.
其中,历史资源使用数据是指容器在当前时刻之前的历史时间段内实际运行时使用的资源的数据,其可以是时间连续的资源使用数据,即历史资源使用时序数据,也可以是时间不连续的资源使用数据。Among them, the historical resource usage data refers to the data of the resources actually used by the container in the historical time period before the current moment. resource usage data.
当资源配置最大值为历史资源使用最大值时,需要获取目标容器在当前时刻之前的一段时间内的资源使用数据,即历史资源使用数据。若目标容器为新创建的容器时,可以获取负载特征相同的同类容器的历史资源使用数据作为目标容器的历史资源使用数据。这里的负载特征是指CPU、内存、显存和磁盘存储等。这时目标容器的资源配置过程便是创建容器的资源配置过程。若目标容器为已经创建并运行的容器,那么直接获取该目标容器的历史资源使用数据即可。这时目标容器的资源配置过程便是更新容器资源的过程。When the maximum value of resource configuration is the maximum value of historical resource usage, it is necessary to obtain resource usage data of the target container for a period of time before the current moment, that is, historical resource usage data. If the target container is a newly created container, the historical resource usage data of the same type of container with the same load characteristics can be obtained as the historical resource usage data of the target container. The load characteristics here refer to CPU, memory, video memory, and disk storage. At this time, the resource configuration process of the target container is the resource configuration process of the created container. If the target container is a container that has already been created and running, you can directly obtain the historical resource usage data of the target container. At this time, the resource configuration process of the target container is the process of updating the container resources.
获取到目标容器的历史资源使用数据之后,便可以对历史资源使用数据进行数据统计分析,以获得历史资源使用数据中的资源最大值,作为目标容器的历史资源使用最大值,即获得目标容器的资源配置最大值max。这样设置的好处在于,减少资源配置过程对人为经验的依赖,提高资源配置的客观性和合理性。After obtaining the historical resource usage data of the target container, you can perform statistical analysis on the historical resource usage data to obtain the maximum resource value in the historical resource usage data as the maximum historical resource usage of the target container, that is, to obtain the maximum value of the target container's historical resource usage. Resource configuration maximum value max. The advantage of this setting is that it reduces the dependence of the resource allocation process on human experience, and improves the objectivity and rationality of resource allocation.
示例性地,依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源包括:依据资源配置最大值和目标百分位确定目标容器的目标私有资源;依据资源配置最大值和目标私有资源,确定目标备用资源。Exemplarily, determining the target private resources and target spare resources of the target container according to the resource configuration maximum value and the target percentile includes: determining the target private resource of the target container according to the resource configuration maximum value and the target percentile; and the target private resource to determine the target alternate resource.
目标私有资源和目标备用资源的确定过程为:计算资源配置最大值max和目标百分位的乘积,即确定目标容器的资源百分位值Tail-bound,将其作为目标容器的目标私有资源。之后,用资源配置最大值减去目标私有资源便可获得目标容器的目标备用资源,即目标备用资源=max-Tail-bound。The process of determining the target private resource and the target backup resource is as follows: calculate the product of the maximum resource configuration max and the target percentile, that is, determine the resource percentile value Tail-bound of the target container, and use it as the target private resource of the target container. After that, the target backup resource of the target container can be obtained by subtracting the target private resource from the maximum resource configuration value, that is, the target backup resource=max-Tail-bound.
S120、依据目标备用资源和目标容器对应的物理机中除目标容器外的至少一个其余容器的其余备用资源,确定目标容器对应的共享备用资源。S120. Determine a shared backup resource corresponding to the target container according to the target backup resource and the remaining backup resources of at least one other container except the target container in the physical machine corresponding to the target container.
其中,物理机是相对于虚拟机而言的对实体计算机的称呼,其可以是单个计算机或服务器,也可以是一个服务器集群或智能设备集群。其余容器是与目标容器相对应的概念,其是物理机中除去目标容器之外的容器。本发明实施例中物理机上的每个容器的资源均设置为私有资源和备用资源两个部分,其余备用资源是其余容器的备用资源。共享备用资源是指多个容器共享的备用资源,其是实际分配的资源空间,而非概念层面的资源,其可同时对接多个容器,而非单个容器。共享备用资源是实际上承载一个容器超出私有资源的性能的资源。一个物理机上的共享备用资源可以为一个,这样物理机上所有的容器均共用该共享备用资源;也可以为多个,物理机上第一部分容器共用其中一个共享备用资源,第二部分容器共用第二个共享备用资源等。共享备用资源的数量依据业务需求而定,本实施例中优选设置为一个物理机上设置一个共享备用资源,以最大程度兼容资源利用率与性能保证。Wherein, a physical machine is a term for a physical computer relative to a virtual machine, which may be a single computer or a server, or a server cluster or a smart device cluster. The remaining containers are concepts corresponding to the target container, which are containers other than the target container in the physical machine. In the embodiment of the present invention, the resources of each container on the physical machine are set to two parts: private resources and spare resources, and the other spare resources are spare resources of other containers. Shared spare resources refer to spare resources shared by multiple containers, which are actually allocated resource spaces, not conceptual resources, and can be connected to multiple containers at the same time instead of a single container. A shared standby resource is a resource that actually hosts the capabilities of a container beyond the private resource. The shared spare resource on a physical machine can be one, so that all containers on the physical machine share the shared spare resource; it can also be multiple, the first part of the containers on the physical machine share one of the shared spare resources, and the second part of the containers share the second shared spare resource. Shared spare resources, etc. The number of shared spare resources is determined according to business requirements. In this embodiment, it is preferable to set one shared spare resource on one physical machine, so as to maximize the compatibility of resource utilization and performance guarantee.
本发明实施例中共享备用资源的确定需要依赖该共享备用资源可对接的容器的备用资源,也就是需要综合考虑多个容器的资源配置。当物理机上的共享备用资源仅对接一部分容器时,确定目标容器对应的共享备用资源便需要依赖目标容器的目标备用资源以及该共享备用资源对应的各个其余容器的其余备用资源。当物理机上的共享备用资源对接全部容器时,确定目标容器对应的共享备用资源便需要依赖目标容器的目标备用资源以及剩余全部的其余容器的其余备用资源。目标备用资源和至少一个其余备用资源的综合方式,即共享备用资源的确定方式可以是取各个备用资源的最大值,或者将各个备用资源分组(或分类),取分组(或各类别)的备用资源总和的均值或最大值等。The determination of the shared spare resource in the embodiment of the present invention needs to depend on the spare resource of the container to which the shared spare resource can be connected, that is, the resource configuration of multiple containers needs to be comprehensively considered. When the shared spare resources on the physical machine are only connected to a part of the containers, determining the shared spare resources corresponding to the target container needs to rely on the target spare resources of the target container and the remaining spare resources of the other containers corresponding to the shared spare resources. When the shared spare resources on the physical machine are connected to all containers, determining the shared spare resources corresponding to the target container needs to depend on the target spare resources of the target container and the rest spare resources of all remaining containers. The comprehensive way of the target spare resource and at least one other spare resource, that is, the way of determining the shared spare resource may be to take the maximum value of each spare resource, or to group (or classify) each spare resource, and take the spare resources of the group (or each category). The mean or maximum value of the sum of resources, etc.
S130、依据目标私有资源和共享备用资源配置目标容器的资源。S130. Configure the resources of the target container according to the target private resources and the shared spare resources.
确定了目标容器的目标私有资源和其对应的共享备用资源之后,便可按照目标私有资源和共享备用资源进行资源分配,便完成目标容器的资源配置。After the target private resource of the target container and its corresponding shared spare resource are determined, resource allocation can be performed according to the target private resource and the shared spare resource, so as to complete the resource configuration of the target container.
本实施例的技术方案,通过获取目标容器的资源配置最大值,并依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源,实现了将一个容器的资源分为两部分,目标私有资源为容器独立使用的资源,以满足容器的大部分性能需求,而目标备用资源将用于确定共享备用资源,以满足超出目标私有资源的额外需求,解决了资源浪费和减少资源导致性能冲突的问题,一定程度上优化了资源利用率且兼顾性能保证。通过依据目标备用资源和目标容器对应的物理机中除目标容器外的至少一个其余容器的其余备用资源,确定目标容器对应的共享备用资源,实现了在配置一个容器的资源时综合考虑物理机上多个容器的资源配置,使得多个容器可以共用共享备用资源,解决了孤立地配置单个容器资源而导致的资源和性能无法兼顾的问题,达到了更加合理地配置容器资源,使得配置的容器资源既能保证性能又能更大程度地节省资源的技术效果。In the technical solution of this embodiment, by obtaining the maximum resource configuration of the target container, and determining the target private resources and target spare resources of the target container according to the maximum resource configuration and the target percentile, the resources of one container are divided into two parts. In part, the target private resource is the resource used independently by the container to meet most of the performance requirements of the container, and the target spare resource will be used to determine the shared spare resource to meet the additional demand beyond the target private resource, solving resource waste and reducing resources The problem that leads to performance conflicts optimizes resource utilization to a certain extent and takes into account performance guarantees. By determining the shared spare resource corresponding to the target container according to the target spare resource and the remaining spare resources of at least one other container except the target container in the physical machine corresponding to the target container, it is possible to comprehensively consider the multiple resources on the physical machine when configuring the resources of a container. The resource configuration of each container enables multiple containers to share and share spare resources, solves the problem of inability to balance resources and performance caused by configuring a single container resource in isolation, and achieves a more reasonable configuration of container resources, so that the configured container resources are both The technical effect of ensuring performance and saving resources to a greater extent.
实施例二Embodiment 2
本实施例在上述实施例一的基础上,增加了“生成目标百分位”的步骤。其中与上述各实施例相同或相应的术语的解释在此不再赘述。参见图2,本实施例提供的容器资源配置方法包括:This embodiment adds a step of "generating a target percentile" on the basis of the above-mentioned first embodiment. The explanations of terms that are the same as or corresponding to the above embodiments are not repeated here. Referring to FIG. 2, the container resource configuration method provided by this embodiment includes:
S210、获取目标容器的资源配置最大值。S210. Obtain the maximum value of the resource configuration of the target container.
S220、确定目标容器对应的目标资源使用时序数据及初始百分位。S220. Determine the target resource usage time series data and the initial percentile corresponding to the target container.
其中,目标资源使用时序数据是目标容器或目标容器的同类容器(目标容器为新建时)基于百分位的容器资源配置方法配置资源的情况下获得的历史资源使用数据。初始百分位是指在当前操作之前,目标容器或其同类容器基于百分位进行资源配置时所依据的百分位。The target resource usage time series data is historical resource usage data obtained when the target container or a container of the same type of the target container (when the target container is newly created) configures resources based on the percentile-based container resource configuration method. The initial percentile refers to the percentile on which the target container or its similar containers configure resources based on the percentile before the current operation.
相关技术中基于百分位的容器资源配置方法中的百分位通常是人为经验性设定,其具有人为主观性。故本发明实施例在依据百分位确定目标私有资源之前,先根据目标容器的资源使用情况来动态地调整初始百分位,以便获得更加客观、更加适配于目标容器的百分位,即目标百分位。The percentile in the percentile-based container resource configuration method in the related art is usually set empirically, which is subjective. Therefore, in the embodiment of the present invention, before determining the target private resource according to the percentile, the initial percentile is dynamically adjusted according to the resource usage of the target container, so as to obtain a percentile that is more objective and more suitable for the target container, that is, Target percentile.
要生成目标百分位,需要先获得目标容器对应的初始百分位及目标资源使用时序数据。当目标容器或其同类容器已经按照百分位的容器资源配置方法配置了资源时,便可直接获得目标容器或其同类容器的历史资源使用时序数据及配置资源所使用的百分位,分别作为目标容器对应的目标资源使用时序数据和初始百分位。To generate the target percentile, you need to obtain the initial percentile corresponding to the target container and the time series data of target resource usage. When the target container or similar containers have configured resources according to the percentile container resource configuration method, the historical resource usage time series data of the target container or similar containers and the percentile used for configuring resources can be directly obtained as The target resource corresponding to the target container uses time series data and initial percentiles.
当目标容器或其同类容器未按照百分位的容器资源配置方法配置资源时,便需要按照百分位的容器资源配置方法为目标容器配置初始资源,由于是按照百分位确定的资源,故上述初始资源可称为初始私有资源。这时所依据的百分位便是初始百分位。示例性地,确定目标容器对应的目标资源使用时序数据及初始百分位包括:依据资源配置最大值和初始百分位确定目标容器的初始私有资源;在目标容器以初始私有资源运行时,获得预设时间段内目标容器的目标资源使用时序数据。具体实施时,先根据目标容器的资源配置最大值和初始百分位的乘积确定目标容器的初始私有资源。之后,触发目标容器在初始私有资源的条件下运行至少预设时间段的时长,并将该预设时间段内的资源使用时序数据作为目标容器的目标资源使用时序数据。When the target container or similar containers do not configure resources according to the percentile container resource configuration method, it is necessary to configure initial resources for the target container according to the percentile container resource configuration method. The above-mentioned initial resources may be referred to as initial private resources. The percentile on which this is based is the initial percentile. Exemplarily, determining the target resource usage time series data and the initial percentile corresponding to the target container includes: determining the initial private resource of the target container according to the resource configuration maximum value and the initial percentile; when the target container runs with the initial private resource, obtaining Time series data of the target resource usage of the target container within a preset time period. During specific implementation, the initial private resource of the target container is first determined according to the product of the maximum resource configuration value of the target container and the initial percentile. After that, trigger the target container to run for at least a preset time period under the condition of the initial private resource, and use the resource usage time series data within the preset time period as the target resource usage time series data of the target container.
S230、确定目标资源使用时序数据中连续资源使用值大于初始私有资源的时长占比。S230. Determine the proportion of the time duration in which the continuous resource usage value is greater than the initial private resource in the target resource usage time series data.
其中,连续资源使用值是指每两个资源使用值之间的时间差小于预设时间阈值的设定数量的资源使用值,该预设时间阈值可以预先人为设定,例如3分钟。初始私有资源为初始百分位对应的目标容器的私有资源。The continuous resource usage value refers to a set number of resource usage values for which the time difference between every two resource usage values is less than a preset time threshold, and the preset time threshold can be manually set in advance, for example, 3 minutes. The initial private resource is the private resource of the target container corresponding to the initial percentile.
判断初始百分位是否与目标容器的性能需求匹配的依据,主要是根据初始百分位所分配的资源是否能够保证大部分的容器性能,也就是所分配的资源在容器运行期间所引起的资源和性能之间的冲突(分配资源无法保证服务性能,简称性能冲突)是否满足用户对性能冲突程度的容忍度,该性能冲突程度可以通过性能冲突的时长在整个运行时长的时长占比来表征。而在表征性能冲突程度时,持续性的性能冲突对容器的性能影响较大,故为了提高性能冲突程度的确定效率,本实施例中采用了连续资源使用值,而非单个的资源使用值。The basis for judging whether the initial percentile matches the performance requirements of the target container is mainly based on whether the resources allocated by the initial percentile can guarantee most of the container performance, that is, the resources caused by the allocated resources during the running of the container. Whether the conflict between performance and performance (allocation of resources cannot guarantee service performance, referred to as performance conflict) satisfies the user's tolerance for the degree of performance conflict, the degree of performance conflict can be characterized by the proportion of the duration of performance conflict in the entire running time. When characterizing the performance conflict degree, the persistent performance conflict has a greater impact on the performance of the container. Therefore, in order to improve the efficiency of determining the performance conflict degree, a continuous resource usage value is used instead of a single resource usage value in this embodiment.
性能冲突更加直观的一种表征方式便是资源使用值超过容器分配的初始私有资源。那么,在确定目标容器的性能冲突程度时,便统计目标资源使用时序数据中连续资源使用值大于初始私有资源的时长与目标资源使用时序数据的总时长之间的比值,即确定时长占比。A more intuitive way of characterizing performance conflicts is when the resource usage value exceeds the initial private resources allocated by the container. Then, when determining the performance conflict degree of the target container, the ratio between the time duration in which the continuous resource usage value in the target resource usage time series data is greater than the initial private resource and the total duration time in the target resource usage time series data is calculated, that is, the duration ratio is determined.
示例性地,S230包括:确定目标资源使用时序数据中每个资源使用峰值大于初始私有资源的峰值长度;依据各峰值长度、预设峰值长度阈值和目标资源使用时序数据,生成第一峰值时序数据;确定第一峰值时序数据中连续峰值的时长占比。Exemplarily, S230 includes: determining that each resource usage peak value in the target resource usage time sequence data is greater than the peak length of the initial private resource; and generating first peak time sequence data according to each peak length, a preset peak length threshold, and the target resource usage time sequence data ; Determine the duration ratio of consecutive peaks in the first peak time series data.
其中,资源使用峰值是指一定时间间隔内资源使用值的最大值,在资源使用时序数据对应的曲线中,资源使用峰值便是每个曲线峰值。峰值长度是指资源使用峰值大于初始私有资源的数值大小。预设峰值长度阈值是指预先设定的峰值长度,其用于对所有的峰值长度进行筛选,以滤除峰值长度较小的数据。第一峰值时序数据是指仅保留了峰值长度超过预设峰值长度阈值的资源使用数据的时序数据。连续峰值是指每两个资源使用峰值之间的时间差小于预设时间阈值的设定数量的资源使用峰值。The resource usage peak refers to the maximum value of resource usage within a certain time interval, and in the curve corresponding to the resource usage time series data, the resource usage peak is the peak value of each curve. The peak length refers to the value of the resource usage peak larger than the initial private resource. The preset peak length threshold refers to a preset peak length, which is used to filter all peak lengths to filter out data with smaller peak lengths. The first peak time series data refers to time series data that only retains resource usage data whose peak length exceeds a preset peak length threshold. A continuous peak refers to a set number of resource usage peaks where the time difference between every two resource usage peaks is less than a preset time threshold.
上述确定时长占比的过程可以进一步改进为:确定目标资源使用时序数据中的各个资源使用峰值,并计算每个资源使用峰值与初始私有资源的差值,确定每个资源使用峰值对应的峰值长度。然后,在目标资源使用时序数据中,保留峰值长度大于预设峰值长度阈值的各个资源使用值,生成第一峰值时序数据。最后,统计第一峰值时序数据中连续峰值所占时长与第一峰值时序数据的总时长之间的比值,即确定时长占比。这样设置的好处在于,一方面通过对资源使用值的过滤处理,减少了数据量,提高时长占比的确定效率,从而进一步提高百分位的调整效率;另一方面滤除了峰值长度较小的资源使用值,能够降低百分位调整的敏感度,一定程度上减少百分位调整幅度过小的百分位调整操作,增强百分位调整操作的实际价值。The above process of determining the duration ratio can be further improved as follows: determine each resource usage peak in the target resource usage time series data, calculate the difference between each resource usage peak and the initial private resource, and determine the peak length corresponding to each resource usage peak . Then, in the target resource usage time series data, each resource usage value whose peak length is greater than a preset peak length threshold is retained to generate first peak time series data. Finally, the ratio between the duration occupied by the continuous peaks in the first peak time series data and the total duration of the first peak time series data is counted, that is, the duration ratio is determined. The advantage of this setting is that, on the one hand, by filtering the resource usage value, the amount of data is reduced, the efficiency of determining the duration ratio is improved, and the adjustment efficiency of percentiles is further improved; The resource usage value can reduce the sensitivity of percentile adjustment, reduce the percentile adjustment operation with too small percentile adjustment range to a certain extent, and enhance the actual value of the percentile adjustment operation.
S240、依据时长占比、预设占比阈值和需求占比,调整初始百分位,生成目标百分位。S240. Adjust the initial percentile according to the duration ratio, the preset ratio threshold, and the demand ratio to generate a target percentile.
其中,预设占比阈值是指是指预先设定的时长占比,例如10%,其用于表征用户对性能冲突程度的容忍度。需求占比是预先设定的时长占比,其用于表征用户期望的容器的性能冲突程度。需求占比可以与预设占比阈值相等,如10%,也可以不相等。The preset proportion threshold refers to a preset time proportion, such as 10%, which is used to represent the user's tolerance to the degree of performance conflict. The demand ratio is a preset duration ratio, which is used to represent the performance conflict degree of the container expected by the user. The demand ratio can be equal to the preset ratio threshold, such as 10%, or it can be unequal.
通过比较时长占比和预设占比阈值来确定是否需要调整初始百分比,以及如何调整。若时长占比大于预设占比阈值,则依据需求占比增大初始百分位,生成目标百分位。这种情况说明目前为目标容器分配的私有资源无法保证目标容器的大部分性能,需要根据需求占比和时长占比的大小关系增大目标私有资源的配置,以便保证融合和服务的运行性能。若时长占比小于预设占比阈值,则依据需求占比减小初始百分位,生成目标百分位。这种情况说明目前为目标容器分配的私有资源较多,在保证目标容器的大部分性能的基础上有所浪费,需要根据需求占比和时长占比的大小关系减少目标私有资源的配置,以进一步节省资源。Determine whether and how to adjust the initial percentage by comparing the duration ratio with the preset ratio threshold. If the proportion of time duration is greater than the preset proportion threshold, the initial percentile is increased according to the proportion of demand, and the target percentile is generated. This situation shows that the private resources currently allocated for the target container cannot guarantee most of the performance of the target container. It is necessary to increase the configuration of the target private resources according to the relationship between the demand ratio and the duration ratio, so as to ensure the running performance of integration and services. If the proportion of time duration is less than the preset proportion threshold, the initial percentile is reduced according to the proportion of demand, and the target percentile is generated. This situation shows that there are many private resources allocated to the target container at present, which is wasted on the basis of ensuring most of the performance of the target container. It is necessary to reduce the configuration of the target private resources according to the relationship between the demand ratio and the duration ratio, so that Further saving resources.
S250、依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源。S250. Determine the target private resource and the target spare resource of the target container according to the maximum resource configuration value and the target percentile.
S260、依据目标备用资源和目标容器对应的物理机中除目标容器外的至少一个其余容器的其余备用资源,确定目标容器对应的共享备用资源。S260: Determine a shared backup resource corresponding to the target container according to the target backup resource and the remaining backup resources of at least one other container except the target container in the physical machine corresponding to the target container.
S270、依据目标私有资源和共享备用资源配置目标容器的资源。S270. Configure the resources of the target container according to the target private resources and the shared spare resources.
本实施例的技术方案,通过目标容器对应的目标资源使用时序数据及初始百分位确定目标资源使用时序数据中连续资源使用值大于初始私有资源的时长占比,并依据时长占比、预设占比阈值和需求占比,调整初始百分位,生成目标百分位。实现了更加客观、更加适配于目标容器的目标百分位的动态确定,使得目标私有资源和目标备用资源的确定也能够更加客观、更加适合于目标容器,进一步提高了目标容器资源配置的灵活性,进而进一步提高目标容器的资源利用率和性能保证的兼容性。In the technical solution of this embodiment, the time-series data of the target resource usage corresponding to the target container and the initial percentile are used to determine the percentage of the time duration in which the continuous resource usage value is greater than the initial private resource in the target resource usage time-series data, and according to the duration percentage, preset The proportion threshold and demand proportion, adjust the initial percentile, and generate the target percentile. The dynamic determination of the target percentile that is more objective and more suitable for the target container is realized, so that the determination of the target private resources and the target spare resources can also be more objective and more suitable for the target container, which further improves the flexibility of the resource configuration of the target container. properties, thereby further improving the resource utilization of the target container and the compatibility of performance guarantees.
实施例三Embodiment 3
本实施例在上述实施例一的基础上,对“依据目标备用资源和目标容器对应的物理机中除目标容器外的至少一个其余容器的其余备用资源,确定目标容器对应的共享备用资源”进行了进一步优化。其中与上述各实施例相同或相应的术语的解释在此不再赘述。参见图3a,本实施例提供的容器资源配置方法包括:On the basis of the above-mentioned first embodiment, this embodiment performs the steps of "determining the shared spare resources corresponding to the target container according to the target spare resources and the remaining spare resources of at least one other container except the target container in the physical machine corresponding to the target container". for further optimization. The explanations of terms that are the same as or corresponding to the above embodiments are not repeated here. Referring to FIG. 3a, the container resource configuration method provided by this embodiment includes:
S310、获取目标容器的资源配置最大值,并依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源。S310. Obtain the maximum resource configuration value of the target container, and determine the target private resources and target backup resources of the target container according to the maximum resource configuration value and the target percentile.
S320、依据目标容器和每个其余容器对应的历史资源使用时序数据,确定两两容器之间的资源需求相关性。S320. Determine the resource requirement correlation between the two containers according to the historical resource usage time series data corresponding to the target container and each of the remaining containers.
其中,资源需求相关性是指两个容器之间的资源需求变化趋势的相关性。如果两个容器的资源需求相关性高,则意味着它们的资源需求高低变化比较一致。反之,如果两个容器的资源需求相关性低,则意味着它们的资源需求没有关联性或者反相关,如一个容器资源需求高时,另一个容器的资源需求低。The resource requirement dependency refers to the dependency of the resource requirement change trend between two containers. If the resource requirements of two containers are highly correlated, it means that their resource requirements are relatively consistent. Conversely, if the resource requirements of two containers are relatively low, it means that their resource requirements are not correlated or anti-correlated, for example, when the resource requirements of one container are high, the resource requirements of the other container are low.
共享备用资源的确定需要综合考虑其对应的各个容器的备用资源,本实施例中将多个备用资源的综合方式确定为基于容器之间的资源需求相关性。那么便需要在确定共享备用资源之前先确定各个容器之间的资源需求相关性。由于历史资源使用时序数据可以反映容器在一段时间内的资源需求情况,故本实施例中的资源需求相关性可以直接依据目标容器和其余容器中任两个容器的历史资源使用时序数据进行计算,如可以利用公式(1)的协方差进行计算:The determination of the shared spare resources needs to comprehensively consider the spare resources of the corresponding containers. In this embodiment, the comprehensive manner of multiple spare resources is determined based on the resource requirement correlation between the containers. Then, it is necessary to determine the resource requirement dependencies between the containers before determining the shared spare resources. Since the historical resource usage time series data can reflect the resource requirements of the container within a period of time, the resource requirement correlation in this embodiment can be calculated directly based on the historical resource usage time series data of the target container and any two of the other containers, For example, the covariance of formula (1) can be used to calculate:
其中,COV(x,y)表示两个容器的协方差,x、y分别表示两个容器的历史资源使用时序数据,分别表示相应容器的历史资源使用时序数据的资源使用均值,n表示历史资源使用时序数据中资源使用值的数量。Among them, COV(x, y) represents the covariance of the two containers, and x and y represent the historical resource usage time series data of the two containers, respectively. Respectively represent the resource usage average of the historical resource usage time series data of the corresponding container, and n represents the number of resource usage values in the historical resource usage time series data.
资源需求相关性也可以利用历史资源使用时序数据中的部分特征数据进行相关性计算。由于历史资源使用数据中的峰值使用率(峰值出现的概率)能够更加明显地反映容器的资源需求,故可以利用两个容器对应的历史资源使用时序数据中的峰值数据来计算这两个容器之间的资源需求相关性。The resource requirement correlation can also be calculated by using some feature data in the historical resource usage time series data. Since the peak usage rate (probability of peak occurrence) in the historical resource usage data can more clearly reflect the resource requirements of the container, the peak data in the historical resource usage time series data corresponding to the two containers can be used to calculate the difference between the two containers. Dependency between resource requirements.
示例性地,S320包括:分别依据目标容器和每个其余容器对应的历史资源使用时序数据生成相应的第二峰值时序数据;分别确定每两个第二峰值时序数据之间的相似度,作为相应的两两容器之间的资源需求相关性。Exemplarily, S320 includes: respectively generating corresponding second peak time series data according to the historical resource usage time series data corresponding to the target container and each remaining container; Resource requirement dependencies between two containers.
其中,第二峰值时序数据是指保留历史资源使用时序数据中的资源使用峰值的时序数据。The second peak time series data refers to the time series data that retains the resource usage peak in the historical resource usage time series data.
利用峰值数据确定资源需求相关性需要先获得每个容器对应的第二峰值时序数据,具体则是对容器的历史资源使用时序数据进行过滤,剔除掉非峰值的资源使用值。为了进一步提高后续资源需求相关性的确定效率以及提高资源需求相关性的参考价值,可以进一步剔除掉所有资源使用峰值中未超过目标私有资源的资源使用峰值,这是因为超过目标私有资源的资源使用峰值更能表征该容器对备用资源的使用情况。之后,利用诸如公式(2)的杰卡德系数计算每两个第二峰值时序数据之间的相似度,该相似度便可以表征两个容器之间的资源需求相关性。Using peak data to determine resource demand correlation requires first obtaining the second peak time series data corresponding to each container. Specifically, filtering the container's historical resource usage time series data to eliminate non-peak resource usage values. In order to further improve the efficiency of determining the correlation of subsequent resource requirements and improve the reference value of the correlation of resource requirements, it is possible to further eliminate the resource usage peaks that do not exceed the target private resource among all resource usage peaks, because the resource usage that exceeds the target private resource The peak value is more indicative of the container's usage of spare resources. After that, the similarity between every two second peak time series data is calculated using the Jaccard coefficient such as formula (2), and the similarity can represent the resource requirement correlation between the two containers.
其中,J(A,B)表示两个容器之间的资源需求相关性,A、B分别表示两个容器的第二峰值时序数据。Among them, J(A, B) represents the resource demand correlation between the two containers, and A and B respectively represent the second peak time series data of the two containers.
这样设置的好处在于能够提高资源需求相关性的确定效率以及提高资源需求相关性的参考价值。The advantage of this setting is that it can improve the efficiency of determining the correlation of resource requirements and improve the reference value of the correlation of resource requirements.
S330、依据各资源需求相关性,基于聚类算法,将目标容器和各其余容器进行分类,获得至少一个容器类别。S330. Classify the target container and each other container according to the correlation of each resource requirement and based on a clustering algorithm to obtain at least one container category.
根据上述资源需求相关性的特性,可知资源需求相关性一致的各个容器在同一时间段达到性能峰值的概率较高,而资源需求相关性不一致的各个容器在同一时间段达到性能峰值的概率较低,故可以将目标容器及各个其余容器按照资源需求相关性进行分类,使得相关性一致的容器处于同一个容器类别内,相关性不一致的容器处于不同的容器类别内,而后根据各容器类别对应的各个备用资源来确定共享备用资源,这样便可保证共享备用资源对应的各个容器不会在同一时间达到性能峰值,使得共享备用资源大概率的小于所有容器的备用资源的总和,以达到大大减少峰值资源需求,尽可能地减少资源分配,又能保证相关容器的性能,最大程度上减少容器的性能冲突。According to the above characteristics of resource demand correlation, it can be seen that each container with consistent resource demand correlation has a higher probability of reaching peak performance in the same time period, while each container with inconsistent resource demand correlation has a lower probability of reaching performance peak in the same time period. , so the target container and each other container can be classified according to the correlation of resource requirements, so that the containers with consistent correlation are in the same container category, and the containers with inconsistent correlation are in different container categories, and then according to the corresponding container categories Each spare resource is used to determine the shared spare resource, so as to ensure that each container corresponding to the shared spare resource will not reach the peak performance at the same time, so that the shared spare resource has a high probability of being less than the sum of the spare resources of all containers, so as to greatly reduce the peak value. Resource requirements, reduce resource allocation as much as possible, and ensure the performance of related containers, minimizing container performance conflicts.
具体实施时,可以利用诸如K-Means的聚类算法,基于每个容器的资源需求相关性将目标容器和各其余容器进行分类,获得至少一个容器类别。基于K-Means算法进行容器分类的过程可以为:In a specific implementation, a clustering algorithm such as K-Means can be used to classify the target container and each remaining container based on the resource requirement correlation of each container to obtain at least one container category. The process of container classification based on the K-Means algorithm can be as follows:
1)从容器中随机选出选择N个容器做为每个类别的初始“中心点”。1) Randomly select N containers from the containers as the initial "center points" of each category.
2)计算每个容器到这N个中心点的欧氏距离,距离定义为容器和这个中心点容器的历史资源使用时序数据的协方差COV。2) Calculate the Euclidean distance from each container to the N central points, and the distance is defined as the covariance COV of the historical resource usage time series data of the container and this central point container.
3)根据欧氏距离把容器归类到距离最近的类别,每个类别里是互相关联的容器。3) According to the Euclidean distance, the containers are classified into the closest categories, and each category is a container that is related to each other.
4)更新每个类别的中心,中心定义为同一个类里面的所有容器的历史资源使用时序数据的平均值。4) Update the center of each category, which is defined as the average of the historical resource usage time series data of all containers in the same category.
5)继续2)进行迭代,直到满足一定次数或指定的误差要求。5) Continue with 2) to iterate until a certain number of times or specified error requirements are met.
S340、依据各容器类别对应的备用资源总和确定共享备用资源。S340. Determine the shared backup resource according to the sum of the backup resources corresponding to each container category.
其中,备用资源总和为相应容器类别内各容器的备用资源的总和。The sum of the spare resources is the sum of the spare resources of each container in the corresponding container category.
首先,确定每个容器类别内所有容器的备用资源总和,那么就可获得与容器类别的数量一致的备用资源总和。如果容器类别内有目标容器和其余容器,那么备用资源总和便是目标备用资源和各其余备用资源的总和,如果容器类别内没有目标容器,那么备用资源总和便是各个其余备用资源的总和。然后,确定各个备用资源总和中的最大值,将该备用资源总和的最大值确定为目标容器和相关的其余容器的共享备用资源。First, determine the sum of the spare resources of all containers in each container class, then the sum of spare resources consistent with the number of container classes can be obtained. If the target container and the rest of the containers are in the container class, the sum of the spares is the sum of the target spare and each of the rest, and if there are no target containers in the container class, the sum of the spares is the sum of the rest of the spares. Then, determine the maximum value in the total sum of each spare resource, and determine the maximum value of the total sum of the spare resources as the shared spare resource of the target container and the other related containers.
如果容器类别的数量为至少两个,那么共享备用资源便小于目标备用资源和各其余备用资源的总和;如果容器类别的数量为一个,那么共享备用资源便等于目标备用资源和各其余备用资源的总和。If the number of container classes is at least two, the shared spare is less than the sum of the target spare and each of the remaining spares; if the number of container classes is one, the shared spare is equal to the sum of the target spare and each of the remaining spares sum.
以两个容器为例,如果两个容器的资源需求相关性低(不相关或负相关),那么它们的共享备用资源等于两个容器各自的备用资源的最大值,即共享备用资源=MAX(max1–Tail_bound1,max2–Tail_bound2),其中max1和max2分别是容器1和容器2的资源配置最大值,Tail_bound1和Tail_bound2分别是容器1和容器2的资源百分位值。如果两个容器的资源需求相关性高,那么它们的共享备用资源等于各自的备用资源的和,即共享备用资源=SUM(max1–Tail_bound1,max2–Tail_bound2)。Taking two containers as an example, if the resource requirements of the two containers have a low correlation (irrelevance or negative correlation), then their shared spare resources are equal to the maximum value of the respective spare resources of the two containers, that is, shared spare resources = MAX ( max 1 –Tail_bound 1 ,max 2 –Tail_bound 2 ), where max 1 and max 2 are the maximum resource configuration values of container 1 and container 2, respectively, and Tail_bound 1 and Tail_bound 2 are the resource percentile values of container 1 and container 2, respectively . If the resource requirements of two containers are highly correlated, then their shared spare resources are equal to the sum of their respective spare resources, ie shared spare resources=SUM(max 1 -Tail_bound 1 ,max 2 -Tail_bound 2 ).
按照本实施例的方法对两个资源需求相关性低的容器1和容器2进行资源配置,便可获得图3b所示的资源配置结果及两个容器的资源使用时序数据曲线。According to the method of this embodiment, the resource configuration of two containers 1 and 2 with low resource requirements correlation can obtain the resource configuration result shown in FIG. 3b and the resource usage time series data curve of the two containers.
S350、依据目标私有资源和共享备用资源配置目标容器的资源。S350. Configure the resources of the target container according to the target private resources and the shared spare resources.
需要说明的是,本实施例中目标百分位的确定也可以采用实施例二中的相应操作。It should be noted that, the determination of the target percentile in this embodiment may also adopt the corresponding operations in the second embodiment.
参见图3c,如果对一个物理机上所有容器进行资源配置,那么基于历史资源使用最大值和目标百分位进行资源配置的流程大致为:Referring to Figure 3c, if resources are configured for all containers on a physical machine, the process of resource configuration based on the maximum historical resource usage and target percentile is roughly as follows:
A、统计分析物理机上单个容器的历史资源使用数据,确定单个容器的历史资源使用最大值;A. Statistically analyze the historical resource usage data of a single container on the physical machine, and determine the maximum historical resource usage of a single container;
B、配置单个容器的私有资源,该私有资源的确定可以依据历史资源使用最大值和目标百分位来计算;B. Configure the private resources of a single container. The determination of the private resources can be calculated according to the maximum historical resource usage and the target percentile;
C、计算单个容器的备用资源,利用单个容器的历史资源使用最大值和私有资源计算其备用资源;C. Calculate the spare resources of a single container, and use the maximum historical resource usage and private resources of a single container to calculate its spare resources;
D、统计分析物理机上所有容器之间的资源需求相关性;D. Statistically analyze the resource requirement correlation between all containers on the physical machine;
E、根据每两个容器之间的资源需求相关性进行容器聚类分析,获得各个容器类别;E. Perform container clustering analysis according to the resource requirement correlation between each two containers to obtain each container category;
F、根据各个容器的备用资源和各个容器类别,计算并配置该物理机上所有容器的共享备用资源。这里,一个容器类别的备用资源总和是该容器类别中每个容器的备用资源的总和,即共享备用资源是各容器类别的备用资源总和的最大值,即 F. According to the spare resources of each container and each container category, calculate and configure the shared spare resources of all containers on the physical machine. Here, the sum of spare resources for a container class is the sum of spare resources for each container in that container class, i.e. The shared spare resource is the maximum value of the sum of spare resources of each container category, that is,
基于上述说明及图3d,在对于9个容器划分为3个容器类别的容器进行资源配置时,其结果为9个容器配置的私有资源总共为C1+C2+…+C9,共享备用资源为max(H1+H2+H3,H4+H5+H6+H7,H8+H9)。Based on the above description and Fig. 3d, when resources are configured for the 9 containers divided into 3 container categories, the result is that the total private resources configured by the 9 containers are C1+C2+...+C9, and the shared spare resources are max( H1+H2+H3, H4+H5+H6+H7, H8+H9).
参见图3e,利用传统的基于百分位(90%)的容器资源配置方法(方法1)、基于最大值的容器资源配置方法(方法2)、基于平均值的容器资源配置方法(方法3)及本发明的资源配置方法(方法4)进行了18个容器的资源配置,并对配置资源总量(以90%百分位的资源配置总量为标准化参照)和性能冲突(性能冲突的时长百分比)进行了比较,该两个比较指标均是数值越小越好。其中,方法4的资源配置总量虽然不是最少,但是其资源配置总量远少于方法2的资源配置总量,并且方法4的性能冲突也较小。综合来看,其他方法很难在满足性能的同时优化资源使用,而方法4在在保证容器性能和同时节省资源方面的效果最佳。Referring to Figure 3e, using the traditional percentile (90%)-based container resource allocation method (method 1), maximum value-based container resource allocation method (method 2), and average-based container resource allocation method (method 3) And the resource configuration method (method 4) of the present invention performs resource configuration of 18 containers, and compares the total amount of configuration resources (with the total amount of resource configuration at the 90% percentile as a standardized reference) and performance conflicts (the duration of performance conflicts). percentage) were compared, and the two comparison indicators are that the smaller the value, the better. Among them, although the total amount of resource allocation of
本实施例的技术方案,通过确定两两容器之间的资源需求相关性,并依据各资源需求相关性对容器进行分类,获得容器类别内部各容器的资源需求相关性一致,而不同容器类别间的各容器的资源需求相关性不一致的各个容器类别,以及依据各容器类别对应的备用资源总和确定共享备用资源,错开了各容器性能峰值的到达时间,从而可以根据各个备用资源总和的最大值来确定共享备用资源,实现了利用各容器的资源需求相关性来进一步优化共享备用资源的配置,使得共享备用资源小于各容器的备用资源总和,进而更大程度上保证各个容器的性能同时节省资源。In the technical solution of this embodiment, by determining the resource requirement correlation between two containers, and classifying the containers according to the resource requirement correlation, it is obtained that the resource requirement correlation of each container within the container category is consistent, and the resource requirement correlation between different container categories is obtained. The resource requirements of each container are inconsistent in each container category, and the shared spare resources are determined according to the sum of the spare resources corresponding to each container category, and the arrival time of the peak performance of each container is staggered. By determining the shared spare resources, the configuration of the shared spare resources can be further optimized by utilizing the resource requirement correlation of each container, so that the shared spare resources are smaller than the sum of the spare resources of each container, thereby ensuring the performance of each container to a greater extent and saving resources.
实施例四
本实施例提供一种容器资源配置装置,参见图4,该装置具体包括:This embodiment provides an apparatus for configuring container resources. Referring to FIG. 4 , the apparatus specifically includes:
目标私有资源确定模块410,用于获取目标容器的资源配置最大值,并依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源;The target private
共享备用资源确定模块420,用于依据目标备用资源和目标容器对应的物理机中除目标容器外的至少一个其余容器的其余备用资源,确定目标容器对应的共享备用资源;The shared spare
容器资源配置模块430,用于依据目标私有资源和共享备用资源配置目标容器的资源。The container
可选地,目标私有资源确定模块410包括:Optionally, the target private
目标私有资源确定子模块,用于依据资源配置最大值和目标百分位确定目标容器的目标私有资源;The target private resource determination submodule is used to determine the target private resource of the target container according to the resource configuration maximum value and the target percentile;
目标备用资源确定子模块,用于依据资源配置最大值和目标私有资源,确定目标备用资源。The target backup resource determination sub-module is used for determining the target backup resource according to the maximum value of the resource configuration and the target private resource.
可选地,在上述装置的基础上,该装置还包括目标百分位生成模块,用于:Optionally, on the basis of the above device, the device also includes a target percentile generation module for:
在依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源之前,确定目标容器对应的目标资源使用时序数据及初始百分位;Before determining the target private resources and target spare resources of the target container according to the maximum resource configuration value and the target percentile, determine the target resource usage time series data and the initial percentile corresponding to the target container;
确定目标资源使用时序数据中连续资源使用值大于初始私有资源的时长占比,其中,初始私有资源为初始百分位对应的目标容器的私有资源;Determine the proportion of the time duration in which the continuous resource usage value in the target resource usage time series data is greater than the initial private resource, where the initial private resource is the private resource of the target container corresponding to the initial percentile;
依据时长占比、预设占比阈值和需求占比,调整初始百分位,生成目标百分位。Adjust the initial percentile to generate the target percentile according to the duration ratio, the preset ratio threshold, and the demand ratio.
进一步地,目标百分位生成模块具体用于:Further, the target percentile generation module is specifically used for:
确定目标资源使用时序数据中每个资源使用峰值大于初始私有资源的峰值长度;Determine the peak length of each resource usage peak in the target resource usage time series data that is greater than the initial private resource;
依据各峰值长度、预设峰值长度阈值和目标资源使用时序数据,生成第一峰值时序数据;generating first peak time series data according to each peak length, preset peak length threshold and target resource usage time series data;
确定第一峰值时序数据中连续峰值的时长占比。Determine the duration ratio of consecutive peaks in the first peak time series data.
可选地,共享备用资源确定模块420具体用于:Optionally, the shared spare
依据目标容器和每个其余容器对应的历史资源使用时序数据,确定两两容器之间的资源需求相关性;Determine the resource requirement correlation between the two containers according to the historical resource usage time series data corresponding to the target container and each other container;
依据各资源需求相关性,基于聚类算法,将目标容器和各其余容器进行分类,获得至少一个容器类别;According to the correlation of each resource requirement, based on the clustering algorithm, classify the target container and each other container, and obtain at least one container category;
依据各容器类别对应的备用资源总和确定共享备用资源,其中,备用资源总和为相应容器类别内各容器的备用资源的总和。The shared spare resources are determined according to the sum of spare resources corresponding to each container category, wherein the sum of spare resources is the sum of spare resources of each container in the corresponding container category.
进一步地,共享备用资源确定模块420还具体用于:Further, the shared spare
分别依据目标容器和每个其余容器对应的历史资源使用时序数据生成相应的第二峰值时序数据;generating corresponding second peak time series data according to the target container and the historical resource usage time series data corresponding to each of the remaining containers respectively;
分别确定每两个第二峰值时序数据之间的相似度,作为相应的两两容器之间的资源需求相关性。The similarity between every two second peak time series data is respectively determined as the resource requirement correlation between the corresponding two containers.
可选地,目标私有资源确定模块410具体用于:Optionally, the target private
获取目标容器对应的历史资源使用数据,并依据历史资源使用数据确定目标容器的历史资源使用最大值,作为资源配置最大值。Obtain the historical resource usage data corresponding to the target container, and determine the historical resource usage maximum value of the target container based on the historical resource usage data as the resource configuration maximum value.
通过本发明实施例四的一种容器资源配置装置,实现了更加合理地配置容器资源,更大程度上在提供性能保证的同时节省资源。Through the container resource configuration device according to the fourth embodiment of the present invention, a more rational configuration of container resources is realized, and resources are saved while providing performance assurance to a greater extent.
本发明实施例所提供的容器资源配置装置可执行本发明任意实施例所提供的容器资源配置方法,具备执行方法相应的功能模块和有益效果。The container resource configuration device provided by the embodiment of the present invention can execute the container resource configuration method provided by any embodiment of the present invention, and has functional modules and beneficial effects corresponding to the execution method.
值得注意的是,上述容器资源配置装置的实施例中,所包括的各个单元和模块只是按照功能逻辑进行划分的,但并不局限于上述的划分,只要能够实现相应的功能即可;另外,各功能单元的具体名称也只是为了便于相互区分,并不用于限制本发明的保护范围。It is worth noting that in the above embodiments of the container resource configuration device, the units and modules included are only divided according to functional logic, but are not limited to the above division, as long as the corresponding functions can be realized; in addition, The specific names of the functional units are only for the convenience of distinguishing from each other, and are not used to limit the protection scope of the present invention.
实施例五
参见图5,本实施例提供了一种设备,其包括:一个或多个处理器520;存储装置510,用于存储一个或多个程序,当一个或多个程序被一个或多个处理器520执行,使得一个或多个处理器520实现本发明实施例所提供的容器资源配置方法,包括:Referring to FIG. 5 , this embodiment provides a device, which includes: one or
获取目标容器的资源配置最大值,并依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源;Obtain the maximum resource configuration of the target container, and determine the target private resources and target spare resources of the target container according to the maximum resource configuration and target percentile;
依据目标备用资源和目标容器对应的物理机中除目标容器外的至少一个其余容器的其余备用资源,确定目标容器对应的共享备用资源;Determine the shared spare resource corresponding to the target container according to the target spare resource and the remaining spare resources of at least one other container except the target container in the physical machine corresponding to the target container;
依据目标私有资源和共享备用资源配置目标容器的资源。Configure the resources of the target container according to the target private resources and shared spare resources.
当然,本领域技术人员可以理解,处理器520还可以实现本发明任意实施例所提供的容器资源配置方法的技术方案。Of course, those skilled in the art can understand that the
图5显示的设备仅仅是一个示例,不应对本发明实施例的功能和使用范围带来任何限制。如图5所示,该设备包括处理器520和存储装置510;设备中处理器520的数量可以是一个或多个,图5中以一个处理器520为例;设备中的处理器520和存储装置可以通过总线或其他方式连接,图5中以通过总线530连接为例。The device shown in FIG. 5 is only an example, and should not impose any limitation on the function and scope of use of the embodiments of the present invention. As shown in FIG. 5, the device includes a
存储装置510作为一种计算机可读存储介质,可用于存储软件程序、计算机可执行程序以及模块,如本发明实施例中的容器资源配置方法对应的程序指令/模块(例如,容器资源配置装置中的目标私有资源确定模块、共享备用资源确定模块和容器资源配置模块)。As a computer-readable storage medium, the
存储装置510可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序;存储数据区可存储根据终端的使用所创建的数据等。此外,存储装置510可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他非易失性固态存储器件。在一些实例中,存储装置510可进一步包括相对于处理器520远程设置的存储器,这些远程存储器可以通过网络连接至设备。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。The
实施例六
本实施例提供一种包含计算机可执行指令的存储介质,计算机可执行指令在由计算机处理器执行时用于执行一种容器资源配置方法,该方法包括:This embodiment provides a storage medium containing computer-executable instructions. The computer-executable instructions are used to execute a container resource configuration method when executed by a computer processor, and the method includes:
获取目标容器的资源配置最大值,并依据资源配置最大值和目标百分位确定目标容器的目标私有资源和目标备用资源;Obtain the maximum resource configuration of the target container, and determine the target private resources and target spare resources of the target container according to the maximum resource configuration and target percentile;
依据目标备用资源和目标容器对应的物理机中除目标容器外的至少一个其余容器的其余备用资源,确定目标容器对应的共享备用资源;Determine the shared spare resource corresponding to the target container according to the target spare resource and the remaining spare resources of at least one other container except the target container in the physical machine corresponding to the target container;
依据目标私有资源和共享备用资源配置目标容器的资源。Configure the resources of the target container according to the target private resources and shared spare resources.
当然,本发明实施例所提供的一种包含计算机可执行指令的存储介质,其计算机可执行指令不限于如上的方法操作,还可以执行本发明任意实施例所提供的容器资源配置方法中的相关操作。Of course, a storage medium containing computer-executable instructions provided by an embodiment of the present invention, the computer-executable instructions of the storage medium are not limited to the above method operations, and can also execute the related container resource configuration methods provided by any embodiment of the present invention. operate.
通过以上关于实施方式的描述,所属领域的技术人员可以清楚地了解到,本发明可借助软件及必需的通用硬件来实现,当然也可以通过硬件实现,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品可以存储在计算机可读存储介质中,如计算机的软盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(RandomAccess Memory,RAM)、闪存(FLASH)、硬盘或光盘等,包括若干指令用以使得一台设备(可以是服务器,或者网络设备等)执行本发明各个实施例所提供的容器资源配置方法。From the above description of the embodiments, those skilled in the art can clearly understand that the present invention can be realized by software and necessary general-purpose hardware, and of course can also be realized by hardware, but in many cases the former is a better embodiment . Based on such understanding, the technical solutions of the present invention can be embodied in the form of software products in essence or the parts that make contributions to the prior art, and the computer software products can be stored in a computer-readable storage medium, such as a floppy disk of a computer , Read-Only Memory (ROM), Random Access Memory (RAM), Flash Memory (FLASH), hard disk or CD, etc., including several instructions to make a device (which can be a server, or a network equipment, etc.) to execute the container resource configuration methods provided by the various embodiments of the present invention.
注意,上述仅为本发明的较佳实施例及所运用技术原理。本领域技术人员会理解,本发明不限于这里所述的特定实施例,对本领域技术人员来说能够进行各种明显的变化、重新调整和替代而不会脱离本发明的保护范围。因此,虽然通过以上实施例对本发明进行了较为详细的说明,但是本发明不仅仅限于以上实施例,在不脱离本发明构思的情况下,还可以包括更多其他等效实施例,而本发明的范围由所附的权利要求范围决定。Note that the above are only preferred embodiments of the present invention and applied technical principles. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and various obvious changes, readjustments and substitutions can be made by those skilled in the art without departing from the protection scope of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments, and can also include more other equivalent embodiments without departing from the concept of the present invention. The scope is determined by the scope of the appended claims.
Claims (10)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910708644.9A CN111736981A (en) | 2019-08-01 | 2019-08-01 | Container resource configuration method, apparatus, device and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910708644.9A CN111736981A (en) | 2019-08-01 | 2019-08-01 | Container resource configuration method, apparatus, device and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN111736981A true CN111736981A (en) | 2020-10-02 |
Family
ID=72646296
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910708644.9A Pending CN111736981A (en) | 2019-08-01 | 2019-08-01 | Container resource configuration method, apparatus, device and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111736981A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113641453A (en) * | 2021-08-17 | 2021-11-12 | 中国联合网络通信集团有限公司 | Node selection method and node selection equipment |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102822798A (en) * | 2010-03-31 | 2012-12-12 | 国际商业机器公司 | Methods and apparatus for resource capacity evaluation in a system of virtual containers |
CN108090225A (en) * | 2018-01-05 | 2018-05-29 | 腾讯科技(深圳)有限公司 | Operation method, device, system and the computer readable storage medium of database instance |
CN108415772A (en) * | 2018-02-12 | 2018-08-17 | 腾讯科技(深圳)有限公司 | A kind of resource adjusting method, device and medium based on container |
WO2019019807A1 (en) * | 2017-07-24 | 2019-01-31 | 中国银联股份有限公司 | Resource allocation method and device |
-
2019
- 2019-08-01 CN CN201910708644.9A patent/CN111736981A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102822798A (en) * | 2010-03-31 | 2012-12-12 | 国际商业机器公司 | Methods and apparatus for resource capacity evaluation in a system of virtual containers |
WO2019019807A1 (en) * | 2017-07-24 | 2019-01-31 | 中国银联股份有限公司 | Resource allocation method and device |
CN108090225A (en) * | 2018-01-05 | 2018-05-29 | 腾讯科技(深圳)有限公司 | Operation method, device, system and the computer readable storage medium of database instance |
CN108415772A (en) * | 2018-02-12 | 2018-08-17 | 腾讯科技(深圳)有限公司 | A kind of resource adjusting method, device and medium based on container |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113641453A (en) * | 2021-08-17 | 2021-11-12 | 中国联合网络通信集团有限公司 | Node selection method and node selection equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112764936B (en) | Edge calculation server information processing method and device based on deep reinforcement learning | |
CN107038069B (en) | Dynamic label matching DLMS scheduling method under Hadoop platform | |
CN106502791B (en) | A kind of method for allocating tasks and device | |
WO2022001086A1 (en) | Efficient gpu resource allocation optimization method and system | |
CN110049130A (en) | A kind of service arrangement and method for scheduling task and device based on edge calculations | |
US10884667B2 (en) | Storage controller and IO request processing method | |
CN102667724A (en) | Goal oriented performance management of workload utilizing accelerators | |
CN110362392A (en) | A kind of ETL method for scheduling task, system, equipment and storage medium | |
US10712945B2 (en) | Deduplication processing method, and storage device | |
US11977761B2 (en) | Predictive allocation of ephemeral containers for cloud computing services | |
CN111414070A (en) | Case power consumption management method and system, electronic device and storage medium | |
CN108572875A (en) | Resource allocation method, device and system | |
CN109828790B (en) | Data processing method and system based on Shenwei heterogeneous many-core processor | |
CN105791254B (en) | Network request processing method and device and terminal | |
CN112000465B (en) | Method and system for reducing performance interference of delay sensitive program in data center environment | |
CN112269656B (en) | A multi-core processor-based application configuration method, device and system | |
CN105740085A (en) | Fault tolerance processing method and device | |
CN104077188A (en) | Method and device for scheduling tasks | |
CN107133332B (en) | Query task allocation method and device | |
WO2020088078A1 (en) | Fpga-based data processing method, apparatus, device and medium | |
CN112087401A (en) | Method and device for realizing service quality in distributed storage | |
WO2020108536A1 (en) | Virtual network resource allocation method and system and electronic device | |
CN111736981A (en) | Container resource configuration method, apparatus, device and storage medium | |
CN108388409B (en) | Print request processing method, apparatus, computer device and storage medium | |
US20170195261A1 (en) | Apparatus and method for virtual switching |
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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20201002 |
|
RJ01 | Rejection of invention patent application after publication |