CN113220432B - Multi-cloud interconnection method, device, equipment, storage medium and product - Google Patents

Multi-cloud interconnection method, device, equipment, storage medium and product Download PDF

Info

Publication number
CN113220432B
CN113220432B CN202110501525.3A CN202110501525A CN113220432B CN 113220432 B CN113220432 B CN 113220432B CN 202110501525 A CN202110501525 A CN 202110501525A CN 113220432 B CN113220432 B CN 113220432B
Authority
CN
China
Prior art keywords
cluster
scheduling
clusters
interconnection
scheduled
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110501525.3A
Other languages
Chinese (zh)
Other versions
CN113220432A (en
Inventor
杨秋霞
栗霖
隗英英
赵斌
常乐
胡云
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China United Network Communications Group Co Ltd
Original Assignee
China United Network Communications Group Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China United Network Communications Group Co Ltd filed Critical China United Network Communications Group Co Ltd
Priority to CN202110501525.3A priority Critical patent/CN113220432B/en
Publication of CN113220432A publication Critical patent/CN113220432A/en
Application granted granted Critical
Publication of CN113220432B publication Critical patent/CN113220432B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

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

Abstract

The embodiment of the application provides a method, a device, equipment, a storage medium and a product for cloud interconnection, wherein the method comprises the following steps: acquiring a plurality of to-be-interconnected Kubernetes clusters, wherein the to-be-interconnected Kubernetes clusters are positioned in corresponding cloud services; for each Kubernetes cluster to be interconnected, determining a corresponding scheduling cluster and at least one scheduled cluster, acquiring access configuration information corresponding to each scheduled cluster, generating corresponding scheduling nodes according to the access configuration information through the scheduling clusters, and establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node. The multi-cloud interconnection method provided by the embodiment of the application has the advantages that the time for realizing interconnection is short, hardware resources are not required to be added, the cost is lower compared with the mode of interconnection after the hardware resources are added, and the interconnection efficiency is higher.

Description

Multi-cloud interconnection method, device, equipment, storage medium and product
Technical Field
The embodiment of the application relates to the technical field of cloud service, in particular to a multi-cloud interconnection method, a device, equipment, a storage medium and a product.
Background
The multi-cloud is a cloud architecture, which is formed by combining a plurality of cloud services provided by a plurality of cloud providers, and does not limit the use of public clouds or private clouds. With the continuous development of cloud services, today enterprises increasingly rely on multiple cloud services, especially differentiated services acquired through different clouds. The service can be more flexibly and efficiently configured through the differentiated services of different clouds, and meanwhile, the dependence on a single cloud provider can be avoided.
However, because network services provided by cloud providers have different capabilities and constraints, it is difficult to establish and maintain an interconnection between clouds. In particular, data between public clouds provided by different suppliers is not communicated and compatible. If interconnection between public clouds is to be realized, resources on a hardware level are generally required to be increased, and the cost is high. And because the hardware resources are related to the actual space and equipment, the interconnection between the clouds is low in efficiency.
Disclosure of Invention
The application provides a method, a device, equipment, a storage medium and a product for multi-cloud interconnection, which are used for solving the problem of low interconnection efficiency between public clouds at present.
An embodiment of the present application provides a method for cloud interconnection, including:
acquiring a plurality of to-be-interconnected Kubernetes clusters, wherein the to-be-interconnected Kubernetes clusters are positioned in corresponding cloud services;
for each Kubernetes cluster to be interconnected, determining a corresponding scheduling cluster and at least one scheduled cluster, acquiring access configuration information corresponding to each scheduled cluster, generating corresponding scheduling nodes according to the access configuration information through the scheduling clusters, and establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node.
Further, the method as described above, for each Kubernetes cluster to be interconnected, determines a corresponding scheduling cluster and at least one scheduled cluster, including:
and determining the to-be-interconnected Kubernetes clusters as scheduling clusters for each to-be-interconnected Kubernetes cluster, and determining other clusters except the scheduling clusters in the plurality of to-be-interconnected Kubernetes clusters as scheduled clusters.
Further, as described above, the generating, by the scheduling cluster, a corresponding scheduling node according to the access configuration information includes:
generating corresponding virtual nodes according to the access configuration information through Master nodes of the scheduling clusters;
and determining the virtual node as a scheduling node.
Further, as described above, the generating, by the Master node of the scheduling cluster, a corresponding virtual node according to the access configuration information includes:
and sending the access configuration information to a Master node of the scheduling cluster, so that the Master node generates a corresponding Virtual node through a Virtual Kubelet construction tool according to the access configuration information.
Further, in the method as described above, the obtaining access configuration information corresponding to each scheduled cluster includes:
obtaining kubeconfig files in each scheduled cluster;
analyzing the kubeconfig file to obtain corresponding access configuration information;
the establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node comprises the following steps:
constructing a mapping relation between each scheduling node and each scheduling cluster and each corresponding scheduled cluster;
and establishing interconnection between the scheduling clusters and each scheduled cluster through each scheduling node according to the mapping relation.
Further, the method as described above, after the establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node, further includes:
receiving a cloud service instruction sent by a user terminal, and determining a scheduling node corresponding to a scheduled cluster according to the cloud service instruction;
scheduling data in the corresponding scheduled cluster according to the corresponding scheduling node;
and sending the data in the corresponding scheduled cluster to the user terminal.
A second aspect of an embodiment of the present application provides a multi-cloud interconnection apparatus, including:
the acquisition module is used for acquiring a plurality of to-be-interconnected Kubernetes clusters, wherein the to-be-interconnected Kubernetes clusters are positioned in corresponding cloud services;
the interconnection module is used for determining a corresponding scheduling cluster and at least one scheduled cluster aiming at each to-be-interconnected Kubernetes cluster, acquiring access configuration information corresponding to each scheduled cluster, generating corresponding scheduling nodes according to the access configuration information through the scheduling clusters, and establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node.
Further, in the apparatus as described above, when determining, for each Kubernetes cluster to be interconnected, a corresponding scheduling cluster and at least one scheduled cluster, the interconnection module is specifically configured to:
and determining the to-be-interconnected Kubernetes clusters as scheduling clusters for each to-be-interconnected Kubernetes cluster, and determining other clusters except the scheduling clusters in the plurality of to-be-interconnected Kubernetes clusters as scheduled clusters.
Further, in the apparatus as described above, the interconnection module is specifically configured to, when generating, by the scheduling cluster, a corresponding scheduling node according to the access configuration information:
generating corresponding virtual nodes according to the access configuration information through Master nodes of the scheduling clusters; and determining the virtual node as a scheduling node.
Further, in the apparatus as described above, the interconnection module is specifically configured to, when generating, by using the Master node of the scheduling cluster, a corresponding virtual node according to the access configuration information:
and sending the access configuration information to a Master node of the scheduling cluster, so that the Master node generates a corresponding Virtual node through a Virtual Kubelet construction tool according to the access configuration information.
Further, in the apparatus as described above, the interconnection module is specifically configured to, when obtaining access configuration information corresponding to each scheduled cluster:
obtaining kubeconfig files in each scheduled cluster; analyzing the kubeconfig file to obtain corresponding access configuration information;
the interconnection module is specifically configured to, when establishing interconnection between the scheduling cluster and each scheduled cluster according to each scheduling node: constructing a mapping relation between each scheduling node and each scheduling cluster and each corresponding scheduled cluster; and establishing interconnection between the scheduling clusters and each scheduled cluster through each scheduling node according to the mapping relation.
Further, the apparatus as described above, further comprising:
the cloud service module is used for receiving a cloud service instruction sent by the user terminal and determining a scheduling node corresponding to the scheduled cluster according to the cloud service instruction; scheduling data in the corresponding scheduled cluster according to the corresponding scheduling node; and sending the data in the corresponding scheduled cluster to the user terminal.
A third aspect of an embodiment of the present application provides an electronic device, including: a memory, a processor;
a memory; a memory for storing the processor-executable instructions;
wherein the processor is configured to perform the multi-cloud interconnection method of any of the first aspects by the processor.
A fourth aspect of the embodiments of the present application provides a computer-readable storage medium having stored therein computer-executable instructions for implementing the multi-cloud interconnection method of any one of the first aspects when executed by a processor.
A fifth aspect of an embodiment of the present application provides a computer program product comprising a computer program which, when executed by a processor, implements the method of clouding interconnection of any of the first aspects.
The embodiment of the application provides a multi-cloud interconnection method, a device, equipment, a storage medium and a product, wherein the method comprises the following steps: acquiring a plurality of to-be-interconnected Kubernetes clusters, wherein the to-be-interconnected Kubernetes clusters are positioned in corresponding cloud services; for each Kubernetes cluster to be interconnected, determining a corresponding scheduling cluster and at least one scheduled cluster, acquiring access configuration information corresponding to each scheduled cluster, generating corresponding scheduling nodes according to the access configuration information through the scheduling clusters, and establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node. According to the multi-cloud interconnection method provided by the embodiment of the application, a plurality of to-be-interconnected Kubernetes clusters in cloud service are firstly obtained, and then interconnection operation is carried out on each to-be-interconnected Kubernetes cluster. The specific operation of interconnection is to firstly determine a corresponding dispatching cluster and at least one dispatched cluster, wherein the dispatching cluster is a main cluster of interconnection, and data in the dispatched cluster can be dispatched after the interconnection is completed. In order to complete interconnection between the dispatching clusters and the dispatched clusters, access configuration information of the dispatched clusters needs to be obtained, so that corresponding dispatching nodes are generated through the dispatching clusters according to the access configuration information, and finally interconnection between the dispatching clusters and each dispatched cluster can be achieved according to the dispatching nodes. The multi-cloud interconnection method of the embodiment of the application can realize the interconnection of the Kubernetes clusters through the operation on a software layer, has shorter interconnection time, does not need to increase hardware resources, has lower cost compared with the interconnection mode after increasing the hardware resources, and has higher interconnection efficiency.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description, serve to explain the principles of the application.
FIG. 1 is a scene diagram of a multi-cloud interconnection method in which embodiments of the present application may be implemented;
fig. 2 is a schematic flow chart of a multi-cloud interconnection method according to a first embodiment of the present application;
fig. 3 is a schematic flow chart of a multi-cloud interconnection method according to a second embodiment of the present application;
fig. 4 is a schematic diagram of a cluster architecture of a multi-cloud interconnection method according to a second embodiment of the present application;
fig. 5 is a schematic structural diagram of a multi-cloud interconnection device according to a third embodiment of the present application;
fig. 6 is a schematic structural diagram of a multi-cloud interconnection apparatus according to a fourth embodiment of the present application;
fig. 7 is a schematic structural diagram of an electronic device according to a fifth embodiment of the present application.
Specific embodiments of the present application have been shown by way of the above drawings and will be described in more detail below. The drawings and the written description are not intended to limit the scope of the inventive concepts in any way, but rather to illustrate the inventive concepts to those skilled in the art by reference to the specific embodiments.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples do not represent all implementations consistent with the application. Rather, they are merely examples of apparatus and methods consistent with aspects of the application as detailed in the accompanying claims.
The technical scheme of the application is described in detail below by specific examples. The following embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments. Embodiments of the present application will be described below with reference to the accompanying drawings.
For a clear understanding of the technical solutions of the present application, the prior art solutions will be described in detail first. Enterprises face a great challenge of data security after using cloud data, and multi-cloud solutions are also emerging. The multi-cloud solution can enable data to be backed up in different cloud ends, and data loss is effectively prevented. At the same time, by the free selection and combination of multiple clouds, the advantages of cloud services of different suppliers can be selected, thereby providing a flexible solution for enterprises. The multi-cloud interconnection is a new trend of multi-cloud solutions, and can establish cloud-to-cloud connection so as to exert the advantage of the multi-cloud to the greatest extent. At present, common multi-cloud interconnection mainly aims at public clouds, wherein the public clouds are cloud services provided by suppliers, and data among the public clouds are not communicated and are not compatible. The public cloud interconnection is generally realized by adding hardware resources such as a plurality of hosts, a plurality of connecting wires and the like by adopting a centralized control console. The method for adding the hardware resources has the advantages of high cost, high time consumption and low efficiency when the hardware resources are arranged.
Therefore, the inventor finds out in the research that in order to solve the problem of low interconnection efficiency between public clouds in the prior art, the interconnection operation can be performed on multiple clouds in a software-level mode. Specifically, a plurality of to-be-interconnected Kubernetes clusters in the cloud service are acquired first, and then interconnection operation is performed on each to-be-interconnected Kubernetes cluster. The specific operation of interconnection is to firstly determine a corresponding dispatching cluster and at least one dispatched cluster, wherein the dispatching cluster is a main cluster of interconnection, and data in the dispatched cluster can be dispatched after the interconnection is completed. In order to complete interconnection between the dispatching clusters and the dispatched clusters, access configuration information of the dispatched clusters needs to be obtained, so that corresponding dispatching nodes are generated through the dispatching clusters according to the access configuration information, and finally interconnection between the dispatching clusters and each dispatched cluster can be achieved according to the dispatching nodes. The multi-cloud interconnection method of the embodiment of the application can realize the interconnection of the Kubernetes clusters through the operation on a software layer, has shorter interconnection time, does not need to increase hardware resources, has lower cost compared with the interconnection mode after increasing the hardware resources, and has higher interconnection efficiency.
The inventor proposes the technical scheme of the application based on the creative discovery.
The application scenario of the multi-cloud interconnection method provided by the embodiment of the application is described below. As shown in fig. 1, 1 is an electronic device, and 2 is a plurality of clusters under cloud service. The network architecture of the application scenario corresponding to the multi-cloud interconnection method provided by the embodiment of the application comprises the following steps: an electronic device 1 and a plurality of clusters 2 under cloud services. Since in cloud architecture the cloud is made up of multiple nodes in a cluster. Thus, embodiments of the present application are illustrated with two clouds, two of the plurality of clusters 2 under cloud service. Among the plurality of clusters 2 under cloud service, there are cluster a and cluster B, both of which are Kubernetes clusters. When it is necessary to interconnect the cluster a and the cluster B, the electronic device 1 first determines, for the cluster a, the cluster a as a scheduled cluster and the cluster B as a scheduled cluster. And acquiring access configuration information corresponding to the scheduled cluster, and generating corresponding scheduling nodes according to the access configuration information through the scheduling cluster, so that interconnection between the scheduling cluster and the scheduled cluster, namely interconnection between the cluster A and the cluster B, is established according to the scheduling nodes. Then, the operation of the cluster A is repeated for the cluster B, so that the data of the other party can be called between the cluster A and the cluster B. The multi-cloud interconnection method of the embodiment of the application can realize the interconnection of the Kubernetes clusters through the operation on a software layer, has shorter interconnection time, does not need to increase hardware resources, has lower cost compared with the interconnection mode after increasing the hardware resources, and has higher interconnection efficiency.
Embodiments of the present application will now be described with reference to the accompanying drawings.
Fig. 2 is a flow chart of a method for multi-cloud interconnection according to a first embodiment of the present application, as shown in fig. 2, in this embodiment, an execution body of the embodiment of the present application is a multi-cloud interconnection device, and the multi-cloud interconnection device may be integrated in an electronic device. The multi-cloud interconnection method provided by the embodiment includes the following steps:
step S101, a plurality of to-be-interconnected Kubernetes clusters are obtained, and the to-be-interconnected Kubernetes clusters are located in corresponding cloud services.
In this embodiment, kubernetes is abbreviated as K8s, which is an abbreviation that replaces 8 characters "kubernete" with 8, and is an open source application for managing node calls and data processing of a cluster in a cloud service. The Kubernetes clusters to be interconnected refer to clusters managed by the Kubernetes system to be interconnected.
In this embodiment, the manner of acquiring the plurality of Kubernetes clusters to be interconnected may be acquired through a preset cluster database, or may also be acquired through other manners, which is not limited in this embodiment.
Step S102, corresponding dispatching clusters and at least one dispatched cluster are determined for each Kubernetes cluster to be interconnected, access configuration information corresponding to each dispatched cluster is obtained, corresponding dispatching nodes are generated through the dispatching clusters according to the access configuration information, and interconnection of the dispatching clusters and each dispatched cluster is established according to each dispatching node.
In this embodiment, the scheduling cluster refers to a cluster that can schedule other cluster data, where the other cluster is a scheduled cluster. If the acquired plurality of to-be-interconnected Kubernetes clusters are 2, the number of the scheduled clusters is 1, and if the plurality of to-be-interconnected Kubernetes clusters are 3, the number of the scheduled clusters can be 1 or 2. At least one of the scheduled clusters represents that, when the interconnection between the Kubernetes cluster and other Kubernetes clusters is constructed, the interconnection can be performed with some Kubernetes clusters or with all other Kubernetes clusters. The setting may be specifically performed according to actual requirements, which is not limited in this embodiment.
In this embodiment, the access configuration information corresponding to the scheduled cluster is configuration information required for accessing the scheduled cluster, where the access configuration information includes an access address of the scheduled cluster, user information, a namespace, and information of an identity authentication mechanism.
In this embodiment, the scheduling node is a node for scheduling the scheduled cluster data, and when a user needs to schedule the corresponding scheduled cluster data from the current scheduling cluster, a scheduling related instruction may be sent through the scheduling node, so as to return the corresponding scheduling data.
In this embodiment, each scheduling node corresponds to a scheduled cluster, for example, if there are 3 scheduled clusters, the number of scheduling nodes is also three, and each scheduling node in the three scheduling nodes corresponds to a scheduled cluster.
In this embodiment, after interconnection operation is performed on all Kubernetes clusters to be interconnected, a scheduling node having a plurality of corresponding scheduled clusters in each Kubernetes cluster is formed. For example, the Kubernetes clusters to be interconnected are a cluster a, a cluster b and a cluster c, after the interconnection operation of all the clusters is completed, the cluster a has a scheduling node b1 and a scheduling node c1, the cluster b has a scheduling node a1 and a scheduling node c2, and the cluster c has a scheduling node a2 and a scheduling node b2. Therefore, each Kubernetes cluster can schedule other Kubernetes clusters, and data sharing of cloud service is completed.
The embodiment of the application provides a multi-cloud interconnection method, which comprises the following steps: and acquiring a plurality of to-be-interconnected Kubernetes clusters, wherein the to-be-interconnected Kubernetes clusters are positioned in the corresponding cloud service. For each Kubernetes cluster to be interconnected, determining a corresponding scheduling cluster and at least one scheduled cluster, acquiring access configuration information corresponding to each scheduled cluster, generating corresponding scheduling nodes according to the access configuration information through the scheduling clusters, and establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node. According to the multi-cloud interconnection method provided by the embodiment of the application, a plurality of to-be-interconnected Kubernetes clusters in cloud service are firstly obtained, and then interconnection operation is carried out on each to-be-interconnected Kubernetes cluster. The specific operation of interconnection is to firstly determine a corresponding dispatching cluster and at least one dispatched cluster, wherein the dispatching cluster is a main cluster of interconnection, and data in the dispatched cluster can be dispatched after the interconnection is completed. In order to complete interconnection between the dispatching clusters and the dispatched clusters, access configuration information of the dispatched clusters needs to be obtained, so that corresponding dispatching nodes are generated through the dispatching clusters according to the access configuration information, and finally interconnection between the dispatching clusters and each dispatched cluster can be achieved according to the dispatching nodes. The multi-cloud interconnection method of the embodiment of the application can realize the interconnection of the Kubernetes clusters through the operation on a software layer, has shorter interconnection time, does not need to increase hardware resources, has lower cost compared with the interconnection mode after increasing the hardware resources, and has higher interconnection efficiency.
Fig. 3 is a schematic flow chart of a multi-cloud interconnection method according to a second embodiment of the present application, as shown in fig. 3, where each step of the multi-cloud interconnection method according to the present application is further refined based on the multi-cloud interconnection method according to the previous embodiment of the present application. The multi-cloud interconnection method provided in this embodiment includes the following steps.
Step S201, a plurality of Kubernetes clusters to be interconnected are obtained, and the Kubernetes clusters to be interconnected are located in the corresponding cloud services.
In this embodiment, the implementation manner of step 201 is similar to that of step 101 in the previous embodiment of the present application, and will not be described in detail here.
Step S202, for each Kubernetes cluster to be interconnected, determining the Kubernetes cluster to be interconnected as a scheduling cluster, and determining other clusters except the scheduling cluster in the plurality of Kubernetes clusters to be interconnected as scheduled clusters.
In this embodiment, when performing interconnection operation on each Kubernetes cluster to be interconnected, the currently processed Kubernetes cluster to be interconnected is used as a scheduling cluster. The scheduling cluster is a main cluster and is used for scheduling the data of the scheduled cluster. If the acquired plurality of to-be-interconnected Kubernetes clusters is 10, the number of the scheduled clusters is 9 Kubernetes clusters except the scheduling clusters.
In this embodiment, the interconnection between the Kubernetes cluster to be interconnected and other Kubernetes clusters to be interconnected, which are currently performing the interconnection operation, may be achieved by determining other clusters than the scheduling cluster in the plurality of Kubernetes clusters to be interconnected as the scheduled clusters.
It should be noted that steps 203 to 208 are further refinements to step 102.
Step S203, a kubeconfig file in each scheduled cluster is acquired.
In this embodiment, the kubeconfig file in the scheduled cluster stores the corresponding access configuration information, and by acquiring the kubeconfig file in each scheduled cluster, a foundation can be provided for subsequently establishing the interconnection relationship between the scheduled cluster and the scheduled cluster.
Step S204, analyzing the kubeconfig file to obtain corresponding access configuration information.
In this embodiment, since the kubeconfig file has a corresponding file format, the access configuration information stored in the file can be obtained by parsing the kubeconfig file.
Step S205, generating corresponding virtual nodes according to the access configuration information through Master nodes of the scheduling clusters.
In this embodiment, the Master node of the scheduling cluster is a Master node in the cluster and is responsible for managing task scheduling and data management of the whole cluster. The virtual nodes are different from the actual nodes, and only have the function of connecting the scheduled clusters. The scheduling cluster may schedule data of the scheduled cluster through the virtual nodes.
In this embodiment, the user information, the namespace, and the information of the identity authentication mechanism in the access configuration information may be used to identify the architecture inside the scheduled cluster, so that the overall scheduling efficiency is improved when the data is scheduled subsequently.
Optionally, in this embodiment, generating, by a Master node of the scheduling cluster, a corresponding virtual node according to the access configuration information includes:
and sending the access configuration information to a Master node of the scheduling cluster, so that the Master node generates a corresponding Virtual node through a Virtual Kubelet construction tool according to the access configuration information.
In this embodiment, the Virtual Kubelet construction tool is a tool for constructing a connection relationship between the cluster itself and other clusters in the Kubelet. The Virtual Kubelet building tool is a dedicated tool for Kubelet, and can improve the efficiency of building Virtual nodes for connecting scheduled clusters.
After the Virtual Kubelet building tool is used to generate the corresponding Virtual nodes, the architecture of the cluster is shown in fig. 4, wherein the cluster comprises three Kubernetes clusters, namely cluster a, cluster b and cluster c, and the Virtual nodes represent the Virtual nodes built by the Virtual Kubelet tool. Wherein cluster a schedules data of cluster b and cluster c through two virtual nodes, cluster b schedules data of cluster a and cluster c through two virtual nodes, and cluster c schedules data of cluster a and cluster b through two virtual nodes.
Step S206, determining the virtual node as a scheduling node.
In this embodiment, since the virtual node functions to establish a connection with the scheduled cluster, the virtual node may be determined as the scheduling node.
In this embodiment, the virtual nodes correspond to different scheduled clusters, and different labels may be created for these virtual nodes. The creation of the labels is similar to a naming scheme, as long as the scheduled clusters corresponding to different virtual nodes can be distinguished on the Master node.
Step S207, a mapping relation between each scheduling node and each scheduling cluster and each corresponding scheduled cluster is constructed.
In this embodiment, a one-to-one correspondence relationship between each scheduling node and each scheduled cluster can be realized by constructing a mapping relationship between each scheduling node and each scheduling cluster, and a corresponding scheduled cluster, so as to provide a foundation for interconnection between a subsequent scheduling cluster and a scheduled cluster.
Step S208, establishing interconnection between the dispatching clusters and each corresponding dispatched cluster through each dispatching node according to the mapping relation.
In this embodiment, since the mapping relationship between the scheduling cluster, each scheduling node, and each scheduled cluster is determined, interconnection between the scheduling cluster and each scheduled cluster can be established according to the mapping relationship.
Optionally, after establishing interconnection between the scheduling cluster and each scheduled cluster according to each scheduling node, the method further includes:
and receiving a cloud service instruction sent by the user terminal, and determining a scheduling node corresponding to the scheduled cluster according to the cloud service instruction.
And scheduling the data in the corresponding scheduled cluster according to the corresponding scheduling node.
And transmitting the data in the corresponding scheduled cluster to the user terminal.
In this embodiment, when the user needs the corresponding cloud service, the user may send the corresponding cloud service instruction from the terminal. At this time, the device corresponding to the method execution main body receives the cloud service instruction sent by the user terminal, so that the cluster to be scheduled can be determined according to the cloud service instruction. For example, the cloud service of the user needs to provide related data for the cluster b and the cluster c, and then the scheduled cluster can be identified as the cluster b and the cluster c through the cloud service instruction. Meanwhile, after the cluster b and the cluster c are identified, corresponding scheduling nodes can be determined, so that the data in the cluster b and the cluster c are scheduled according to the scheduling nodes, and the data in the scheduled cluster are sent to the terminal.
According to the multi-cloud interconnection method provided by the embodiment of the application, all the Kubernetes clusters are interconnected by interconnecting each to-be-interconnected Kubernetes cluster based on the Kubernetes clusters. First, for each Kubernetes cluster to be interconnected, the Kubernetes cluster to be interconnected is determined as a scheduling cluster, and other clusters other than the scheduling cluster in the plurality of Kubernetes clusters to be interconnected are determined as scheduled clusters. And aiming at the dispatching clusters, acquiring an access configuration file of a kubeconfig file corresponding to each dispatched cluster, thereby establishing a Virtual node corresponding to the dispatched clusters through a Master node and a Virtual Kubelet construction tool in the dispatching clusters according to the access configuration file, and further realizing interconnection of the dispatching clusters and the corresponding each dispatched clusters according to the Virtual nodes. According to the method, interconnection of the Kubernetes clusters can be better supported through the kubeconfig file, the Master node and the Virtual Kubelet construction tool in the Kubernetes clusters, so that efficiency of interconnection of all the Kubernetes clusters to be interconnected is improved.
Fig. 5 is a schematic structural diagram of a multi-cloud interconnection apparatus according to a third embodiment of the present application, as shown in fig. 5, in this embodiment, the multi-cloud interconnection apparatus 300 includes:
the acquiring module 301 is configured to acquire a plurality of to-be-interconnected Kubernetes clusters, where the to-be-interconnected Kubernetes clusters are located in corresponding cloud services.
The interconnection module 302 is configured to determine, for each Kubernetes cluster to be interconnected, a corresponding scheduling cluster and at least one scheduled cluster, obtain access configuration information corresponding to each scheduled cluster, generate, by using the scheduling cluster, a corresponding scheduling node according to the access configuration information, and establish interconnection between the scheduling cluster and each scheduled cluster according to each scheduling node.
The technical scheme of the method embodiment shown in fig. 2 may be executed by the multi-cloud interconnection apparatus provided in this embodiment, and the implementation principle and technical effects are similar to those of the method embodiment shown in fig. 2, and are not described in detail herein.
Fig. 6 is a schematic structural diagram of a cloudy interconnection device according to a fourth embodiment of the present application, and meanwhile, the cloudy interconnection device 400 provided by the present application is further refined on the basis of the cloudy interconnection device provided by the previous embodiment.
Optionally, in this embodiment, when determining, for each Kubernetes cluster to be interconnected, a corresponding scheduling cluster and at least one scheduled cluster, the interconnection module 302 is specifically configured to:
and determining the to-be-interconnected Kubernetes clusters as scheduling clusters for each to-be-interconnected Kubernetes cluster, and determining other clusters except the scheduling clusters in the plurality of to-be-interconnected Kubernetes clusters as scheduled clusters.
Optionally, in this embodiment, when generating, by the scheduling cluster, a corresponding scheduling node according to the access configuration information, the interconnection module 302 is specifically configured to:
and generating corresponding virtual nodes according to the access configuration information through Master nodes of the scheduling clusters. The virtual node is determined to be a scheduling node.
Optionally, in this embodiment, when generating, by using the Master node of the scheduling cluster, a corresponding virtual node according to the access configuration information, the interconnection module 302 is specifically configured to:
and sending the access configuration information to a Master node of the scheduling cluster, so that the Master node generates a corresponding Virtual node through a Virtual Kubelet construction tool according to the access configuration information.
Optionally, in this embodiment, when obtaining access configuration information corresponding to each scheduled cluster, the interconnection module 302 is specifically configured to:
the kubeconfig file in each scheduled cluster is obtained. And analyzing the kubeconfig file to acquire corresponding access configuration information.
Meanwhile, when the interconnection module 302 establishes interconnection between the scheduling cluster and each scheduled cluster according to each scheduling node, the interconnection module is specifically configured to: and constructing a mapping relation between each scheduling node and each scheduling cluster and each corresponding scheduled cluster. And establishing interconnection between the dispatching clusters and each corresponding dispatched cluster through each dispatching node according to the mapping relation.
Optionally, in this embodiment, the cloud interconnection apparatus 400 further includes:
the cloud service module 401 is configured to receive a cloud service instruction sent by a user terminal, and determine a scheduling node corresponding to a scheduled cluster according to the cloud service instruction. And scheduling the data in the corresponding scheduled cluster according to the corresponding scheduling node. And transmitting the data in the corresponding scheduled cluster to the user terminal.
The technical solution of the method embodiment shown in fig. 2 to 4 may be executed by the multi-cloud interconnection apparatus provided in this embodiment, and the implementation principle and the technical effect are similar to those of the method embodiment shown in fig. 2 to 4, which are not described in detail herein.
According to embodiments of the present application, the present application also provides an electronic device, a computer-readable storage medium, and a computer program product.
As shown in fig. 7, fig. 7 is a schematic structural diagram of an electronic device according to a fifth embodiment of the present application. Electronic devices are intended for various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular telephones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the applications described and/or claimed herein.
As shown in fig. 7, the electronic device includes: a processor 501, and a memory 502. The various components are interconnected using different buses and may be mounted on a common motherboard or in other manners as desired. The processor may process instructions executing within the electronic device.
Memory 502 is a non-transitory computer readable storage medium provided by the present application. The memory stores instructions executable by the at least one processor to cause the at least one processor to perform the multi-cloud interconnection method provided by the application. The non-transitory computer readable storage medium of the present application stores computer instructions for causing a computer to execute the multi-cloud interconnection method provided by the present application.
The memory 502 is used as a non-transitory computer readable storage medium for storing non-transitory software programs, non-transitory computer executable programs, and modules, such as program instructions/modules (e.g., the acquisition module 301 and the interconnection module 302 shown in fig. 5) corresponding to the multi-cloud interconnection method according to the embodiment of the present application. The processor 501 executes various functional applications of the server and data processing by running non-transitory software programs, instructions, and modules stored in the memory 502, i.e., implements the multi-cloud interconnection method in the method embodiments described above.
Meanwhile, the present embodiment also provides a computer product, which when executed by a processor of an electronic device, enables the electronic device to perform the multi-cloud interconnection method of the first and second embodiments.
Other implementations of the examples of the application will be apparent to those skilled in the art from consideration of the specification and practice of the application disclosed herein. This application is intended to cover any variations, uses, or adaptations of embodiments of the application following, in general, the principles of the embodiments of the application and including such departures from the present disclosure as come within known or customary practice within the art to which the embodiments of the application pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the embodiments being indicated by the following claims.
It is to be understood that the embodiments of the application are not limited to the precise arrangements and instrumentalities shown in the drawings, which have been described above, and that various modifications and changes may be made without departing from the scope thereof. The scope of embodiments of the application is limited only by the appended claims.

Claims (7)

1. A method of multi-cloud interconnection, comprising:
acquiring a plurality of to-be-interconnected Kubernetes clusters, wherein the to-be-interconnected Kubernetes clusters are positioned in corresponding cloud services;
determining a corresponding scheduling cluster and at least one scheduled cluster aiming at each to-be-interconnected Kubernetes cluster, acquiring access configuration information corresponding to each scheduled cluster, generating corresponding scheduling nodes according to the access configuration information through the scheduling clusters, and establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node;
the generating, by the scheduling cluster, a corresponding scheduling node according to the access configuration information includes:
sending the access configuration information to a Master node of the scheduling cluster, so that the Master node generates a corresponding Virtual node through a Virtual Kubelet construction tool according to the access configuration information;
and determining the virtual node as a scheduling node.
2. The method of claim 1, wherein the determining, for each Kubernetes cluster to be interconnected, a corresponding scheduling cluster and at least one scheduled cluster comprises:
and determining the to-be-interconnected Kubernetes clusters as scheduling clusters for each to-be-interconnected Kubernetes cluster, and determining other clusters except the scheduling clusters in the plurality of to-be-interconnected Kubernetes clusters as scheduled clusters.
3. The method of claim 1, wherein the obtaining access configuration information corresponding to each scheduled cluster comprises:
obtaining kubeconfig files in each scheduled cluster;
analyzing the kubeconfig file to obtain corresponding access configuration information;
the establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node comprises the following steps:
constructing a mapping relation between each scheduling node and each scheduling cluster and each corresponding scheduled cluster;
and establishing interconnection between the scheduling clusters and each scheduled cluster through each scheduling node according to the mapping relation.
4. A method according to any one of claims 1 to 3, wherein after said establishing interconnection of said scheduling clusters with corresponding each of said scheduled clusters according to each of said scheduling nodes, further comprising:
receiving a cloud service instruction sent by a user terminal, and determining a scheduling node corresponding to a scheduled cluster according to the cloud service instruction;
scheduling data in the corresponding scheduled cluster according to the corresponding scheduling node;
and sending the data in the corresponding scheduled cluster to the user terminal.
5. A multi-cloud interconnect device, comprising:
the acquisition module is used for acquiring a plurality of to-be-interconnected Kubernetes clusters, wherein the to-be-interconnected Kubernetes clusters are positioned in corresponding cloud services;
the interconnection module is used for determining a corresponding scheduling cluster and at least one scheduled cluster aiming at each to-be-interconnected Kubernetes cluster, acquiring access configuration information corresponding to each scheduled cluster, generating corresponding scheduling nodes according to the access configuration information through the scheduling clusters, and establishing interconnection between the scheduling clusters and each scheduled cluster according to each scheduling node;
the interconnection module is specifically configured to send the access configuration information to a Master node of the scheduling cluster, so that the Master node generates a corresponding Virtual node through a Virtual Kubelet construction tool according to the access configuration information; and determining the virtual node as a scheduling node.
6. An electronic device, comprising: a memory, a processor;
a memory; a memory for storing the processor-executable instructions;
wherein the processor is configured to perform the multi-cloud interconnection method of any of claims 1 to 4 by the processor.
7. A computer readable storage medium having stored therein computer executable instructions which when executed by a processor are for implementing a multi-cloud interconnection method as claimed in any of claims 1 to 4.
CN202110501525.3A 2021-05-08 2021-05-08 Multi-cloud interconnection method, device, equipment, storage medium and product Active CN113220432B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110501525.3A CN113220432B (en) 2021-05-08 2021-05-08 Multi-cloud interconnection method, device, equipment, storage medium and product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110501525.3A CN113220432B (en) 2021-05-08 2021-05-08 Multi-cloud interconnection method, device, equipment, storage medium and product

Publications (2)

Publication Number Publication Date
CN113220432A CN113220432A (en) 2021-08-06
CN113220432B true CN113220432B (en) 2023-11-21

Family

ID=77094095

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110501525.3A Active CN113220432B (en) 2021-05-08 2021-05-08 Multi-cloud interconnection method, device, equipment, storage medium and product

Country Status (1)

Country Link
CN (1) CN113220432B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113641503A (en) * 2021-09-01 2021-11-12 上海联蔚盘云科技有限公司 Multi-cloud multi-cluster Kubernetes management system, method and equipment
CN115633084A (en) * 2022-12-01 2023-01-20 苏州浪潮智能科技有限公司 K8s cluster access method and device and computer readable storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110851145A (en) * 2019-09-30 2020-02-28 烽火通信科技股份有限公司 Edge cloud installation and maintenance method and system based on container arrangement
CN111143673A (en) * 2019-12-19 2020-05-12 上海云角信息技术有限公司 Method and system for multi-channel customer information processing and automatic marketing
CN111522628A (en) * 2020-04-27 2020-08-11 上海仪电(集团)有限公司中央研究院 Kubernets cluster building and deploying method, architecture and storage medium based on OpenStack
CN112104723A (en) * 2020-09-07 2020-12-18 腾讯科技(深圳)有限公司 Multi-cluster data processing system and method

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109525624B (en) * 2017-09-20 2022-01-04 腾讯科技(深圳)有限公司 Container login method and device and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110851145A (en) * 2019-09-30 2020-02-28 烽火通信科技股份有限公司 Edge cloud installation and maintenance method and system based on container arrangement
CN111143673A (en) * 2019-12-19 2020-05-12 上海云角信息技术有限公司 Method and system for multi-channel customer information processing and automatic marketing
CN111522628A (en) * 2020-04-27 2020-08-11 上海仪电(集团)有限公司中央研究院 Kubernets cluster building and deploying method, architecture and storage medium based on OpenStack
CN112104723A (en) * 2020-09-07 2020-12-18 腾讯科技(深圳)有限公司 Multi-cluster data processing system and method

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
FLEDGE: Kubernetes Compatible Container Orchestration on Low-Resource Edge Devices;Tom Goethals 等;《IOV 2019: Internet of Vehicles. Technologies and Services Toward Smart Cities》;174-189 *
Kubernetes高可用集群的部署实践;盛乐标 等;《电脑知识与技术》;第14卷(第36期);40-43 *
基于阿里云的Kubernetes容器云平台的设计与实现;陈金光;《中国优秀硕士学位论文全文数据库 信息科技辑》;I139-395 *

Also Published As

Publication number Publication date
CN113220432A (en) 2021-08-06

Similar Documents

Publication Publication Date Title
WO2020177533A1 (en) Electronic invoice identifier allocation method, and electronic ticket generating method, device and system
CN113220432B (en) Multi-cloud interconnection method, device, equipment, storage medium and product
CN112398936B (en) Kubernetes-based multi-network card container implementation method and system
CN114281263B (en) Storage resource processing method, system and equipment of container cluster management system
CN110377369B (en) Method, device and computer storage medium for running small program
CN113849312A (en) Data processing task allocation method and device, electronic equipment and storage medium
CN109743202B (en) Data management method, device and equipment and readable storage medium
EP2842044A1 (en) Platform runtime abstraction
CN113766042A (en) Container address configuration method, system, device, equipment and medium
CN112491980A (en) Cloud host service management method, system, terminal and storage medium
US11645109B2 (en) Managing failures in edge computing environments
CN110798358B (en) Distributed service identification method and device, computer readable medium and electronic equipment
CN115859261A (en) Password cloud service method, platform, equipment and storage medium
CN115658332A (en) GPU (graphics processing Unit) sharing method and device, electronic equipment and storage medium
CN115665231A (en) Service creation method, device and computer-readable storage medium
US11494239B2 (en) Method for allocating computing resources, electronic device, and computer program product
CN109614242B (en) Computing capacity sharing method, device, equipment and medium
CN110300131B (en) Routing method, device, equipment and system for multiple services of wind power plant
CN113779122A (en) Method and apparatus for exporting data
CN112463748A (en) Storage system file lock identification method, system, terminal and storage medium
CN113556370A (en) Service calling method and device
CN114461228B (en) Object generation method, device, equipment, system and readable storage medium
CN113179308B (en) Service request processing method and device, electronic equipment and storage medium
CN117608746A (en) Virtual machine network equipment creation method, device, equipment and storage medium
CN116800808A (en) GPU resource calling method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant