A data disaster recovery method, device, equipment and computer-readable storage medium

By setting up local and remote target backup sub-kernels in the FPGA accelerator, the problems of sub-kernel congestion and locking caused by memory blockage in the virtualized FPGA cluster are solved, ensuring data security and achieving rapid processing, and solving virtualization in the existing technology is solved Security and performance issues of FPGA clusters.

CN113722046BActive Publication Date: 2024-11-15LANGCHAO ELECTRONIC INFORMATION IND CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110873296.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-07-30
Publication Date
2024-11-15
Estimated Expiration
2041-07-30

AI Technical Summary

Technical Problem

The FPGA accelerator has a problem of idle logical resources when providing computing services. In the case of network congestion, the security of the virtualized sub-core and the data transmission delay cannot be effectively guaranteed. The existing technology has failed to effectively solve the data of the virtualized FPGA cluster. Security and performance issues.

Method used

By setting the local target backup sub-kernel and the remote target backup sub-kernel, the preset distribution hops are used to distribute the data to be calculated and the calculation results to the backup sub-kernel with similar applications for calculation when the memory is blocked, ensuring data security and fast deal with.

Benefits of technology

It solves the problems of sub-kernel congestion and locking caused by memory blockage in FPGA accelerator, ensures the data security of the virtualized FPGA cluster, and implements rapid data processing within a limited number of hops.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113722046B_ABST
    Figure CN113722046B_ABST
Patent Text Reader

Abstract

The present application discloses a data disaster recovery method, including: setting a local target backup sub-kernel and a remote target backup sub-kernel; the local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up; when the memory of the FPGA accelerator to which the sub-kernel to be backed up belongs is in a blocked state, the data to be calculated and the feedback address of the calculation result are distributed to the local target backup sub-kernel and the remote target backup sub-kernel according to the preset distribution hop number, so as to calculate the data to be calculated through the local target backup sub-kernel and the remote target backup sub-kernel, and feedback the calculation result according to the calculation result feedback address. The data disaster recovery method can solve the sub-kernel congestion and locking problems caused by the memory blockage in the FPGA accelerator, and ensure the data security of the virtualized FPGA cluster. The present application also discloses a data disaster recovery device, equipment and computer-readable storage medium, all of which have the above-mentioned technical effects.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of server technology, and in particular to a data disaster recovery method; and also to a data disaster recovery device, equipment, and a computer-readable storage medium. Background Art

[0002] Heterogeneous computing hardware such as GPU (Graphics Processing Unit) and FPGA (Field Programmable Gate Array) have attracted more and more attention due to their advantages of low energy consumption and high-speed parallel computing. Many manufacturers at home and abroad have successively launched AI servers equipped with GPU and FPGA hardware, which have played a role in high-speed computing in artificial intelligence fields such as deep learning. In response to the problem of idle FPGA logic resources when FPGA accelerators provide external computing services, Intel and other companies have proposed FPGA virtualization. By dividing the kernel corresponding to the FPGA logic resources into multiple kernels, the logic resources of the FPGA accelerator kernel are fully utilized, and multiple different applications can be implemented at the same time. However, when the FPGA accelerator accesses the network through an optical port to provide cluster services, the security of the divided sub-kernels cannot be guaranteed. When a sub-kernel of an FPGA accelerator cannot work again, the corresponding security measures often require the remote server responsible for scheduling to perform secondary scheduling. In the case of network congestion, the time spent on this is unbearable for delay-sensitive applications. There are few existing security solutions designed specifically for FPGA virtualization clusters. Most of them use FPGA accelerators to implement encryption algorithms to ensure the security of server clusters. Alternatively, the remote server in charge of control can convert the data into ciphertext through encryption algorithm, and implement the corresponding decryption algorithm in the FPGA accelerator to read the data. However, this method only ensures the security of the server cluster to the accelerator data transmission, but does not consider the security of the virtualized sub-kernel program of the FPGA accelerator.

[0003] Therefore, providing an efficient and secure data disaster recovery mechanism for virtual FPGA clusters has become a technical problem that needs to be solved urgently by those skilled in the art. Summary of the invention

[0004] The purpose of this application is to provide a data disaster recovery method that can solve the sub-core congestion and lockup problems caused by memory congestion in FPGA accelerators, and ensure the data security of virtualized FPGA clusters. Another purpose of this application is to provide a data disaster recovery device, equipment and computer-readable storage medium, all of which have the above technical effects.

[0005] To solve the above technical problems, the present application provides a data disaster recovery method, including:

[0006] Setting a local target backup sub-kernel and a remote target backup sub-kernel; the local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up;

[0007] When the memory of the FPGA accelerator to which the sub-kernel to be backed up belongs is in a blocked state, the data to be calculated and the calculation result feedback address are distributed to the local target backup sub-kernel and the remote target backup sub-kernel according to a preset distribution hop number, so that the data to be calculated are calculated by the local target backup sub-kernel and the remote target backup sub-kernel, and the calculation result is fed back according to the calculation result feedback address.

[0008] Optionally, setting the local target backup subkernel includes:

[0009] If the sub-kernel and the sub-kernel to be backed up have the same type of application, and the idle time of the sub-kernel reaches a preset value within a preset time, setting the sub-kernel as the local target backup sub-kernel;

[0010] Alternatively, if the sub-kernel and the sub-kernel to be backed up have different types of applications, and the idle time of the sub-kernel reaches the preset value within the preset time, the application of the sub-kernel is replaced with the application of the sub-kernel to be backed up, and the sub-kernel is set as the local target backup sub-kernel.

