Remote memory access protection mechanism construction method, remote memory node, and device

By introducing permission application and authentication mechanisms into the remote memory architecture, the problem of insufficient remote memory access protection performance in the existing technology is solved, effective isolation and security improvement of remote data are achieved, and remote data security is ensured. security and access efficiency.

WO2024192557A1PCT designated stage expired Publication Date: 2024-09-26TSINGHUA UNIVERSITY
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2023/082125
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Filing Date
2023-03-17
Publication Date
2024-09-26

AI Technical Summary

Technical Problem

The existing remote memory access protection mechanism is inferior to the RDMA data path in terms of performance and latency, and cannot effectively isolate illegal remote access, resulting in the risk of remote data damage and privacy leakage.

Method used

By introducing permission application and authentication mechanisms into the remote memory architecture, user programs need to obtain permissions before accessing remote memory. Permission application is based on authentication by binding the memory window to the remote content address and unbinding it at the end of the access. , using lease semantics and hash tables to manage permission symbols to ensure that the permission symbols expire when the access ends or the lease expires, to avoid illegal access.

Benefits of technology

It effectively isolates illegal remote access, prevents remote data damage and privacy leakage, improves the security and efficiency of remote memory access, and ensures that permission symbols expire when the access ends or the lease expires, avoiding potential risks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2023082125_26092024_PF_FP
    Figure CN2023082125_26092024_PF_FP
Patent Text Reader

Abstract

The present application provides a remote memory access protection mechanism construction method, a remote memory node, and a device. The method comprises: obtaining a permission application of a computing node, wherein the permission application is generated by submitting an access request of a user program to a network adapter queue pair by the computing node, and the access request comprises a remote memory address; when authentication on the permission application succeeds, binding a memory window to a remote content address, and returning a permission character, wherein the permission character is used for remote memory access; and when the remote memory access ends, unbinding the memory window and the remote content address to invalidate the permission character.
Need to check novelty before this filing date? Find Prior Art

Description

Remote memory access protection mechanism construction method, remote memory node and device Technical Field

[0001] The present application belongs to the field of remote memory access technology, and in particular relates to a method for constructing a remote memory access protection mechanism, a remote memory node, and a device. Background Art

[0002] Remote Direct Memory Access (RDMA) is a high-speed network technology with hundreds of Gbps of bandwidth and microsecond-level latency. Due to its impressive performance, RDMA is widely used in data centers by major enterprises. Due to information security requirements, RDMA often requires protection mechanisms to address issues such as remote data corruption and privacy leaks. However, existing protection mechanisms have very limited performance, with throughput and latency often far inferior to RDMA data paths, making them incapable of providing runtime remote memory access protection.

[0003] Therefore, it is necessary to provide a method for constructing a remote memory access protection mechanism that isolates illegal remote access, thereby avoiding remote data corruption and remote data privacy leakage.

[0004] Summary of the Invention

[0005] The embodiments of the present application provide a method for constructing a remote memory access protection mechanism, a remote memory node, and a device, which can isolate illegal remote access, thereby avoiding remote data damage and remote data privacy leakage.

[0006] In a first aspect, an embodiment of the present application provides a method for constructing a remote memory access protection mechanism, which is applied to a remote memory node in a remote memory architecture, wherein the remote memory architecture also includes a computing node. The method includes:

[0007] Obtaining the permission application of the computing node. The permission application is generated based on the computing node submitting the user program's access request to the network card queue pair. The access request includes the remote memory address.

[0008] If the permission request is authenticated, the memory window is bound to the remote content address and a permission token is returned. The permission token is used for remote memory access.

[0009] When the remote memory access ends, the memory window is unbound from the remote content address to invalidate the permission symbol.

[0010] In some embodiments, if the permission request is authenticated, the memory window is bound to the remote content address and a permission symbol is returned, including:

[0011] If the permission request is authenticated, obtain the historical permission symbol corresponding to the ongoing remote memory access;

[0012] Determine whether the permission application conflicts with historical permission symbols;

[0013] If there is no conflict between the permission request and the historical permission symbol, the memory window is bound to the remote content address and the permission symbol is returned.

[0014] In some embodiments, if the permission request is authenticated, the memory window is bound to the remote content address, and after returning the permission symbol, the method further includes:

[0015] Store the permission token in the hash table;

[0016] When the remote memory access is completed, the memory window is unbound from the remote content address to invalidate the permission symbol. The method further includes:

[0017] Remove the permission token from the hash table.

[0018] In some embodiments, the permission symbol includes lease semantics, and the lease semantics corresponds to a lease period. If the permission request is authenticated, the memory window is bound to the remote content address, and after returning the permission symbol, the method further includes:

[0019] When the response time of remote memory access exceeds the lease period, the memory window is unbound from the remote content address to invalidate the permission token.

[0020] In some embodiments, the lease period is updated based on a user program using a unilateral access to the remote memory.

[0021] In some embodiments, the network card queue pair has a backup queue pair, wherein the backup queue pair replaces the network card queue pair in the event of a failure of the network card queue pair.

[0022] In some embodiments, when the remote memory access ends, unbinding the memory window from the remote content address to invalidate the permission symbol includes:

[0023] When the remote memory access is completed, obtain the load pressure of the remote memory architecture and the number of unbound memory windows;

[0024] When the load pressure is less than a preset pressure threshold, or the quantity is less than a preset quantity threshold, the memory window is unbound from the remote content address to invalidate the permission symbol.

[0025] In some embodiments, the method further comprises:

[0026] Combine a memory window binding operation and an unbinding operation into a binding change operation;

[0027] When multiple remote memory addresses to be bound are consecutive addresses, multiple binding operations of the memory window are replaced with one batch binding operation.

[0028] In some embodiments, the remote memory architecture includes a plurality of compute nodes and a plurality of remote memory nodes.

[0029] In a second aspect, an embodiment of the present application provides a remote memory node, which belongs to a remote memory architecture. The remote memory architecture also includes a computing node. The remote memory node includes:

[0030] An acquisition module is used to obtain a permission application from a computing node. The permission application is generated based on the computing node submitting an access request from a user program to a network card queue pair. The access request includes a remote memory address.

[0031] The binding module is used to bind the memory window to the remote content address and return the permission symbol when the permission application is authenticated. The permission symbol is used for remote memory access.

[0032] The unbinding module is used to unbind the memory window from the remote content address when the remote memory access ends, so as to invalidate the permission symbol.

[0033] In a third aspect, an embodiment of the present application provides a device for constructing a remote memory access protection mechanism, the device comprising:

[0034] a processor and a memory storing programs or instructions;

[0035] The above method is implemented when the processor executes the program or instruction.

[0036] In a fourth aspect, an embodiment of the present application provides a machine-readable storage medium, on which a program or instruction is stored, and the above-mentioned method is implemented when the program or instruction is executed by a processor.

[0037] In a fifth aspect, an embodiment of the present application provides a computer program product. When the instructions in the computer program product are executed by a processor of an electronic device, the electronic device executes the above method.

[0038] The remote memory access protection mechanism construction method, remote memory node and device of the embodiment of the present application can obtain the permission application of the computing node. The permission application is generated based on the computing node submitting the access request of the user program to the network card queue pair, and the access request includes the remote memory address; if the permission application authentication is passed, the memory window is bound to the remote content address and the permission symbol is returned. The permission symbol is used for remote memory access; when the remote memory access ends, the memory window is unbound from the remote content address to invalidate the permission symbol. In this way, the permission mechanism can be used to effectively isolate illegal remote access from user programs, and the permission symbol will become invalid after the access ends, effectively avoiding the problems of remote data damage, remote data privacy leakage and other problems potentially faced by the remote memory architecture. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0040] FIG1 is a flow chart of a method for constructing a remote memory access protection mechanism according to an embodiment of the present application;

[0041] FIG2 is a schematic diagram of a remote memory architecture provided in an embodiment of the present application;

[0042] 3 is a schematic diagram of the remote memory layout and data management format of the remote memory access protection mechanism construction method provided in an embodiment of the present application;

[0043] FIG4 is a user usage flow chart of a method for constructing a remote memory access protection mechanism provided in an embodiment of the present application;

[0044] FIG5 is a schematic diagram of a binding change operation of a method for constructing a remote memory access protection mechanism provided in an embodiment of the present application;

[0045] 6 is a schematic diagram of batch binding operations and batch unbinding operations of the method for constructing a remote memory access protection mechanism provided in an embodiment of the present application;

[0046] FIG7 is a schematic diagram of the structure of a remote memory node provided by another embodiment of the present application;

[0047] FIG8 is a schematic structural diagram of an electronic device provided in yet another embodiment of the present application. DETAILED DESCRIPTION

[0048] The features and exemplary embodiments of various aspects of the present application will be described in detail below. In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only intended to explain the present application, rather than to limit the present application. For those skilled in the art, the present application can be implemented without the need for some of these specific details. The following description of the embodiments is merely to provide a better understanding of the present application by illustrating the examples of the present application.

[0049] It should be noted that, in this document, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article, or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or device. In the absence of further limitations, the elements defined by the phrase "comprising..." do not exclude the presence of other identical elements in the process, method, article, or device comprising the elements.

