Database hybrid deployment method and device

By providing a hybrid database deployment method in a cloud environment, and choosing to deploy database services on multi-chip type servers according to the user's chip architecture, it solves the problem of waste of resources and dissatisfaction with deployment requirements, and achieves rapid and efficient database deployment.

CN119556946APending Publication Date: 2025-03-04CHINA UNIONPAY
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411710914.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-26
Publication Date
2025-03-04

AI Technical Summary

Technical Problem

Servers of different chip types in the current cloud environment are usually independently deployed due to different instruction sets, different computing capabilities, and different types of software supported, resulting in waste of resources and the inability to quickly meet database deployment requirements.

Method used

Provide a hybrid database deployment method. By obtaining the user's chip architecture selection, selecting servers and software images that support the corresponding chip type in the server cluster of the database platform, thereby realizing the deployment of database services in the scenario where multi-chip type servers are used simultaneously.

Benefits of technology

It realizes that in a multi-chip server environment, selecting the chip architecture to deploy database services according to user needs, quickly meeting database deployment needs and avoiding resource waste.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119556946A_ABST
    Figure CN119556946A_ABST
Patent Text Reader

Abstract

The invention discloses a database hybrid deployment method and device.The method comprises the steps that a first request is obtained and used for requesting to apply for creating a first database service on a database platform, and the database platform comprises at least one server cluster and a software mirror image supporting multiple chip types; each server cluster comprises servers supporting at least one chip type; in a database software deployment process, aiming at each database node, according to a chip architecture selected by a user for the first database service, and screening a server supporting the chip type corresponding to the database node in a database cluster, screening a software mirror image supporting the chip type corresponding to the database node from a database platform, and deploying the database node on the first server according to the first software mirror image. Therefore, under the scene that multiple chip type servers are used at the same time, database services are deployed according to the chip architecture selected by a user by himself / herself, and the service requirements are met quickly.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of cloud platforms, and in particular to a database hybrid deployment method and device. Background Art

[0002] There are many different instruction set chips on the current server market, such as Intel, Zhaoxin, and Hygon chips based on the x86 architecture; Feiteng and Kunpeng chips based on the ARM architecture; Loongson chips based on the MIPS architecture, and Shenwei chips based on the Alpha architecture. Traditional cloud environments, container cloud environments, and database cloud environments are currently facing the scenario of using multiple core servers at the same time. Servers containing INTEL chips have been widely deployed in production, and servers containing other types of chips such as Hygon chips or Kunpeng chips are also gradually increasing.

[0003] However, currently, servers with different chip types are generally deployed independently due to different instruction sets, computing capabilities, and supported software types. That is, only servers with one chip type are deployed in the same cluster, and different nodes included in the same database service can only run on servers with the same chip type. For logical clusters, currently only servers with one chip type are deployed in a cluster. When the resources of the server with this chip type are insufficient, even if the resources of servers with other chip types are sufficient, they cannot be mixed, resulting in a waste of resources. The creation of new clusters with other chip types requires additional supporting resources. For example, a database cluster requires a supporting proxy cluster and corresponding network resources. In this case, it is often impossible to quickly meet database deployment requirements. Summary of the invention

[0004] The embodiments of the present invention provide a database hybrid deployment method and device, which are used to quickly meet database deployment requirements in a scenario where multiple chip type servers are used simultaneously.

[0005] In a first aspect, an embodiment of the present invention provides a database hybrid deployment method, comprising: obtaining a first request, the first request being used to request the creation of a first database service on a database platform, the first database service comprising at least one database node; the database platform comprising at least one server cluster and a software image supporting multiple chip types, each server cluster comprising a server supporting at least two chip types; for each database node in the first data block service, executing: according to the chip architecture selected by a user for the first database service, selecting a first server supporting the chip type corresponding to the database node in at least one server cluster of the database platform, and selecting a first software image supporting the chip type corresponding to the database node from the database platform; and deploying the database node on the first server according to the first software image.

[0006] In the above technical solution, during the database software deployment process, based on the chip architecture selected by the user for the first database service, servers supporting the chip type corresponding to the database node and software images supporting the chip type corresponding to the database node are screened in the database cluster. In this way, in a scenario where multiple chip type servers are used at the same time, the database service can be deployed based on the chip architecture selected by the user, thereby quickly meeting the database deployment needs.

[0007] Optionally, the chip architecture is a single chip architecture that supports a first chip type; the step of selecting, according to the chip architecture selected by the user for the first database service, a first server that supports a chip type corresponding to the database node in at least one server cluster of the database platform, and selecting a first software image that supports a chip type corresponding to the database node from the database platform includes:

[0008] According to the single chip architecture supporting the first chip type selected by the user for the first database service, selecting a first server supporting the first chip type in at least one server cluster of the database platform, and selecting a first software image supporting the first chip type from the database platform;

[0009] The step of deploying the database node on the first server according to the first software image includes:

[0010] The database node is deployed on a selected first server supporting the first chip type according to the selected first software image supporting the first chip type.

[0011] Optionally, the chip architecture is a hybrid chip architecture; and selecting, according to the chip architecture selected by the user for the first database service, a first server supporting a chip type corresponding to the database node in at least one server cluster of the database platform includes:

[0012] Determining a chip type corresponding to the database node according to the hybrid chip architecture selected by the user for the first database service;

[0013] Determine the chip package size corresponding to the database node according to the performance benchmark package selected by the user for the first database service, the chip type corresponding to the database node, and the performance evaluation score of the chip type corresponding to the database node;

[0014] According to the chip package size corresponding to the database node and the chip type corresponding to the database node, a first server supporting the chip type corresponding to the database node is selected from at least one server cluster of the database platform.

[0015] Optionally, the hybrid chip architecture includes a hybrid deployment mode and a chip type specified by a user for each database node; and determining the chip type corresponding to the database node according to the hybrid chip architecture selected by the user for the first database service includes:

[0016] According to the hybrid chip architecture selected by the user for the first database service, a chip type specified by the user for the database node is determined.

[0017] Optionally, the hybrid chip architecture includes a hybrid deployment mode and multiple chip types selected by a user for the first database service; determining the chip type corresponding to the database node based on the hybrid chip architecture selected by the user for the first database service includes: calculating the number of nodes deployed for each of the multiple chip types based on the number of chip types corresponding to the multiple chip types selected by the user for the first database service and the number of nodes included in the first database service; determining the chip type corresponding to the database node based on the number of nodes deployed for each of the multiple chip types.

[0018] Optionally, the hybrid chip architecture includes a hybrid deployment mode; determining the chip type corresponding to the database node based on the hybrid chip architecture selected by the user for the first database service includes: calculating the number of nodes deployed for each chip type supported by the server in the database platform according to the number of chip types supported by the server in the database platform and the number of nodes included in the first database service; determining the chip type corresponding to the database node according to the number of nodes deployed for each chip type supported by the server in the database platform.

[0019] Optionally, the method further includes:

[0020] For each chip type supported by the server in the database platform, execute:

[0021] Obtaining a performance evaluation matrix corresponding to the chip type, the performance evaluation matrix comprising performance test data obtained by testing at least one preset performance indicator of the chip of the chip type, a weight corresponding to the at least one preset performance indicator, and an indicator benchmark value corresponding to the at least one preset performance indicator;

[0022] For each test data corresponding to a preset performance indicator in the performance evaluation matrix, the test data corresponding to the preset performance indicator is normalized according to the indicator reference value and the correction coefficient corresponding to the preset performance indicator to obtain normalized test data;

[0023] The performance evaluation score of the chip type is calculated according to the weight corresponding to each preset performance indicator in the performance evaluation matrix and the normalized test data corresponding to each preset performance indicator.

[0024] Optionally, the method further includes:

[0025] When a new operation or storage operation is performed on an operation object on the database platform, a supported chip type label is added to the operation object according to the chip type selected by the user; the operation object includes any of the following: a cluster, a server, and a software image; or,

[0026] When a label update operation is performed on an operation object on a database platform, a supported chip type label is updated for the operation object according to the chip type updated by the user.

