CN115951908A - Mirror image preloading method and related device - Google Patents

Mirror image preloading method and related device Download PDF

Info

Publication number
CN115951908A
CN115951908A CN202310017927.5A CN202310017927A CN115951908A CN 115951908 A CN115951908 A CN 115951908A CN 202310017927 A CN202310017927 A CN 202310017927A CN 115951908 A CN115951908 A CN 115951908A
Authority
CN
China
Prior art keywords
cache
mirror image
mirror
resource
preloading
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
Application number
CN202310017927.5A
Other languages
Chinese (zh)
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.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information Technology 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 Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN202310017927.5A priority Critical patent/CN115951908A/en
Publication of CN115951908A publication Critical patent/CN115951908A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • 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

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application discloses a mirror image preloading method, which comprises the following steps: creating a corresponding cache list object based on the information input by the user and the custom resource of the mirror image management platform; performing platform resource conversion based on the cache list object through a cache controller to obtain a mirror image cache object in the mirror image management platform; and executing the mirror image cache object to realize preloading of the corresponding mirror image in the corresponding node. The mirror image caching object realizes automatic mirror image caching operation without manually configuring each node, thereby improving the efficiency of preloading the mirror image and further improving the efficiency of using the mirror image. The application also discloses a mirror preloading device, a server and a computer readable storage medium, which have the beneficial effects.

Description