[0050] In order to solve the problems of the prior art, the embodiments of the present application provide a method for constructing a remote memory access protection mechanism, a remote memory node, and a device. The following first introduces the method for constructing a remote memory access protection mechanism provided by the embodiments of the present application.

[0051] Figure 1 shows a flow chart of a method for establishing a remote memory access protection mechanism according to one embodiment of the present application. As shown in Figure 1, the method for establishing a remote memory access protection mechanism can be applied to remote memory nodes in a remote memory architecture, which can also include computing nodes. The method for establishing a remote memory access protection mechanism can include the following steps:

[0052] Step 101: Obtain a permission application of a computing node. The permission application is generated based on the computing node submitting an access request of a user program to a network card queue pair. The access request includes a remote memory address.

[0053] In step 101, before accessing remote memory, a user can request access permissions from the remote memory on demand through a remote procedure call. Specifically, a user program can submit an access request to a compute node in the remote memory architecture. The access request includes the address of the remote memory the user wishes to access. Upon receiving the access request, the compute node submits it to the network interface card queue pair, generating a corresponding permission request. This request can then be retrieved by the remote memory node from the network interface card queue pair.

[0054] Step 102: If the permission application is authenticated, the memory window is bound to the remote content address and a permission symbol is returned. The permission symbol is used for remote memory access.

[0055] In step 102, it is understood that the permission application may carry the user program's authentication information, such as user ID, user password, etc. The remote memory node can authenticate the permission application based on this authentication information and determine whether the user program can perform remote memory access. If so, it means that the authentication is successful. At this time, the memory window (MW) can be bound to the remote content address and a permission symbol is returned. The permission symbol can be used for remote memory access. In other words, unauthorized remote access will not be executed.

[0056] Step 103: When the remote memory access is completed, the memory window is unbound from the remote content address to invalidate the permission symbol.

[0057] In step 103, if the remote memory access ends, the memory window and the remote content address can be untied to invalidate the permission symbol. In this way, since the permission symbol is invalid, the remote memory access cannot be continued, thereby protecting the privacy of the remote data.

[0058] In some examples, as shown in FIG2 , the remote memory architecture may include computing nodes and remote memory nodes, wherein the remote memory nodes may be divided into two parts: a permission header resource pool and a remote memory pool. As shown in sequence number 1 of FIG2 , when a user applies for access rights (i.e., the remote memory node can obtain a permission application), the remote memory node allocates a permission header from the permission header resource pool, allocates a piece of remote memory from the remote memory pool, binds the two MWs to the permission header and the remote memory respectively, and returns the two permission symbols to the user. When the user revokes access rights (i.e., the remote memory access ends), the remote memory node unbinds the corresponding two MWs, making the permission symbols invalid.

[0059] It is understandable that remote memory can be managed using a slab allocator. Remote memory is divided into multiple fixed-size block groups. When users allocate and use remote memory, they can select a piece of remote memory from the smallest non-empty block group that meets the user's needs for allocation according to user needs.

[0060] As shown in Figure 3, the main part of the remote memory node is divided into the remote memory pool, and a small part is divided into the permission header resource pool. The permission header can include the memory address and length of the open permission, the location of the MW used, the timestamp of the permission opening, and the permission lease period, etc.

[0061] The remote memory access protection mechanism construction method of the embodiment of the present application can obtain the permission application of the computing node. The permission application is generated based on the computing node submitting the access request of the user program to the network card queue pair. The access request includes the remote memory address. If the permission application authentication is passed, the memory window is bound to the remote content address and the permission symbol is returned. The permission symbol is used for remote memory access. When the remote memory access ends, the memory window is unbound from the remote content address to invalidate the permission symbol. In this way, the permission mechanism can be used to effectively isolate illegal remote access from user programs, and the permission symbol will become invalid after the access ends, effectively avoiding the problems of remote data damage, remote data privacy leakage, etc. that the remote memory architecture may face.

[0062] In some embodiments, step 102 may include the following steps:

[0063] If the permission request is authenticated, obtain the historical permission symbol corresponding to the ongoing remote memory access;

[0064] Determine whether the permission application conflicts with historical permission symbols;

[0065] If there is no conflict between the permission request and the historical permission symbol, the memory window is bound to the remote content address and the permission symbol is returned.

[0066] In this embodiment, if the permission application is authenticated, the historical permission symbol corresponding to the ongoing remote memory access can be obtained. In other words, the historical permission symbol can refer to the currently valid permission symbol, and the historical permission symbol can be used to determine whether the permission application conflicts with the ongoing remote memory access.

[0067] For example, if the historical permission symbol indicates that the remote memory address corresponding to the permission application is currently being accessed in a private remote memory, it can be considered that there is a conflict between the permission application and the historical permission symbol. After the conflict is resolved (that is, after the private remote memory access is completed), the memory window can be bound to the remote content address and the permission symbol can be returned.

[0068] If the permission request does not conflict with the historical permission symbol, the memory window can be directly bound to the remote content address and the permission symbol can be returned.

[0069] In some examples, as shown in FIG4 , part (a) of FIG4 illustrates a non-conflicting situation, where user 1 applies for shared access rights to a remote memory node and is performing shared remote memory access. During the remote memory access process, user 1 can extend the lease of the rights to the remote memory node, where the operation of extending the rights lease can occur multiple times. At this time, user 1 initiates remote write and remote read operations to the remote memory, and attaches a permission symbol. If the permission symbol has not expired at this time, the remote write and remote read operations can be successfully executed. If the permission symbol has expired at this time, the remote write and remote read operations will not be executed. During this process, user 2 can apply for the same shared permission, and multiple shared permissions pointing to the same remote memory can exist at the same time.

[0070] Part (b) of Figure 4 illustrates a conflicting situation. User 1 applies for private access rights from a remote memory node and is currently accessing private remote memory. At this time, user 2 applies for access rights to the same remote memory from the remote memory node. Due to the conflicting rights, the remote memory node delays granting access rights to user 2 until the conflict is resolved.

[0071] It is understandable that if user 1's user program crashes, when the lease of user 1's permission symbol times out, user 1's private access rights are forcibly and automatically reclaimed, and the permission conflict is resolved. At this time, the remote memory node grants user 2 access rights, that is, returns the permission symbol to user 2.

[0072] In some embodiments, after step 102, the method for establishing a remote memory access protection mechanism may further include the following steps:

[0073] Store the permission token in the hash table;

[0074] When the remote memory access is completed, the memory window is unbound from the remote content address to invalidate the permission symbol. The method further includes:

[0075] Remove the permission token from the hash table.

[0076] In this embodiment, the permission symbol may be managed using a hash table, that is, after the permission symbol is returned, the permission symbol may be stored in the hash table, and after the permission symbol becomes invalid, the permission symbol may be deleted from the hash table.

[0077] The key of the hash table can be the remote memory address that the user applies to access, and the value is the metadata required for permission management. The metadata may include the address of the remote memory, the location of the MW, the permission opening time, and the permission lease period.

[0078] In this way, by managing permission symbols through a hash table, conflicting permission applications can be quickly detected to improve the operating efficiency of remote memory access.

[0079] In some examples, as shown in sequence number 2 of Figure 2, the permission symbols can be managed in the form of a hash table. The remote memory covered by the permission symbols needs to be aligned with the blocks in the slab allocator block group. The permission symbols are stored in the hash table. The key of the hash table is the remote memory address that the user applies to access, and the value is the metadata required for permission management, that is, the permission header, where the permission header may include the address of the remote memory, the location of the MW, the permission activation time, and the permission lease period, etc.

[0080] Remote memory nodes can detect conflicting permission requests through a hash table. When processing a user's permission request, the remote memory node uses the remote memory address requested in the request as the key to query the hash table. If an access conflict is detected between the permission request and the historical permission symbols in the hash table, the permission request will be delayed until the conflict is resolved.

[0081] In some embodiments, the permission symbol includes lease semantics, and the lease semantics corresponds to a lease period. After step 102, the method for constructing a remote memory access protection mechanism may further include the following steps:

[0082] When the response time of remote memory access exceeds the lease period, the memory window is unbound from the remote content address to invalidate the permission token.

[0083] In this embodiment, the permission symbol can include lease semantics, which correspond to a lease period. In the event that a user program is suspended or crashes, the response time for remote memory access often times out. In this case, the lease semantics can be used to release residual permissions, that is, to unbind the memory window from the remote content address, thereby invalidating the permission symbol. Using the lease mechanism can solve the problem of permission resource leakage and system blockage caused by user program crashes or suspensions.

[0084] In some embodiments, the lease period is updated based on a user program using a unilateral access to the remote memory.

[0085] In this embodiment, the lease semantics can support the extension of the lease period, and the lease period is updated based on the user program using a unilateral access to remote memory. For example, the permission lease field on the permission header is exposed to the user through MW, and the user uses the compare and swap primitive (CAS) of the unilateral access to remote memory to complete the update of the permission lease variable. Accordingly, the remote memory node can periodically access the hash table, check the permission lease variable of the permission symbol therein, and abolish all permission symbols that have exceeded the lease period. The method of abolishing the permission symbol is to unbind the relevant MW, making the relevant permission symbol invalid.

[0086] In some examples, to avoid fairness issues between shared and private permissions caused by repeated lease extensions, a remote memory node can refuse to extend the lease of a permission symbol when it detects that a piece of remote memory is actively in a shared or private access state for a long time. For example, the remote memory node can set the permission lease field of the permission header to zero. When the user extends the lease of the permission, the compare and exchange primitive fails and returns a zero value, so the user knows that the permission extension is prohibited. At the same time, the remote memory node can reserve a bit in the start time field of the permission header and set the bit to one to mark that the permission symbol should be revoked after the current round of timeout.

[0087] In some examples, to avoid resource occupation issues caused by repeated lease extensions, no permission token can remain valid beyond a maximum lifetime. The maximum lifetime can be set based on actual needs and is not specifically limited here. The permission activation time stored in the permission header can be used for judgment. Permission tokens that exceed the maximum lifetime are considered to have timed out and are revoked.

[0088] In some embodiments, the network card queue pair has a backup queue pair, wherein the backup queue pair replaces the network card queue pair in the event of a failure of the network card queue pair.

[0089] In this embodiment, the network card queue pair required for remote memory access can have multiple backup queue pairs. If a network card queue pair fails due to illegal remote access by a user, the backup queue pair can replace the failed network card queue pair, thereby quickly restoring the user's remote memory access capability. This minimizes the additional recovery time caused by queue pair failures due to illegal remote access by using a small number of redundant backup queue pairs.

[0090] In some examples, as shown in Figure 2, sequence number 3, any remote memory access with an invalid or expired permission token will not be executed. For example, even if an invalid permission request is sent to the network card queue pair, the invalid permission token attached to the invalid permission request will be detected by the network card on the remote memory node side, and the remote memory access will not be executed by the network card on the remote memory node.

[0091] In some examples, as shown in sequence number 4 of Figure 2, the network card queue pair can have several redundant standby queue pairs to complete the switching of the standby queue pair when the network card queue pair fails. Each user program in the remote memory architecture will be assigned a fixed virtual queue pair number. The virtual queue pair number is mapped to an actual network card queue pair through a virtual-to-real mapping table. All permission requests of the user program will be sent to the actual network card queue pair according to the mapping table. Illegal remote memory access will cause the network card queue pair to fail. At this time, the standby queue pair will replace the failed network card queue pair, and the virtual-to-real mapping table will be changed to remap the virtual queue number to a valid standby queue pair so that the remote memory access capability can be quickly restored.

[0092] In some embodiments, step 103 may include the following steps:

[0093] When the remote memory access is completed, obtain the load pressure of the remote memory architecture and the number of unbound memory windows;

[0094] When the load pressure is less than a preset pressure threshold, or the quantity is less than a preset quantity threshold, the memory window is unbound from the remote content address to invalidate the permission symbol.

[0095] In this embodiment, when the remote memory access ends, the load pressure of the remote memory architecture and the number of unbound memory windows can be obtained. If the load pressure is less than a preset pressure threshold, or the number is less than a preset number threshold, the memory window can be unbound from the remote content address to invalidate the permission symbol. If the load pressure is greater than or equal to the preset pressure threshold, and the number of unbound memory windows is greater than or equal to the preset number threshold, the unbinding operation can be delayed. The preset pressure threshold and the preset number threshold can be set according to actual needs and are not specifically limited here.

[0096] In other words, when processing a memory window unbinding operation, if the remote memory framework faces high load pressure, the memory window unbinding operation can be delayed until the load pressure is relieved or the number of available memory windows is lower than a critical value.

[0097] In some embodiments, the method for establishing a remote memory access protection mechanism may further include the following steps:

[0098] Combine a memory window binding operation and an unbinding operation into a binding change operation;

[0099] When multiple remote memory addresses to be bound are consecutive addresses, multiple binding operations of the memory window are replaced with one batch binding operation.

[0100] In this embodiment, a memory window bind and unbind operation can be combined into a single rebinding operation. For example, as shown in Figure 5, when simultaneously processing requests to bind and unbind a memory window, this can be accomplished by rebinding the memory window. During the rebinding, the memory window to be unbound is rebinded to the remote memory whose access rights need to be exposed, and the newly generated permission token is returned.

[0101] When multiple remote memory addresses to be bound are continuous, multiple memory window binding operations can be replaced with a single batch binding operation. For example, as shown in Figure 6, when binding multiple MWs to continuous remote memory, multiple memory window binding operations can be reduced to a single memory window binding operation for the entire continuous remote memory address. In addition to being allocated in the permission resource pool, permission headers are also speculatively allocated immediately before the remote memory. The two memory window binding operations of binding to the remote memory and binding to the adjacent permission header are reduced to a single binding operation for the continuous remote memory address.