[0011] Optionally, setting up a remote target backup subkernel includes:

[0012] Obtaining an external network transmission utility value of the remote backup sub-core according to the transmission delay of the remote backup sub-core;

[0013] Obtaining an internal backup environment utility value of the remote backup sub-kernel according to the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have different types of application as the sub-kernel to be backed up;

[0014] Obtaining a fault-tolerant control utility value of the remote backup sub-core according to a sub-core error probability of the FPGA accelerator to which the remote backup sub-core belongs within a specified time;

[0015] According to the external network transmission utility value, the internal backup environment utility value and the fault tolerance control utility value, a preset number of the remote backup sub-kernels are selected as the remote target backup sub-kernels.

[0016] Optionally, obtaining the internal backup environment utility value of the remote backup sub-kernel according to the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have different types of application as the sub-kernel to be backed up comprises:

[0017] The number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up is used as a parameter of the logarithmic term of the internal backup environment utility value function, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have a different type of application from the sub-kernel to be backed up is used as a parameter of the exponential term of the internal backup environment utility value function, to calculate the internal backup environment utility value of the remote backup sub-kernel; wherein the sign of the logarithmic term is positive, and the sign of the exponential term is negative.

[0018] Optionally, the selecting a preset number of the remote backup sub-kernels as the remote target backup sub-kernels according to the external network transmission utility value, the internal backup environment utility value, and the fault tolerance control utility value comprises:

[0019] Multiplying the external network transmission utility value, the internal backup environment utility value, and the fault tolerance control utility value to obtain a screening target value;

[0020] Sort the screening target values ​​from high to low;

[0021] The preset number of remote backup sub-kernels ranked first are selected as the remote target backup sub-kernels.

[0022] Optionally, distributing the data to be calculated to the local target backup sub-kernel and the remote target backup sub-kernel includes:

[0023] The data to be calculated is evenly distributed to the local target backup sub-kernel and the remote target backup sub-kernel.

[0024] Optionally, before distributing the to-be-calculated data and the calculation result feedback address to the local target backup sub-kernel and the remote target backup sub-kernel, the step further includes:

[0025] Query whether the local target backup sub-kernel and the remote target backup sub-kernel are in an idle state;

[0026] If the local target backup sub-kernel and the remote target backup sub-kernel are in an idle state, the data to be calculated and the calculation result feedback address are distributed to the local target backup sub-kernel and the remote target backup sub-kernel.

[0027] In order to solve the above technical problems, the present application also provides a data disaster recovery device, including:

[0028] A setting module is used to set a local target backup sub-kernel and a remote target backup sub-kernel; the local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up;

[0029] The distribution module is used to distribute the data to be calculated and the calculation result feedback address to the local target backup sub-core and the remote target backup sub-core according to a preset distribution hop number when the memory of the FPGA accelerator to which the sub-core to be backed up belongs is in a blocked state, so as to calculate the data to be calculated through the local target backup sub-core and the remote target backup sub-core, and feed back the calculation result according to the calculation result feedback address.

[0030] In order to solve the above technical problems, the present application also provides a data disaster recovery device, including:

[0031] Memory for storing computer programs;

[0032] A processor is used to implement the steps of the data disaster recovery method as described in any one of the above items when executing the computer program.

[0033] To solve the above technical problems, the present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the data disaster recovery method as described in any one of the above items are implemented.

[0034] The data disaster recovery method provided by the present application includes: setting a local target backup sub-kernel and a remote target backup sub-kernel; the local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up; when the memory of the FPGA accelerator to which the sub-kernel to be backed up belongs is in a blocked state, according to a preset distribution hop number, the data to be calculated and the calculation result feedback address are distributed to the local target backup sub-kernel and the remote target backup sub-kernel, so that the data to be calculated is calculated by the local target backup sub-kernel and the remote target backup sub-kernel, and the calculation result is fed back according to the calculation result feedback address.

[0035] It can be seen that the data disaster recovery method provided by the present application, by constructing a local target backup sub-kernel and a remote target backup sub-kernel with the same application as the sub-kernel to be backed up, can solve the sub-kernel congestion and locking problems caused by memory congestion in the FPGA accelerator by taking over the computing task and recalculating the sub-kernel when the sub-kernel to be backed up crashes due to memory congestion, and ensure the data security of the virtualized FPGA cluster. At the same time, when distributing the data to be calculated, the data distribution can be controlled within a limited number of hops to achieve rapid processing of the data to be calculated.

[0036] The data disaster recovery device, equipment and computer-readable storage medium provided in this application all have the above-mentioned technical effects. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0038] Figure 1 A flowchart of a data disaster recovery method provided in an embodiment of the present application;

[0039] Figure 2 A schematic diagram of a virtual FPGA cluster provided in an embodiment of the present application;

[0040] Figure 3 A schematic diagram of a data disaster recovery device provided in an embodiment of the present application;

[0041] Figure 4 A schematic diagram of a data disaster recovery device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0042] The core of this application is to provide a data disaster recovery method, which can solve the sub-core congestion and lockup problems caused by memory congestion in FPGA accelerators, and ensure the data security of virtualized FPGA clusters. Another core of this application is to provide a data disaster recovery device, equipment and computer-readable storage medium, all of which have the above technical effects.

[0043] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0044] Please refer to Figure 1 , Figure 1 A schematic diagram of a data disaster recovery method provided in an embodiment of the present application, referring to Figure 1 As shown, the method mainly includes:

[0045] S101: Setting a local target backup sub-kernel and a remote target backup sub-kernel; the local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up;

[0046] Specifically, the sub-kernel to be backed up refers to the sub-kernel generated by FPGA virtualization, and the sub-kernel has security risks, and it is necessary to select a sub-kernel with the same application for data backup. The target backup sub-kernel refers to the sub-kernel that can perform data backup. The local target backup sub-kernel is the target backup sub-kernel that belongs to the same FPGA accelerator as the sub-kernel that distributes data. The remote target backup sub-kernel is the target backup sub-kernel that belongs to a different FPGA accelerator than the sub-kernel that distributes data.

[0047] For example, for the sub-kernel to be backed up, the target backup sub-kernel that belongs to the same FPGA accelerator as the sub-kernel to be backed up is the local target backup sub-kernel corresponding to the sub-kernel to be backed up. The target backup sub-kernel that belongs to a different FPGA accelerator than the sub-kernel to be backed up and transmits to the sub-kernel to be backed up is the remote target backup sub-kernel corresponding to the sub-kernel to be backed up.

[0048] It is clear that the local target backup sub-kernel itself may also correspond to a remote target backup sub-kernel. The remote target backup sub-kernel itself may also correspond to a local target backup sub-kernel and a remote target backup sub-kernel.

[0049] By setting a local target backup sub-kernel and a remote target backup sub-kernel, when the memory of the sub-kernel to be backed up, such as DDR (Double Data Rate, double-rate synchronous dynamic random access memory) is in a blocked state, the local target backup sub-kernel and the remote target backup sub-kernel can recalculate the data that should have been calculated by the sub-kernel to be backed up, thereby solving the sub-kernel congestion and locking problems caused by memory congestion in the FPGA accelerator.

[0050] The method for setting the local target backup sub-kernel may be:

[0051] If the sub-kernel and the sub-kernel to be backed up have the same type of application, and the idle time of the sub-kernel reaches a preset value within a preset time, setting the sub-kernel as the local target backup sub-kernel;

[0052] Alternatively, if the sub-kernel and the sub-kernel to be backed up have different types of applications, and the idle time of the sub-kernel reaches the preset value within the preset time, the application of the sub-kernel is replaced with the application of the sub-kernel to be backed up, and the sub-kernel is set as the local target backup sub-kernel.

[0053] Taking the local target backup sub-kernel corresponding to the sub-kernel to be backed up as an example, there are two cases for setting the local target backup sub-kernel corresponding to the sub-kernel to be backed up:

[0054] One situation is: one or some sub-kernels that belong to the same FPGA accelerator as the sub-kernel to be backed up have the same type of application as the sub-kernel to be backed up, and the idle time of these sub-kernels reaches a preset value within a preset time, then these sub-kernels are used as local target backup sub-kernels of the sub-kernel to be backed up.

[0055] Another situation is: although the idle time of one or some sub-kernels belonging to the same FPGA accelerator as the sub-kernel to be backed up reaches a preset value within the preset time, these sub-kernels and the sub-kernel to be backed up have different types of applications. In this case, the applications of these sub-kernels are first erased, and then the applications of these sub-kernels are rewritten to be the same as the applications of the sub-kernel to be backed up, and these sub-kernels with rewritten applications are used as local target backup sub-kernels of the sub-kernel to be backed up.

[0056] In addition, the remote target backup sub-kernel can be set as follows:

[0057] Obtaining an external network transmission utility value of the remote backup sub-core according to the transmission delay of the remote backup sub-core;

[0058] Obtaining an internal backup environment utility value of the remote backup sub-kernel according to the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have different types of application as the sub-kernel to be backed up;

[0059] Obtaining a fault-tolerant control utility value of the remote backup sub-core according to a sub-core error probability of the FPGA accelerator to which the remote backup sub-core belongs within a specified time;

[0060] According to the external network transmission utility value, the internal backup environment utility value and the fault tolerance control utility value, a preset number of the remote backup sub-kernels are selected as the remote target backup sub-kernels.

[0061] When selecting a remote target backup sub-kernel, this embodiment comprehensively considers data transmission delay, the working status of other sub-kernels of the FPGA accelerator where the remote backup sub-kernel is located, and the statistical probability of historical errors of the remote backup sub-kernel, and provides a multi-dimensional remote target backup sub-kernel screening solution to ensure that the remote target backup sub-kernel has a good network transmission environment and fault tolerance.

[0062] Specifically, the external network transmission utility value of the remote backup sub-kernel is obtained according to the transmission delay of the remote backup sub-kernel. For the sub-kernel to be backed up, the external network transmission utility value of the remote backup sub-kernel is obtained according to the transmission delay between the sub-kernel to be backed up and the remote backup sub-kernel. The network transmission utility value of the remote backup sub-kernel can be obtained specifically according to the transmission delay between the kernel to be backed up and the remote backup sub-kernel and a preset segmented utility function.

[0063] For example, the transmission delay between the backup sub-core with the j-th type of application and the k-th remote backup sub-core of the i-th FPGA accelerator in the virtual FPGA cluster is represented by D ijk The unit is ms. The piecewise utility function is as follows:

[0064]

[0065] If the transmission delay D ijk If it is greater than 10ms, then the utility U of the kth remote backup sub-core is considered ijk is 0, indicating that the data transmission delay is too large; if the transmission delay D ijk If the kth remote backup sub-core has a utility U less than or equal to 10ms and greater than 1ms, then the utility U ijk 5, indicating that the network transmission environment is good; if the transmission delay D ijk If the kth remote backup sub-core is less than or equal to 1ms, the utility U ijk The value is 10, indicating that the network transmission environment at this time is most suitable.

[0066] For a single FPGA accelerator, due to the limitation of the core logic resources of the FPGA chip, the number of FPGA sub-cores that can be virtualized is only in the single digit. Therefore, the value of k can be 0≤k≤9, k∈N + , that is, the maximum number of sub-cores of the i-th FPGA accelerator is 10.

[0067] It can be understood that the value of k is only one implementation method provided in this application, and is not the only limitation. It can also be set to other numbers. If the core resources of the FPGA chip allow, the maximum number of sub-cores of the i-th FPGA accelerator can be set to other numbers.

[0068] In addition to considering the remote backup sub-kernel from the perspective of external network transmission efficiency, we further measure the impact of other sub-kernels in the i-th FPGA accelerator where the k-th remote backup sub-kernel with the j-th type of application is located on the k-th remote backup sub-kernel.

[0069] Among them, according to the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have different types of application as the sub-kernel to be backed up, the method for obtaining the internal backup environment utility value of the remote backup sub-kernel can be: using the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up as the parameter of the logarithmic term of the internal backup environment utility value function, and using the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have different types of application as the sub-kernel to be backed up as the parameter of the exponential term of the internal backup environment utility value function, to calculate the internal backup environment utility value of the remote backup sub-kernel; wherein the sign of the logarithmic term is positive, and the sign of the exponential term is negative.

[0070] Specifically, the number of remote backup sub-cores in the i-th FPGA accelerator that also has the j-th type of application is recorded as n ij , n ij The larger the number, the more it means that only one of the remote backup sub-kernels needs to be used as the remote target backup sub-kernel. The other sub-kernels of the i-th FPGA accelerator that have the j-th type of application can be used as the local target backup sub-kernel of the remote target backup sub-kernel to implement data backup within the FPGA accelerator. Even if the k-th remote backup sub-kernel that serves as the remote target backup sub-kernel crashes, the remote backup sub-kernel in the i-th FPGA accelerator that also has the j-th type of application can implement local data backup. The number of remote backup sub-kernels that do not have the j-th type of application in the i-th FPGA accelerator is recorded as The larger the value, the more sub-kernels will occupy network resources when backing up data.

[0071] This embodiment measures the impact of data backup on the kth remote backup sub-core with the jth type of application by using a mixed exponential and logarithmic internal backup environment utility value function. For example, the internal backup environment utility value function is as follows:

[0072] Among them, S ijk Indicates the internal backup environment utility value.

[0073] The number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up is used as the parameter of the logarithmic term of the internal backup environment utility value function, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have different types of application as the sub-kernel to be backed up is used as the parameter of the exponential term of the internal backup environment utility value function, so that the calculation result is more inclined to use the FPGA accelerator with sub-kernels having more similar applications.

[0074] After measuring the network transmission environment and internal backup environment of the remote backup sub-kernel from two aspects: the external network transmission delay and the working status of other sub-kernels of the FPGA accelerator where the remote backup sub-kernel is located, the error probability of the FPGA accelerator sub-kernel is further statistically analyzed to consider the operating stability of the remote backup sub-kernel.

[0075] That is, according to the sub-kernel error probability of the FPGA accelerator to which the remote backup sub-kernel belongs within a preset time, the fault-tolerant control utility value of the remote backup sub-kernel is obtained. The fault-tolerant control utility value of the remote backup sub-kernel can be obtained by obtaining the fault-tolerant control utility value according to the sub-kernel error probability of the FPGA accelerator of the remote backup sub-kernel within a preset time and a preset piecewise utility function.

[0076] Specifically, the sub-core error probability of the i-th FPGA accelerator to which the k-th remote backup sub-core with the j-th type of application belongs within the preset time is expressed as p ijk The piecewise utility function is expressed as follows:

[0077]

[0078] If the sub-kernel error probability p ijk If the fault-tolerant control utility value is less than or equal to 3%, then ijk is 10, indicating that the remote backup sub-kernel has the strongest security capability; if the sub-kernel error probability p ijk If the fault-tolerant control utility value E is greater than 3% and less than or equal to 10%, ijk is 5, indicating that the remote backup sub-kernel has good security capabilities; if the sub-kernel error probability p ijk If it is greater than 10%, the fault-tolerant control utility value E ijk If it is 0, it means that the remote backup sub-kernel does not have the ability to be used safely.

[0079] Furthermore, after obtaining the external network transmission utility value, the internal backup environment utility value and the fault-tolerant control utility value, a preset number of the remote backup sub-kernels are selected as the remote target backup sub-kernels according to the external network transmission utility value, the internal backup environment utility value and the fault-tolerant control utility value.

[0080] Specifically, the external network transmission utility value, the internal backup environment utility value and the fault-tolerant control utility value can be multiplied to obtain the screening target value, and the screening target values ​​can be sorted in descending order, and a preset number of remote backup sub-kernels ranked first can be selected as the remote target backup sub-kernels.

[0081] The reason why the preset number of remote backup sub-kernels in the front order are selected as the remote target backup sub-kernels is that the sub-kernel resources of the FPGA accelerator are limited and can only store a small part of the information of the target backup sub-kernel.

[0082] After the remote target backup sub-kernel of the sub-kernel to be backed up is determined, information such as the IP address and data transmission port of the corresponding remote backup sub-kernel is marked in the sub-kernel to be backed up.

[0083] S102: When the memory of the FPGA accelerator to which the sub-kernel to be backed up belongs is in a blocked state, the data to be calculated and the calculation result feedback address are distributed to the local target backup sub-kernel and the remote target backup sub-kernel according to a preset distribution hop number, so that the data to be calculated are calculated by the local target backup sub-kernel and the remote target backup sub-kernel, and the calculation result is fed back according to the calculation result feedback address.

[0084] Specifically, on the basis of setting the local target backup sub-kernel and the remote target backup sub-kernel, when the memory of the sub-kernel FPGA accelerator to be backed up is in a blocked state, causing the sub-kernel to be backed up to crash and be unable to perform data calculation normally, then according to the preset distribution hops, when it is queried that the local target backup sub-kernel and the remote target backup sub-kernel are in an idle state, the data to be calculated and the calculation result feedback address are distributed to the local target backup sub-kernel and the remote target backup sub-kernel, so that the data to be calculated is calculated by the local target backup sub-kernel and the remote target backup sub-kernel, and the calculation result is fed back according to the calculation result feedback address.

[0085] That is to say, first, the sub-kernel to be backed up distributes the data to be calculated and the calculation result feedback address to the local target backup sub-kernel corresponding to the sub-kernel to be backed up. Then, the sub-kernel to be backed up and the local target backup sub-kernel corresponding to the sub-kernel to be backed up query the operation status of the remote target backup sub-kernel corresponding to each other through the inter-kernel high-speed transmission channel, and when the remote target backup sub-kernel is in an idle state, the sub-kernel to be backed up and the local target backup sub-kernel corresponding to the sub-kernel to be backed up distribute the data to be calculated and the calculation result feedback address to the remote target backup sub-kernel corresponding to each other. Each remote target backup sub-kernel further distributes the data to be calculated and the calculation result feedback address to the local target backup sub-kernel and the remote target backup sub-kernel corresponding to the remote target backup sub-kernel. The data to be calculated and the calculation result feedback address are distributed in this way until the preset distribution hop count is reached, that is, until the maximum distribution number is reached.

[0086] If the local target backup sub-core is in a busy state, the data and calculation result feedback address will not be distributed to the local target backup sub-core. If the remote target backup sub-core is in a busy state, the data and calculation result feedback address will not be distributed to the remote target backup sub-core.

[0087] After completing the data distribution, each local target backup sub-core and remote target backup sub-core with data processing capability (in idle state and the DDR of the FPGA accelerator to which it belongs is normal) processes the data to be calculated and feeds back the calculation results to the location pointed to by the calculation result feedback address.

[0088] The method of distributing the data to be calculated may be to equally divide the data to be calculated, whereby the local target backup sub-kernel and the remote target backup sub-kernel only need to process a part of the data to be calculated, thereby speeding up the data processing speed.

[0089] The following Figure 2 Taking the virtual FPGA cluster shown as an example, a specific embodiment of the present application is described:

[0090] Assume that the virtual FPGA cluster includes 3 FPGA accelerators (i takes the values ​​of 0, 1, and 2 respectively), and each FPGA accelerator includes 3 sub-cores (j takes the values ​​of 0, 1, and 2). The applications of each sub-core in the 3 FPGA accelerators are shown in Table 1:

[0091] Table 1

[0092] Application Number Application Name FPGA Accelerator - Sub-core Number 0 ResNet 50 0-0,0-1,1-0,1-1,2-2 1 ResNet 18 0-2,1-2 2 ResNet 152 2-0,2-1

[0093] It can be seen that there are three types of applications (k takes the value of 0, 1, and 2). It is assumed that the sub-core No. 1 of the FPGA accelerator No. 0 is the sub-core to be backed up. It is assumed that the time used for screening the target backup sub-core is 10 minutes, that is, the preset time in the previous text is 10 minutes, and the idle state time of each sub-core of the accelerator No. 0 within 10 minutes is shown in Table 2:

[0094] Table 2

[0095] Subkernel number Free time 0 9.5 minutes 1 9.2 minutes 2 9.8 minutes

[0096] As shown in Table 1 and Table 2, sub-kernel No. 0 of FPGA accelerator No. 0 and sub-kernel No. 1 of FPGA accelerator No. 0 have the same application program, and within 10 minutes, the idle time of sub-kernel No. 1 of FPGA accelerator No. 0 exceeds 90%. Therefore, sub-kernel No. 1 of FPGA accelerator No. 0 is used as the local target backup sub-kernel. Although sub-kernel No. 2 of FPGA accelerator No. 0 has a different application program from the sub-kernel to be backed up (sub-kernel No. 1 of FPGA accelerator No. 0), within 10 minutes, the idle time of sub-kernel No. 2 of FPGA accelerator No. 0 is 98%, which exceeds 90%. Therefore, the logic control sub-kernel can erase the application logic of sub-kernel No. 2 of FPGA accelerator No. 0, and set the application program of sub-kernel No. 2 of FPGA accelerator No. 0 to ResNet 50, which is the same as the application program of sub-kernel No. 0 of FPGA accelerator No. 0. Therefore, the local target backup sub-kernel is composed of sub-kernel No. 0 of FPGA accelerator No. 0 and sub-kernel No. 2 of FPGA accelerator No. 0.

[0097] The accelerator and sub-kernel information corresponding to each application in Table 1 is updated as shown in Table 3:

[0098] Table 3

[0099] Application Number Application Name FPGA Accelerator - Sub-core Number 0 ResNet 50 0-0,0-1,0-2,1-0,1-1,2-2 1 ResNet 18 1-2 2 ResNet 152 2-0,2-1

[0100] Assume that the number of remote target backup sub-kernels is 2. As shown in Table 3, there are three remote backup sub-kernels, namely sub-kernel 0 of FPGA accelerator 1, sub-kernel 1 of FPGA accelerator 1, and sub-kernel 2 of FPGA accelerator 2. Consider the data transmission delay, the working status of other sub-kernels of the FPGA accelerator where the remote backup sub-kernel is located, and the statistical probability of historical errors of the remote backup sub-kernel. Assume that the transmission delay of the remote backup sub-kernel of the sub-kernel to be backed up is shown in Table 4, and the corresponding external network transmission utility value is shown in Table 5.

[0101] Table 4

[0102] <![CDATA[D ijk ]]> Duration (ms) <![CDATA[D 100 ]]> 8 <![CDATA[D 101 ]]> 7.8 <![CDATA[D 202 ]]> 0.3

[0103] Table 5

[0104] <![CDATA[U ijk ]]> Numeric <![CDATA[U 100 ]]> 5 <![CDATA[U 101 ]]> 5 <![CDATA[U 202 ]]> 10

[0105] In addition, from Table 3, the number of sub-kernels that are the same as the application of the remote backup sub-kernel and the number of sub-kernels that are different from the application of the remote backup sub-kernel can be obtained, as shown in Table 6 and Table 7 respectively.

[0106] Table 6

[0107] <![CDATA[n ij ]]> Numeric <![CDATA[n 10 ]]> 2 <![CDATA[n 20 ]]> 1

[0108] Table 7

[0109]

[0110] The corresponding internal backup environment utility values ​​are shown in Table 8. Assuming that the historical error probability values ​​of each remote backup sub-core are shown in Table 9, the fault-tolerant control utility values ​​calculated according to the piecewise function are shown in Table 10.

[0111] Table 8

[0112]

[0113]

[0114] Table 9

[0115] <![CDATA[p ijk ]]> Numeric <![CDATA[p 100 ]]> 1% <![CDATA[p 101 ]]> 8% <![CDATA[p 202 ]]> 2%

[0116] Table 10

[0117] <![CDATA[E ijk ]]> Numeric <![CDATA[E 100 ]]> 10 <![CDATA[E 101 ]]> 5 <![CDATA[E 202 ]]> 10

[0118] Multiply the external network transmission utility value, the internal backup environment utility value, and the fault-tolerant control utility value to obtain the screening target value Res ijk As shown in Table 11.

[0119] Table 11

[0120] <![CDATA[Res ijk ]]> Numeric <![CDATA[Res 100 ]]> 419 <![CDATA[Res 101 ]]> 209.5 <![CDATA[Res 202 ]]> 330

[0121] After sorting the screening target values ​​from high to low, since the number of remote target backup sub-kernels is set to 2, the remote target backup sub-kernels are sub-kernel No. 0 of FPGA accelerator No. 1 and sub-kernel No. 2 of FPGA accelerator No. 2.

[0122] In summary, the sub-kernel to be backed up is sub-kernel No. 1 of FPGA accelerator No. 0, and the local target backup sub-kernels corresponding to the sub-kernel to be backed up are sub-kernel No. 0 of FPAG accelerator No. 0 and sub-kernel No. 2 of FPGA accelerator No. 0. The remote target backup sub-kernels corresponding to the sub-kernel to be backed up are sub-kernel No. 0 of FPGA accelerator No. 1 and sub-kernel No. 2 of FPGA accelerator No. 2.

[0123] When the DDR of FPGA accelerator No. 0 is in a blocked state, the sub-core to be backed up, that is, sub-core No. 1 of FPGA accelerator No. 0, distributes the data to be calculated and the feedback address of the calculation result to the local target backup sub-core of the sub-core to be backed up, which is sub-core No. 0 of FPAG accelerator No. 0 and sub-core No. 2 of FPGA accelerator No. 0.

[0124] Sub-kernel No. 0 of FPAG accelerator No. 0 and sub-kernel No. 2 of FPGA accelerator No. 0 further distribute the received data to be calculated and the calculation result feedback address to their respective corresponding remote target backup sub-kernels. At the same time, sub-kernel No. 1 of FPGA accelerator No. 0 distributes the data to be calculated and the calculation result feedback address to sub-kernel No. 0 of FPGA accelerator No. 1 and sub-kernel No. 2 of FPGA accelerator No. 2.

[0125] Further, each remote target backup sub-kernel distributes the received data to be calculated and the calculation result feedback address to its corresponding local target backup sub-kernel and remote target backup sub-kernel until the number of distributions reaches the preset number of distribution hops.

[0126] After the data and calculation result feedback addresses are distributed, each local target backup sub-core and remote target backup sub-core with processing capabilities calculates the data and feeds back the calculation results.

[0127] In summary, the data disaster recovery method provided by the present application, by constructing a local target backup sub-kernel and a remote target backup sub-kernel with the same application as the sub-kernel to be backed up, can solve the sub-kernel congestion and locking problems caused by memory congestion in the FPGA accelerator by taking over the computing task and recalculating the sub-kernel when the sub-kernel to be backed up crashes due to memory congestion, and ensure the data security of the virtualized FPGA cluster. At the same time, when distributing the data to be calculated, the data distribution can be controlled within a limited number of hops to achieve rapid processing of the data to be calculated.

[0128] The present application also provides a data disaster recovery device, and the device described below can be referred to in correspondence with the method described above. Figure 3 , Figure 3 A schematic diagram of a data disaster recovery device provided in an embodiment of the present application, combined with Figure 3 As shown, the device comprises:

[0129] A setting module 10 is used to set a local target backup sub-kernel and a remote target backup sub-kernel; the local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up;

[0130] The distribution module 20 is used to distribute the data to be calculated and the calculation result feedback address to the local target backup sub-core and the remote target backup sub-core according to a preset distribution hop number when the memory of the FPGA accelerator to which the sub-core to be backed up belongs is in a blocked state, so as to calculate the data to be calculated through the local target backup sub-core and the remote target backup sub-core, and feed back the calculation result according to the calculation result feedback address.

[0131] Based on the above embodiment, optionally, the setting module 10 is specifically used for:

[0132] If the sub-kernel and the sub-kernel to be backed up have the same type of application, and the idle time of the sub-kernel reaches a preset value within a preset time, setting the sub-kernel as the local target backup sub-kernel;

[0133] Alternatively, if the sub-kernel and the sub-kernel to be backed up have different types of applications, and the idle time of the sub-kernel reaches the preset value within the preset time, the application of the sub-kernel is replaced with the application of the sub-kernel to be backed up, and the sub-kernel is set as the local target backup sub-kernel.

[0134] Based on the above embodiment, optionally, the setting module 10 includes:

[0135] An external network transmission utility value calculation unit, used to obtain the external network transmission utility value of the remote backup sub-core according to the transmission delay of the remote backup sub-core;

[0136] an internal backup environment utility value calculation unit, configured to obtain an internal backup environment utility value of the remote backup sub-kernel according to the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have different types of application as the sub-kernel to be backed up;

[0137] A fault-tolerant control utility value calculation unit, used to obtain the fault-tolerant control utility value of the remote backup sub-core according to the sub-core error probability of the FPGA accelerator to which the remote backup sub-core belongs within a specified time;

[0138] A selection unit is used to select a preset number of the remote backup sub-kernels as the remote target backup sub-kernels according to the external network transmission utility value, the internal backup environment utility value and the fault-tolerant control utility value.

[0139] Based on the above embodiment, optionally, the internal backup environment utility value calculation unit is specifically used to:

[0140] The number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up is used as a parameter of the logarithmic term of the internal backup environment utility value function, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have a different type of application from the sub-kernel to be backed up is used as a parameter of the exponential term of the internal backup environment utility value function, to calculate the internal backup environment utility value of the remote backup sub-kernel; wherein the sign of the logarithmic term is positive, and the sign of the exponential term is negative.

[0141] Based on the above embodiment, optionally, the selection unit is specifically used to:

[0142] Multiplying the external network transmission utility value, the internal backup environment utility value, and the fault tolerance control utility value to obtain a screening target value;

[0143] Sort the screening target values ​​from high to low;

[0144] The preset number of remote backup sub-kernels ranked first are selected as the remote target backup sub-kernels.

[0145] Based on the above embodiment, the distribution module 20 is specifically used for:

[0146] The data to be calculated is evenly distributed to the local target backup sub-kernel and the remote target backup sub-kernel.

[0147] Based on the above embodiment, optionally, the method further includes:

[0148] The query module is used to query whether the local target backup sub-kernel and the remote target backup sub-kernel are in an idle state; if the local target backup sub-kernel and the remote target backup sub-kernel are in an idle state, the distribution module 20 distributes the data to be calculated and the calculation result feedback address to the local target backup sub-kernel and the remote target backup sub-kernel.

[0149] The present application also provides a data disaster recovery device, referring to Figure 4 As shown, the device includes a memory 1 and a processor 2 .

[0150] Memory 1, used for storing computer programs;

[0151] Processor 2 is used to execute the computer program to implement the following steps:

[0152] A local target backup sub-kernel and a remote target backup sub-kernel are set; the local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up; when the memory of the FPGA accelerator to which the sub-kernel to be backed up belongs is in a blocked state, the data to be calculated and the calculation result feedback address are distributed to the local target backup sub-kernel and the remote target backup sub-kernel according to a preset distribution hop number, so that the data to be calculated are calculated by the local target backup sub-kernel and the remote target backup sub-kernel, and the calculation result is fed back according to the calculation result feedback address.

[0153] For an introduction to the equipment provided in this application, please refer to the above method embodiments, and this application will not go into details here.

[0154] The present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the following steps can be implemented:

[0155] A local target backup sub-kernel and a remote target backup sub-kernel are set; the local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up; when the memory of the FPGA accelerator to which the sub-kernel to be backed up belongs is in a blocked state, the data to be calculated and the calculation result feedback address are distributed to the local target backup sub-kernel and the remote target backup sub-kernel according to a preset distribution hop number, so that the data to be calculated are calculated by the local target backup sub-kernel and the remote target backup sub-kernel, and the calculation result is fed back according to the calculation result feedback address.

[0156] The computer-readable storage medium may include: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and other media that can store program codes.

[0157] For an introduction to the computer-readable storage medium provided in this application, please refer to the above method embodiment, and this application will not go into details here.

[0158] The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referred to each other. For the devices, equipment, and computer-readable storage media disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the description is relatively simple, and the relevant parts can be referred to the method part description.

[0159] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0160] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0161] The data disaster recovery method, device, equipment and computer-readable storage medium provided by the present application are described in detail above. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method and core idea of ​​the present application. It should be pointed out that for ordinary technicians in this technical field, without departing from the principles of the present application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the scope of protection of the claims of the present application.

Claims

1. A data disaster recovery method, characterized in that: include: Set up the local target backup sub-kernel and the remote target backup sub-kernel; The local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up; When the memory of the FPGA accelerator to which the sub-kernel to be backed up belongs is in a blocked state, the data to be calculated and the calculation result feedback address are distributed to the local target backup sub-kernel and the remote target backup sub-kernel according to a preset distribution hop number, so that the data to be calculated are calculated by the local target backup sub-kernel and the remote target backup sub-kernel, and the calculation result is fed back according to the calculation result feedback address; Setting up the local target backup subkernel includes: If the sub-kernel and the sub-kernel to be backed up have the same type of application, and the idle time of the sub-kernel reaches a preset value within a preset time, setting the sub-kernel as the local target backup sub-kernel; Alternatively, if the sub-kernel and the sub-kernel to be backed up have different types of applications, and the idle time of the sub-kernel within the preset time reaches the preset value, then after replacing the application of the sub-kernel with the application of the sub-kernel to be backed up, the sub-kernel is set as the local target backup sub-kernel; Setting up the remote target backup subkernel includes: Obtaining an external network transmission utility value of the remote backup sub-core according to the transmission delay of the remote backup sub-core; Obtaining an internal backup environment utility value of the remote backup sub-kernel according to the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have different types of application as the sub-kernel to be backed up; Obtaining a fault-tolerant control utility value of the remote backup sub-core according to a sub-core error probability of the FPGA accelerator to which the remote backup sub-core belongs within a specified time; According to the external network transmission utility value, the internal backup environment utility value and the fault tolerance control utility value, a preset number of the remote backup sub-kernels are selected as the remote target backup sub-kernels.

2. The data disaster recovery method according to claim 1, characterized in that: The obtaining of the internal backup environment utility value of the remote backup sub-kernel according to the number of sub-kernels having the same type of application as the sub-kernel to be backed up in the FPGA accelerator to which the remote backup sub-kernel belongs, and the number of sub-kernels having different types of application as the sub-kernel to be backed up in the FPGA accelerator to which the remote backup sub-kernel belongs comprises: The number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up is used as a parameter of the logarithmic term of the internal backup environment utility value function, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have a different type of application from the sub-kernel to be backed up is used as a parameter of the exponential term of the internal backup environment utility value function, to calculate the internal backup environment utility value of the remote backup sub-kernel; wherein the sign of the logarithmic term is positive, and the sign of the exponential term is negative.

3. The data disaster recovery method according to claim 1, characterized in that: The selecting a preset number of the remote backup sub-kernels as the remote target backup sub-kernels according to the external network transmission utility value, the internal backup environment utility value and the fault tolerance control utility value comprises: Multiplying the external network transmission utility value, the internal backup environment utility value, and the fault tolerance control utility value to obtain a screening target value; Sort the screening target values ​​from high to low; The preset number of remote backup sub-kernels ranked first are selected as the remote target backup sub-kernels.

4. The data disaster recovery method according to claim 1, characterized in that: Distributing the data to be calculated to the local target backup sub-kernel and the remote target backup sub-kernel includes: The data to be calculated is evenly distributed to the local target backup sub-kernel and the remote target backup sub-kernel.

5. The data disaster recovery method according to claim 1, characterized in that: Before distributing the to-be-calculated data and the calculation result feedback address to the local target backup sub-kernel and the remote target backup sub-kernel, the method further includes: Query whether the local target backup sub-kernel and the remote target backup sub-kernel are in an idle state; If the local target backup sub-kernel and the remote target backup sub-kernel are in an idle state, the data to be calculated and the calculation result feedback address are distributed to the local target backup sub-kernel and the remote target backup sub-kernel.

6. A data disaster recovery device, characterized in that: include: A setting module is used to set the local target backup sub-kernel and the remote target backup sub-kernel; The local target backup sub-kernel and the remote target backup sub-kernel have the same application as the sub-kernel to be backed up; A distribution module, used for distributing the data to be calculated and the calculation result feedback address to the local target backup sub-core and the remote target backup sub-core according to a preset distribution hop number when the memory of the FPGA accelerator to which the sub-core to be backed up belongs is in a blocked state, so as to calculate the data to be calculated by the local target backup sub-core and the remote target backup sub-core, and to feed back the calculation result according to the calculation result feedback address; The settings module is specifically used to: If the sub-kernel and the sub-kernel to be backed up have the same type of application, and the idle time of the sub-kernel reaches a preset value within a preset time, setting the sub-kernel as the local target backup sub-kernel; Alternatively, if the sub-kernel and the sub-kernel to be backed up have different types of applications, and the idle time of the sub-kernel within the preset time reaches the preset value, then after replacing the application of the sub-kernel with the application of the sub-kernel to be backed up, the sub-kernel is set as the local target backup sub-kernel; The setup module includes: An external network transmission utility value calculation unit, used to obtain the external network transmission utility value of the remote backup sub-core according to the transmission delay of the remote backup sub-core; an internal backup environment utility value calculation unit, configured to obtain an internal backup environment utility value of the remote backup sub-kernel according to the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have the same type of application as the sub-kernel to be backed up, and the number of sub-kernels in the FPGA accelerator to which the remote backup sub-kernel belongs that have different types of application as the sub-kernel to be backed up; A fault-tolerant control utility value calculation unit, used to obtain the fault-tolerant control utility value of the remote backup sub-core according to the sub-core error probability of the FPGA accelerator to which the remote backup sub-core belongs within a specified time; A selection unit is used to select a preset number of the remote backup sub-kernels as the remote target backup sub-kernels according to the external network transmission utility value, the internal backup environment utility value and the fault-tolerant control utility value.

7. A data disaster recovery device, characterized in that: include: Memory for storing computer programs; A processor, configured to implement the steps of the data disaster recovery method according to any one of claims 1 to 5 when executing the computer program.

8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the data disaster recovery method according to any one of claims 1 to 5 are implemented.