Database deployment method, system and device, storage medium and computer product
The database deployment method addresses the Kubernetes scheduler's limitations by using multi-dimensional node parameter screening to match Pods with different resource demands, enhancing resource utilization efficiency.
Patent Information
- Application Number
- CN202411265076.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-10
- Publication Date
- 2024-12-13
AI Technical Summary
The Kubernetes scheduler lacks judgment on other dimensional resources during the node screening process, unable to accurately match Pods with different resource requirements based on actual operating conditions and custom configurations, affecting resource utilization.
A database deployment method that involves obtaining node requirement parameters, determining a user portrait strategy, and deploying the database on the target target, and determining a target node, and deploying the database on the target target, thereby ensuring the operating efficiency of the database.
Enables terminal devices to screen out nodes that better match the database by considering multi-dimensional node demand parameters, ensuring accurate matching and improved resource utilization.
Smart Images

Figure CN119127402A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a database deployment method, system, terminal device, storage medium and computer program product. Background Art
[0002] With the continuous development of computer technology, automated deployment of databases to nodes has become an important means of managing large-scale container clusters.
[0003] In related technologies, technicians usually rely on the Kubernetes (container cluster management system) scheduler to select suitable nodes for Pods, and then deploy Pods to suitable nodes. However, in the process of selecting nodes, the Kubernetes scheduler can only make decisions based on the remaining memory of the node, the allocation of resources such as CPU, and whether other related Pod and node configurations match. This results in the Kubernetes scheduler missing judgments on other dimensional resources in the process of selecting nodes, and it is unable to select nodes that match Pods based on actual operating conditions and custom configurations, and thus cannot accurately match Pods with different resource requirements.
[0004] Therefore, how to enable terminal devices to screen out nodes that better match the database has become a technical problem that needs to be urgently solved in the industry. Summary of the invention
[0005] The main purpose of this application is to provide a database deployment method, system, terminal device, storage medium and computer program product, aiming to solve the technical problems in the related technology that the Kubernetes scheduler lacks judgment on other dimensional resources during the node screening process, and cannot screen out nodes that match Pods through actual operation conditions and custom configurations, and thus cannot accurately match Pods with different resource demand focuses and affect resource utilization.
[0006] To achieve the above objectives, the present application proposes a database deployment method, the method comprising:
[0007] Obtaining node requirement parameters of a preset database, and determining a user profiling strategy corresponding to the preset database according to the node requirement parameters;
[0008] Reading node operation parameters corresponding to each of a plurality of preset initial nodes, and determining a target node among the plurality of initial nodes based on the plurality of node operation parameters and the user portrait strategy;
[0009] The preset database is deployed to the target node, so that the preset database runs on the target node.
[0010] In one embodiment, the step of determining the user portrait strategy corresponding to the preset database according to the node requirement parameter includes:
[0011] Determine a plurality of baseline demand parameter ranges, and baseline profiling strategies corresponding to the plurality of baseline demand parameter ranges;
[0012] Determining a target demand parameter range from a plurality of reference demand parameter ranges according to the node demand parameter, wherein the target demand parameter range is a reference demand parameter range including the node demand parameter;
[0013] The benchmark portrait strategy corresponding to the target demand parameter range is determined as the user portrait strategy corresponding to the preset database.
[0014] In one embodiment, the step of determining a target node from a plurality of initial nodes based on the plurality of node operating parameters and the user portrait strategy includes:
[0015] Read multiple node parameter thresholds included in the user portrait strategy;
[0016] Obtaining node matching results corresponding to each of the plurality of initial nodes based on the plurality of node operation parameters and the plurality of node parameter thresholds;
[0017] Screening the plurality of initial nodes according to the node matching results to determine a plurality of nodes to be evaluated from the plurality of initial nodes;
[0018] Determine the target node evaluation scores corresponding to each of the plurality of nodes to be evaluated, and determine the target node among the plurality of nodes to be evaluated based on the plurality of target node evaluation scores.
[0019] In one embodiment, the step of obtaining node matching results corresponding to each of the plurality of initial nodes based on the plurality of node operating parameters and the plurality of node parameter thresholds includes:
[0020] Determine node parameter thresholds corresponding to each of the plurality of node operating parameters, and compare the plurality of node operating parameters with the corresponding node parameter thresholds to obtain a plurality of comparison results;
[0021] When the multiple comparison results corresponding to the initial node are all standard comparison results, determining that the node matching result corresponding to the initial node is a successful match, wherein the standard comparison result is that the node operation parameter reaches the node parameter threshold;
[0022] When there is an abnormal comparison result among the multiple comparison results corresponding to the initial node, it is determined that the node matching result corresponding to the initial node is a matching failure, wherein the abnormal comparison result is that the node operation parameter does not reach the node parameter threshold.
[0023] In one embodiment, the step of determining the target node evaluation scores corresponding to each of the plurality of nodes to be evaluated comprises:
[0024] Determining target operating parameters corresponding to each of the plurality of nodes to be evaluated from the plurality of node operating parameters;
[0025] Determine the weight value corresponding to each of the target operating parameters according to the user portrait strategy, and determine the initial node score value corresponding to each of the plurality of nodes to be evaluated according to the user portrait strategy;
[0026] The target node evaluation scores corresponding to each of the plurality of nodes to be evaluated are determined based on the initial node score values and the weight values.
[0027] In one embodiment, after the step of determining the initial node score values corresponding to each of the plurality of nodes to be evaluated according to the user portrait strategy, the method includes:
[0028] Determine the scheduling quantities corresponding to each of the plurality of nodes to be evaluated, and based on each of the scheduling quantities, update the initial node score values corresponding to each of the plurality of nodes to be evaluated to obtain an intermediate node score value;
[0029] The target node evaluation scores corresponding to each of the plurality of nodes to be evaluated are determined based on the score values of each of the intermediate nodes and each of the weight values.
[0030] In addition, to achieve the above objectives, the present application also proposes a deployment system, the system comprising:
[0031] A strategy screening module, used to obtain node requirement parameters of a preset database, and determine a user profiling strategy corresponding to the preset database according to the node requirement parameters;
[0032] A node screening module, used to read node operation parameters corresponding to each of a plurality of preset initial nodes, and determine a target node from the plurality of initial nodes based on the plurality of node operation parameters and the user portrait strategy;
[0033] The application deployment module is used to deploy the preset database to the target node so that the preset database runs on the target node.
[0034] In addition, to achieve the above-mentioned purpose, the present application also proposes a terminal device, which includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the database deployment method as described above.
[0035] In addition, to achieve the above-mentioned purpose, the present application also proposes a storage medium, which is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the database deployment method described above are implemented.
[0036] In addition, to achieve the above-mentioned purpose, the present application also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, the steps of the database deployment method described above are implemented.
[0037] The database deployment method provided in the embodiment of the present application obtains the node requirement parameters of a preset database, and determines the user portrait strategy corresponding to the preset database according to the node requirement parameters; reads the node operation parameters corresponding to each of a plurality of preset initial nodes, and determines the target node among the plurality of initial nodes based on the plurality of node operation parameters and the user portrait strategy; and deploys the preset database to the target node so that the preset database runs on the target node.
[0038] In this embodiment, the terminal device first determines the node requirement parameters of the preset database that needs to be deployed during operation, and determines the user portrait strategy corresponding to the preset database based on the node requirement parameters. After that, the terminal device reads the node operation parameters corresponding to each of the preset multiple initial nodes, and performs multi-dimensional screening of the multiple initial nodes based on the node operation parameters and the user portrait strategy, thereby screening out the target node that meets the user portrait strategy from the multiple initial nodes. Finally, the terminal device binds the preset database and the target node, thereby deploying the preset database on the target node so that the preset database runs on the target node.
[0039] In this way, the present application solves the technical problem in the related technology that the Kubernetes scheduler lacks judgment on resources of other dimensions during the process of node screening, and is unable to screen out nodes that match the Pod through actual operation conditions and custom configurations, and thus is unable to accurately match Pods with different resource demand focuses and affects resource utilization. That is, the present application screens out user portrait strategies that match the preset database based on multi-dimensional node demand parameters, and then screens multiple initial nodes according to the user portrait strategy to obtain target nodes that match the preset database, thereby achieving the technical effect of enabling terminal devices to screen out nodes that better match the database, thereby ensuring the operating efficiency of the database. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0041] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0042] Figure 1 A flowchart of a method for deploying a database according to the present application;
[0043] Figure 2 A schematic diagram of a node screening process involved in an embodiment of a method for deploying a database of the present application;
[0044] Figure 3 A schematic diagram of the system architecture involved in an embodiment of a method for deploying a database of the present application;
[0045] Figure 4 A schematic diagram of the expander interaction process involved in an embodiment of the database deployment method of the present application;
[0046] Figure 5 A schematic diagram of a user portrait strategy generation process involved in an embodiment of a method for deploying a database of this application;
[0047] Figure 6 A schematic diagram of a node selection process involved in an embodiment of a method for deploying a database of the present application;
[0048] Figure 7 A detailed flow chart of an embodiment of a method for deploying a database of the present application;
[0049] Figure 8A schematic diagram of the device structure of the hardware operating environment involved in the deployment method of the database of this application;
[0050] Fig. 9 This is a functional structure diagram of a deployment system involved in an embodiment of a database deployment method of the present application.
[0051] The purpose, features and advantages of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0052] It should be understood that the specific embodiments described herein are only used to explain the technical solutions of the present application and are not used to limit the present application.
[0053] In order to better understand the technical solution of the present application, a detailed description will be given below in conjunction with the accompanying drawings and specific implementation methods.
[0054] In this embodiment, for ease of description, please refer to Figure 3 , Figure 3 This is a schematic diagram of the system architecture involved in an embodiment of the database deployment method of this application, such as Figure 3 As shown, the following is explained with the terminal device configured with the kubernetes control interface and the kubernetes resource pool as the execution subject. It can be understood that the kubernetes control interface is used to determine the user portrait strategy corresponding to the preset database. In addition, the kubernetes resource pool contains node resource pools corresponding to different user portrait strategies.
[0055] Based on the above-mentioned terminal device, the overall concept of the deployment method of the database of this application is proposed here.
[0056] With the continuous development of computer technology, the automated deployment of databases to nodes has become an important means of managing large-scale container clusters. In related technologies, technicians usually rely on the Kubernetes (container cluster management system) scheduler to select suitable nodes for Pods, and then deploy Pods to suitable nodes. However, in the process of selecting nodes, the Kubernetes scheduler can only make decisions based on the remaining memory of the node, the allocation of resources such as CPU, and whether other related Pods and node configurations match. This results in the Kubernetes scheduler missing judgments on other dimensional resources in the process of selecting nodes, and it is impossible to select nodes that match Pods through actual operation conditions and custom configurations, and thus it is impossible to accurately match Pods with different resource requirements.
[0057] In response to the above phenomenon, the present application provides a database deployment method, which includes: obtaining node requirement parameters of a preset database, and determining a user portrait strategy corresponding to the preset database based on the node requirement parameters; reading node operation parameters corresponding to each of a plurality of preset initial nodes, and determining a target node among the plurality of initial nodes based on the plurality of node operation parameters and the user portrait strategy; deploying the preset database to the target node so that the preset database runs on the target node.
[0058] In this way, the present application solves the technical problem in the related technology that the Kubernetes scheduler lacks judgment on resources of other dimensions during the process of node screening, and is unable to screen out nodes that match the Pod through actual operation conditions and custom configurations, and thus is unable to accurately match Pods with different resource demand focuses and affects resource utilization. That is, the present application screens out user portrait strategies that match the preset database based on multi-dimensional node demand parameters, and then screens multiple initial nodes according to the user portrait strategy to obtain target nodes that match the preset database, thereby achieving the technical effect of enabling terminal devices to screen out nodes that better match the database, thereby ensuring the operating efficiency of the database.
[0059] Based on the overall concept of the database deployment method of the present application, the embodiment of the present application provides a database deployment method, referring to Figure 1 , Figure 1 This is a flowchart of the first embodiment of the database deployment method of the present application.
[0060] In this embodiment, the database deployment method includes steps S10 to S30:
[0061] Step S10: Obtain node requirement parameters of a preset database, and determine a user profiling strategy corresponding to the preset database according to the node requirement parameters;
[0062] It should be noted that the preset database is a containerized database that needs to be run, which usually exists in the form of a Pod. It is understandable that the preset database usually stores data for users to view, such as user account balances and other information. In addition, the node requirement parameters are the resource parameters that the node needs to provide during the operation of the Pod, which can specifically include original node requirement parameters and custom node requirement parameters. The original node requirement parameters include: CPU usage, total memory size, memory usage size, etc. The custom node requirement parameters are the requirement parameters obtained based on the original node requirement parameters, which specifically include: average CPU peak value, average memory peak value, average iops peak value, CPU overselling ratio, number of business pods, actual disk usage, etc. In addition, please refer to Figure 5 , Figure 5 This is a schematic diagram of a user portrait strategy generation process involved in an embodiment of a method for deploying a database of this application, such as Figure 5 As shown, the user portrait strategy is a rule generated by arranging the original node requirement parameters and the custom node requirement parameters, which can specifically include: computing-intensive strategy, storage-intensive strategy, and storage-computation balance strategy. It can be understood that the node type required by the Pod can be determined through the user portrait strategy.
[0063] In this embodiment, when the terminal device is running, it first calls its own configured adapter to access the preset database, thereby obtaining multiple node demand parameters corresponding to the preset database, including original node demand parameters and customized node demand parameters. The terminal device then determines a user portrait strategy that matches the preset database based on the multiple node demand parameters.
[0064] For example, see Figure 7 , Figure 7 This is a detailed flow chart of an embodiment of a method for deploying a database of this application, such as Figure 7 As shown, when the terminal device is running, it first calls the k8s-prometheus-adapter adapter configured by itself to aggregate the API interface of the preset Pod, so as to determine that the API interface of the Pod is custom.metrics.k8s.io. The terminal device then accesses the API interface through the adapter to obtain the original node demand parameters such as cpu usage, total memory size, memory usage size, etc. provided by the node required by the preset Pod through the API interface. The terminal device then calls the averagepeak-exporter tool and the Prometheus Recording Rule tool to calculate the original node demand parameters to obtain the custom node demand parameters such as the average cpu peak value, the average memory peak value, the average iops peak value, the cpu oversold ratio, the number of business pods, and the actual disk usage rate, and integrates the original node demand parameters and the custom node demand parameters to determine whether the user portrait strategy corresponding to the preset Pod is a computing-intensive strategy, a storage-intensive strategy, or a storage-computing balance strategy.
[0065] It should be noted that the specific process of processing parameters such as cpu usage, total memory size, memory usage size, etc. through the averagepeak-exporter tool and the Prometheus Recording Rule tool to obtain parameters such as cpu average peak value, memory average peak value, iops average peak value, cpu oversold ratio, number of business pods, actual disk usage, etc. is an existing technology, so it will not be repeated here. In addition, after the terminal device determines the API interface through the k8s-prometheus-adapter adapter, it can call the Prometheus tool configured by itself to periodically pull data from the preset Pod through the API interface and store the data in the time series database configured by itself.
[0066] In addition, in this embodiment and another embodiment, before accessing the preset Pod, the terminal device may also generate a preset Pod. Specifically, the terminal device first receives a naming initiation request initiated by the user, and calls the Kube-apiserver tool configured by itself to call the preset kubeconfig configuration file to authenticate the naming initiation request, so that after the authentication is passed, the preset Pod information is stored in ETCD (Etcd Cluste, ETCD storage system). At the same time, the Controller-Manager in the terminal device updates the Pod information through the interface of the Kube-apiserver tool, and writes the updated Pod information into ETCD through the Kube-apiserver tool. After that, when the Scheduler in the terminal device is updated to the preset Pod through the Kube-apiserver tool, the Scheduler in the terminal device can allocate a node for the Pod, and write the binding information between the Pod and the corresponding node into ETCD through the Kube-apiserver tool. Finally, the terminal device calls the preset CNI (Container Network Interface, container network interface), CSI (ContainerStorage Interface, container storage interface), CRI (Container Runtime Interface, container operation interface) and other interfaces process the binding information and Pod information in ETCD to complete the creation of related resources, and then complete the Pod creation. It can be understood that the Kube-apiserver tool is mainly used to process request information. In addition, the Controller-Manager is used to update the Pod information after detecting the Pod information update, and pass the updated Pod information to the Kube-apiserver tool. In addition, ETCD is used to save all data in the Kubernetes cluster. In addition, Kubelet is an agent service running on each node, responsible for maintaining the life cycle of the container, including starting the container, monitoring the container running status and resource usage, and communicating with the Kube-apiserver tool.
[0067] In this way, the terminal device can obtain the node requirement parameters of the preset Pod in multiple dimensions, and filter out the user portrait strategy that matches the Pod based on the multi-dimensional node requirement parameters.
[0068] In a feasible implementation manner, the step of “determining the user portrait strategy corresponding to the preset database according to the node requirement parameters” in the above step S10 may specifically include steps S101 to S103:
[0069] Step S101: determining a plurality of reference requirement parameter ranges and reference profile strategies corresponding to the plurality of reference requirement parameter ranges;
[0070] Step S102: determining a target demand parameter range from a plurality of reference demand parameter ranges according to the node demand parameter, wherein the target demand parameter range is a reference demand parameter range including the node demand parameter;
[0071] Step S103: Determine the baseline portrait strategy corresponding to the target demand parameter range as the user portrait strategy corresponding to the preset database.
[0072] In this embodiment, after obtaining the original node demand parameters and custom node demand parameters corresponding to the preset database, the terminal device further reads the storage module configured by itself to obtain multiple benchmark demand parameter ranges and benchmark portrait strategies corresponding to the multiple benchmark demand parameter ranges. Afterwards, the terminal device compares the obtained original node demand parameters and custom node demand parameters with their corresponding benchmark demand parameter ranges respectively, thereby determining the target demand parameter range containing the node demand parameters in the multiple benchmark demand parameter ranges. Finally, the terminal device determines the benchmark portrait strategy that corresponds to multiple target demand parameter ranges at the same time among the multiple benchmark portrait strategies, and determines the benchmark portrait strategy that corresponds to multiple target demand parameter ranges at the same time as the user portrait strategy that matches the preset database.
[0073] Exemplarily, for example, after the terminal device accesses the API interface through the k8s-prometheus-adapter adapter to obtain original node demand parameters such as cpu usage, total memory size, and memory usage size, and obtains custom node demand parameters such as cpu average peak value, memory average peak value, iops average peak value, cpu overselling ratio, number of business pods, and actual disk usage based on each original node demand parameter, it further reads the storage module configured by itself to obtain the benchmark cpu usage parameter range corresponding to the cpu usage, the benchmark total memory size parameter range corresponding to the total memory size, the benchmark memory usage size parameter range corresponding to the memory usage size, and the cpu average peak value. The terminal device then calls the Scheduler-extender configured by itself to determine the target CPU usage parameter range in multiple benchmark CPU usage parameter ranges, and determines the target total memory size parameter range in multiple benchmark total memory size parameter ranges, and determines the target total memory size parameter range in multiple benchmark ranges. The target memory usage size parameter range is determined in the memory usage size parameter range, and the target CPU average peak parameter range is determined in multiple benchmark CPU average peak parameter ranges, and the target memory average peak parameter range is determined in multiple benchmark memory average peak parameter ranges, and the target iops average peak parameter range is determined in multiple benchmark iops average peak parameter ranges, and the target CPU overselling ratio parameter range is determined in multiple benchmark CPU overselling ratio parameter ranges, and the target business pod number parameter range is determined in multiple benchmark business pod number parameter ranges, and the target disk actual usage range is determined in multiple benchmark disk actual usage ranges. Finally, Scheduler-extender extension The scheduler screens compute-intensive strategies, storage-intensive strategies, and storage-computation balance strategies according to the target CPU usage parameter range, target total memory size parameter range, target memory usage size parameter range, target CPU average peak parameter range, target memory average peak parameter range, target iops average peak parameter range, target CPU oversold ratio parameter range, target business pod number parameter range, and target disk actual usage range. Thus, among the three benchmark portrait strategies of compute-intensive strategy, storage-intensive strategy, and storage-computation balance strategy, the corresponding multiple benchmark demand parameter ranges and the benchmark portrait strategies that match the target demand parameter ranges are screened out as the user portrait strategies that match the preset Pods.
[0074] In this way, the terminal device can obtain the node requirement parameters of the preset Pod in multiple dimensions, and filter out the user portrait strategy that matches the Pod based on the multi-dimensional node requirement parameters.
[0075] Step S20: reading node operation parameters corresponding to each of the plurality of preset initial nodes, and determining a target node from the plurality of initial nodes based on the plurality of node operation parameters and the user portrait strategy;
[0076] It should be noted that the node operating parameters are the original node operating parameters and custom node operating parameters generated by each node during its operation. The original node operating parameters include: CPU usage, total memory size, memory usage size, etc. The custom node operating parameters are the operating parameters obtained based on the original node operating parameters, specifically including: CPU average peak value, memory average peak value, iops average peak value, CPU overselling ratio, number of business pods, actual disk usage, etc.
[0077] In this embodiment, after determining the user portrait strategy corresponding to the preset database, the terminal device further reads the original node operating parameters and custom node operating parameters contained in each of the multiple preset initial nodes, and filters the multiple initial nodes based on the original node operating parameters, custom node operating parameters, and user portrait strategy, thereby filtering out the target node that matches the preset database from the multiple initial nodes.
[0078] For example, for example, Figure 7As shown, when the Scheduler-extender in the terminal device determines that the user portrait strategy corresponding to the preset Pod is a computing-intensive strategy, it further calls the above-mentioned prometheus tool to access the API interface to collect the original node operating parameters such as the CPU usage rate, total memory size, and memory usage size generated by each initial node during operation, and processes the operating parameters of each original node through the above-mentioned averagepeak-exporter tool and PrometheusRecording Rule tool to obtain the custom node operating parameters such as the average peak value of CPU, the average peak value of memory, the average peak value of iops, the oversold ratio of CPU, the number of business pods, and the actual disk usage rate generated by each initial node during operation. The Scheduler-extender then reads the parameter thresholds of each node contained in the computing-intensive strategy, and compares the CPU usage rate, total memory size, memory usage size, average peak value of CPU, average peak value of memory, average peak value of iops, oversold ratio of CPU, number of business pods, and actual disk usage with the corresponding node parameter thresholds, so as to screen multiple initial nodes based on multiple comparison results, thereby screening out the target node that matches the preset Pod from multiple nodes.
[0079] In this way, the terminal device can screen each initial node in multiple dimensions based on the user portrait strategy, thereby filtering out the target node that matches the preset Pod from each initial node.
[0080] In addition, in this embodiment and another embodiment, please refer to Figure 2 and Figure 4 ,in, Figure 2 This is a schematic diagram of a node screening process involved in an embodiment of a method for deploying a database of this application. Figure 4 This is a schematic diagram of the expander interaction process involved in an embodiment of the database deployment method of this application, such as Figure 2 and Figure 4As shown, the terminal device is also configured with a Scheduler extender as the default extender. Before the terminal device uses the Scheduler-extender to extend the scheduler to screen each initial node, it can also first allocate a node to the Pod node through the Scheduler default extender. Specifically, the Scheduler default extender first checks whether the available resources in the candidate node meet the resource requirements of the Pod through the PodFitsResources filter function, and selects the schedulable nodes after filtering. After that, the Scheduler default extender enters the scoring stage, thereby selecting the node with the highest score from all schedulable nodes, and deploying the preset Pod to the node with the highest score. It can be understood that in a Kubernetes cluster, a node that meets a Pod scheduling request is called a schedulable node, and if no node in the Kubernetes cluster can meet the scheduling requirements of the Pod, the Pod will remain in an unscheduled state until the Scheduler matches a suitable node for the Pod.
[0081] In a feasible implementation manner, the step of “determining a target node from a plurality of initial nodes based on a plurality of node operation parameters and the user portrait strategy” in the above step S20 may specifically include steps S201 to S204:
[0082] Step S201: reading multiple node parameter thresholds included in the user portrait strategy;
[0083] Step S202: obtaining node matching results corresponding to each of the plurality of initial nodes based on the plurality of node operation parameters and the plurality of node parameter thresholds;
[0084] Step S203: screening the plurality of initial nodes according to the node matching results to determine a plurality of nodes to be evaluated from the plurality of initial nodes;
[0085] Step S204: determining the target node evaluation scores corresponding to each of the plurality of nodes to be evaluated, and determining the target node among the plurality of nodes to be evaluated based on the plurality of target node evaluation scores.
[0086] In this embodiment, after obtaining the original node operating parameters and custom node operating parameters contained in each of the multiple preset initial nodes, the terminal device further reads the user portrait strategy to determine the multiple node parameter thresholds contained in the user portrait strategy. Thereafter, the terminal device compares the obtained original node operating parameters and custom node operating parameters with the corresponding node parameter thresholds respectively to determine the matching results corresponding to each of the multiple initial nodes according to the comparison results. Thereafter, the terminal device determines the initial node with a successful matching result as a node to be evaluated that can meet the scheduling requirements of the preset database. Finally, the terminal device evaluates the multiple nodes to be evaluated according to the user portrait strategy to obtain the target node evaluation scores corresponding to each of the multiple nodes to be evaluated, and based on the target node evaluation scores, determines the node to be evaluated with the highest target node evaluation score among the multiple nodes to be evaluated as the target node that best matches the preset database.
[0087] Exemplarily, for example, after obtaining the node operating parameters such as cpu usage, total memory size, memory usage size, cpu average peak value, memory average peak value, iops average peak value, cpu oversold ratio, number of business pods, and actual disk usage, the Scheduler-extender further reads the cpu usage threshold, total memory size threshold, memory usage size threshold, cpu average peak value threshold, memory average peak value threshold, iops average peak value threshold, cpu oversold ratio threshold, number of business pods threshold, and actual disk usage threshold contained in the computing-intensive strategy. Then, the Scheduler-extender extends the scheduler. The analyzer compares the CPU usage rates of the multiple initial nodes with the CPU usage threshold, and the total memory sizes of the multiple initial nodes with the total memory threshold. The memory usage sizes of the multiple initial nodes with the memory usage threshold. The CPU average peak values of the multiple initial nodes with the CPU average peak threshold. The memory average peak values of the multiple initial nodes with the memory average peak threshold. The iops average peak values of the multiple initial nodes with the iops average peak threshold. Yes, at the same time, the CPU overselling ratios corresponding to the multiple initial nodes are compared with the CPU overselling ratio threshold, and the business pod numbers corresponding to the multiple initial nodes are compared with the business pod number threshold. At the same time, the actual disk usage rates corresponding to the multiple initial nodes are compared with the actual disk usage threshold, and then multiple comparison results corresponding to the multiple initial nodes are obtained. The Scheduler-extender extended scheduler determines whether each initial node can meet the scheduling requirements of the Pod based on the multiple comparison results, and generates matching results corresponding to each initial node. After that, the Scheduler-extender extended scheduler determines the initial node with a successful matching result as the node to be evaluated that can meet the scheduling requirements of the Pod. Finally, the Scheduler-extender extended scheduler scores each node to be evaluated according to the computing intensive strategy, so as to obtain the target node score value corresponding to each node to be evaluated. The Scheduler-extender extended scheduler then sorts each node to be evaluated according to the target node score value, so as to determine the node to be evaluated with the highest score among the nodes to be evaluated as the target node matching the preset Pod. In this way, the terminal device can screen each initial node in multiple dimensions based on the user portrait strategy, thereby filtering out the target node that matches the preset Pod from each initial node.
[0088] In a feasible implementation manner, the above step S202 may specifically include steps S2021 to S2023:
[0089] Step S2021: determining node parameter thresholds corresponding to each of the plurality of node operating parameters, and comparing the plurality of node operating parameters with the corresponding node parameter thresholds to obtain a plurality of comparison results;
[0090] Step S2022: when the multiple comparison results corresponding to the initial node are all standard comparison results, determining that the node matching result corresponding to the initial node is a successful match, wherein the standard comparison result is that the node operation parameter reaches the node parameter threshold;
[0091] Step S2023: when there is an abnormal comparison result among the multiple comparison results corresponding to the initial node, determining that the node matching result corresponding to the initial node is a matching failure, wherein the abnormal comparison result is that the node operation parameter does not reach the node parameter threshold;
[0092] In this embodiment, after obtaining multiple node parameter thresholds, the terminal device first determines the node parameter thresholds corresponding to the original node operating parameters and the custom node operating parameters, and compares the original node operating parameters and the custom node operating parameters with the corresponding node parameter thresholds to obtain multiple comparison results. Thereafter, the terminal device reads the multiple comparison results corresponding to each of the multiple initial nodes, and when it is determined that the multiple comparison results corresponding to the initial node are all node operating parameters that reach the node parameter threshold, it is determined that the matching result corresponding to the initial node is a successful match, and when it is determined that there is an abnormal comparison result in which the node operating parameter does not reach the node parameter threshold among the multiple comparison results corresponding to the initial node, it is determined that the matching result corresponding to the initial node is a failed match.
[0093] For example, after obtaining the CPU usage threshold, total memory size threshold, memory usage threshold, CPU average peak threshold, memory average peak threshold, iops average peak threshold, CPU oversold ratio threshold, business pod number threshold, and disk actual usage threshold contained in the computing-intensive strategy, the Scheduler-extender further compares the CPU usage corresponding to each of the multiple initial nodes with the CPU usage threshold, and at the same time, compares the total memory size corresponding to each of the multiple initial nodes with the total memory size threshold. At the same time, the memory usage size corresponding to each of the multiple initial nodes is compared with the memory usage size threshold, the average CPU peak value corresponding to each of the multiple initial nodes is compared with the average CPU peak value threshold, the average memory peak value corresponding to each of the multiple initial nodes is compared with the average memory peak value threshold, the average iops peak value corresponding to each of the multiple initial nodes is compared with the average iops peak value threshold, the oversold CPU ratio corresponding to each of the multiple initial nodes is compared with the oversold CPU ratio threshold, and the number of business pods corresponding to each of the multiple initial nodes is compared with the number of business pods. At the same time, the actual disk usage corresponding to each of the multiple initial nodes is compared with the actual disk usage threshold, and then multiple comparison results corresponding to the multiple initial nodes are obtained. After that, the Scheduler-extender reads the multiple comparison results corresponding to the multiple initial nodes, and compares them when the multiple comparison results are: cpu usage reaches the cpu usage threshold, the total memory size reaches the total memory size threshold, the memory usage size reaches the memory usage size threshold, the cpu average peak reaches the cpu average peak threshold, the memory average peak reaches the memory average peak threshold, and the iops average peak reaches When the average iops peak threshold is reached, the cpu overselling ratio reaches the cpu overselling ratio threshold, the number of business pods reaches the business pod number threshold, and the actual disk usage reaches the actual disk usage threshold, it is determined that the initial node can meet the scheduling requirements of the preset Pod, and thus the matching result of the initial node is determined to be a successful match. When the Scheduler-extender determines that there are any one or more abnormal comparison results in which the node operating parameters do not reach the node parameter threshold among multiple comparison results, it is determined that the initial node cannot meet the scheduling requirements of the preset Pod, and thus the matching result of the initial node is determined to be a failed match.
[0094] In this way, the terminal device can evaluate each node to be evaluated in multiple dimensions based on the user portrait strategy, thereby determining the degree of match between each node and the preset Pod.
[0095] In a feasible implementation manner, the step of "determining the target node evaluation scores corresponding to each of the plurality of nodes to be evaluated" in the above step S204 may specifically include steps S2041 to S2043:
[0096] Step S2041: determining target operating parameters corresponding to the plurality of nodes to be evaluated from the plurality of node operating parameters;
[0097] Step S2042: determining the weight value corresponding to each of the target operating parameters according to the user portrait strategy, and determining the initial node score value corresponding to each of the plurality of nodes to be evaluated according to the user portrait strategy;
[0098] Step S2043: determining the target node evaluation scores corresponding to each of the plurality of nodes to be evaluated based on the initial node score values and the weight values.
[0099] In this embodiment, after screening out each node to be evaluated, the terminal device further determines the target node operating parameters corresponding to the node to be evaluated from multiple node operating parameters. After that, the terminal device reads the user portrait strategy to obtain the first weight value corresponding to the original node operating parameters and the second weight value corresponding to the custom node operating parameters contained in the user portrait strategy. The terminal device also reads the scoring mapping table contained in the user portrait strategy to determine the first initial scoring value corresponding to the target original node operating parameters contained in the target node operating parameters and the second initial scoring value corresponding to the target custom node operating parameters contained in the target node operating parameters. Finally, the terminal device obtains the target node evaluation score corresponding to the node to be evaluated based on the first initial scoring value, the second initial scoring value, the first weight value, and the second weight value.
[0100] For example, after screening out the node to be evaluated, the Scheduler-extender determines the target node operating parameters corresponding to the node to be evaluated from the node operating parameters such as CPU usage, total memory size, memory usage, CPU average peak value, memory average peak value, iops average peak value, CPU overselling ratio, number of business pods, and actual disk usage. At the same time, the Scheduler-extender reads the computing-intensive strategy to obtain the CPU usage, total memory size, memory usage, CPU average peak value, memory average peak value, iops average peak value, CPU overselling ratio, business pod number, and actual disk usage contained in the computing-intensive strategy. The Scheduler-extender extends the scheduler to read the score mapping table contained in the compute-intensive strategy, and then determines the initial node score values corresponding to the CPU usage, total memory size, memory usage, CPU average peak value, memory average peak value, iops average peak value, CPU overselling ratio, number of business pods, and actual disk usage in the node to be evaluated. Finally, the Scheduler-extender extends the scheduler to combine the obtained weight values with the initial node score values to obtain the target node evaluation score corresponding to the node to be evaluated.
[0101] It is understandable that technicians can set different weight values for node operating parameters such as CPU usage, total memory size, memory usage size, average CPU peak, average memory peak, average iops peak, CPU overselling ratio, number of business pods, actual disk usage, etc. included in the user portrait strategy. The present application does not limit the specific values of the weight values. In addition, the specific process of the Scheduler-extender extending the scheduler to obtain the target node score value of the node to be evaluated based on the weight value and the initial node score value is a prior art, so it will not be repeated here.
[0102] In this way, the terminal device can evaluate each node to be evaluated in multiple dimensions based on the user portrait strategy, thereby determining the degree of match between each node and the preset Pod.
[0103] Step S30: deploying the preset database to the target node, so that the preset database runs on the target node;
[0104] In this embodiment, after determining the target node, the terminal device binds the preset database and the target node, thereby deploying the preset database on the target node, so that the preset database runs on the target node.
[0105] For example, for example, Figure 7As shown in the figure, after screening out the target node, the Scheduler-extender binds the preset Pod and the target node, so that the preset Pod runs on the target node, thereby meeting the scheduling requirements of the Pod.
[0106] In this embodiment, when the terminal device is running, it first calls its own configured adapter to access the preset database, thereby obtaining multiple node requirement parameters corresponding to the preset database, including original node requirement parameters and custom node requirement parameters. The terminal device then determines a user portrait strategy that matches the preset database based on the multiple node requirement parameters. After that, the terminal device further reads the original node operating parameters and custom node operating parameters contained in each of the multiple preset initial nodes, and screens the multiple initial nodes based on the original node operating parameters, custom node operating parameters, and user portrait strategy, thereby screening out a target node that matches the preset database from the multiple initial nodes. Finally, the terminal device binds the preset database and the target node, thereby deploying the preset database on the target node so that the preset database runs on the target node.
[0107] In this way, the present application solves the technical problem in the related technology that the Kubernetes scheduler lacks judgment on resources of other dimensions during the process of node screening, and is unable to screen out nodes that match the Pod through actual operation conditions and custom configurations, and thus is unable to accurately match Pods with different resource demand focuses and affects resource utilization. That is, the present application screens out user portrait strategies that match the preset database based on multi-dimensional node demand parameters, and then screens multiple initial nodes according to the user portrait strategy to obtain target nodes that match the preset database, thereby achieving the technical effect of enabling terminal devices to screen out nodes that better match the database, thereby ensuring the operating efficiency of the database.
[0108] Based on the first embodiment of the present application, a second embodiment of the present application is proposed. In the second embodiment of the present application, the same or similar contents as those of the first embodiment can be referred to the above description and will not be described in detail later. On this basis, after the above step S2042, the deployment method of the database of the present application can also include steps A10 to A20:
[0109] Step A10: determining the scheduling quantities corresponding to each of the plurality of nodes to be evaluated, and updating the initial node scoring values corresponding to each of the plurality of nodes to be evaluated based on each of the scheduling quantities to obtain an intermediate node scoring value;
[0110] Step A20: Determine the target node evaluation scores corresponding to each of the plurality of nodes to be evaluated based on the score values of each intermediate node and each weight value.
[0111] In this embodiment, after obtaining the initial node scoring value corresponding to each node to be evaluated, the terminal device may also first obtain a preset time length, and determine the scheduling quantity corresponding to each node to be evaluated within the preset time length based on the preset time length. The terminal device then updates the initial node scoring value according to each scheduling quantity to obtain an intermediate node scoring value. Finally, the terminal device combines the intermediate node scoring value with each weight value to obtain the target node evaluation score corresponding to the node to be evaluated.
[0112] For example, see Figure 6 , Figure 6 This is a schematic diagram of a node optimization process involved in an embodiment of a method for deploying a database of this application, such as Figure 6 As shown, after screening out each node to be evaluated, the Scheduler-extender extended scheduler further determines that the preset duration is 1 hour, and detects each node to be evaluated according to the preset duration, so as to obtain the pod scheduling quantity of each node to be evaluated within 1 hour. The Scheduler-extender extended scheduler queries a preset score mapping table including multiple benchmark scheduling quantities and benchmark score values corresponding to each of the multiple benchmark scheduling quantities according to each pod scheduling quantity. The Scheduler-extender extended scheduler determines the benchmark score value corresponding to each pod scheduling quantity according to the score mapping table. The Scheduler-extender extended scheduler updates the initial node score of each node to be evaluated according to each benchmark score value to obtain the intermediate node score value corresponding to each node to be evaluated. After that, the Scheduler-extender extended scheduler combines the intermediate node score value with the above-mentioned weight values to obtain the target node evaluation score corresponding to each node to be evaluated.
[0113] In this way, the terminal device can further screen each node to avoid excessive scheduling of a certain node, which may lead to performance bottlenecks in the node.
[0114] This application also provides a deployment system, please refer to Fig. 9 , the system comprising:
[0115] A strategy screening module 10 is used to obtain node requirement parameters of a preset database, and determine a user profile strategy corresponding to the preset database according to the node requirement parameters;
[0116] The node screening module 20 is used to read the node operation parameters corresponding to each of the plurality of preset initial nodes, and determine the target node among the plurality of the initial nodes based on the plurality of the node operation parameters and the user portrait strategy;
[0117] The application deployment module 30 is used to deploy the preset database to the target node so that the preset database runs on the target node.
[0118] Furthermore, the policy screening module 10 is also used for:
[0119] Determine a plurality of baseline demand parameter ranges, and baseline profiling strategies corresponding to the plurality of baseline demand parameter ranges;
[0120] Determining a target demand parameter range from a plurality of reference demand parameter ranges according to the node demand parameter, wherein the target demand parameter range is a reference demand parameter range including the node demand parameter;
[0121] The benchmark portrait strategy corresponding to the target demand parameter range is determined as the user portrait strategy corresponding to the preset database.
[0122] Furthermore, the node screening module 20 is also used for:
[0123] Read multiple node parameter thresholds included in the user portrait strategy;
[0124] Obtaining node matching results corresponding to each of the plurality of initial nodes based on the plurality of node operation parameters and the plurality of node parameter thresholds;
[0125] Screening the plurality of initial nodes according to the node matching results to determine a plurality of nodes to be evaluated from the plurality of initial nodes;
[0126] Determine the target node evaluation scores corresponding to each of the plurality of nodes to be evaluated, and determine the target node among the plurality of nodes to be evaluated based on the plurality of target node evaluation scores.
[0127] Furthermore, the node screening module 20 is also used for:
[0128] Determine node parameter thresholds corresponding to each of the plurality of node operating parameters, and compare the plurality of node operating parameters with the corresponding node parameter thresholds to obtain a plurality of comparison results;
[0129] When the multiple comparison results corresponding to the initial node are all standard comparison results, determining that the node matching result corresponding to the initial node is a successful match, wherein the standard comparison result is that the node operation parameter reaches the node parameter threshold;
[0130] When there is an abnormal comparison result among the multiple comparison results corresponding to the initial node, it is determined that the node matching result corresponding to the initial node is a matching failure, wherein the abnormal comparison result is that the node operation parameter does not reach the node parameter threshold.
[0131] Furthermore, the node screening module 20 is also used for:
[0132] Determining target operating parameters corresponding to each of the plurality of nodes to be evaluated from the plurality of node operating parameters;
[0133] Determine the weight value corresponding to each of the target operating parameters according to the user portrait strategy, and determine the initial node score value corresponding to each of the plurality of nodes to be evaluated according to the user portrait strategy;
[0134] The target node evaluation scores corresponding to each of the plurality of nodes to be evaluated are determined based on the initial node score values and the weight values.
[0135] Furthermore, the node screening module 20 is also used for:
[0136] Determine the scheduling quantities corresponding to each of the plurality of nodes to be evaluated, and based on each of the scheduling quantities, update the initial node score values corresponding to each of the plurality of nodes to be evaluated to obtain an intermediate node score value;
[0137] The target node evaluation scores corresponding to each of the plurality of nodes to be evaluated are determined based on the score values of each of the intermediate nodes and each of the weight values.
[0138] The deployment system provided by the present application adopts the database deployment method in the above embodiment, which can solve the technical problems that the Kubernetes scheduler in the process of screening nodes in the related technology lacks judgment on other dimensional resources, and cannot screen out nodes that match Pods through actual operation conditions and custom configurations, and thus cannot accurately match Pods with different resource demand focuses and affect resource utilization. Compared with the prior art, the beneficial effects of the deployment system provided by the present application are the same as the beneficial effects of the database deployment method provided in the above embodiment, and other technical features in the deployment system are the same as the features disclosed in the above embodiment method, which will not be repeated here.
[0139] The present application provides a terminal device, which includes: at least one processor; and a memory that is communicatively connected to the at least one processor; wherein the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the database deployment method in the above-mentioned embodiment one.
[0140] Reference below Figure 8, which shows a schematic diagram of the structure of a terminal device suitable for implementing the embodiment of the present application. The terminal device in the embodiment of the present application may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Descriptions), PMPs (Portable Media Players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 8 The terminal device shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0141] like Figure 8 As shown, the terminal device may include a processing device 1001 (e.g., a central processing unit, a graphics processor, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM: Read Only Memory) 1002 or a program loaded from a storage device 1003 to a random access memory (RAM: Random Access Memory) 1004. In RAM1004, various programs and data required for the operation of the terminal device are also stored. The processing device 1001, ROM1002, and RAM1004 are connected to each other through a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Generally, the following systems can be connected to the I / O interface 1006: an input device 1007 including, for example, a touch screen, a touch pad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; an output device 1008 including, for example, a liquid crystal display (LCD: Liquid Crystal Display), a speaker, a vibrator, etc.; a storage device 1003 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1009. The communication device 1009 can allow the terminal device to communicate with other devices wirelessly or by wire to exchange data. Although the figure shows a terminal device with various systems, it should be understood that it is not required to implement or have all the systems shown. More or fewer systems can be implemented or provided instead.
[0142] In particular, according to the embodiments disclosed in the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device 1003, or installed from a ROM 1002. When the computer program is executed by the processing device 1001, the above-mentioned functions defined in the method of the embodiment disclosed in the present application are executed.
[0143] The terminal device provided by the present application adopts the database deployment method in the above embodiment, which can solve the problem that the Kubernetes scheduler in the related technology lacks judgment on other dimensional resources in the process of node screening, and cannot screen out nodes matching Pods through actual operation conditions and custom configurations, and thus cannot accurately match Pods with different resource demand focuses and affect resource utilization. Compared with the prior art, the beneficial effects of the terminal device provided by the present application are the same as the beneficial effects of the database deployment method provided in the above embodiment, and the other technical features in the terminal device are the same as the features disclosed in the method of the previous embodiment, which will not be repeated here.
[0144] It should be understood that the various parts disclosed in this application can be implemented by hardware, software, firmware or a combination thereof. In the description of the above embodiments, specific features, structures, materials or characteristics can be combined in any one or more embodiments or examples in a suitable manner.
[0145] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
[0146] The present application provides a computer-readable storage medium having computer-readable program instructions (ie, computer programs) stored thereon, and the computer-readable program instructions are used to execute the database deployment method in the above-mentioned embodiment.
[0147] The computer-readable storage medium provided in the present application may be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, systems or devices, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, system or device. The program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination of the above.
[0148] The computer-readable storage medium may be included in the terminal device; or may exist independently without being installed in the terminal device.
[0149] The above-mentioned computer-readable storage medium carries one or more programs. When the above-mentioned one or more programs are executed by the terminal device, the terminal device: obtains the node requirement parameters of the preset database, and determines the user portrait strategy corresponding to the preset database according to the node requirement parameters; reads the node operation parameters corresponding to each of the multiple preset initial nodes, and determines the target node among the multiple initial nodes based on the multiple node operation parameters and the user portrait strategy; deploys the preset database to the target node so that the preset database runs on the target node.
[0150] Computer program code for performing the operations of the present application may be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0151] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a sequence different from that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flow chart, and the combination of the boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0152] The modules involved in the embodiments described in this application may be implemented by software or hardware, wherein the name of the module does not constitute a limitation on the unit itself in some cases.
[0153] The readable storage medium provided by the present application is a computer-readable storage medium, which stores computer-readable program instructions (i.e., computer programs) for executing the above-mentioned database deployment method, and can solve the problem that the Kubernetes scheduler in the related technology is missing judgment on other dimensional resources during the node screening process, and cannot screen out nodes that match the Pod through actual operation conditions and custom configurations, and thus cannot accurately match Pods with different resource demand focuses and affect resource utilization. Technical problems. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided by the present application are the same as the beneficial effects of the database deployment method provided by the above-mentioned embodiment, which will not be repeated here.
[0154] The present application also provides a computer program product, including a computer program, which implements the steps of the above-mentioned database deployment method when executed by a processor.
[0155] The computer program product provided by this application can solve the technical problems that the Kubernetes scheduler in the related technology lacks judgment on other dimensional resources during the node screening process, and cannot screen out nodes that match Pods through actual operation conditions and custom configurations, and thus cannot accurately match Pods with different resource demand focuses and affect resource utilization. Compared with the prior art, the beneficial effects of the computer program product provided by this application are the same as the beneficial effects of the database deployment method provided in the above embodiment, which will not be repeated here.
[0156] The above descriptions are only some embodiments of the present application, and are not intended to limit the patent scope of the present application. All equivalent structural changes made using the contents of the present application specification and drawings under the technical concept of the present application, or direct / indirect applications in other related technical fields are included in the patent protection scope of the present application.
Claims
1. A database deployment method, characterized in that: The method comprises: Obtaining node requirement parameters of a preset database, and determining a user profiling strategy corresponding to the preset database according to the node requirement parameters; Reading node operation parameters corresponding to each of a plurality of preset initial nodes, and determining a target node among the plurality of initial nodes based on the plurality of node operation parameters and the user portrait strategy; The preset database is deployed to the target node, so that the preset database runs on the target node.
2. The method according to claim 1, characterized in that The step of determining the user portrait strategy corresponding to the preset database according to the node requirement parameter includes: Determine a plurality of baseline demand parameter ranges, and baseline profiling strategies corresponding to the plurality of baseline demand parameter ranges; Determining a target demand parameter range from a plurality of reference demand parameter ranges according to the node demand parameter, wherein the target demand parameter range is a reference demand parameter range including the node demand parameter; The benchmark portrait strategy corresponding to the target demand parameter range is determined as the user portrait strategy corresponding to the preset database.
3. The method according to claim 1, characterized in that The step of determining a target node from a plurality of initial nodes based on the plurality of node operation parameters and the user portrait strategy comprises: Read multiple node parameter thresholds included in the user portrait strategy; Obtaining node matching results corresponding to each of the plurality of initial nodes based on the plurality of node operation parameters and the plurality of node parameter thresholds; Screening the plurality of initial nodes according to the node matching results to determine a plurality of nodes to be evaluated from the plurality of initial nodes; Determine the target node evaluation scores corresponding to each of the plurality of nodes to be evaluated, and determine the target node among the plurality of nodes to be evaluated based on the plurality of target node evaluation scores.
4. The method according to claim 3, characterized in that The step of obtaining node matching results corresponding to each of the plurality of initial nodes based on the plurality of node operation parameters and the plurality of node parameter thresholds comprises: Determine node parameter thresholds corresponding to each of the plurality of node operating parameters, and compare the plurality of node operating parameters with the corresponding node parameter thresholds to obtain a plurality of comparison results; When the multiple comparison results corresponding to the initial node are all standard comparison results, determining that the node matching result corresponding to the initial node is a successful match, wherein the standard comparison result is that the node operation parameter reaches the node parameter threshold; When there is an abnormal comparison result among the multiple comparison results corresponding to the initial node, it is determined that the node matching result corresponding to the initial node is a matching failure, wherein the abnormal comparison result is that the node operation parameter does not reach the node parameter threshold.
5. The method according to claim 3, characterized in that The step of determining the target node evaluation scores corresponding to each of the plurality of nodes to be evaluated comprises: Determining target operating parameters corresponding to each of the plurality of nodes to be evaluated from the plurality of node operating parameters; Determine the weight value corresponding to each of the target operating parameters according to the user portrait strategy, and determine the initial node score value corresponding to each of the plurality of nodes to be evaluated according to the user portrait strategy; The target node evaluation scores corresponding to each of the plurality of nodes to be evaluated are determined based on the initial node score values and the weight values.
6. The method according to claim 5, characterized in that After the step of determining the initial node score values corresponding to each of the plurality of nodes to be evaluated according to the user portrait strategy, the method includes: Determine the scheduling quantities corresponding to each of the plurality of nodes to be evaluated, and based on each of the scheduling quantities, update the initial node score values corresponding to each of the plurality of nodes to be evaluated to obtain an intermediate node score value; The target node evaluation scores corresponding to each of the plurality of nodes to be evaluated are determined based on the score values of each of the intermediate nodes and each of the weight values.
7. A deployment system, characterized in that: The system comprises: A strategy screening module, used to obtain node requirement parameters of a preset database, and determine a user profiling strategy corresponding to the preset database according to the node requirement parameters; A node screening module, used to read node operation parameters corresponding to each of a plurality of preset initial nodes, and determine a target node from the plurality of initial nodes based on the plurality of node operation parameters and the user portrait strategy; The application deployment module is used to deploy the preset database to the target node so that the preset database runs on the target node.
8. A terminal device, characterized in that: The device comprises: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the database deployment method according to any one of claims 1 to 6.
9. A storage medium, characterized in that: The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the database deployment method according to any one of claims 1 to 6 are implemented.
10. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed by a processor, the steps of the database deployment method according to any one of claims 1 to 6 are implemented.
Citation Information
Cited By
Scheduling method, electronic device, medium and computer program product
CN122614526A