[0102] Similarly, as shown in FIG6 , when multiple MWs corresponding to continuous remote memories are unbound, multiple memory window unbinding operations can be reduced to one memory window batch unbinding operation for the entire continuous remote memory address.

[0103] In this way, the number of operations can be effectively reduced, thereby improving the efficiency of remote memory access.

[0104] In some embodiments, the remote memory architecture includes a plurality of compute nodes and a plurality of remote memory nodes.

[0105] In this embodiment, the remote memory architecture may include multiple compute nodes and multiple remote memory nodes. The compute nodes have relatively large computing resources and limited memory capacity, while the remote memory nodes have limited computing resources and relatively large memory capacity. The remote memory architecture allows the compute nodes and memory nodes to scale independently, thereby improving resource utilization within the data center.

[0106] Based on the method for constructing a remote memory access protection mechanism provided in the above embodiment, the present application also provides an embodiment of a remote memory node.

[0107] FIG7 shows a schematic structural diagram of a remote memory node provided in another embodiment of the present application. For ease of explanation, only the portion related to the embodiment of the present application is shown.

[0108] 7 , a remote memory node 700 belongs to a remote memory architecture. The remote memory architecture may further include a computing node. The remote memory node 700 may include:

[0109] An acquisition module 701 is configured to acquire a permission application from a computing node. The permission application is generated based on the computing node submitting an access request from a user program to a network card queue pair. The access request includes a remote memory address.

[0110] Binding module 702, for binding the memory window to the remote content address and returning a permission symbol when the permission application is authenticated, which is used for remote memory access;

[0111] The unbinding module 703 is used to unbind the memory window from the remote content address when the remote memory access ends, so as to invalidate the permission symbol.

[0112] In some embodiments, the binding module 702 may also be used to:

[0113] If the permission request is authenticated, obtain the historical permission symbol corresponding to the ongoing remote memory access;

[0114] Determine whether the permission application conflicts with historical permission symbols;

[0115] If there is no conflict between the permission request and the historical permission symbol, the memory window is bound to the remote content address and the permission symbol is returned.

[0116] In some embodiments, the remote memory node 700 may include:

[0117] A storage module, used to store permission symbols in a hash table;

[0118] The delete module is used to delete the permission token from the hash table.

[0119] In some embodiments, the permission symbol includes lease semantics, and the lease semantics corresponds to a lease period. The unbinding module 703 can also be used to:

[0120] When the response time of remote memory access exceeds the lease period, the memory window is unbound from the remote content address to invalidate the permission token.

[0121] In some embodiments, the lease period is updated based on a user program using a unilateral access to the remote memory.

[0122] In some embodiments, the network card queue pair has a backup queue pair, wherein the backup queue pair replaces the network card queue pair in the event of a failure of the network card queue pair.

[0123] In some embodiments, the unbinding module 703 may also be used to:

[0124] When the remote memory access is completed, obtain the load pressure of the remote memory architecture and the number of unbound memory windows;

[0125] When the load pressure is less than a preset pressure threshold, or the quantity is less than a preset quantity threshold, the memory window is unbound from the remote content address to invalidate the permission symbol.

[0126] In some embodiments, the remote memory node 700 may include a processing module, which may be configured to:

[0127] Combine a memory window binding operation and an unbinding operation into a binding change operation;

[0128] When multiple remote memory addresses to be bound are consecutive addresses, multiple binding operations of the memory window are replaced with one batch binding operation.

[0129] In some embodiments, the remote memory architecture includes a plurality of compute nodes and a plurality of remote memory nodes.

[0130] It should be noted that the information interaction, execution process, etc. between the above-mentioned devices / units are based on the same concept as the method embodiment of the present application, and are devices corresponding to the above-mentioned remote memory access protection mechanism construction method. All implementation methods in the above-mentioned method embodiment are applicable to the embodiment of the device. Its specific functions and the technical effects brought about can be found in the method embodiment part, which will not be repeated here.

[0131] Those skilled in the art can clearly understand that, for the convenience and brevity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated into one processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.

[0132] FIG8 shows a schematic diagram of the hardware structure of an electronic device provided in yet another embodiment of the present application.

[0133] The device may include a processor 801 and a memory 802 storing programs or instructions.

[0134] When the processor 801 executes the program, the steps in any of the above method embodiments are implemented.

[0135] For example, the program can be divided into one or more modules / units, one or more modules / units are stored in the memory 802 and executed by the processor 801 to complete the present application. One or more modules / units can be a series of program instruction segments that can perform specific functions, and the instruction segments are used to describe the execution process of the program in the device.