Mirror image preloading method and related device
Technical Field
The present application relates to the field of cloud computing technologies, and in particular, to a mirror preloading method, a mirror preloading device, a server, and a computer-readable storage medium.
Background
With the continuous development of cloud computing technology, platform tools for managing images in a cloud platform are provided. Kubernetes is a portable, extensible, open source container orchestration platform for managing containerized workloads and services, facilitating declarative configuration and automation, and gradually becoming a de facto standard for cloud computing.
In an actual cloud computing business scenario, the following two scenarios are often encountered:
1, a certain service needs to be started immediately. For example, timing business in the financial industry, second killing of e-commerce platforms, and the need to pull up service quickly at a set period of time.
2, a certain service needs to be quickly expanded. For example, testing requires rapid capacity expansion of the number of service instances for service pressure testing, heavy activities, resource shortage, workload increase, and the like.
In these scenarios, one solution is to load the container image on the cluster working node directly through a pull command such as docker pull (operation instruction) when the container runs, so that Kubelet (node agent in the image management platform) does not need to pull the images, but immediately uses the pulled images. It is estimated that if the mirror of the sidecar (a mode) container and the base mirror of the service container can be pulled on the node in advance, the Pod (the most basic unit for scheduling) creation process can be greatly shortened, wherein the time consumption for pulling the mirror can be optimized even by more than 70%.
In the related art, a container such as a docker (an application container engine) is deployed as a stand-alone device during operation, and when the cluster size is large, for example, the cluster size includes hundreds of nodes, and executing a pull command on each node to preload all required images on the node consumes a large amount of manpower and material resources. That is, no mirror-oriented friendly operation capability is provided in the mirror image management platform, so that the personnel cost is increased, and the mirror image management efficiency is reduced.
Therefore, how to improve the efficiency of preloading images is a key issue that those skilled in the art are concerned about.
Disclosure of Invention
The application aims to provide a mirror image preloading method, a mirror image preloading device, a server and a computer readable storage medium, so that the efficiency of preloading a mirror image is improved, and a large amount of labor cost is avoided in the preloading process.
In order to solve the above technical problem, the present application provides a mirror preloading method, including:
creating a corresponding cache list object based on the information input by the user and the custom resource of the mirror image management platform;
performing platform resource conversion based on the cache list object through a cache controller to obtain a mirror image cache object in the mirror image management platform;
and executing the mirror image cache object to realize preloading of the corresponding mirror image in the corresponding node.
Optionally, the creating a corresponding cache list object based on the information input by the user and the custom resource of the image management platform includes:
acquiring resource cache information input by a user;
and processing the resource cache information based on the custom resource of the cache list type to obtain the corresponding cache list object.
Optionally, the resource cache information includes mirror list information and node identification information, and correspondingly, the resource cache information is processed based on a custom resource of a cache list type to obtain the corresponding cache list object, including:
and adding the mirror list information and the node identification information to the custom resource of the cache list type, and configuring overtime information and failure retry times to obtain the corresponding cache list object.
Optionally, performing, by the cache controller, platform resource conversion based on the cache list object to obtain a mirror cache object inside the platform, including:
and creating a plurality of mirror image cache objects of corresponding nodes by a mirror image management process in the cache controller based on the mirror image list information and the node identification information in the cache list object.
Optionally, the method further includes:
and when the cache list object is obtained, verifying the cache list object through the cache controller.
Optionally, the method further includes:
refreshing the nodes according to a preset period through a mirror image refreshing process in a cache controller; the refreshing processing comprises mirror image defect filling processing, mirror image updating processing and mirror image expansion loading processing.
Optionally, executing the mirror cache object includes:
and determining a corresponding mirror image through the mirror image cache object, and loading the mirror image into a corresponding node.
The present application further provides a mirror preloading device, comprising:
the preloading list acquisition module is used for creating a corresponding cache list object based on information input by a user and custom resources of the mirror image management platform;
the object creating module is used for performing platform resource conversion based on the cache list object through a cache controller to obtain a mirror image cache object in the mirror image management platform;
and the mirror image caching module is used for executing the mirror image caching object and realizing the preloading of the corresponding mirror image in the corresponding node.
The present application further provides a server, comprising:
a memory for storing a computer program;
a processor for implementing the steps of the image preloading method as described above when executing the computer program.
The present application also provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the image preloading method as described above.
The application provides a mirror image preloading method, which comprises the following steps: creating a corresponding cache list object based on the information input by the user and the custom resource of the mirror image management platform; performing platform resource conversion based on the cache list object through a cache controller to obtain a mirror image cache object in the mirror image management platform; and executing the mirror image cache object to realize preloading of the corresponding mirror image in the corresponding node.
The corresponding cache list object is established based on the custom resource in the mirror image preloading method, the corresponding custom cache list object is configured, then the cache controller performs platform resource conversion based on the cache list object to obtain the mirror image cache object in the mirror image management platform, automatic mirror image cache operation is realized through the mirror image cache object, each node does not need to be configured manually, the efficiency of preloading the mirror image is improved, and the mirror image use efficiency is further improved.
The present application further provides a mirror preloading device, a server, and a computer readable storage medium, which have the above beneficial effects, and are not described herein again.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, it is obvious that the drawings in the following description are only embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
FIG. 1 is a flowchart of a mirror preloading method according to an embodiment of the present disclosure;
FIG. 2 is a schematic structural diagram of a mirror preloading device according to an embodiment of the present disclosure;
fig. 3 is a schematic structural diagram of a server according to an embodiment of the present application.
Detailed Description
The core of the application is to provide a mirror image preloading method, a mirror image preloading device, a server and a computer readable storage medium, so that the efficiency of preloading a mirror image is improved, and a large amount of labor cost is avoided in the preloading process.
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In the related art, containers such as dockers and the like are deployed as a single machine during operation, and when the cluster size is large, for example, the cluster size includes hundreds of nodes, and executing a pull command on each node to preload all required images on the nodes consumes a large amount of manpower and material resources. That is, no mirror-oriented friendly operation capability is provided in the mirror image management platform, so that the personnel cost is increased, and the mirror image management efficiency is reduced.
Therefore, the mirror image preloading method is provided, the corresponding cache list object is created based on the custom resource in the mirror image preloading method, the configuration of the corresponding custom cache list object is achieved, then the cache controller performs platform resource conversion based on the cache list object, the mirror image cache object in the mirror image management platform is obtained, automatic mirror image cache operation is achieved through the mirror image cache object, each node does not need to be configured manually, the efficiency of preloading the mirror image is improved, and the efficiency of using the mirror image is further improved.
The following describes a mirror preloading method provided by the present application by using an embodiment.
Referring to fig. 1, fig. 1 is a flowchart illustrating a mirror preloading method according to an embodiment of the present disclosure.
In this embodiment, the method may include:
s101, creating a corresponding cache list object based on information input by a user and custom resources of a mirror image management platform;
it can be seen that this step is intended to create a corresponding cache list object based on the information input by the user and the custom resources of the mirror management platform.
The user-defined Resource (CRD) is a Resource of kubernets (mirror management platform), allows a user to define a new Resource type, and can extend the cluster capability based on the existing kubernets Resource, such as Deployment, job, and the like, and can convert the user-defined Resource type into the Resource type on k8s through the CRD Resource. Besides CRD, the user needs to provide a Controller to implement its own logic, which is specially responsible for monitoring the resource change of the corresponding resource type, and instantiating the corresponding resource as the resource object on the corresponding k8 s.
Further, the step may include:
step 1, acquiring resource cache information input by a user;
and 2, processing the resource cache information based on the custom resource of the cache list type to obtain a corresponding cache list object.
It can be seen that the present alternative scheme mainly illustrates how to generate the cache list object. In the alternative, resource cache information input by a user is acquired; and processing the resource cache information based on the custom resource of the cache list type to obtain a corresponding cache list object. As can be seen, in this alternative, the corresponding cache list object may be determined based on the resource cache information input by the user.
Further, the resource cache information includes mirror list information and node identification information, and step 2 in the last alternative may include:
and adding the mirror image list information and the node identification information into the custom resource of the cache list type, and configuring overtime information and failure retry times to obtain a corresponding cache list object.
It can be seen that the alternative scheme mainly illustrates how to specifically generate the cache list object. In this alternative, the mirror list information and the node identification information are added to the custom resource of the cache list type, and the timeout time information and the number of times of failure retries are configured to obtain the corresponding cache list object.
S102, performing platform resource conversion based on the cache list object through a cache controller to obtain a mirror image cache object in a mirror image management platform;
on the basis of S101, the step aims to perform platform resource conversion based on the cache list object through the cache controller to obtain a mirror image cache object inside the mirror image management platform.
The mirror cache object inside the mirror management platform can be a Job object or a CronJob object. Through these objects, the corresponding mirror can be preloaded in the node.
Further, the step may include:
and creating a plurality of mirror image cache objects of the corresponding nodes by a mirror image management process in the cache controller based on the mirror image list information and the node identification information in the cache list objects.
It can be seen that the present alternative scheme mainly illustrates how to create the mirror cache object. In this alternative, a plurality of mirror image cache objects corresponding to the nodes are created by a mirror image management process in the cache controller based on the mirror image list information and the node identification information in the cache list object.
Further, this embodiment may further include:
and when the cache list object is obtained, verifying the cache list object through the cache controller.
It can be seen that the present alternative mainly illustrates that object data can also be verified. In this alternative, when the cache list object is obtained, the cache list object is verified by the cache controller.
Further, this embodiment may further include:
refreshing the nodes according to a preset period through a mirror image refreshing process in a cache controller; the refreshing processing comprises mirror image defect filling processing, mirror image updating processing and mirror image expansion loading processing.
It can be seen that the present alternative is mainly illustrative of how the mirror can also be refreshed. In the alternative scheme, the mirror image refreshing process in the cache controller refreshes the nodes according to a preset period; the refreshing processing comprises mirror image defect filling processing, mirror image updating processing and mirror image expansion loading processing.
The mirror image filling-up processing is to fill up the missing mirror images. The mirror image updating process refers to updating the mirror image. The mirror image expansion loading processing is the loading processing of the mirror image to the new node when the expansion exists.
S103, executing the mirror image cache object, and preloading the corresponding mirror image in the corresponding node.
On the basis of S102, this step is intended to execute a mirror cache object, so as to preload a corresponding mirror in a corresponding node.
Further, the step may include:
and determining a corresponding mirror image through the mirror image cache object, and loading the mirror image into a corresponding node.
In summary, in the embodiment, the corresponding cache list object is created based on the custom resource in the mirror image preloading method, so that the corresponding custom cache list object is configured, then the cache controller performs platform resource conversion based on the cache list object to obtain the mirror image cache object inside the mirror image management platform, and the mirror image cache object is used to implement automatic mirror image cache operation without manually configuring each node, so that the efficiency of preloading the mirror image is improved, and the efficiency of using the mirror image is further improved.
A mirror preloading method provided by the present application is further described below with another specific embodiment.
First, objects incorporated in the kubernets platform, such as Job, cronJob, label, and Selector, will be described.
Wherein the Job object is used to create 1 or more Pods and ensure that a specified number (. Spec. Completions) of Pods are successfully completed. When a Pod completes successfully (. Status. Phase = successful), the Job records the number of Pod completed, but completes when the number of completion reaches a specified value. When a Pod fails to execute, job will continue to create a new Pod for retries until the number of failures reaches the value specified by spec.
The CronJob object is a managed Job object, that is, one Job is created to execute a task every cycle, and only one Job can be managed at a time. CronTab in CronJob and Linux is very similar, adding time scheduling to Job, running a task at a given point in time, or periodically running at a given point in time.
Wherein the Label object is a set of key/value pairs bound to the K8s resource object. The keys of the labels attribute of the same object must be unique, and labels can be attached to various resource objects, such as nodes, pod, service, and the like. The multi-dimensional resource grouping management function is realized by binding one or more unused labels to the specified resource object, so that the management work of resource allocation, scheduling, configuration, deployment and the like can be flexibly and conveniently carried out.
The Selector object is a grouping mechanism of Kubernets, and a group of resource objects with common characteristics or attributes can be identified through a Label Selector client/user.
It can be seen that based on the above-described native kubernets resource, a Job/cron Job object implementation can be created that caches a particular set of images on a particular set of nodes within a cluster.
Figure BDA0004041271980000081
The image in the xml file is the mirror image which needs to be loaded on the node, and the key and value are the label key-value pair on the node which needs to be loaded with the mirror image. Thus, the user can specify in Job the scope of a mirror to preload, as well as the pull policy for this mirror, job's lifecycle, etc. After a Job is created and executed, pod is created on the nodes with the matching label respectively, so that the scale preheating is completed. Thus, the application pod starts almost immediately because there is no need to extract the image from the registry.
However, the above-mentioned Job/CronJob object can only realize that a certain specific mirror object is loaded on a group of nodes, and only one group of Job/CronJob object can be created for the requirement of loading batch mirrors, which is cumbersome to operate and not user-friendly. In addition, the Kubernetes native Job/CronJob object can mechanically load a specific mirror on a specific node, but cannot realize management functions such as creation, update, deletion, query and the like of a mirror cache object, and the above policies need to be packaged into a k8s operator (namely, CRD) for directly creating and managing the cache of a container mirror on a working node of a Kubernetes cluster. The CRD is a resource of Kubernets, allows a user to define a new resource type, can expand the cluster capacity based on the existing Kubernets resource, such as Deployment, job and the like, and can convert the user-defined resource type into the resource type on k8s through the CRD resource. Besides CRD, the user is also required to provide a controller to implement its own logic, which is specially responsible for monitoring the resource change of the corresponding resource type, and instantiating the corresponding resource as the resource object on the corresponding k8 s.
This embodiment may define a custom resource with a type of "Cache" (Cache list object), and the example content is as follows:
Figure BDA0004041271980000091
Figure BDA0004041271980000101
the images are mirror image lists needing to be loaded on the nodes, and the keys and the values are label key value pairs on the nodes needing to be loaded with mirror images.
Further, when node-selector in the yaml file is empty, the mirror image indicated in images can be deployed to all nodes.
Further, the mirror indicated in the images field may be from a private warehouse address (e.g. Harbor), and if necessary, the images PullSecrets field may be filled with secret information required for accessing the private warehouse address, and these secrets must be stored in the namespace where the cache is located.
Further, timeoutSeconds is the image pull timeout time, and backoff is the number of failed retries.
In addition to the CRD object cache, this embodiment implements a controller (which may be referred to as a cache-controller) and a verifier (which may be referred to as a cache-webhooker). Wherein, the Cache-webhook-server is responsible for verifying the fields of the Cache resources. A user can create and delete cache resources by using a kubecect command, and a cache-controller is provided with a built-in Manager (mirror image management process) routine and is responsible for pulling and deleting a mirror image; the Cache-controller has a built-in refresh routine responsible for periodically refreshing the mirror, and updates the states of mirror pull, refresh and mirror delete in the status field of the Cache resources.
Further, the workflow of the above operation is as follows:
the cache is created by specifying the list of images to pull and is used by the nodesector to specify the node where the image should be cached. The request is firstly sent to a Cache-webhook-server through an APIServer to verify a field of the cacheSpec, and after a successful response from the webhook is received, the APIServer keeps the Cache resource in an etcd (a storage system) for a long time. This triggers the manager routine processing on the cache-controller and queues the requests, which creates a set of k8s-Job objects for each request, responsible for pulling the mirror to the node for caching. manager keeps track of the jobs it creates, and once the jobs are completed, it places the responses in a separate queue to update the state portion of the Cache resources and change the state data in etcd.
In addition to the manager process, the refresh process runs periodically to keep the mirror cache refreshed. Firstly, if a certain mirror image is lacked in the node cache, the mirror image is pulled to the node again; secondly, if the mirror image in the mirror image warehouse is updated, the mirror image is pulled to all nodes again; and thirdly, if the label key value indicated in the cache expands the node range covered by the label key value, the mirror image is pulled to a new node.
In addition, the image list indicated by images field in the cache object can be updated, and the nodesector can also be used for changing the node range to which the image needs to be loaded.
In addition, the cache object can be deleted, all the specific mirror images loaded to the specific nodes can be cleared before the cache object is deleted, the storage resources of the nodes are released, and then the cache object is deleted.
Further, the usage scenario is as follows:
1, cluster dimension preheating
This scenario may keep warming some base images throughout the cluster dimension, which may be those base sidecar images that are carried in substantially every service Pod. And maintaining the field object of the nodeselector to be empty, defaulting all images specified by images to be uniformly loaded on all nodes of the whole cluster dimension, and preheating the subsequently added nodes and automatically loading immediately. And the mirror preheating is carried out once in advance in a large scale, so that the subsequent expansion and release speed of the Pod can be greatly improved.
2, preheating in node dimension
Specifying the selector preheat range, the node that can match the key = value tag. Thus, there may be multiple different traffic resource pools in some multi-tenanted kubernets clusters, where some specific traffic images may need to be warmed up by resource pool dimension.
It can be seen that, in the embodiment, the corresponding cache list object is created based on the custom resource in the mirror image preloading method, so that the corresponding custom cache list object is configured, then, the cache controller performs platform resource conversion based on the cache list object to obtain the mirror image cache object inside the mirror image management platform, and the mirror image cache object is used to implement automatic mirror image cache operation without manually configuring each node, so that the efficiency of preloading the mirror image is improved, and the efficiency of using the mirror image is further improved.
In the following, the mirror preloading device provided in the embodiments of the present application is described, and the mirror preloading device described below and the mirror preloading method described above may be referred to correspondingly.
Referring to fig. 2, fig. 2 is a schematic structural diagram of a mirror preloading device according to an embodiment of the present disclosure.
In this embodiment, the apparatus may include:
a preloaded list obtaining module 100, configured to create a corresponding cache list object based on information input by a user and a custom resource of the mirror image management platform;
the object creation module 200 is configured to perform platform resource conversion based on the cache list object through the cache controller to obtain a mirror cache object inside the mirror management platform;
the mirror image caching module 300 is configured to execute a mirror image caching object, so as to preload a corresponding mirror image in a corresponding node.
Optionally, the preloaded list obtaining module 100 is specifically configured to obtain resource cache information input by a user; and processing the resource cache information based on the custom resource of the cache list type to obtain a corresponding cache list object.
Optionally, the resource cache information includes mirror list information and node identification information, and correspondingly, the resource cache information is processed based on the custom resource of the cache list type to obtain a corresponding cache list object, including:
adding the mirror list information and the node identification information into the custom resources of the cache list type, and configuring overtime information and failure retry times to obtain a corresponding cache list object.
Optionally, the object creating module 200 is specifically configured to create, by a mirror management process in the cache controller, a plurality of mirror cache objects corresponding to the node based on the mirror list information and the node identification information in the cache list object.
Optionally, the apparatus may further include:
and the data verification module is used for verifying the cache list object through the cache controller when the cache list object is obtained.
Optionally, the apparatus may further include:
the mirror image refreshing module is used for refreshing the nodes according to a preset period through a mirror image refreshing process in the cache controller; the refreshing processing comprises mirror image defect filling processing, mirror image updating processing and mirror image expansion loading processing.
Optionally, the mirror image caching module 300 is specifically configured to determine a corresponding mirror image through a mirror image caching object, and load the mirror image into a corresponding node.
It can be seen that, in the embodiment, the corresponding cache list object is created based on the custom resource in the mirror image preloading method, so that the corresponding custom cache list object is configured, then the cache controller performs platform resource conversion based on the cache list object to obtain the mirror image cache object inside the mirror image management platform, and the mirror image cache object is used to implement automatic mirror image cache operation without manually configuring each node, so that the efficiency of preloading the mirror image is improved, and the efficiency of using the mirror image is further improved.
Referring to fig. 3, fig. 3 is a schematic structural diagram of a server provided in the embodiment of the present application, where the server may include:
a memory for storing a computer program;
a processor, configured to execute a computer program, may implement the steps of any of the image preloading methods described above.
As shown in fig. 3, which is a schematic diagram of a composition structure of a server, the server may include: a processor 10, a memory 11, a communication interface 12 and a communication bus 13. The processor 10, the memory 11 and the communication interface 12 all communicate with each other through a communication bus 13.
In the embodiment of the present application, the processor 10 may be a Central Processing Unit (CPU), an application specific integrated circuit, a digital signal processor, a field programmable gate array or other programmable logic device, etc.
The processor 10 may call a program stored in the memory 11, and in particular, the processor 10 may perform operations in an embodiment of the exception IP recognition method.
The memory 11 is used for storing one or more programs, the program may include program codes, the program codes include computer operation instructions, in this embodiment, the memory 11 stores at least the program for implementing the following functions:
creating a corresponding cache list object based on the information input by the user and the custom resource of the mirror image management platform;
performing platform resource conversion based on the cache list object through a cache controller to obtain a mirror image cache object in a mirror image management platform;
and executing the mirror image cache object to realize preloading of the corresponding mirror image in the corresponding node.
In one possible implementation, the memory 11 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required for at least one function, and the like; the storage data area may store data created during use.
Further, the memory 11 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device or other volatile solid state storage device.
The communication interface 12 may be an interface of a communication module for connecting with other devices or systems.
Of course, it should be noted that the structure shown in fig. 3 does not constitute a limitation on the server in the embodiment of the present application, and in practical applications, the server may include more or less components than those shown in fig. 3, or some components may be combined.
The present application also provides a computer readable storage medium, on which a computer program is stored, which, when executed by a processor, can implement the steps of any of the image preloading methods described above.
The computer-readable storage medium may include: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
For the introduction of the computer-readable storage medium provided in the present application, please refer to the above method embodiments, which are not described herein again.
The embodiments are described in a progressive mode in the specification, the emphasis of each embodiment is on the difference from the other embodiments, and the same and similar parts among the embodiments can be referred to each other. The device disclosed in the embodiment corresponds to the method disclosed in the embodiment, so that the description is simple, and the relevant points can be referred to the description of the method part.
Those of skill would further appreciate that the various illustrative components and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the components and steps of the various examples have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may reside in Random Access Memory (RAM), memory, read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
The image preloading method, the image preloading device, the server and the computer readable storage medium provided by the present application are described in detail above. The principles and embodiments of the present application are described herein using specific examples, which are only used to help understand the method and its core idea of the present application. It should be noted that, for those skilled in the art, it is possible to make several improvements and modifications to the present application without departing from the principle of the present application, and such improvements and modifications also fall within the scope of the claims of the present application.

Claims (10)

1. A method of mirror preloading, comprising:
creating a corresponding cache list object based on the information input by the user and the custom resource of the mirror image management platform;
performing platform resource conversion based on the cache list object through a cache controller to obtain a mirror image cache object in the mirror image management platform;
and executing the mirror image cache object to realize preloading of the corresponding mirror image in the corresponding node.
2. The image preloading method of claim 1, wherein creating the corresponding cache list object based on the information input by the user and the custom resource of the image management platform comprises:
acquiring resource cache information input by a user;
and processing the resource cache information based on the custom resource of the cache list type to obtain the corresponding cache list object.
3. The mirror preloading method according to claim 2, wherein the resource cache information includes mirror list information and node identification information, and correspondingly, the resource cache information is processed based on a custom resource of a cache list type to obtain the corresponding cache list object, including:
and adding the mirror list information and the node identification information to the custom resource of the cache list type, and configuring overtime information and failure retry times to obtain the corresponding cache list object.
4. The mirror preloading method according to claim 1, wherein performing platform resource transformation based on the cache list object by a cache controller to obtain a mirror cache object inside the platform comprises:
and creating a plurality of mirror image cache objects of corresponding nodes by a mirror image management process in the cache controller based on the mirror image list information and the node identification information in the cache list object.
5. The mirror preloading method of claim 4, further comprising:
and when the cache list object is obtained, verifying the cache list object through the cache controller.
6. The mirror preloading method of claim 4, further comprising:
refreshing the nodes according to a preset period through a mirror image refreshing process in the cache controller; the refreshing processing comprises mirror image defect filling processing, mirror image updating processing and mirror image expansion loading processing.
7. The mirror preloading method of claim 1, wherein executing the mirror cache object comprises:
and determining a corresponding mirror image through the mirror image cache object, and loading the mirror image into a corresponding node.
8. A mirrored preloading device, comprising:
the preloading list acquisition module is used for creating a corresponding cache list object based on information input by a user and custom resources of the mirror image management platform;
the object creating module is used for performing platform resource conversion based on the cache list object through a cache controller to obtain a mirror image cache object in the mirror image management platform;
and the mirror image caching module is used for executing the mirror image caching object and preloading a corresponding mirror image in a corresponding node.
9. A server, comprising:
a memory for storing a computer program;
a processor for implementing the steps of the image preloading method as defined in any one of claims 1 to 7 when said computer program is executed.
10. A computer-readable storage medium, having stored thereon a computer program which, when being executed by a processor, carries out the steps of the image preloading method according to any one of claims 1 to 7.
CN202310017927.5A 2023-01-06 2023-01-06 Mirror image preloading method and related device Pending CN115951908A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310017927.5A CN115951908A (en) 2023-01-06 2023-01-06 Mirror image preloading method and related device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310017927.5A CN115951908A (en) 2023-01-06 2023-01-06 Mirror image preloading method and related device

Publications (1)

Publication Number Publication Date
CN115951908A true CN115951908A (en) 2023-04-11

Family

ID=87290499

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310017927.5A Pending CN115951908A (en) 2023-01-06 2023-01-06 Mirror image preloading method and related device

Country Status (1)

Country Link
CN (1) CN115951908A (en)

Similar Documents

Publication Publication Date Title
US10237118B2 (en) Efficient application build/deployment for distributed container cloud platform
CN111488241B (en) Method and system for realizing agent-free backup and recovery operation in container arrangement platform
US20230308525A1 (en) Embedded database as a microservice for distributed container cloud platform
RU2429529C2 (en) Dynamic configuration, allocation and deployment of computer systems
US20180143856A1 (en) Flexible job management for distributed container cloud platform
US9535754B1 (en) Dynamic provisioning of computing resources
KR20110030447A (en) Synchronizing virtual machine and application life cycles
US11449350B2 (en) Systems and methods for automatically updating compute resources
CN107566518B (en) Method and device for managing equipment information in file installation process
CN110941393A (en) Logical volume management-based LV supply method, device, equipment and medium
CN113626286A (en) Multi-cluster instance processing method and device, electronic equipment and storage medium
CN113296805A (en) Method and device for realizing hot upgrade of auxiliary container
CN114528085A (en) Resource scheduling method, device, computer equipment, storage medium and program product
CN106874343B (en) Data deletion method and system for time sequence database
CN104793981A (en) Online snapshot managing method and device for virtual machine cluster
US20150220517A1 (en) Efficient conflict resolution among stateless processes
CN114385349A (en) Container group deployment method and device
CN112035062B (en) Migration method of local storage of cloud computing, computer equipment and storage medium
CN111159156B (en) Backup method and device for SQLite database
CN115357198B (en) Mounting method and device of storage volume, storage medium and electronic equipment
US20230161643A1 (en) Lifecycle management for workloads on heterogeneous infrastructure
CN115951908A (en) Mirror image preloading method and related device
CN115357336A (en) Online capacity expansion method and device of container group, terminal equipment and medium
CN111431951B (en) Data processing method, node equipment, system and storage medium
CN111858234A (en) Task execution method, device, equipment and 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