Communication method, device, storage disaster recovery system, electronic equipment and storage medium
By obtaining and matching the hardware and software attributes of the device cluster, compatible communication interfaces are automatically determined, which solves the interface compatibility problem between storage clusters and disaster recovery clusters in enterprise-level data centers, improves processing efficiency and reduces R&D personnel dependency.
Patent Information
- Application Number
- CN202211067350.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-01
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2042-09-01
AI Technical Summary
There is an interface compatibility problem between storage clusters and disaster recovery clusters in enterprise-level data centers. The existing solutions rely on manual design, which are inefficient and have high requirements.
By obtaining the hardware and software attributes of the device cluster, matching communication capability information is determined, thereby automatically determining compatible communication interfaces to achieve interface compatibility between different device clusters.
It improves the efficiency of interface compatibility processing, reduces the need for R&D personnel's design capabilities, and realizes automated processing of interface compatibility.
Smart Images

Figure CN115484277B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical fields of cloud computing and data storage, and in particular to a communication method, device, storage disaster recovery system, electronic equipment and storage medium. Background Art
[0002] There are always interface compatibility issues in the communication between different device clusters. For example, there are interface compatibility issues between storage clusters and disaster recovery clusters in enterprise-level data centers. Currently, most of the methods to solve interface compatibility are manually solved by R&D personnel according to actual needs. This not only requires R&D personnel to have high design capabilities, but also requires continuous maintenance of interface compatibility. This processing method is difficult to meet the needs of data centers for interface compatibility in storage disaster recovery scenarios. It is inefficient and demanding. Summary of the invention
[0003] The embodiments of the present application provide a communication method, apparatus, storage disaster recovery system, electronic device and storage medium to automatically achieve interface compatibility between different device clusters, improve the efficiency of interface compatibility processing, and reduce the demand for design capabilities of R&D personnel.
[0004] In a first aspect, an embodiment of the present application provides a communication method of a device cluster, which is applied to a local device cluster, and the method includes:
[0005] Acquire a first cluster attribute of the local device cluster and a second cluster attribute of the opposite device cluster;
[0006] respectively determining first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute;
[0007] A communication interface for sending communication information from the local device cluster to the opposite device cluster is determined according to the first communication capability information and the second communication capability information; wherein the communication interface includes an information sending interface used by the local device cluster to send the communication information, and an information receiving interface used by the opposite device cluster to receive the communication information.
[0008] In a possible implementation manner, the acquiring the first cluster attribute of the local device cluster includes:
[0009] Acquire the hardware attributes of the local device cluster and the software attributes of the software used by the local device cluster;
[0010] A first cluster attribute of the local device cluster is determined according to the hardware attribute and the software attribute.
[0011] In a possible implementation manner, the hardware attributes of the local device cluster include at least one of the following: processor information, memory information, network information, and interface information of the local device cluster;
[0012] The software attributes include version information of the software used by the local device cluster.
[0013] In a possible implementation manner, obtaining the second cluster attribute of the peer device cluster includes:
[0014] Sending an attribute acquisition request to the peer device cluster;
[0015] The second cluster attribute fed back by the peer device cluster according to the attribute acquisition request is received.
[0016] In a possible implementation manner, the separately determining first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute includes:
[0017] Acquire, from a communication information database, first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute;
[0018] The communication information database stores a matching relationship between at least one cluster attribute and communication capability information.
[0019] In a possible implementation manner, the first communication capability information includes information about at least one communication interface supported by the local device cluster; the second communication capability information includes information about at least one communication interface supported by the opposite device cluster;
[0020] The determining, according to the first communication capability information and the second communication capability information, a communication interface through which the local device cluster sends communication information to the opposite device cluster includes:
[0021] The first communication capability information is matched with the second communication capability information, and the communication interfaces having a matching relationship are used as information sending interfaces used by the local device cluster to send communication information and information receiving interfaces used by the opposite device cluster to receive communication information.
[0022] In a possible implementation manner, the first communication capability information includes information about at least one communication interface supported by the local device cluster; the second communication capability information includes information about at least one communication interface supported by the opposite device cluster;
[0023] The determining, according to the first communication capability information and the second communication capability information, a communication interface through which the local device cluster sends communication information to the opposite device cluster includes:
[0024] According to the first communication capability information and the second communication capability information, the communication interface supported by the local device cluster and the communication interface supported by the opposite device cluster are intersected to obtain an information sending interface used by the local device cluster to send communication information and an information receiving interface used by the opposite device cluster to receive communication information.
[0025] In a second aspect, an embodiment of the present application provides a storage cluster communication method, which is applied to a local storage cluster, and the method includes:
[0026] Acquire a third cluster attribute of the local storage cluster and a fourth cluster attribute of the opposite storage cluster;
[0027] respectively determining third communication capability information matching the third cluster attribute and fourth communication capability information matching the fourth cluster attribute;
[0028] According to the third communication capability information and the fourth communication capability information, a communication interface for the local storage cluster to send communication information to the opposite storage cluster is determined; wherein the communication interface includes an information sending interface used by the local storage cluster to send the communication information, and an information receiving interface used by the opposite storage cluster to receive the communication information.
[0029] In a third aspect, an embodiment of the present application provides a communication device, which is applied to a local device cluster, and the device includes:
[0030] A first acquisition module, used to acquire a first cluster attribute of the local device cluster and a second cluster attribute of the opposite device cluster;
[0031] A first determination module, configured to respectively determine first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute;
[0032] A first interface screening module is used to determine, based on the first communication capability information and the second communication capability information, a communication interface through which the local device cluster sends communication information to the opposite device cluster; wherein the communication interface includes an information sending interface used by the local device cluster to send the communication information, and an information receiving interface used by the opposite device cluster to receive the communication information.
[0033] In a fourth aspect, an embodiment of the present application provides a communication device, which is applied to a local storage cluster, and the device includes:
[0034] A second acquisition module, used to acquire a third cluster attribute of the local storage cluster and a fourth cluster attribute of the opposite storage cluster;
[0035] a second determination module, configured to respectively determine third communication capability information matching the third cluster attribute and fourth communication capability information matching the fourth cluster attribute;
[0036] The second interface screening module determines the communication interface through which the local storage cluster sends communication information to the opposite storage cluster according to the third communication capability information and the fourth communication capability information; wherein the communication interface includes an information sending interface used by the local storage cluster to send the communication information, and an information receiving interface used by the opposite storage cluster to receive the communication information.
[0037] In a fifth aspect, an embodiment of the present application provides a storage disaster recovery system, comprising a local storage cluster that executes the above-mentioned storage cluster communication method, and a peer storage cluster; wherein the peer storage cluster is a disaster recovery storage cluster of the local storage cluster.
[0038] In a sixth aspect, an embodiment of the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory, wherein the processor implements any of the methods described above when executing the computer program.
[0039] In a seventh aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, any of the methods described above is implemented.
[0040] Compared with the prior art, this application has the following advantages:
[0041] According to the embodiment of the present application, first, the local device cluster obtains its own first cluster attribute and the second cluster attribute of the opposite device cluster; then, the local device cluster determines the first communication capability information of the local device cluster according to the first cluster attribute, and determines the second communication capability information of the opposite device cluster according to the second cluster attribute; finally, the local device cluster determines the communication interface for the local device cluster to send communication information to the opposite device cluster according to the first communication capability information and the second communication capability information; wherein the communication interface here includes the information sending interface used by the local device cluster to send the communication information, and the information receiving interface used by the opposite device cluster to receive the communication information. The above-mentioned interface compatibility processing method can determine the communication capability information that matches the hardware and software characteristics of the device cluster itself according to the cluster attributes of the device cluster itself, and the communication capability information can be used to accurately determine the communication interface that is compatible with both device clusters, that is, the communication interface for the local device cluster to send communication information to the opposite device cluster, thereby realizing the automatic processing of interface compatibility, while improving the efficiency of interface compatibility processing and reducing the design capability requirements of R&D personnel.
[0042] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] In the accompanying drawings, unless otherwise specified, the same reference numerals throughout the multiple drawings represent the same or similar parts or elements. These drawings are not necessarily drawn to scale. It should be understood that these drawings only depict some embodiments according to the present application and should not be regarded as limiting the scope of the present application.
[0044] Figure 1 A schematic diagram of a communication scheme provided for this application;
[0045] Figure 2 A flow chart of a communication method executed by a local device cluster according to an embodiment of the present application;
[0046] Figure 3 An architecture diagram of a system for executing a communication method according to an embodiment of the present application;
[0047] Figure 4 It is a flow chart of a communication method executed by a local storage cluster according to an embodiment of the present application;
[0048] Figure 5 is a structural block diagram of a communication device according to an embodiment of the present application;
[0049] Figure 6is a structural block diagram of a communication device according to another embodiment of the present application;
[0050] Figure 7 is a structural block diagram of a disaster recovery system according to an embodiment of the present application;
[0051] Figure 8 A block diagram of an electronic device used to implement an embodiment of the present application. DETAILED DESCRIPTION
[0052] In the following, only some exemplary embodiments are briefly described. As those skilled in the art will appreciate, the described embodiments may be modified in various ways without departing from the concept or scope of the present application. Therefore, the drawings and descriptions are considered to be exemplary in nature and not restrictive.
[0053] To facilitate understanding of the technical solutions of the embodiments of the present application, the following describes the related technologies of the embodiments of the present application. The following related technologies can be combined with the technical solutions of the embodiments of the present application as optional solutions, and they all belong to the protection scope of the embodiments of the present application.
[0054] Before describing the communication method and apparatus of the device cluster, the communication method and apparatus of the storage cluster, and the storage disaster recovery system to be protected by the present application, an application scenario of the present application and the concepts that may be involved are first described.
[0055] Block storage refers to adding a controller and a group of disk drives to a redundant array of independent disks (RAID), and controlling and using the disks in the redundant array of independent disks through the controller and disk drives.
[0056] Block storage uses mapping to map a redundant array of independent disks to multiple logical hard disks, and then allocates the mapped logical hard disks to the host. The operating system on the host will recognize the multiple logical hard disks allocated, but the operating system cannot distinguish whether these hard disks are logical hard disks or physical hard disks. It considers these hard disks to be physical hard disks, which is no different from directly mounting a physical hard disk to the operating system.
[0057] In the block storage disaster recovery scenario, there are at least two storage clusters based on block storage, one of which can be used as the production storage cluster, and the other storage cluster as the disaster recovery storage cluster. When the production storage cluster fails, the disaster recovery storage cluster replaces the production storage cluster. Figure 1 As shown in Figure 1, both the production storage cluster and the disaster recovery storage cluster include multiple disks, which form the RAID of the corresponding storage cluster. Figure 1 The production storage cluster and the disaster recovery storage cluster shown in the figure both include hardware based on microprocessors. Specifically, the production storage cluster includes hardware based on X86, and the disaster recovery storage cluster includes hardware based on other microprocessors. The hardware of the production storage cluster includes a central processing unit (CPU), memory, internet network, transmission medium, and interface adapter. Figure 1 As shown, the production-end storage cluster and the disaster-recovery-end storage cluster each include disaster-recovery software for performing disaster-recovery processing.
[0058] according to Figure 1 It can be seen that the storage cluster at the production end and the storage cluster at the disaster recovery end may have hardware heterogeneity, such as different microprocessors, and may also have software heterogeneity, such as large differences in the versions of disaster recovery software, which brings difficulties to the interface compatibility between storage clusters. In order to solve this technical problem, the present application provides a communication method, device, storage disaster recovery system, electronic device and storage medium. The embodiment of the present application can determine the communication capability information that matches the hardware and software characteristics of the storage cluster itself according to the cluster attributes of the storage cluster itself. The communication capability information can be used to accurately determine the communication interface that is compatible with both storage clusters. The embodiment of the present application realizes the automatic processing of interface compatibility, while improving the efficiency of interface compatibility processing and reducing the demand for the design capabilities of R&D personnel.
[0059] The following describes the communication method and apparatus of the device cluster, the communication method and apparatus of the storage cluster, the storage disaster recovery system, etc. of the present application.
[0060] like Figure 2 As shown, the embodiment of the present application provides a communication method of a device cluster, which is applied to a local device cluster. The method may include the following steps:
[0061] S210. Obtain a first cluster attribute of the local device cluster and a second cluster attribute of the opposite device cluster. S220. Determine first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute respectively. S230. Determine a communication interface for the local device cluster to send communication information to the opposite device cluster based on the first communication capability information and the second communication capability information; wherein the communication interface includes an information sending interface used by the local device cluster to send the communication information and an information receiving interface used by the opposite device cluster to receive the communication information.
[0062] The local device cluster can be Figure 1The production-end storage cluster in the example may also be any cluster that needs to communicate with other devices or other device clusters. For example, the local device cluster may also be a cluster formed by multiple servers for data processing. In addition, the local device cluster may include only one device, in which case the local device cluster is a local device. This application does not limit the type and number of devices included in the local device cluster.
[0063] Similarly, the peer device cluster can be Figure 1 The disaster recovery end storage cluster in the present invention is a cluster that needs to communicate with the local device cluster. The peer device cluster may also include only one device, in which case the peer device cluster is a peer device. In addition, the peer device cluster is not limited to a storage cluster. For example, the peer device cluster may also be a cluster formed by multiple servers for data processing. The present application does not limit the type and number of devices included in the peer device cluster.
[0064] The above-mentioned first cluster attribute can be used to characterize the hardware and / or software characteristics of the local device cluster. Specifically, the first cluster attribute can directly include at least part of the information in the hardware attributes of the local device cluster and at least part of the information in the software attributes of the software used by the local device cluster. It can also be obtained after the local device cluster processes its hardware attributes and software attributes.
[0065] The above-mentioned hardware attributes may include at least one of the processor information, memory information, network information, and interface information of the local device cluster. Exemplarily, the memory information of the local device cluster may specifically include the model of the central processing unit CPU used by the local device cluster and the resource quota for the CPU; the memory information may include the model of the memory used by the local device cluster and the resource quota for the memory; the network information may include the model of the network card of the Internet network used by the local device cluster and the bandwidth quota; the interface information may include the interface card model of the interface adapter used by the local device cluster, the interface quota, the interface card version information version, etc. In addition, the above-mentioned hardware attributes may also include the type of DISK in the local device cluster, the capacity quota of DISK, the type of transmission medium medium, and other information. The above-mentioned hardware attributes can more comprehensively and accurately characterize the hardware characteristics of the local device cluster.
[0066] The software attributes of the software used by the local device cluster may specifically include at least one of the version information and the type information of the software used by the local device cluster. Figure 1In the case of the production end storage cluster shown, the software used by the local device cluster may be disaster recovery software, and the software attributes include version information and type information of the disaster recovery software. The above software attributes can more accurately characterize the software features of the local device cluster.
[0067] like Figure 3 As shown, a disaster recovery function set version manager (DisasterTolerance Function-Set-Version Manager, DTFM) can be set in the local device cluster. The local device cluster uses the DTFM to obtain the above-mentioned hardware attributes and software attributes of the local device cluster, and processes the obtained hardware attributes and software attributes to obtain the first cluster attributes of the local device cluster.
[0068] Exemplarily, the above-mentioned first cluster attribute can exist in the form of disaster recovery communication interface set version information (disaster recovery communication interface set version information, FSV), and the FSV includes two pieces of information, one of which can be the hardware type information of the local device cluster determined by DTFM based on the hardware attributes of the local device cluster, and can also be at least part of the information filtered by DTFM from the above-mentioned hardware attribute information; the other piece of information in the FSV can be the software identification information determined by DTFM based on the software attributes of the local device cluster, and can also be at least part of the information filtered by DTFM from the above-mentioned software attributes, for example, the other piece of information in the FSV is the version information filtered from the above-mentioned software attributes.
[0069] When DTFM determines the hardware type information based on the hardware attributes of the local device cluster, it can be implemented specifically using the following steps: first, a first mapping relationship between the hardware attributes and the hardware type information is obtained. The first mapping relationship is pre-set and can be set using the above-mentioned DTFM, and of course, it can also be set using other devices in the local device cluster. Afterwards, based on the obtained hardware attributes of the local device cluster and the first mapping relationship, the hardware type information that matches the hardware attributes can be determined, that is, the hardware type information of the local device cluster is obtained.
[0070] When DTFM determines the software identification information based on the software attributes of the local device cluster, it can be implemented specifically using the following steps: first, a second mapping relationship between the software attributes and the software identification information is obtained. The second mapping relationship is pre-set and can be set using the above-mentioned DTFM, and of course, it can also be set using other devices in the local device cluster; thereafter, based on the obtained software attributes of the local device cluster and the second mapping relationship, the software identification information that matches the software attributes can be determined, that is, the software identification information of the local device cluster is obtained.
[0071] After obtaining the two pieces of information of the FSV, the DTFM of the local device cluster concatenates the two pieces of information to obtain the FSV of the local device cluster. Then, the DTFM of the local device cluster stores its own FSV.
[0072] The above-mentioned second cluster attribute can be used to characterize the hardware and / or software characteristics of the peer device cluster. Specifically, the second cluster attribute may include at least part of the information in the hardware attributes of the peer device cluster and at least part of the information in the software attributes of the software used by the peer device cluster. It may also be obtained after the peer device cluster processes its hardware attributes and software attributes.
[0073] The above hardware attributes may include at least one of the processor information, memory information, network information, and interface information of the peer device cluster. Exemplarily, the memory information of the peer device cluster may specifically include the model of the central processing unit CPU used by the peer device cluster and the resource quota for the CPU; the memory information may include the model of the memory used by the peer device cluster and the resource quota for the memory; the network information may include the model of the network card of the Internet network used by the peer device cluster and the bandwidth quota; the interface information may include the interface card model, interface quota, and interface card version information of the interface adapter used by the peer device cluster. In addition, the above hardware attributes may also include information such as the type of DISK in the peer device cluster, the capacity quota of DISK, and the type of transmission medium medium. The above hardware attributes can more comprehensively and accurately characterize the hardware characteristics of the peer device cluster.
[0074] The software attributes of the software used by the peer device cluster may specifically include at least one of the version information and software type information of the software used by the peer device cluster. Figure 1 When the disaster recovery end storage cluster is shown, the software used by the peer device cluster may be disaster recovery software, and the software attributes include version information and type information of the disaster recovery software. The above software attributes can more accurately characterize the software features of the peer device cluster.
[0075] like Figure 3 As shown, the peer device cluster may also be provided with DTFM, and the peer device cluster uses the DTFM to obtain the hardware attributes and software attributes of the peer device cluster, and processes the obtained hardware attributes and software attributes to obtain the second cluster attributes of the peer device cluster.
[0076] Exemplarily, the above-mentioned second cluster attribute can also exist in the form of FSV, which includes two pieces of information, one of which can be the hardware type information of the peer device cluster determined by DTFM based on the hardware attributes of the peer device cluster, and can also be at least part of the information filtered by DTFM from the hardware attribute information of the peer device cluster; the other piece of information in the FSV can be the software identification information determined by DTFM based on the software attributes of the peer device cluster, and can also be at least part of the information filtered by DTFM from the software attributes of the peer device cluster, for example, the other piece of information in the FSV is the version information filtered from the software attributes of the above-mentioned peer device cluster.
[0077] When DTFM determines the hardware type information based on the hardware attributes of the peer device cluster, it can be implemented specifically using the following steps: first, a third mapping relationship between the hardware attributes and the hardware type information is obtained. The third mapping relationship is pre-set and can be set using the DTFM in the peer device cluster, and of course, it can also be set using other devices in the peer device cluster; thereafter, based on the obtained hardware attributes of the peer device cluster and the third mapping relationship, the hardware type information that matches the hardware attributes can be determined, that is, the hardware type information of the peer device cluster is obtained.
[0078] When DTFM determines the software identification information based on the software attributes of the peer device cluster, it can be implemented specifically using the following steps: first, the fourth mapping relationship between the software attributes and the software identification information is obtained. The fourth mapping relationship is pre-set and can be set using the DTFM in the peer device cluster, and of course, it can also be set using other devices in the peer device cluster; thereafter, based on the obtained software attributes of the peer device cluster and the fourth mapping relationship, the software identification information that matches the software attributes can be determined, that is, the software identification information of the peer device cluster is obtained.
[0079] After obtaining the two pieces of information of the FSV, the DTFM of the peer device cluster concatenates the two pieces of information to obtain the FSV of the peer device cluster. Then, the DTFM of the peer device cluster stores its own FSV.
[0080] In some embodiments, the above-mentioned obtaining of the first cluster attribute of the local device cluster and the second cluster attribute of the opposite device cluster may be implemented by the following steps:
[0081] When the local device cluster has a communication demand, it will obtain its own FSV, that is, the first cluster attribute, from its own storage, and send an attribute acquisition request to the opposite device cluster; after receiving the attribute acquisition request, the opposite device cluster will obtain the FSV, that is, the second cluster attribute, from its own storage, and feed back the obtained second cluster attribute to the local device cluster; the local device cluster receives the second cluster attribute fed back by the opposite device cluster.
[0082] For example, Figure 3 As shown, the DTFM of the local device cluster obtains its own FSV from its own memory, and sends an attribute acquisition request to the DTFM of the opposite device cluster; after receiving the attribute acquisition request, the DTFM of the opposite device cluster obtains the FSV from its own storage, and feeds back the obtained FSV to the DTFM of the local device cluster; the DTFM of the local device cluster receives the FSV fed back by the opposite device cluster.
[0083] In some embodiments, the above-mentioned respectively determining the first communication capability information matching the first cluster attribute and the second communication capability information matching the second cluster attribute may be specifically implemented by the following steps:
[0084] The local device cluster obtains first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute from a communication information database; wherein the communication information database stores a matching relationship between at least one cluster attribute and communication capability information.
[0085] The first communication capability information includes information about at least one communication interface supported by the local device cluster; exemplarily, the first communication capability information includes at least one of the following: an identifier and version information of at least one communication interface supported by the local device cluster. The second communication capability information includes information about at least one communication interface supported by the opposite device cluster; exemplarily, the second communication capability information includes at least one of the following: an identifier and version information of at least one communication interface supported by the opposite device cluster.
[0086] The matching relationship between cluster attributes and communication capability information in the above communication information database is preset, such as Figure 3 As shown, the communication information database stores communication capability information matching the attributes of each cluster. The above communication information database may exist independently or in the local device cluster and / or the back-end device cluster.
[0087] In some embodiments, Figure 3As shown, a disaster recovery negotiation module is provided in the local device cluster, which is used to set a matching relationship between the cluster attributes of the local device cluster and the communication capability information, and store the matching relationship in the communication information database using the Disaster Tolerance Negotiation Protocol (DTNP).
[0088] like Figure 3 As shown, a disaster recovery negotiation module is also provided in the peer device cluster, which is used to set a matching relationship between the cluster attributes of the peer device cluster and the communication capability information, and store the matching relationship in the communication information database using the Disaster Tolerance Negotiation Protocol (DTNP).
[0089] like Figure 3 As shown, when the local device cluster has a communication demand, the local device cluster uses its own DTFM to obtain its own first cluster attribute and the second cluster attribute of the opposite device cluster, and then DTFM will send a communication capability acquisition request to DTNP based on the first cluster attribute and the second cluster attribute. DTNP parses the communication capability acquisition request to obtain the first cluster attribute and the second cluster attribute, and obtains the first communication capability information of the local device cluster and the second communication capability information of the opposite device cluster from the communication information database based on the first cluster attribute and the second cluster attribute. Finally, DTNP feeds back the obtained first communication capability information and the second communication capability information to DTFM.
[0090] After the local device cluster obtains the first communication capability information of the local device cluster and the second communication capability of the opposite device cluster, the local device cluster can determine the communication interface through which the local device cluster sends communication information to the opposite device cluster in the following two ways:
[0091] Method 1: Match the first communication capability information with the second communication capability information, and use the matching communication interfaces as the information sending interface used by the local device cluster to send communication information and the information receiving interface used by the opposite device cluster to receive communication information.
[0092] Exemplarily, the first communication capability information includes the version information of the communication interface of the local device cluster, and the second communication capability information includes the version information of the communication interface of the opposite device cluster. The communication interfaces with a matching relationship can be two communication interfaces with the same version, or two communication interfaces with a version compatibility relationship. However, it is necessary to ensure that the version of the communication interface of the opposite device cluster is higher than the version of the communication interface of the local device cluster, that is, it is necessary to ensure that the version of the information receiving interface is higher than the version of the information sending interface, so that the opposite device cluster can accurately parse the received communication information.
[0093] Exemplarily, the local device cluster uses DTFM to match the first communication capability information with the second communication capability information to obtain a communication interface with a matching relationship.
[0094] Method 2: Based on the first communication capability information and the second communication capability information, the communication interface supported by the local device cluster and the communication interface supported by the opposite device cluster are intersected to obtain the information sending interface used by the local device cluster to send communication information and the information receiving interface used by the opposite device cluster to receive communication information.
[0095] Exemplarily, the first communication capability information includes an identifier of the communication interface of the local device cluster, and the second communication capability information includes an identifier of the communication interface of the opposite device cluster. Specifically, the identifier of the communication interface supported by the local device cluster and the identifier of the communication interface supported by the opposite device cluster can be intersected to obtain the communication interface supported by both the local device cluster and the opposite device cluster, that is, the information sending interface used by the local device cluster to send communication information and the information receiving interface used by the opposite device cluster to receive communication information.
[0096] Exemplarily, the local device cluster uses DTFM to implement the above intersection processing to obtain a communication interface supported by both the local device cluster and the opposite device cluster.
[0097] The above communication interface is a cluster-level communication interface, which is managed by the device cluster to which it belongs. It can be a communication interface set by the device cluster or a communication interface of a device in the cluster.
[0098] The communication method of the above embodiment combines the hardware attributes and software attributes of the device cluster to determine the communication interface for communication between device clusters, overcoming the defect of the related technology that the communication interface is difficult to be compatible due to the hardware heterogeneity of the two device clusters or the large difference in the software used, and effectively ensures the compatibility of the communication interfaces between multiple device clusters in hardware heterogeneous and software heterogeneous scenarios.
[0099] In the above embodiments, it has been explained that both the local device cluster and the opposite device cluster can be storage clusters formed based on block storage. In this case, the local device cluster is the local storage cluster, and the opposite device cluster is the opposite storage cluster. The local storage cluster can execute the same or similar communication method as the local device cluster in the above embodiments. Figure 4 The flowchart of the communication method performed by the local storage cluster is shown below:
[0100] S410: Obtain a third cluster attribute of the local storage cluster and a fourth cluster attribute of the opposite storage cluster.
[0101] S420: Determine third communication capability information matching the third cluster attribute and fourth communication capability information matching the fourth cluster attribute respectively.
[0102] S430. Determine, based on the third communication capability information and the fourth communication capability information, a communication interface through which the local storage cluster sends communication information to the opposite storage cluster; wherein the communication interface includes an information sending interface used by the local storage cluster to send the communication information, and an information receiving interface used by the opposite storage cluster to receive the communication information.
[0103] Since the communication method executed by the local storage cluster is the same as or similar to the communication method executed by the local device cluster in the above embodiment, the repeated steps will not be described again.
[0104] Corresponding to the application scenario and method of the method provided in the embodiment of the present application, the embodiment of the present application also provides a communication device applied to a local device cluster. Figure 5 The structure block diagram of a communication device applied to a local device cluster according to an embodiment of the present application is shown, and the communication device may include:
[0105] The first acquisition module 510 is configured to acquire a first cluster attribute of the local device cluster and a second cluster attribute of the opposite device cluster.
[0106] The first determination module 520 is configured to respectively determine first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute.
[0107] The first interface screening module 530 is used to determine the communication interface through which the local device cluster sends communication information to the opposite device cluster based on the first communication capability information and the second communication capability information; wherein the communication interface includes the information sending interface used by the local device cluster to send the communication information, and the information receiving interface used by the opposite device cluster to receive the communication information.
[0108] In some embodiments, when acquiring the first cluster attribute of the local device cluster, the first acquisition module 510 is used to:
[0109] Acquire the hardware attributes of the local device cluster and the software attributes of the software used by the local device cluster;
[0110] A first cluster attribute of the local device cluster is determined according to the hardware attribute and the software attribute.
[0111] In some embodiments, the hardware attributes of the local device cluster include at least one of the following: processor information, memory information, network information, and interface information of the local device cluster; the software attributes include version information of the software used by the local device cluster.
[0112] In some embodiments, when acquiring the second cluster attribute of the peer device cluster, the first acquisition module 510 is used to:
[0113] Sending an attribute acquisition request to the peer device cluster;
[0114] The second cluster attribute fed back by the peer device cluster according to the attribute acquisition request is received.
[0115] In some embodiments, when the first determination module 520 determines the first communication capability information matching the first cluster attribute and the second communication capability information matching the second cluster attribute respectively, it is used to:
[0116] Acquire, from a communication information database, first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute;
[0117] The communication information database stores a matching relationship between at least one cluster attribute and communication capability information.
[0118] In some embodiments, the first communication capability information includes information about at least one communication interface supported by the local device cluster; and the second communication capability information includes information about at least one communication interface supported by the opposite device cluster.
[0119] When determining the communication interface through which the local device cluster sends communication information to the opposite device cluster according to the first communication capability information and the second communication capability information, the first interface screening module 530 is used to:
[0120] The first communication capability information is matched with the second communication capability information, and the communication interfaces having a matching relationship are used as information sending interfaces used by the local device cluster to send communication information and information receiving interfaces used by the opposite device cluster to receive communication information.
[0121] In some embodiments, the first communication capability information includes information about at least one communication interface supported by the local device cluster; and the second communication capability information includes information about at least one communication interface supported by the opposite device cluster.
[0122] When determining the communication interface through which the local device cluster sends communication information to the opposite device cluster according to the first communication capability information and the second communication capability information, the first interface screening module 530 is used to:
[0123] According to the first communication capability information and the second communication capability information, the communication interface supported by the local device cluster and the communication interface supported by the opposite device cluster are intersected to obtain an information sending interface used by the local device cluster to send communication information and an information receiving interface used by the opposite device cluster to receive communication information.
[0124] Corresponding to the application scenario and method of the method provided in the embodiment of the present application, the embodiment of the present application also provides a communication device applied to the local storage cluster. Figure 6 The structure block diagram of a communication device applied to a local storage cluster according to an embodiment of the present application is shown, which may include:
[0125] The second acquisition module 610 is configured to acquire a third cluster attribute of the local storage cluster and a fourth cluster attribute of the opposite storage cluster.
[0126] The second determination module 620 is configured to respectively determine third communication capability information matching the third cluster attribute and fourth communication capability information matching the fourth cluster attribute.
[0127] The second interface screening module 630 determines the communication interface through which the local storage cluster sends communication information to the opposite storage cluster according to the third communication capability information and the fourth communication capability information; wherein the communication interface includes an information sending interface used by the local storage cluster to send the communication information, and an information receiving interface used by the opposite storage cluster to receive the communication information.
[0128] The second acquisition module 610 in this embodiment performs the same or similar method steps as the first acquisition module 510 in the above embodiment, and the same parts are not repeated here.
[0129] The second determination module 620 in this embodiment performs the same or similar method steps as the first determination module 520 in the above embodiment, and the same parts will not be repeated here.
[0130] The second interface screening module 630 in this embodiment performs the same or similar method steps as the first interface screening module 530 in the above embodiment, and the same parts will not be repeated here.
[0131] The functions of each module in each device in the embodiments of the present application can be found in the corresponding description in the above method, and have corresponding beneficial effects, which will not be repeated here.
[0132] Corresponding to the application scenario and method of the method provided in the embodiment of the present application, the embodiment of the present application also provides a disaster recovery system. Figure 7 The structure block diagram of the disaster recovery system of an embodiment of the present application is shown, which may include a local storage cluster 710 that executes the above communication method, and a peer storage cluster 720; wherein the peer storage cluster 720 is a disaster recovery storage cluster of the local storage cluster 710.
[0133] The method steps executed by the local storage cluster in this embodiment are the same or similar to the method steps executed by the local storage cluster in the above-mentioned embodiment, and the same parts are not repeated here.
[0134] The method steps executed by the peer storage cluster in this embodiment are the same or similar to the method steps executed by the peer storage cluster in the above embodiment, and the same parts are not repeated here.
[0135] Figure 8 is a block diagram of an electronic device used to implement an embodiment of the present application. Figure 8 As shown, the electronic device includes: a memory 810 and a processor 820. The memory 810 stores a computer program that can be run on the processor 820. When the processor 820 executes the computer program, the method in the above embodiment is implemented. The number of the memory 810 and the processor 820 can be one or more.
[0136] The electronic device also includes:
[0137] The communication interface 830 is used to communicate with external devices and perform data exchange transmission.
[0138] If the memory 810, the processor 820 and the communication interface 830 are implemented independently, the memory 810, the processor 820 and the communication interface 830 can be connected to each other through a bus and communicate with each other. The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 8 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.
[0139] Optionally, in a specific implementation, if the memory 810, the processor 820 and the communication interface 830 are integrated on a chip, the memory 810, the processor 820 and the communication interface 830 can communicate with each other through an internal interface.
[0140] An embodiment of the present application provides a computer-readable storage medium storing a computer program, which implements the method provided in the embodiment of the present application when the program is executed by a processor.
[0141] An embodiment of the present application also provides a chip, which includes a processor for calling and executing instructions stored in the memory from the memory, so that a communication device equipped with the chip executes the method provided by the embodiment of the present application.
[0142] An embodiment of the present application also provides a chip, including: an input interface, an output interface, a processor and a memory, wherein the input interface, the output interface, the processor and the memory are connected via an internal connection path, and the processor is used to execute the code in the memory. When the code is executed, the processor is used to execute the method provided in the embodiment of the application.
[0143] It should be understood that the processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. It is worth noting that the processor may be a processor supporting the Advanced RISC Machines (ARM) architecture.
[0144] Further, optionally, the above-mentioned memory may include a read-only memory and a random access memory. The memory may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memory. Among them, the non-volatile memory may include a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may include a random access memory (RAM), which is used as an external cache. By way of exemplary but not limiting description, many forms of RAM are available. For example, static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM) and direct memory bus random access memory (DR RAM).
[0145] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function according to the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium.
[0146] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine different embodiments or examples described in this specification and the features of different embodiments or examples, unless they are contradictory.
[0147] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of this application, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0148] Any process or method described in the flow chart or otherwise described herein can be understood as a module, fragment or portion of a code representing one or more executable instructions for implementing the steps of a specific logical function or process. And the scope of the preferred embodiment of the present application includes other implementations, in which the functions may not be performed in the order shown or discussed, including in a substantially simultaneous manner or in a reverse order according to the functions involved.
[0149] The logic and / or steps described in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, which can be specifically implemented in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or used in combination with these instruction execution systems, devices or apparatuses.
[0150] It should be understood that the various parts of the present application can be implemented with hardware, software, firmware or a combination thereof. In the above embodiments, multiple steps or methods can be implemented with software or firmware stored in a memory and executed by a suitable instruction execution system. All or part of the steps of the above embodiment method can be completed by instructing the relevant hardware through a program, which can be stored in a computer-readable storage medium, and when the program is executed, it includes one of the steps of the method embodiment or a combination thereof.
[0151] In addition, each functional unit in each embodiment of the present application can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into one module. The above-mentioned integrated module can be implemented in the form of hardware or in the form of a software functional module. If the above-mentioned integrated module is implemented in the form of a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. The storage medium can be a read-only memory, a disk or an optical disk, etc.
[0152] The above is only an exemplary embodiment of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of various changes or substitutions within the technical scope recorded in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A communication method for a device cluster, characterized in that: Applied to a local device cluster, the method includes: Acquire a first cluster attribute of the local device cluster and a second cluster attribute of the opposite device cluster; Acquire first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute from a communication information database; wherein the communication information database stores a matching relationship between at least one cluster attribute and communication capability information; the first communication capability information includes information about at least one communication interface supported by the local device cluster; the second communication capability information includes information about at least one communication interface supported by the opposite device cluster; A communication interface for sending communication information from the local device cluster to the opposite device cluster is determined according to the first communication capability information and the second communication capability information; wherein the communication interface includes an information sending interface used by the local device cluster to send the communication information, and an information receiving interface used by the opposite device cluster to receive the communication information.
2. The method according to claim 1, characterized in that The obtaining of the first cluster attribute of the local device cluster includes: Acquire the hardware attributes of the local device cluster and the software attributes of the software used by the local device cluster; A first cluster attribute of the local device cluster is determined according to the hardware attribute and the software attribute.
3. The method according to claim 2, characterized in that The hardware attributes of the local device cluster include at least one of the following: processor information, memory information, network information, and interface information of the local device cluster; The software attributes include version information of the software used by the local device cluster.
4. The method according to claim 1, characterized in that: Acquiring a second cluster attribute of the peer device cluster includes: Sending an attribute acquisition request to the peer device cluster; The second cluster attribute fed back by the peer device cluster according to the attribute acquisition request is received.
5. The method according to claim 1, characterized in that The determining, according to the first communication capability information and the second communication capability information, a communication interface through which the local device cluster sends communication information to the opposite device cluster includes: The first communication capability information is matched with the second communication capability information, and the communication interfaces having a matching relationship are used as information sending interfaces used by the local device cluster to send communication information and information receiving interfaces used by the opposite device cluster to receive communication information.
6. The method according to claim 1, characterized in that The determining, according to the first communication capability information and the second communication capability information, a communication interface through which the local device cluster sends communication information to the opposite device cluster includes: According to the first communication capability information and the second communication capability information, the communication interface supported by the local device cluster and the communication interface supported by the opposite device cluster are intersected to obtain an information sending interface used by the local device cluster to send communication information and an information receiving interface used by the opposite device cluster to receive communication information.
7. A communication method for a storage cluster, characterized in that: Applied to the local storage cluster, the method includes: Obtain a third cluster attribute of the local storage cluster and a fourth cluster attribute of the opposite storage cluster; obtain third communication capability information matching the third cluster attribute and fourth communication capability information matching the fourth cluster attribute from a communication information database; wherein the communication information database stores a matching relationship between at least one cluster attribute and communication capability information; the third communication capability information includes information about at least one communication interface supported by the local storage cluster; the fourth communication capability information includes information about at least one communication interface supported by the opposite storage cluster; according to the third communication capability information and the fourth communication capability information, determine the communication interface through which the local storage cluster sends communication information to the opposite storage cluster; wherein the communication interface includes an information sending interface used by the local storage cluster to send the communication information and an information receiving interface used by the opposite storage cluster to receive the communication information.
8. A communication device, characterized in that: Applied to a local device cluster, the device comprises: A first acquisition module, used to acquire a first cluster attribute of the local device cluster and a second cluster attribute of the opposite device cluster; A first determination module is used to obtain first communication capability information matching the first cluster attribute and second communication capability information matching the second cluster attribute from a communication information database; wherein the communication information database stores a matching relationship between at least one cluster attribute and communication capability information; the first communication capability information includes information about at least one communication interface supported by the local device cluster; the second communication capability information includes information about at least one communication interface supported by the opposite device cluster; A first interface screening module is used to determine, based on the first communication capability information and the second communication capability information, a communication interface through which the local device cluster sends communication information to the opposite device cluster; wherein the communication interface includes an information sending interface used by the local device cluster to send the communication information, and an information receiving interface used by the opposite device cluster to receive the communication information.
9. A communication device, characterized in that: Applied to a local storage cluster, the device comprises: A second acquisition module, used to acquire a third cluster attribute of the local storage cluster and a fourth cluster attribute of the opposite storage cluster; A second determination module is used to obtain third communication capability information matching the third cluster attribute and fourth communication capability information matching the fourth cluster attribute from a communication information database; wherein the communication information database stores a matching relationship between at least one cluster attribute and communication capability information; the third communication capability information includes information about at least one communication interface supported by the local storage cluster; and the fourth communication capability information includes information about at least one communication interface supported by the opposite storage cluster; The second interface screening module determines the communication interface through which the local storage cluster sends communication information to the opposite storage cluster according to the third communication capability information and the fourth communication capability information; wherein the communication interface includes an information sending interface used by the local storage cluster to send the communication information, and an information receiving interface used by the opposite storage cluster to receive the communication information.
10. A storage disaster recovery system, characterized in that: It comprises a local storage cluster for executing the communication method described in claim 7, and a peer storage cluster; wherein the peer storage cluster is a disaster recovery storage cluster of the local storage cluster.
11. An electronic device comprising a memory, a processor and a computer program stored in the memory, wherein the processor implements the method according to any one of claims 1 to 7 when executing the computer program.
12. A computer-readable storage medium, wherein a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Method for establishing links and communication device
CN106549776A