[0027] In a second aspect, an embodiment of the present invention provides a database hybrid deployment device, including:

[0028] A receiving module, configured to obtain a first request, wherein the first request is used to apply for creating a first database service on a database platform, and the first database service includes at least one database node;

[0029] The processing module is used to execute, for each database node in the first database service: selecting, according to the chip architecture selected by a user for the first database service, a first server that supports the chip type corresponding to the database node in at least one server cluster of the database platform, and selecting, from the database platform, a first software image that supports the chip type corresponding to the database node; and deploying the database node on the first server according to the first software image.

[0030] In a third aspect, an embodiment of the present invention further provides a computer device, including:

[0031] A memory for storing program instructions;

[0032] The processor is used to call the program instructions stored in the memory and execute the above-mentioned database hybrid deployment method according to the obtained program.

[0033] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the above-mentioned database hybrid deployment method. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0035] Figure 1 A schematic diagram of a system architecture provided by an embodiment of the present invention;

[0036] Figure 2 A schematic diagram of a flow chart of a database hybrid deployment method provided by an embodiment of the present invention;

[0037] Figure 3 A schematic diagram of the structure of a deployment device provided by an embodiment of the present invention;

[0038] Figure 4 A schematic diagram of a chip type label and a performance evaluation score setting process provided by an embodiment of the present invention;

[0039] Figure 5 A schematic diagram of the interface of the cluster label provided by an embodiment of the present invention;

[0040] Figure 6 A schematic diagram of the interface of a server tag provided in an embodiment of the present invention;

[0041] Figure 7 A schematic diagram of the interface of a software image label provided by an embodiment of the present invention;

[0042] Figure 8 A schematic diagram of a process for calculating a performance evaluation score provided by an embodiment of the present invention;

[0043] Fig. 9 A schematic diagram of a flow chart of a database hybrid deployment method provided by an embodiment of the present invention;

[0044] Fig.10 A schematic diagram of an interface for applying for a database creation service provided in an embodiment of the present invention;

[0045] Fig.11 A schematic diagram of the architecture of heterogeneous chip colocation within a cluster provided by an embodiment of the present invention;

[0046] Fig.12 A schematic diagram of a flow chart of a database hybrid deployment method provided by an embodiment of the present invention;

[0047] Fig.13 A schematic diagram of the architecture of a database node with heterogeneous chips provided in an embodiment of the present invention;

[0048] Fig.14 A schematic diagram of the structure of a database hybrid deployment device provided by an embodiment of the present invention;

[0049] Fig.15 A schematic diagram of the structure of a computer device provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0050] In order to make the purpose, technical scheme and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0051] refer to Figure 1 , which is a system architecture diagram applicable to an embodiment of the present application. The system architecture at least includes a deployment device 101 and a database platform 102. The deployment device 101 and the database platform 102 can be directly or indirectly connected via wired or wireless communication, and the present application does not make any limitation thereto.

[0052] The deployment device 101 may be a terminal device, a server, or a device in a database platform, wherein the terminal device may be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart home appliance, an intelligent voice interaction device, an intelligent vehicle-mounted device, etc., but is not limited thereto. The server may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms.

[0053] The database cloud platform 102 is a new type of cloud computing service that provides high-performance, high-reliability, high-security, and scalable database hosting services. The database cloud platform 102 can provide a variety of database services, such as relational database Mysql, non-relational databases Redis, MongoDB, etc., distributed databases Tidb, Oceanbase, Updrdb, etc.; the database cloud platform 102 can also provide a full set of database operation and maintenance solutions such as backup and recovery, monitoring, rapid expansion, and data transmission.

[0054] In this application, the database cloud platform 102 adopts a database cloud platform based on container technology, which uses k8s or swarm for container management to complete database container deployment and management. Each database instance in the platform is an independent container deployed on the host machine, and the container is configured with a dedicated IP address, a central processing unit (CPU) and memory, as well as a table space and a log space. The table space stores data, and the log space stores database logs.

[0055] The database service in the embodiments of the present application refers to all systems that can store data, including relational databases, in-memory databases, non-relational databases, message middleware, etc.

[0056] The database cloud platform 102 includes multiple server clusters, and any server cluster may include servers of the same chip type or servers of different chip types. This application does not specifically limit the number of server clusters included in the database cloud platform 102 and the number of servers included in each server cluster.

[0057] When deploying database services, in order to prevent failures such as downtime or unexpected interruptions, a multi-node architecture is usually built, such as master-slave, master-slave, MHA (Master HA) cluster, and MGR (MySQL Group Replication) cluster. High-availability architectures are used to restore database availability as quickly as possible through other nodes when a single node fails, minimizing downtime and ensuring that business is not interrupted due to database failures.

[0058] In the embodiment of the present application, in the physical cabinet deployment, the original correspondence between the logical cluster and the cabinet is broken, that is, different clusters and different types of servers can be mixed in the same physical cabinet, which helps to improve the average cabinet usage U number index. For example, a server with chip type 1 is currently deployed in the cabinet. If this chip type 1 server is no longer used in future procurement or planning, the cabinet that is not fully equipped can be configured with servers of other chip types, which can avoid idle U positions in the cabinet and improve the U number index.

[0059] It should be noted that the above Figure 1 The structure shown is only an example and is not limited to this embodiment of the present invention.

[0060] Based on the above description, Figure 2 The following is a schematic diagram showing a flow chart of a database hybrid deployment method provided by an embodiment of the present application. The flow chart can be executed by a deployment device, which can be Figure 1 The deployment device 101 is shown.

[0061] like Figure 2 As shown in the figure, the process specifically includes:

[0062] Step 210, obtaining a first request, the first request is used to request to apply for the creation of a first database service on a database platform, the first database service includes at least one database node; the database platform includes at least one server cluster and a software image that supports multiple chip types, each server cluster includes a server that supports at least two chip types.

[0063] In the embodiment of the present application, the first database service may be any database service applied for and created on the database platform. For any database service, it may include one database node or multiple database nodes.

[0064] Step 220: for each database node in the first database service, execute the following steps 220-1 to 220-2 respectively:

[0065] Step 220-1, based on the chip architecture selected by the user for the first database service, select a first server that supports the chip type corresponding to the database node in at least one server cluster of the database platform, and select a first software image that supports the chip type corresponding to the database node from the database platform.

[0066] Step 220 - 2 , deploying a database node on the first server according to the first software image.

[0067] Specifically, a container is deployed on the first server according to the first software image, thereby completing the deployment of the database node.

[0068] In the embodiment of the present application, each server cluster supports servers of at least two chip types, which can solve the problem of insufficient resources of a single type of server and inability to expand capacity, thereby quickly meeting business deployment needs. In addition, during the database software deployment process, according to the chip architecture selected by the user for the first database service, the server supporting the chip type corresponding to the database node and the software image supporting the chip type corresponding to the database node are screened in the database cluster, so that in the scenario where multiple chip type servers are used at the same time, the database service can be deployed according to the chip architecture selected by the user.

[0069] Optionally, in the above step 220-1, the chip architecture selected by the user for the first database service may be a single chip architecture or a hybrid chip architecture. The specific implementation process of the above step 220 is described below based on these two chip architectures.

[0070] In the first implementation mode, when the chip architecture selected by the user for the first database service is a single-chip architecture, the chip types corresponding to all database nodes included in the first database service are the same, for example, the chip type selected by the user for the first database service is the first chip type. The deployment device performs step S11 and step S12 for each database node included in the first database service:

[0071] Step S11, according to the first chip type selected by the user for the first database service, screening a first server supporting the first chip type from the database platform for the database node, and screening a first software image supporting the first chip type from the database platform;

[0072] Step S12: deploying the database node on the screened first server supporting the first chip type according to the screened first software image supporting the first chip type.

[0073] For example, taking the first database service including two database nodes, namely database node 1 and database node 2, and the first chip type being Kunpeng chip as an example, the specific implementation process of the above step 220 includes: for database node 1, screening out a server cluster that supports Kunpeng chip from at least one server cluster of the database platform, and then screening out a server that supports Kunpeng chip from the server cluster that supports Kunpeng chip. If multiple servers that support Kunpeng chip are screened out, then a server can be randomly selected from the multiple servers that support Kunpeng chip, such as server 1, as the server for deploying database node 1; and, screening out software image 1 that supports Kunpeng chip from the database platform; and then creating database node 1 on server 1 according to software image 1. Afterwards, for database node 2, a server cluster supporting Kunpeng chips is screened out from at least one server cluster of the database platform, and then a server supporting Kunpeng chips is screened out from the server cluster supporting Kunpeng chips. If multiple servers supporting Kunpeng chips are screened out, then a server, such as server 2, can be randomly selected from the multiple servers supporting Kunpeng chips as the server for deploying database node 2; and software image 2 supporting Kunpeng chips is screened out from the database platform; and then database node 2 is created on server 2 according to software image 2. Thus, the creation process of the first database service including database node 1 and database node 2 is completed.

[0074] It should be noted that database node 1 and database node 2 can be deployed on the same server or on different servers. If database node 1 and database node 2 are deployed on two different servers, the two servers can be in the same cluster or in different clusters. From the perspective of high availability, different nodes of the same database service are generally deployed on different servers or in different clusters to avoid single point failures that affect the use of database services.

[0075] In this embodiment, during the database software deployment process, according to the single-chip architecture selected by the user, the server matching the chip type selected by the user is screened in the database cluster and the software image matching the chip type selected by the user is deployed, thereby realizing the deployment of database services by selecting the chip type according to the user's needs. In addition, in the multi-core server usage scenario, the database service is deployed according to the single-chip architecture selected by the user, that is, the various database nodes included in the database service are deployed on servers that support the same chip type, thereby ensuring that the performance of different database nodes is equal and the computing power of each database node is consistent.

[0076] Implementation method two, when the chip architecture selected by the user for the first database service is a hybrid chip architecture, there are at least two database nodes among all the database nodes included in the first database service that correspond to different chip types. For example, the first database service includes database node 1, database node 2, and database node 3, wherein database node 1 corresponds to the Haiguang chip type, database node 2 corresponds to the Kunpeng chip type, and database node 3 corresponds to the Intel chip type; for another example, the first database service includes database node 1, database node 2, and database node 3, wherein database node 1 corresponds to the Haiguang chip type, database node 2 corresponds to the Haiguang chip type, and database node 3 corresponds to the Kunpeng chip type. Based on this situation, the above step 220-1 can be implemented in the following way: the deployment device determines the chip type corresponding to each database node according to the hybrid chip architecture selected by the user for the first database service, and then selects a first server that supports the chip type corresponding to the database node in at least one server cluster of the database platform, and selects a first software image that supports the chip type corresponding to the database node from the database platform. Several possible implementation methods are provided below:

[0077] In a first possible implementation, the hybrid chip architecture includes a hybrid deployment mode and a user specifies a corresponding chip type for each database node in the first database service, that is, the user not only selects a hybrid deployment mode for the first database service, but also specifies a corresponding chip type for each database node included in the first database service. The deployment device obtains the chip type selected by the user for each database node, and executes step S21 and step S22 for each database node included in the first database service:

[0078] Step S21, according to the chip type selected by the user for a database node, screening a first server supporting the chip type selected by the user for the database node from the database platform, and screening a first software image supporting the chip type selected by the user for the database node from the database platform;

[0079] Step S22 , deploying the database node on a first server that supports the chip type selected by the user for the database node according to the first software image of the chip type selected by the user for the database node.

[0080] For example, the first database service includes three database nodes, namely database node 1, database node 2 and database node 3. The user specifies the Haiguang chip type for database node 1, the Kunpeng chip type for database node 2, and the Intel chip type for database node 3. The specific implementation process of the above step 220 includes: the deployment device selects a first server that supports the Haiguang chip type from at least one server cluster of the database platform, and selects a first software image that supports the Haiguang chip type from the database platform, and then creates database node 1 on the first server that supports the Haiguang chip type according to the first software image that supports the Haiguang chip type; then, the deployment device selects a first server that supports the Kunpeng chip type from at least one server cluster of the database platform, and selects a first software image that supports the Kunpeng chip type from the database platform, and then creates database node 2 on the first server that supports the Kunpeng chip type according to the first software image that supports the Kunpeng chip type; then, the deployment device selects a first server that supports the Intel chip type from at least one server cluster of the database platform, and selects a first software image that supports the Intel chip type from the database platform, and then creates database node 3 on the first server that supports the Intel chip type according to the first software image that supports the Intel chip type.

[0081] In a second possible implementation, the hybrid chip architecture includes a hybrid deployment mode and multiple chip types selected by the user for the first database service, that is, the user not only selects a hybrid deployment mode for the first database service, but also selects multiple chip types supported by the first database service, but does not specify the chip type of each database node. The deployment device obtains the multiple chip types selected by the user, and then determines the chip type corresponding to each database node based on the multiple chip types supported by the first database service selected by the user, and then executes steps S31 and S32 for each database node included in the first database service:

[0082] Step S31, according to the chip type corresponding to the database node determined by the deployment device, selecting a first server supporting the chip type corresponding to the database node from the database platform for the database node, and selecting a first software image supporting the chip type corresponding to the database node from the database platform;

[0083] Step S32: deploying the database node on a first server that supports the chip type that is screened out and that corresponds to the database node according to the screened out first software image that supports the chip type that corresponds to the database node.

[0084] In some embodiments, the determination of the chip type corresponding to each database node based on the multiple chip types supported by the first database service selected by the user may be implemented in the following manner:

[0085] Process 1: Based on the multiple chip types selected by the user and the number of nodes included in the first database service, the number of nodes deployed for each of the multiple chip types selected by the user is calculated.

[0086] Taking the case where the number of nodes included in the first database service is n and the number of chip types corresponding to the multiple chip types selected by the user is m as an example, it is assumed that arrays k[1] to k[m] respectively store the node data deployed from the first chip type to the number of nodes deployed from the mth chip type, where k[0]=0, 1≤x≤m, then the number of nodes n included in the first database service, the number of chip types m, and the number of nodes k[x] deployed for each chip type satisfy the following formula (1):

[0087]

[0088] In formula (1), Indicates rounding operation.

[0089] For example, the number of nodes included in the first database service is 10, that is, n is 10; the multiple chip types selected by the user include three chip types: Haiguang chip type, Kunpeng chip type and Intel chip type, that is, m is 3, then substituting n=10, m=3, x=1 into the above formula (1), it can be obtained that the number of nodes deployed with the first chip type is k[1]=4; substituting n=10, m=3, x=2 into the above formula (1), it can be obtained that the number of nodes deployed with the second chip type is k[2]=4; substituting n=10, m=3, x=3 into the above formula (1), it can be obtained that the number of nodes deployed with the third chip type is k[3]=3.

[0090] In the second step, the chip type corresponding to each database node is determined according to the number of nodes deployed for each chip type.

[0091] Taking the three chip types selected by the user, including Haiguang chip type, Kunpeng chip type and Intel chip type, as an example, the combination of the number of nodes deployed by these three chip types is 4, 4, and 3. Which chip type deploys 3 database nodes and which chip type deploys 4 database nodes can be randomly determined by the deployment device or specified by the user. This application does not impose any restrictions on this.

[0092] For example, the Hygon chip type deploys 4 database nodes, the Kunpeng chip type deploys 4 database nodes, and the Intel chip type deploys 3 database nodes; for another example, the Hygon chip type deploys 4 database nodes, the Intel chip type deploys 4 database nodes, and the Kunpeng chip type deploys 3 database nodes; for another example, the Kunpeng chip type deploys 4 database nodes, the Intel chip type deploys 4 database nodes, and the Hygon chip type deploys 3 database nodes.

[0093] In a third possible implementation, the hybrid chip architecture includes a hybrid deployment mode, that is, the user only selects the hybrid deployment mode for the first database service, does not specify the multiple chip types supported by the first database service, and does not specify the chip type of each database node. The deployment device determines the chip type selected for each database node according to the hybrid chip architecture selected by the user. Then, the above steps S31 and S32 are performed once for each database node included in the first database service.

[0094] The deployment device may determine the chip type selected by each database node according to the hybrid chip architecture selected by the user in the following manner:

[0095] Process 1: Calculate the number of nodes deployed for each chip type supported by all servers included in the database platform according to the number of chip types supported by the database platform and the number of nodes included in the first database service.

[0096] The number of chip types supported by the database platform can be understood as the number of chip types supported by all servers included in the database platform. For example, if the chip types of all servers included in the database platform include the following categories: Haiguang chip type, Kunpeng chip type, Intel chip type, Zhaoxin chip type, Loongson chip type, and Shenwei chip type, then the number of chip types supported by the database platform is 6.

[0097] Taking the example that the number of nodes included in the first database service is n, the number of chip types supported by the database platform is m, and the number of nodes deployed for each chip type is k[x], these three parameters also satisfy the above formula (1), where the calculation method of the number of nodes k[x] deployed for each chip type can refer to the relevant description in the aforementioned second implementation method, which will not be repeated here.

[0098] Process 2: Determine the chip type corresponding to each database node according to the number of nodes deployed for each chip type supported by the database platform. For specific implementation, please refer to the relevant content in the second embodiment above, which will not be described here.

[0099] In a fourth possible implementation, the hybrid chip architecture includes a hybrid deployment mode, and the user selects the hybrid deployment mode only for the first database service, does not specify multiple chip types supported by the first database service, and does not specify the chip type of each database node. The deployment device determines the chip type corresponding to the database node according to the hybrid chip architecture selected by the user and the database type of the first database service.

[0100] The database types of the first database service include the database type of the master-slave architecture and the load balancing type. The following describes the specific methods of determining the chip type corresponding to the database node based on these two database types:

[0101] First, the database type of the first database service is a database type of a master-slave architecture, and the deployment device can determine the chip type for the master database node and the standby database node respectively. For example, the deployment device can randomly select the chip type for the master database node and the standby database node respectively from the chip types supported by the database platform.

[0102] Among them, the chip types selected for the primary and standby database nodes can be the same or different. In the case where the chip types determined for the primary database node and the standby database node are different, for each database node, the chip package size corresponding to the database node can be determined based on the performance benchmark package selected by the user for the first database service, the performance evaluation score of the benchmark chip corresponding to the performance benchmark package, and the performance evaluation score of the chip type corresponding to the database node, so as to ensure that the performance of the two database nodes included in the first database service is equal. The specific implementation process of determining the chip package size corresponding to each database node can be found in the following description of step S41, which will not be repeated here.

[0103] The second type is that the database type of the first database service is a multi-node load balancing type, and the deployment device calculates the number of nodes deployed for each chip type supported by the server in the database platform according to the number of chip types supported by the database platform and the number of nodes included in the first database service; and then determines the chip type corresponding to the database node according to the number of nodes deployed for each chip type supported by the server in the database platform. The specific implementation process can be referred to the relevant description of the third embodiment mentioned above, which will not be repeated here.

[0104] In any possible implementation of the second implementation, after determining the chip type corresponding to each database node, the deployment device may further perform the following steps:

[0105] Step S41, determining the chip package size corresponding to the database node according to the performance benchmark package selected by the user for the first database service, the performance evaluation score of the benchmark chip corresponding to the performance benchmark package, and the performance evaluation score of the chip type corresponding to the database node;

[0106] Among them, the performance benchmark package selected by the user for the first database service includes the number of CPU cores and memory size. For example, if the database platform uses Intel chips as the performance package benchmark, the performance benchmark package selected by the user is, for example, 2C8G, that is, the performance benchmark package selected by the user based on Intel chips as the package benchmark includes 2 CPU cores and 8G memory.

[0107] Before step S41, the deployment device may also first obtain the performance evaluation score of the chip type corresponding to the database node. In a possible implementation, for each chip type supported by the server in the database platform, execute: obtain the performance evaluation matrix corresponding to the chip type, the performance evaluation matrix includes performance test data obtained by testing at least one preset performance indicator of the chip of the chip type, the weight corresponding to at least one preset performance indicator, and the index benchmark value corresponding to at least one preset performance indicator; for the test data corresponding to each preset performance indicator in the performance evaluation matrix, according to the index benchmark value corresponding to the preset performance indicator and the correction coefficient, the test data corresponding to the preset performance indicator is normalized to obtain the normalized test data; according to the weight corresponding to each preset performance indicator in the performance evaluation matrix and the normalized test data corresponding to each preset performance indicator, the performance evaluation score of the chip type is calculated.

[0108] Specifically, different weights are set for each preset performance indicator based on the importance of at least one preset performance indicator and the degree of impact on the performance of the server. The weight refers to the relative importance of a preset performance indicator in chip performance evaluation. The higher the weight, the more important the preset performance indicator.

[0109] It should be noted that when normalizing the test data corresponding to multiple preset performance indicators of a chip type, the correction coefficients used for different preset performance indicators can be the same or different. For the same preset performance indicator of different chip types, the same correction coefficient needs to be used.

[0110] In the embodiment of the present application, the number of CPU cores D of the performance benchmark package and the performance evaluation score T of the benchmark chip corresponding to the performance benchmark package d , the performance evaluation score T of the chip type corresponding to the database node c And the number of CPU cores C in the chip performance package corresponding to the database node satisfies the following formula (2):

[0111]

[0112] In formula (2), Indicates rounding operation.

[0113] For example, the performance benchmark package is 2C8G, the performance evaluation score of the INTEL chip is 100, the performance evaluation score of the Haiguang chip is 68, and the performance evaluation score of the Kunpeng chip is 59. Then, through the above formula (2), it can be calculated that the performance package of the Haiguang chip with the same performance as the performance benchmark package is 3C12G, and the performance package of the Kunpeng chip with the same performance as the performance benchmark package is 4C16G. In the embodiment of the present application, the memory defaults to 4 times the number of CPU cores. It should be understood that in the specific implementation process, the multiple relationship between the memory and the number of CPU cores can also be set according to actual needs, and this application does not limit this.

[0114] Step S42, selecting a first server that supports the chip type corresponding to the database node from at least one server cluster of the database platform according to the chip package size corresponding to the database node and the chip type corresponding to the database node.

[0115] In the implementation of this application, when creating a database service, a certain chip type is selected as the computing power benchmark to determine the chip performance package corresponding to the selected chip type, so that the equivalent resource package can be calculated for heterogeneous nodes. The same calculation method is used when scaling the database to add database nodes with equivalent performance resources.

[0116] In order to better explain the embodiment of the present application, a database hybrid deployment method provided by the embodiment of the present application is introduced below in combination with a specific implementation scenario. The process of the method can be as follows: Figure 1 The deployment device shown is executed, wherein the structure of the deployment device 300 is as follows Figure 3 As shown, it includes a label device 301, a chip computing power evaluation device 302, a cluster heterogeneous chip mixed deployment device 303, and a database node heterogeneous chip mixed deployment device 304.

[0117] First, the tag device 301 is introduced.

[0118] In an embodiment of the present application, when creating a server cluster, a server in the library, and a software image in the library on the database platform, the label device 301 in the deployment device can add labels or attributes to the operation object, such as marking the chip type supported by the operation object, the performance evaluation score, and other attributes. Among them, the operation object includes any of the following: a server cluster, a server, and a software image. The following is an introduction to adding or updating labels to the operation object. The specific implementation of adding performance evaluation scores or attributes can refer to the implementation method of adding labels, and the specific implementation of updating performance evaluation scores or attributes can refer to the implementation method of updating labels, which will not be repeated here.

[0119] When a new operation or storage operation is performed on an operation object on the database platform, a supported chip type label is added to the operation object according to the chip type selected by the user; or, when a label update operation is performed on the database platform, the supported chip type label is updated for the operation object according to the chip type updated by the user.