[0136] Specifically, the processor 801 may include a central processing unit (CPU), or an application-specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of the embodiments of the present application.

[0137] The memory 802 may include a large capacity memory for data or instructions. By way of example and not limitation, the memory 802 may include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive, or a combination of two or more of these. Where appropriate, the memory 802 may include removable or non-removable (or fixed) media. Where appropriate, the memory 802 may be inside or outside the integrated gateway disaster recovery device. In a specific embodiment, the memory 802 is a non-volatile solid-state memory.

[0138] The memory may include read-only memory (ROM), random access memory (RAM), magnetic disk storage media devices, optical storage media devices, flash memory devices, electrical, optical or other physical / tangible memory storage devices. Thus, generally, the memory includes one or more tangible (non-transitory) machine-readable storage media (e.g., memory devices) encoded with software including computer-executable instructions, and when the software is executed (e.g., by one or more processors), it is operable to perform the operations described with reference to the method according to an aspect of the present disclosure.

[0139] The processor 801 implements any one of the methods in the above embodiments by reading and executing the program or instructions stored in the memory 802 .

[0140] In one example, the electronic device may further include a communication interface 803 and a bus 804. The processor 801, the memory 802, and the communication interface 803 are connected via the bus 804 and communicate with each other.

[0141] The communication interface 803 is mainly used to implement communication between various modules, devices, units and / or equipment in the embodiments of the present application.

[0142] Bus 804 includes hardware, software or both, and the parts of online data flow metering equipment are coupled to each other. For example, but not limitation, bus can include accelerated graphics port (AGP) or other graphics bus, enhanced industry standard architecture (EISA) bus, front side bus (FSB), hypertransport (HT) interconnection, industry standard architecture (ISA) bus, infinite bandwidth interconnection, low pin count (LPC) bus, memory bus, micro channel architecture (MCA) bus, peripheral component interconnection (PCI) bus, PCI-Express (PCI-X) bus, serial advanced technology attachment (SATA) bus, video electronics standard association local (VLB) bus or other suitable bus or two or more of these combinations. In appropriate cases, bus 804 can include one or more buses. Although the present application embodiment describes and shows specific bus, the application considers any suitable bus or interconnection.

[0143] In addition, in conjunction with the methods in the above embodiments, embodiments of the present application may be implemented by providing a machine-readable storage medium. The machine-readable storage medium stores a program or instructions; when the program or instructions are executed by a processor, any of the methods in the above embodiments is implemented. The machine-readable storage medium can be read by a machine, such as a computer.

[0144] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned method embodiment and achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0145] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.

[0146] An embodiment of the present application provides a computer program product, which is stored in a machine-readable storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned method embodiment and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0147] It should be understood that the present application is not limited to the specific configurations and processes described above and illustrated in the figures. For the sake of brevity, a detailed description of known methods is omitted here. In the above embodiments, several specific steps are described and illustrated as examples. However, the method process of the present application is not limited to the specific steps described and illustrated. Those skilled in the art can make various changes, modifications, and additions, or change the order of the steps after understanding the spirit of the present application.

[0148] The functional modules shown in the above-described block diagram can be implemented as hardware, software, firmware or a combination thereof. When implemented in hardware, it can be, for example, an electronic circuit, an application specific integrated circuit (ASIC), suitable firmware, a plug-in unit, a function card or the like. When implemented in software, the elements of the present application are programs or code segments that are used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link by a data signal carried in a carrier wave. "Machine-readable medium" can include any medium that can store or transmit information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROMs, flash memories, erasable ROMs (EROMs), floppy disks, CD-ROMs, optical disks, hard disks, optical fiber media, radio frequency (RF) links, or the like. The code segment can be downloaded via a computer grid such as the Internet, an intranet, or the like.

[0149] It should also be noted that the exemplary embodiments mentioned in this application describe some methods or systems based on a series of steps or devices. However, this application is not limited to the order of the above steps. In other words, the steps can be performed in the order mentioned in the embodiments, or in a different order, or several steps can be performed simultaneously.

[0150] Aspects of the present disclosure have been described above with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and program products according to the embodiments of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by a computer program or instruction. These programs or instructions can be provided to a processor of a general-purpose computer, a special-purpose computer or other programmable data processing device to produce a machine so that these instructions executed by the processor of the computer or other programmable data processing device enable the implementation of the function / action specified in one or more boxes of the flowchart and / or block diagram. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor or a field programmable logic circuit. It is also understood that each box in the block diagram and / or flowchart and the combination of the boxes in the block diagram and / or flowchart can also be implemented by dedicated hardware that performs a specified function or action, or can be implemented by a combination of dedicated hardware and computer instructions.

[0151] The above description is only a specific embodiment of the present application. Those skilled in the art will clearly understand that for the convenience and brevity of description, the specific working processes of the systems, modules and units described above can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here. It should be understood that the scope of protection of the present application is not limited thereto. Any person skilled in the art can easily think of various equivalent modifications or replacements within the technical scope disclosed in the present application, and these modifications or replacements should be included in the scope of protection of the present application.

Claims

1. A method for constructing a remote memory access protection mechanism, applied to a remote memory node in a remote memory architecture, wherein the remote memory architecture also includes a computing node, and the method comprises: Obtaining a permission application of the computing node, the permission application is generated based on the computing node submitting an access request of a user program to a network card queue pair, the access request including a remote memory address, If the permission application is authenticated, the memory window is bound to the remote content address and a permission symbol is returned, the permission symbol is used for remote memory access. When the remote memory access is terminated, the memory window is unbound from the remote content address to invalidate the permission symbol.

2. The method according to claim 1, wherein: When the permission application is authenticated, the memory window is bound to the remote content address, and a permission symbol is returned, including: When the permission application is authenticated, the historical permission symbol corresponding to the ongoing remote memory access is obtained. Determine whether the permission application conflicts with the historical permission symbol. In the case that there is no conflict between the permission application and the historical permission symbol, the memory window is bound to the remote content address and the permission symbol is returned.

3. The method according to claim 1 or 2, wherein: In the case where the permission application is authenticated, the memory window is bound to the remote content address, and after the permission symbol is returned, the method further includes: The permission symbol is stored in a hash table. In the case where the remote memory access is terminated, after the memory window is unbound from the remote content address to invalidate the permission symbol, the method further includes: The permission symbol is deleted from the hash table.

4. The method according to claim 1, wherein: The permission symbol includes lease semantics, and the lease semantics corresponds to a lease period. When the permission application is authenticated, the memory window is bound to the remote content address, and after the permission symbol is returned, the method further includes: When the response time of the remote memory access exceeds the lease period, the memory window is unbound from the remote content address to invalidate the permission symbol.

5. The method according to claim 4, wherein: The lease period is updated based on the user program using a remote memory unilateral access method.

6. The method according to claim 1, wherein: The network card queue pair has a standby queue pair, wherein in the event that the network card queue pair fails, the standby queue pair replaces the network card queue pair.

7. The method according to claim 1, wherein: When the remote memory access ends, unbinding the memory window from the remote content address to invalidate the permission symbol includes: When the remote memory access is completed, the load pressure of the remote memory architecture and the number of unbound memory windows are obtained. When the load pressure is less than a preset pressure threshold, or the quantity is less than a preset quantity threshold, the memory window is unbound from the remote content address to invalidate the permission symbol.

8. The method according to claim 1, further comprising: Combining a binding operation and an unbinding operation of the memory window into a binding change operation, In the case where multiple remote memory addresses to be bound are continuous addresses, multiple binding operations of the memory window are replaced with one batch binding operation.

9. The method according to claim 1, wherein: The remote memory architecture includes multiple computing nodes and multiple remote memory nodes.

10. A remote memory node, belonging to a remote memory architecture, wherein the remote memory architecture further comprises a computing node, and the remote memory node comprises: an acquisition module, configured to acquire a permission application of the computing node, wherein the permission application is generated based on the computing node submitting an access request of a user program to a network card queue pair, wherein the access request includes a remote memory address, A binding module is used to bind the memory window to the remote content address and return a permission symbol when the permission application is authenticated, wherein the permission symbol is used for remote memory access. The unbinding module is used to unbind the memory window from the remote content address when the remote memory access is completed, so as to invalidate the permission symbol.

11. An electronic device, comprising: A processor and a memory storing programs or instructions; When the processor executes the program or instruction, the method according to any one of claims 1 to 9 is implemented.

12. A machine-readable storage medium having a program or instruction stored thereon, wherein the program or instruction, when executed by a processor, implements the method according to any one of claims 1 to 9.

13. A computer program product, wherein when instructions in the computer program product are executed by a processor of an electronic device, the electronic device executes the method according to any one of claims 1 to 9.

Citation Information

Patent Citations

  • System and method for distributed shared memory on basis of hardware characteristics

    CN106844048A

  • Safety access right with time limit

    CN109559407A

  • Access request authentication method and device, storage medium and electronic equipment

    CN113014593A

  • Data transmission method, processor system and memory access system

    CN113852656A

  • Remote direct memory access authorization

    US20190141041A1