[0120] Figure 4 FIG. 1 is a schematic diagram of a process of setting a chip type label and a performance evaluation score exemplarily shown in an embodiment of the present invention. The process is executed by the label device 301. Figure 4 As shown, the specific process includes:

[0121] Step 401, select an operation object on the database platform; if the selected operation object is a cluster, continue to step 402; if the selected operation object is a server, continue to step 405; if the selected operation object is a software image, continue to step 409.

[0122] Step 402: Continue to determine the type of operation performed on the cluster. If the operation type is to create a new cluster, continue to execute step 403; if the operation type is to update cluster attributes, continue to execute step 404.

[0123] Step 403: Create a new cluster and add a chip type tag to the cluster; then determine whether it is successful. If successful, the process ends; if failed, perform exception processing and end.

[0124] For example Figure 5 The interface diagram of the cluster label is shown in Figure 1. Each heterogeneous chip colocation cluster can support multiple chip architectures such as X86, Kunpeng, and Hygon. When creating a new database cluster, users can add a chip type label supported by the cluster in the CPU architecture column.

[0125] Step 404: Update the chip type label of the cluster; if successful, the process ends; if failed, perform exception handling and end.

[0126] The chip type tag of the cluster supports adding and deleting operations.

[0127] Step 405: Continue to determine the type of operation performed on the server; if the operation type is to add a new server to the database, continue to step 406; if the operation type is to update the server attributes, continue to step 408;

[0128] Step 406: Add the server to the warehouse and add a chip type tag to the new server; if successful, continue to step 407; if failed, perform exception processing and end.

[0129] like Figure 6 The interface diagram of the server label is shown in the figure. Figure 6 The host in the application is the server, and the chip architecture supported by each server is fixed to one type. For any cluster, the chip architecture supported by each server in the cluster can be the same or different. Figure 6 Only examples of servers with the same chip type in the cluster are shown.

[0130] Step 407: Calculate the chip performance evaluation score of the server; if successful, the process ends; if failed, perform exception processing and end.

[0131] Among them, the server's chip performance evaluation score label is recorded in the background database and is not displayed on the page.

[0132] The specific implementation of the above step 407 can be found in the subsequent Figure 7 In the chip performance evaluation method shown, the chip performance evaluation score is calculated when each chip type server is first put into storage or when the chip performance evaluation matrix is ​​updated. When the same chip type server is subsequently put into storage, there is no need to repeatedly calculate the performance evaluation score, that is, the performance evaluation score is calculated for the chip type, not for each server. For example, when a server with a Haiguang chip type is put into storage for the first time, the performance evaluation score corresponding to the Haiguang chip type is calculated. When the server with a Haiguang chip is put into storage again, there is no need to calculate the performance evaluation score again. The performance evaluation scores of other chip type servers are also calculated when they are first put into storage.

[0133] Step 408: Update the chip type tag of the server; if successful, the process ends; if failed, perform exception handling and end.

[0134] Among them, the chip type tag of the server supports adding and deleting operations.

[0135] Step 409: Continue to determine the type of operation performed on the software image; if the operation type is to store a new software image, continue to execute step 410; if the operation type is to update the software image attribute, continue to execute step 411;

[0136] Step 410: Add a new software image to the database and add a chip type tag to the software image; if successful, the process ends; if failed, perform exception processing and end.

[0137] like Figure 7 The interface diagram of the software image label shown in the figure, each software image supports multiple chip architectures, such as Figure 7 The software images with X86 chip type and Haiguang chip type added are shown in FIG.

[0138] Step 411: Update the chip type tag of the software image. If successful, the process ends. If failed, perform exception handling and end.

[0139] Among them, the chip type label of the software image supports adding and deleting operations.

[0140] The exception handling in the above steps mainly records the relevant logs of failure, including the time of failure, operation steps, failure reasons, etc.

[0141] The chip computing power evaluation device 302 is introduced below.

[0142] Since the CPU performance of servers with different chip types included in the database platform is different, when heterogeneous chips of database nodes are mixed, if different nodes included in the database service use different types of CPU chips, under the same number of CPU cores, the performance of different database nodes included in the database service is often inconsistent. In this case, if the database service with a master-slave architecture undergoes a master-slave switch, or if some nodes in the database service with a multi-node architecture fail, there will be a risk of overall performance degradation or nonlinear degradation of the database service. Therefore, a key problem that needs to be solved when heterogeneous chips of database nodes are mixed is to evaluate the performance differences of different types of chips, and try to equip the master and standby libraries or multiple nodes of the same database service with almost the same computing power. This evaluation work can be implemented by the chip computing power evaluation device 302.

[0143] After research and testing, there is currently no single indicator that can reflect the differences between different chips in database application scenarios. Therefore, the embodiment of the present application proposes a comprehensive evaluation method for server performance of different chip types, with the help of general CPU performance test data (including test data obtained by using speccpu and cpubench for performance testing), combined with other indicators such as CPU main frequency and cache, and focusing on the database performance test data of the sysbench tool, to build a performance evaluation matrix. The performance evaluation matrix can be expressed in a tabular form, in which the first column is the name of the performance indicator, the second column is the test method, the third column is the measured data (according to the measured data obtained by each test method), the fourth column is the indicator weight, and the fifth column is the indicator benchmark value. The benchmark value generally selects the test data of the chip type used in large-scale production or commonly used, such as Intel chips. It should be understood that the performance evaluation matrix can be continuously expanded and updated according to the advancement of computing power evaluation work and the upgrading of test methods, so as to more accurately reflect the computing power of the chip, thereby ensuring the consistency of multi-node performance of database services.

[0144] For example, the performance evaluation matrix of the Haiguang chip Haiguang 5380 is shown in Table 1 below, where the index benchmark value is the INTEL4314 chip.

[0145] Table 1 Performance evaluation matrix of optical chip Haiguang 5380

[0146] Indicator name Test Method Measured data Indicator weight Index benchmark value Single-core integer performance score CPUBench 1.309 0.025 2.068 Single-core integer performance score SPEC CPU 7.21 0.025 9.19 Single-core floating point computing power score CPUBench 1.391 0.025 2.111 Single-core floating point computing power score SPEC CPU 76 0.025 152 Multi-core integer performance score CPUBench 51.38 0.05 57.78 Multi-core integer performance score SPEC CPU 154 0.05 277 Multi-core floating point computing power score CPUBench 48.49 0.05 43.6 Multi-core floating point computing power score SPEC CPU 147 0.05 283 Frequency Fixed value 2.5 0.05 2.4 L1 Cache Fixed value 32 0.05 48 L2 Cache Fixed value 512 0.05 1280 L3 cache Fixed value 8192 0.05 24576 TPS Sysbench 12600 0.3 18000 1 / Delay Sysbench 0.015 0.2 0.02

[0147] The following is an introduction to the specific implementation of calculating the performance evaluation scores of each chip type.

[0148] The following is an introduction to the chip performance evaluation method with reference to specific examples. Figure 8 FIG. 1 is a flow chart showing an exemplary method of calculating a performance evaluation score in an embodiment of the present invention. Figure 8 As shown, the specific process includes:

[0149] Step 801: Obtain the chip type to be evaluated.

[0150] Step 802, determining whether the chip type of the server is a new chip type; if it is a new type chip, executing step 804; if it is not a new type chip, indicating that it is an evaluated chip, executing step 803;

[0151] Step 803, determine whether there is any test data update or new addition for the evaluated chip; if so, execute step 804, that is, update the performance evaluation data recorded in the database; if not, end the process.

[0152] Step 804, record the performance evaluation data and generate a performance evaluation matrix. If successful, continue to step 805, if failed, end the process after exception handling.

[0153] The specific process of step 804 includes: obtaining the test results of the chip type of the server according to various tools such as CPUBench and SPEC CPU, and then recording the performance evaluation data of the chip in the database to generate a performance evaluation matrix.

[0154] Step 805: Normalize the performance evaluation data. If the normalization succeeds, continue to step 806. If it fails, the process ends after exception handling.

[0155] Since the test data in the chip performance evaluation matrix are provided by different test tools and have different standards, the test data needs to be normalized into dimensionless scores before calculating the chip performance comprehensive score. The normalization formula is as follows:

[0156]

[0157] In formula (3), Indicates that the calculation result is rounded.

[0158] Among them, X is the normalized score of the indicator, the calculation result is an integer, S is the test data in the third column of the chip performance evaluation matrix, D is the benchmark value of the indicator in the fifth column, and α is the correction coefficient.

[0159] Step 806: Calculate the performance evaluation score of the chip based on the normalized dimensionless score; if the performance evaluation score is calculated successfully, continue to step 807, if it fails, end the process after exception handling.

[0160] The chip performance evaluation score calculation formula is as follows:

[0161]

[0162] In formula (4), Indicates the rounding of the calculation result, T is the performance evaluation score of the chip, X(i) is the dimensionless score of the i-th indicator, W(i) represents the weight of the i-th indicator, i∈(1, N) represents the indicator category, and N is the total number of indicators.

[0163] For example, for the performance evaluation matrix of Haiguang 5380 shown in Table 1 above, the measured data corresponding to each indicator in the performance evaluation data in the performance evaluation matrix is ​​normalized according to formula (3), and then the performance evaluation score of Haiguang 5380 is calculated as 69 points according to the above formula (4).

[0164] Step 807: Record the performance evaluation score of the chip type in the database; if successful, end the process; if failed, end the process after exception handling. The performance evaluation score of the chip type recorded in the database is used to calculate the performance packages of various chips when the database node is mixed with heterogeneous chips.

[0165] The exception handling process in step 807 mainly records the failure-related logs, including time, operation step 80, failure reason, etc.

[0166] The heterogeneous chip colocation device 303 within the cluster is introduced below.

[0167] By setting label attributes, CPU chip type labels are added to clusters, servers, and software images. Then, servers of different chip types can be added to a logical cluster. During the database software deployment process, the heterogeneous chip mixing device 303 in the cluster can screen servers of matching types in the cluster and deploy software images of matching types according to the chip architecture selected by the user.

[0168] Fig. 9 1 is a flow chart of a method for hybrid deployment of a database exemplarily shown in an embodiment of the present invention. The flow is executed by a heterogeneous chip hybrid deployment device 303 in a cluster. Fig. 9 As shown, the specific process includes:

[0169] Step 901: Apply to create a database service on the database platform.

[0170] Step 902: Select the CPU architecture, ie, the chip type.

[0171] like Fig.10 The interface diagram of applying to create a database service is shown. The CPU architectures in this interface include X86, ARM, Haiguang, and hybrid. If the user selects any of X86, ARM, and Haiguang, a single-chip architecture is selected. If the user selects hybrid, a hybrid chip architecture is selected. In this example, the CPU architecture selected by the user is the x86 chip, that is, the user selects the single-chip architecture of the x86 chip, which means that all database nodes in the database service that needs to be created currently use x86 chip type servers.

[0172] Step 903: The database platform deploys database nodes according to the user application options.

[0173] Step 904: Filter clusters and check whether there is a cluster that supports the selected chip type according to the CPU architecture label of the cluster. If yes, continue to step 905. If not, end the process after exception handling.

[0174] Step 905: Filter the servers in the cluster and select servers that support the selected chip type through the CPU architecture labels of the servers. If there are any, continue to step 906. If not, end the process after exception handling.

[0175] Step 906: Filter the software image and determine whether the selected chip type is supported according to the CPU architecture label of the software image. If supported, continue to step 907. If not supported, end the process after exception handling.

[0176] Step 907: Create a database node.

[0177] Step 908: Check whether the creation is successful; if successful, continue to step 909; if failed, end the process after exception handling.

[0178] Step 909: Determine whether there are other database nodes to be deployed. If yes, continue to execute step 904. If no, end the process.

[0179] The exception handling process in each of the above steps mainly records failure-related logs, including time, operation steps, failure reasons, etc.

[0180] The above database hybrid deployment method is applicable to the architecture of heterogeneous chip hybrid deployment in the cluster. Fig.11 As shown, the server cluster in the architecture is a hybrid cluster, which includes several Haiguang, Kunpeng and X86 servers. Three database services with different chip types are deployed in the cluster by using the cluster hybrid device 303, such as Fig.11 As shown in the figure, these three database services all have a master-slave architecture. The CPU chips of the master and standby database nodes of each database service are the same. The CPU chips of the master and standby database nodes of the first database service are both Haiguang chips, the CPU chips of the master and standby database nodes of the second database service are both Kunpeng chips, and the CPU chips of the master and standby database nodes of the third database service are both X86 chips.

[0181] Database services are generally deployed in multiple nodes. For example, MySQL database can be deployed in two nodes, active and standby. Kafka can be deployed in three or five nodes according to demand. In addition to being deployed on a selected chip type server in the cluster, multiple database nodes can also be deployed on a selected chip type server, as mentioned above. Fig. 9In some other embodiments, hybrid deployment can also be performed on heterogeneous chip servers within the cluster, and this deployment method can be performed by the database node heterogeneous chip hybrid deployment device 304. The database platform provides multiple switches or options to meet the personalized needs of hybrid deployment: first, it can control whether multiple nodes are hybrid deployed through heterogeneous chips; second, the chip type of multiple nodes can be specified; third, the heterogeneous chip computing power model benchmark can be selected. The database platform completes the hybrid deployment of multiple nodes of the database service on heterogeneous chips based on the user's personalized options.

[0182] Fig.12 FIG. 1 is a flow chart of a method for hybrid deployment of a database exemplarily shown in an embodiment of the present invention. The flow chart is executed by the database node heterogeneous chip hybrid deployment device 304. Fig.12 As shown, the specific process includes:

[0183] Step 1201: Apply to create a database service on the database platform.

[0184] Step 1202: Select whether the CPU architecture is to be deployed in a “hybrid” manner; if “hybrid” is selected, continue to step 1203; if another architecture is selected, the intra-cluster hybrid process is executed and ends.

[0185] exist Fig.10 In the interface for applying to create a database service, the CPU architectures include X86, ARM, Hygon, and hybrid. If the user selects "hybrid" in the interface for applying to create a database service, that is, a hybrid chip architecture is selected, then the database service that needs to be created currently supports at least two chip types.

[0186] The intra-cluster colocation process can refer to the above Fig. 9 The method shown will not be repeated here.

[0187] Step 1203: Select chip type.

[0188] Since heterogeneous chip servers are to be deployed together, two or more chip types need to be selected according to the type of database service to be deployed. One way is for the user to specify the chip type of each database node separately. For example, the user can specify the chip type of each database node in the following example: Fig.10 After selecting "Hybrid" in the interface for applying to create a database service shown in FIG. 1 , the interface can also display multiple chip type options, and the user can specify the corresponding chip type for each database node. In another method, the user only specifies the hybrid deployment method, for example, the user Fig.10After selecting "Mixed" in the interface for applying to create a database service, the interface can also display multiple chip type options. The user can select multiple chip types for the database service to be deployed, but the user does not specify the chip type corresponding to each database node, and then the database platform determines the chip type corresponding to each database node. Another way is for the database platform to determine the chip type of each database node.

[0189] Step 1204: Select a baseline performance package for the database service.

[0190] Among them, the benchmark performance package includes the number of CPU cores and memory size, such as 2C8G, for example, 4C16G, and the database platform uses INTEL chips as the performance package benchmark.

[0191] Step 1205: Calculate the package sizes of other types of chips based on the performance evaluation scores of each type of chip and the selected benchmark performance package.

[0192] The specific calculation method of the above step 1205 can refer to the relevant description in the above step S41, which will not be repeated here.

[0193] For example, the benchmark package of the INTEL chip is 2C8G, the performance evaluation score of the INTEL chip is 100, the performance evaluation score of the Hygon chip is 68, and the performance evaluation score of the Kunpeng chip is 59. Then the same performance package of the Hygon chip is 3C12G, and the same performance package of the Kunpeng chip is 4C16G (the default memory is 4 times the number of CPU cores).

[0194] Step 1206: Calculate the number of nodes deployed for each type of chip.

[0195] If it is a database service with a master-slave architecture, the chip type is determined according to the current node type, such as the master node is Hygon and the slave node is x86.

[0196] If it is a multi-node load balancing database service, it will be evenly distributed according to the number of nodes and the number of chip types. Assuming that the total number of nodes of the database service is n and there are m types of chips selected, then 1 ~ m The calculation method of the number of nodes deployed for each chip type can refer to the above formula (1), which will not be repeated here.

[0197] Step 1207: Deploy each database node in sequence according to the calculation result of the number of nodes deployed by each chip type and other application options of the user.

[0198] Step 1208: Filter the clusters and check whether there is a cluster that supports the database node chip type according to the cluster CPU architecture label. If there is a cluster, continue to step 1209. If not, end the process after exception handling.

[0199] Step 1209: Filter the servers in the cluster and filter out servers that support the selected chip type through the server CPU architecture label. If there are any, continue to step 1210. If not, end the process after exception handling.

[0200] Step 1210: Filter the software and determine whether the selected chip type is supported according to the software image label. If supported, continue to step 1211. If not supported, end the process after exception handling.

[0201] Step 1211: Create a database service node.

[0202] Step 1212: Check whether the creation is successful. If so, proceed to step 1213. If not, terminate the process after exception handling.

[0203] Step 1213: Determine whether there are other database nodes to be deployed. If yes, continue to step 1208; if no, end the process.

[0204] The exception handling process in each of the above steps mainly records failure-related logs, including time, operation steps, failure reasons, etc.

[0205] The above database hybrid deployment method is applicable to the architecture of database node heterogeneous chip hybrid deployment as follows Fig.13 As shown in Figure 1, the server cluster in this architecture is a hybrid cluster. The server cluster contains several servers using Haiguang, Kunpeng, and X86 chips. There are four database services deployed on heterogeneous chips in the cluster, such as Fig.13 As shown in the figure, these three database services are all active-standby architectures. The CPU chips of the active and standby databases of each database service are different. The active database of the first database service is a Haiguang chip, and the standby database is an X86 chip. The active database of the second database service is a Kunpeng chip, and the standby database is an X86 chip. The active database of the third database service is a Haiguang chip, and the standby database is a Kunpeng chip. The active database of the fourth database service is a Kunpeng chip, and the standby database is a Haiguang chip.

[0206] In the embodiment of the present application, by mixing the database master and standby nodes on heterogeneous chip servers, the needs of user-specified chips can be met in greater quantities, avoiding the shortage of resources on a certain type of chip server while other types of servers are idle, resulting in uneven distribution and waste of resources. Taking the Mysql database with a master-slave architecture as an example, if the user specifies the use of a Haiguang chip server, the master node can be deployed on the Haiguang server and the standby node can be deployed on the INTEL server. By effectively combining different chips together, the advantages of each chip can be fully utilized to improve the heterogeneous capabilities of the database, thereby improving the performance of the entire database system, and improving the continuity of database services and resource utilization efficiency.

[0207] In addition, by deploying different nodes of various software on heterogeneous chip servers, the data migration efficiency of database and other software during the migration and transformation process can be improved and the migration process can be simplified. Taking the migration of Mysql database from INTEL server to Kunpeng server as an example, the previous migration process was to first create a new Kunpeng database, then migrate the data through data logical backup, and finally take the original INTEL database offline. This application supports the reconstruction function of the database cloud platform DBAAS after chip hybrid deployment. The INTEL database node to be migrated can be rebuilt on the Kunpeng server, and then the database full library backup and restore function provided by DBAAS can be used to quickly complete the data migration. The efficiency is better than logical migration, and the process is simple. The old node will be automatically deleted during the reconstruction process, and it does not occupy additional resources for a long time and does not require offline processes.

[0208] Based on the same technical concept, the embodiment of the present application provides a structural diagram of a database hybrid deployment device, such as Fig.14 As shown, the device 1400 includes:

[0209] An acquisition module 1401 is used to acquire a first request, where the first request is used to apply for creating a first database service on a database platform, where the first database service includes at least one database node;

[0210] Processing module 1402 is used to execute, for each database node in the first database service: selecting, based on the chip architecture selected by the user for the first database service, a first server that supports the chip type corresponding to the database node in at least one server cluster of the database platform, and selecting, from the database platform, a first software image that supports the chip type corresponding to the database node; and deploying the database node on the first server based on the first software image.

[0211] Optionally, the chip architecture is a single-chip architecture that supports the first chip type; the processing module 1402 is specifically used to: select a first server that supports the first chip type in at least one server cluster of the database platform according to the single-chip architecture that supports the first chip type selected by the user for the first database service, and select a first software image that supports the first chip type from the database platform; and deploy the database node on the selected first server that supports the first chip type according to the selected first software image that supports the first chip type.

[0212] Optionally, the chip architecture is a hybrid chip architecture; the processing module 1402 is used to:

[0213] Determining a chip type corresponding to the database node according to the hybrid chip architecture selected by the user for the first database service;

[0214] Determine the chip package size corresponding to the database node according to the performance benchmark package selected by the user for the first database service, the chip type corresponding to the database node, and the performance evaluation score of the chip type corresponding to the database node;

[0215] According to the chip package size corresponding to the database node and the chip type corresponding to the database node, a first server supporting the chip type corresponding to the database node is selected from at least one server cluster of the database platform.

[0216] Optionally, the hybrid chip architecture includes a hybrid deployment mode and a chip type specified by the user for each database node; the processing module 1402 is specifically used to: determine the chip type specified by the user for the database node based on the hybrid chip architecture selected by the user for the first database service.

[0217] Optionally, the hybrid chip architecture includes a hybrid deployment mode and multiple chip types selected by the user for the first database service; the processing module 1402 is specifically used to: calculate the number of nodes deployed for each of the multiple chip types according to the number of chip types corresponding to the multiple chip types selected by the user for the first database service and the number of nodes included in the first database service; determine the chip type corresponding to the database node according to the number of nodes deployed for each of the multiple chip types.

[0218] Optionally, the hybrid chip architecture includes a hybrid deployment mode; the processing module 1402 is specifically configured to:

[0219] Calculate the number of nodes deployed for each chip type supported by the server in the database platform according to the number of chip types supported by the server in the database platform and the number of nodes included in the first database service;

[0220] The chip type corresponding to the database node is determined according to the number of nodes deployed for each chip type supported by the server in the database platform.

[0221] Optionally, the acquisition module 1401 is further used to: for each chip type supported by the server in the database platform, obtain a performance evaluation matrix corresponding to the chip type, wherein the performance evaluation matrix includes performance test data obtained by testing at least one preset performance indicator of the chip of the chip type, a weight corresponding to the at least one preset performance indicator, and an indicator benchmark value corresponding to the at least one preset performance indicator;

[0222] The processing module 1402 is also used to: for each test data corresponding to the preset performance indicator in the performance evaluation matrix, normalize the test data corresponding to the preset performance indicator according to the indicator reference value and the correction coefficient corresponding to the preset performance indicator to obtain the normalized test data;

[0223] The performance evaluation score of the chip type is calculated according to the weight corresponding to each preset performance indicator in the performance evaluation matrix and the normalized test data corresponding to each preset performance indicator.

[0224] Optionally, the processing module 1402 is further configured to:

[0225] When a new operation or storage operation is performed on an operation object on the database platform, a supported chip type label is added to the operation object according to the chip type selected by the user; the operation object includes any of the following: a cluster, a server, and a software image; or,

[0226] When a label update operation is performed on an operation object on a database platform, a supported chip type label is updated for the operation object according to the chip type updated by the user.

[0227] The computer device may be Figure 1 The deployment device shown, such as Fig.15 As shown, the computer device includes at least one processor 1501 and a memory 1502 connected to the at least one processor. The specific connection medium between the processor 1501 and the memory 1502 is not limited in the embodiment of the present application. Fig.15 For example, the processor 1501 and the memory 1502 are connected via a bus. The bus can be divided into an address bus, a data bus, a control bus, etc.

[0228] In the embodiment of the present application, the memory 1502 stores instructions that can be executed by at least one processor 1501, and the at least one processor 1501 can perform the steps of the above-mentioned database health assessment method by executing the instructions stored in the memory 1502.

[0229] Among them, the processor 1501 is the control center of the computer device, and various interfaces and lines can be used to connect various parts of the computer device, and the database health assessment can be realized by running or executing instructions stored in the memory 1502 and calling the data stored in the memory 1502. Optionally, the processor 1501 may include one or more processing units, and the processor 1501 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 1501. In some embodiments, the processor 1501 and the memory 1502 may be implemented on the same chip, and in some embodiments, they may also be implemented separately on independent chips.

[0230] Processor 1501 can be a general-purpose processor, such as a central processing unit (CPU), a digital signal processor, an application-specific integrated circuit (ASIC), a field programmable gate array or other programmable logic device, a discrete gate or transistor logic device, a discrete hardware component, and can implement or execute the various methods, steps and logic block diagrams disclosed in the embodiments of the present application. A general-purpose processor can be a microprocessor or any conventional processor, etc. The steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware processor for execution, or can be executed by a combination of hardware and software modules in the processor.

[0231] Memory 1502, as a non-volatile computer-readable storage medium, can be used to store non-volatile software programs, non-volatile computer executable programs and modules. Memory 1502 may include at least one type of storage medium, such as flash memory, hard disk, multimedia card, card-type memory, random access memory (Random Access Memory, RAM), static random access memory (Static Random Access Memory, SRAM), programmable read-only memory (Programmable Read Only Memory, PROM), read-only memory (Read Only Memory, ROM), electrically erasable programmable read-only memory (Electrically Erasable Programmable Read-Only Memory, EEPROM), magnetic memory, disk, optical disk, etc. Memory 1502 is any other medium that can be used to carry or store a desired program code in the form of an instruction or data structure and can be accessed by a computer device, but is not limited thereto. The memory 1502 in the embodiment of the present application can also be a circuit or any other device that can realize a storage function, for storing program instructions and / or data.

[0232] Based on the same inventive concept, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program that can be executed by a computer device. When the program runs on the computer device, the computer device executes the steps of the above-mentioned database health assessment method.

[0233] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0234] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer device or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0235] These computer program instructions may also be stored in a computer readable memory capable of directing a computer device or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0236] These computer program instructions can also be loaded onto a computer device or other programmable data processing device so that a series of operation steps are executed on the computer device or other programmable device to produce a process implemented by the computer device, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0237] Although the preferred embodiments of the present invention have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention.

[0238] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. A database hybrid deployment method, characterized in that: include: Obtaining a first request, where the first request is used to request to apply for creating a first database service on a database platform, where the first database service includes at least one database node; The database platform includes at least one server cluster and software images supporting multiple chip types, each server cluster includes servers supporting at least two chip types; For each database node in the first database service, execute: According to the chip architecture selected by the user for the first database service, selecting a first server supporting the chip type corresponding to the database node in at least one server cluster of the database platform, and selecting a first software image supporting the chip type corresponding to the database node from the database platform; The database node is deployed on the first server according to the first software image.

2. The method according to claim 1, characterized in that The chip architecture is a single chip architecture that supports a first chip type; the selecting, according to the chip architecture selected by the user for the first database service, a first server that supports a chip type corresponding to the database node in at least one server cluster of the database platform, and selecting a first software image that supports a chip type corresponding to the database node from the database platform include: According to the single chip architecture supporting the first chip type selected by the user for the first database service, selecting a first server supporting the first chip type in at least one server cluster of the database platform, and selecting a first software image supporting the first chip type from the database platform; The step of deploying the database node on the first server according to the first software image includes: The database node is deployed on a selected first server supporting the first chip type according to the selected first software image supporting the first chip type.

3. The method according to claim 1, characterized in that The chip architecture is a hybrid chip architecture; and selecting, according to the chip architecture selected by the user for the first database service, a first server of a chip type that supports the database node in at least one server cluster of the database platform includes: Determining a chip type corresponding to the database node according to the hybrid chip architecture selected by the user for the first database service; Determine the chip package size corresponding to the database node according to the performance benchmark package selected by the user for the first database service, the chip type corresponding to the database node, and the performance evaluation score of the chip type corresponding to the database node; According to the chip package size corresponding to the database node and the chip type corresponding to the database node, a first server supporting the chip type corresponding to the database node is selected from at least one server cluster of the database platform.

4. The method according to claim 3, characterized in that The hybrid chip architecture includes a hybrid deployment approach and a user-specified chip type for each database node; The determining, according to the hybrid chip architecture selected by the user for the first database service, a chip type corresponding to the database node includes: According to the hybrid chip architecture selected by the user for the first database service, a chip type specified by the user for the database node is determined.

5. The method according to claim 3, characterized in that The hybrid chip architecture includes a hybrid deployment mode and multiple chip types selected by a user for the first database service; The determining, according to the hybrid chip architecture selected by the user for the first database service, a chip type corresponding to the database node includes: Calculate the number of nodes deployed for each of the multiple chip types according to the number of chip types corresponding to the multiple chip types selected by the user for the first database service and the number of nodes included in the first database service; The chip type corresponding to the database node is determined according to the number of nodes deployed for each chip type of the multiple chip types.

6. The method according to claim 3, characterized in that The hybrid chip architecture includes a hybrid deployment mode; and determining the chip type corresponding to the database node according to the hybrid chip architecture selected by the user for the first database service includes: Calculate the number of nodes deployed for each chip type supported by the server in the database platform according to the number of chip types supported by the server in the database platform and the number of nodes included in the first database service; The chip type corresponding to the database node is determined according to the number of nodes deployed for each chip type supported by the server in the database platform.

7. The method according to any one of claims 1 to 6, characterized in that: The method further comprises: For each chip type supported by the server in the database platform, execute: Obtaining a performance evaluation matrix corresponding to the chip type, the performance evaluation matrix comprising performance test data obtained by testing at least one preset performance indicator of the chip of the chip type, a weight corresponding to the at least one preset performance indicator, and an indicator benchmark value corresponding to the at least one preset performance indicator; For each test data corresponding to a preset performance indicator in the performance evaluation matrix, the test data corresponding to the preset performance indicator is normalized according to the indicator reference value and the correction coefficient corresponding to the preset performance indicator to obtain normalized test data; The performance evaluation score of the chip type is calculated according to the weight corresponding to each preset performance indicator in the performance evaluation matrix and the normalized test data corresponding to each preset performance indicator.

8. The method according to any one of claims 1 to 6, characterized in that: The method further comprises: When a new operation or storage operation is performed on an operation object on the database platform, a supported chip type label is added to the operation object according to the chip type selected by the user; the operation object includes any of the following: a cluster, a server, and a software image; or, When a label update operation is performed on an operation object on a database platform, a supported chip type label is updated for the operation object according to the chip type updated by the user.

9. A database hybrid deployment device, characterized in that: include: A receiving module, configured to obtain a first request, wherein the first request is used to apply for creating a first database service on a database platform, and the first database service includes at least one database node; a processing module, configured to execute, for each database node in the first database service: selecting, according to a chip architecture selected by a user for the first database service, a first server supporting a chip type corresponding to the database node in at least one server cluster of a database platform, and selecting a first software image supporting a chip type corresponding to the database node from the database platform; The database node is deployed on the first server according to the first software image.

10. A computer device, characterized in that: include: A memory for storing program instructions; A processor, configured to call the program instructions stored in the memory, and execute the method according to any one of claims 1 to 8 according to the obtained program.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the method according to any one of claims 1 to 8.

Citation Information

Cited By

  • Hybrid database deployment method and apparatus

    WO2026113506A1