Method and device for enabling DPU to adapt to multiple operating systems, DPU and server

By running the target image file in the local operating system, entering the target image operating system, and adapting the DPU to multiple operating systems, the problem of poor compatibility in the existing technology is solved and the effect of meeting the needs of different users is achieved.

CN119415162APending Publication Date: 2025-02-11NANJING JAGUAR MICROSYSTEMS CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411482834.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-22
Publication Date
2025-02-11

AI Technical Summary

Technical Problem

Existing DPUs have poor compatibility when adapted to multiple operating systems, making it difficult to meet the usage needs of all users.

Method used

By running the target image file in the local operating system and entering the target image operating system, the DPU can adapt to multiple versions of the operating system without preinstalling the local operating system.

Benefits of technology

It realizes that the DPU is adapted to multiple operating systems without specifying a local operating system, thereby meeting different usage needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119415162A_ABST
    Figure CN119415162A_ABST
Patent Text Reader

Abstract

The invention discloses a method and device for enabling a DPU to adapt to various operating systems, the DPU and a server, the method for enabling the DPU to adapt to the various operating systems comprises the steps that an execution instruction is received, a target mirror image file is obtained from a mirror image resource module according to the execution instruction, the mirror image resource module comprises a plurality of mirror image files, and the mirror image files are sent to the server; the target mirror image file is one of the plurality of mirror image files; and running the target mirror image file in the local operating system, and entering a target mirror image operating system. According to the method and the device, the target mirror image file is operated in the local operating system, and the target mirror image operating system is entered, so that the DPU can adapt to the operating systems of various versions under the condition that the pre-installed local operating system of the DPU is not specified, and the DPU can meet different use requirements.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a method, device, DPU and server for adapting a DPU to multiple operating systems. Background Art

[0002] In cloud computing centers, DPU (Data Processing Unit) is an emerging hardware component. DPU shares the data processing tasks on the host server, allowing the host CPU to focus on executing core business, thereby improving system response speed. With the widespread application of DPU, DPU needs to adapt to various versions of operating systems to meet the needs of different users and application scenarios.

[0003] Currently, when solving the operating system adaptation problem, the main method used by DPU manufacturers is to pre-install a specific version of the operating system for the DPU.

[0004] However, the method of pre-installing the operating system has poor compatibility, and a specific version of the operating system is often difficult to meet the usage requirements of all users. Summary of the invention

[0005] In view of the shortcomings of the prior art, the present application provides a method, device, DPU and server for adapting a DPU to multiple operating systems. By running a target image file in a local operating system and entering the target image operating system, the DPU can be adapted to multiple versions of operating systems without specifying a local operating system pre-installed on the DPU, thereby enabling the DPU to meet different usage requirements.

[0006] To solve the above problems, the present invention provides the following technical solutions:

[0007] In a first aspect, an embodiment of the present application provides a method for adapting a DPU to multiple operating systems, which is applied to a DPU, and the method includes:

[0008] receiving an execution instruction, and acquiring a target image file from an image resource module according to the execution instruction, wherein the image resource module includes a plurality of image files, and the target image file is one of the plurality of image files;

[0009] The target image file is run in the local operating system to enter the target image operating system.

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

[0011] An operation instruction is received, and the target DPU service software in the target image operating system is operated according to the operation instruction.

[0012] In some implementations, the receiving an execution instruction and obtaining a target image file from an image resource module according to the execution instruction includes:

[0013] The container engine receives the execution instruction and obtains the target image file from the image resource module;

[0014] The step of running the target image file in the local operating system to enter the target image operating system includes:

[0015] The container engine runs the target image file in the local operating system and enters the target image operating system.

[0016] In a second aspect, an embodiment of the present application provides a method for adapting a DPU to multiple operating systems, which is applied to a server, and is characterized in that the method includes:

[0017] Get the system kernel corresponding to each image operating system version;

[0018] Obtaining a patch file adapted to each of the system kernels, wherein the patch file is used to extend the functions of the mirror operating system;

[0019] Each of the system kernels is compiled according to the patch file to obtain an initial image file corresponding to each image operating system version.

[0020] In some implementations, the obtaining a patch file adapted to each of the system kernels includes:

[0021] Get the patch file list corresponding to each image operating system version;

[0022] The patch file adapted to each of the system kernels is obtained according to the patch file list.

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

[0024] Obtaining an installation file of the DPU service software adapted to each of the initial image files;

[0025] Each of the initial image files is compiled according to the installation file of the DPU service software to obtain a final image file corresponding to each image operating system version.

[0026] In a third aspect, an embodiment of the present application provides a device for adapting a DPU to multiple operating systems, which is applied to a DPU, and the device includes an image management module, and the image management module is connected to the image resource module;

[0027] The image management module is used to receive an execution instruction, and obtain a target image file from the image resource module according to the execution instruction, wherein the image resource module includes a plurality of image files, and the target image file is one of the plurality of image files;

[0028] The image management module is also used to run the target image file in the local operating system to enter the target image operating system.

[0029] In a fourth aspect, an embodiment of the present application provides a device for adapting a DPU to multiple operating systems, which is applied to a server, wherein the device includes a kernel driver adaptation module and an image resource module, wherein the kernel driver adaptation module is used to obtain a system kernel corresponding to each image operating system version; obtain a patch file adapted to each of the system kernels, wherein the patch file is used to functionally expand the image operating system; compile each of the system kernels according to the patch file to obtain an initial image file corresponding to each image operating system version;

[0030] The image resource module is used to store multiple image files.

[0031] In a fifth aspect, an embodiment of the present application provides a DPU, wherein the DPU includes:

[0032] at least one processor; and,

[0033] a memory communicatively connected to the at least one processor; wherein,

[0034] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method for adapting the DPU to multiple operating systems as described in the first aspect.

[0035] In a sixth aspect, an embodiment of the present application provides a server, comprising the DPU as described in the fifth aspect.

[0036] In a seventh aspect, an embodiment of the present application provides a server, the server comprising:

[0037] at least one processor; and,

[0038] a memory communicatively connected to the at least one processor; wherein,

[0039] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method for adapting the DPU to multiple operating systems as described in the second aspect.

[0040] The present application provides a method, device, DPU and server for adapting a DPU to multiple operating systems. The present application runs a target image file in a local operating system to enter the target image operating system, and can adapt the DPU to multiple versions of operating systems without specifying a local operating system pre-installed on the DPU, thereby enabling the DPU to meet different usage requirements. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Figure 1 It is a flowchart of a first implementation of a first method for adapting a DPU to multiple operating systems provided in an embodiment of the present application.

[0042] Figure 2 It is a flowchart of the second implementation of the first method for adapting a DPU to multiple operating systems provided in an embodiment of the present application.

[0043] Figure 3 It is a flowchart of the first implementation of the second method for adapting a DPU to multiple operating systems provided in an embodiment of the present application.

[0044] Figure 4 It is a flowchart of a second implementation of a second method for adapting a DPU to multiple operating systems provided in an embodiment of the present application.

[0045] Figure 5 It is a structural diagram of a first device for adapting a DPU to multiple operating systems provided in an embodiment of the present application.

[0046] Figure 6 It is a structural diagram of a first implementation of a second device for adapting a DPU to multiple operating systems provided in an embodiment of the present application.

[0047] Figure 7 It is a structural diagram of a second implementation of a second device for adapting a DPU to multiple operating systems provided in an embodiment of the present application.

[0048] Figure 8 It is a schematic diagram of the structure of the DPU provided in an embodiment of the present application.

[0049] Fig. 9 It is a schematic diagram of the structure of the server provided in the embodiment of the present application.

[0050] Fig.10 It is a structural block diagram of a computer-readable storage medium provided in an embodiment of the present application. DETAILED DESCRIPTION

[0051] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only 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.

[0052] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.

[0053] The present application provides a method, device, DPU and server for adapting a DPU to multiple operating systems. By running a target image file in a local operating system and entering the target image operating system, the DPU can be adapted to multiple versions of operating systems without specifying a local operating system pre-installed on the DPU, thereby enabling the DPU to meet different usage requirements.

[0054] The method for adapting a DPU to multiple operating systems provided by the present application will be described in detail below with reference to the accompanying drawings.

[0055] The present application provides a first method for adapting a DPU to multiple operating systems, which is applied to a DPU.

[0056] See also Figure 1 , Figure 1 1 is a flow chart of a first implementation of a first method for adapting a DPU to multiple operating systems provided in an embodiment of the present application. Figure 1 As shown, the first method for adapting a DPU to multiple operating systems includes: steps S100 to S200.

[0057] Step S100: receiving an execution instruction, and obtaining a target image file from an image resource module according to the execution instruction.

[0058] The image resource module includes multiple image files, and the target image file is one of the multiple image files.

[0059] In some implementations, the mirror resource module is stored in a mirror resource server connected to the DPU.

[0060] Optionally, the DPU is connected to an image resource server via a network to obtain a target image file from the image resource module.

[0061] In some embodiments, the DPU includes a local operating system.

[0062] In some implementations, the execution instruction includes specified information of the target image file.

[0063] In some implementations, the local operating system of the DPU is used to receive an execution instruction, select an image file as the target image file from multiple image files in the image resource module according to the specified information of the target image file in the execution instruction, and download the target image file.

[0064] Optionally, the specified information of the target image file is an identifier or a storage address of the target image file.

[0065] In some implementations, the local operating system of the DPU includes a container engine, which is used to obtain and run an image file in the image resource module.

[0066] An image file is a lightweight, independent, executable software package that contains all the code, libraries, environment variables, and configuration files needed to run the operating system.

[0067] Optionally, the container engine is also used to manage multiple image files in the image resource module.

[0068] Optionally, the container engine may be a Docker container engine.

[0069] In some implementations, the container engine receives the execution instruction and obtains the target image file from the image resource module.

[0070] In some implementations, running the target image file may enter the target image operating system in the local operating system of the DPU, where the target image operating system is an operating system specified by a user to be used on the DPU.

[0071] Step S200: Run the target image file in the local operating system to enter the target image operating system.

[0072] In some implementations, the container engine runs the target image file in the local operating system and enters the target image operating system.

[0073] Optionally, the target image operating system is a container generated by the container engine running the target image file. A container is a running instance of an image file. A container is an isolated, lightweight running environment.

[0074] By running the target image file in the local operating system and entering the target image operating system, the DPU can be adapted to multiple versions of operating systems without specifying the local operating system pre-installed on the DPU, thereby enabling the DPU to meet different usage requirements.

[0075] See also Figure 2 , Figure 2 1 is a flow chart of a second implementation of the first method for adapting a DPU to multiple operating systems provided in an embodiment of the present application. Figure 2 As shown, in some implementations, the first method for adapting the DPU to multiple operating systems includes: steps S100 to S300.

[0076] Step S100: receiving an execution instruction, and obtaining a target image file from an image resource module according to the execution instruction.

[0077] Step S200: Run the target image file in the local operating system to enter the target image operating system.

[0078] The contents of step S100 to step S200 refer to the above description.

[0079] Step S300: receiving an operation instruction, and running the target DPU service software in the target image operating system according to the operation instruction.

[0080] In some implementations, the target mirror operating system includes a plurality of DPU service software, and the DPU service software is used to extend the functionality of the mirror operating system.

[0081] In some embodiments, the DPU service software includes OVS (Open vSwitch, open virtual switch) software, DPDK (Data Plane Development Kit) software, RDMA (Remote Direct Memory Access, remote direct memory access) software and PCI (Peripheral Component Interconnect, peripheral component interconnect) device simulation software, etc.

[0082] In some embodiments, OVS software is used to implement network bridging functions in a network virtualization environment. DPDK software is used to improve the performance and efficiency of network packet processing. RDMA software is used to implement remote direct memory access. PCI device simulation software is used to simulate PCI or PCIE (PCI Express) devices so that the host server connected to the DPU can identify and use the resources of the simulated PCI or PCIE devices.

[0083] In some implementations, the target DPU service software is a target DPU service software among the multiple DPU service softwares, and the target DPU service software is also the DPU service software specified by the user to be used. In this way, the DPU can further meet different usage requirements.

[0084] The present application also provides a second method for adapting a DPU to multiple operating systems, which is applied to a server. The server is a mirror resource server connected to the DPU.

[0085] See also Figure 3 , Figure 3 1 is a flow chart of a first implementation of a second method for adapting a DPU to multiple operating systems provided in an embodiment of the present application. Figure 3 As shown, the second method for adapting the DPU to multiple operating systems includes: steps S400 to S600.

[0086] Step S400: Obtain the system kernel corresponding to each mirror operating system version.

[0087] In some implementations, the system kernel is a Linux operating system kernel. The Linux operating system is an open source and free operating system based on Unix. The Linux operating system usually has different versions, and the source code of the system kernel corresponding to each version is different.

[0088] In some implementations, there are multiple versions of the mirrored operating system.

[0089] In some embodiments, the mirror operating system versions include openEuler, Ubuntu, Dragon Lizard, BC-Linux, CentOS 8, and Kylin, etc.

[0090] In some implementations, the system kernel may also be the kernel of other operating systems, such as the kernel of a Windows operating system or a kernel of a BSD operating system.

[0091] Step S500: Obtain a patch file adapted to each system kernel.

[0092] Among them, the patch file is used to expand the functions of the mirror operating system.

[0093] In some implementations, the patch file is used to implement the target functionality of the DPU.

[0094] Exemplarily, the target function of the DPU includes a peripheral driver reporting function of the DPU.

[0095] In some implementations, there are multiple patch files adapted to one system kernel, and all patch files adapted to one system kernel need to be acquired.

[0096] In some embodiments, step S500 includes step (500.1) to step (500.2).

[0097] (500.1) Obtain a list of patch files corresponding to each image operating system version.

[0098] In some implementations, a patch file list includes identifiers of all patch files adapted to a system kernel corresponding to an image operating system version.

[0099] (500.2) Obtain a patch file adapted to each system kernel according to the patch file list.

[0100] In some implementations, for each system kernel, all patch files adapted to the system kernel are acquired according to a patch file list corresponding to the system kernel.

[0101] Optionally, all patch files are acquired according to identifiers of all patch files in the patch file list.

[0102] Optionally, the server has stored all patch files, the identifier of the patch file in the patch file list is the storage address of the patch file, and the server obtains the patch file according to the storage address of the patch file.

[0103] Optionally, the identifier of the patch file in the patch file list is the name or download address of the patch file, and the server downloads the patch file from the Internet according to the name or download address of the patch file.

[0104] Step S600: Compile each system kernel according to the patch file to obtain an initial image file corresponding to each image operating system version.

[0105] In some implementations, one image operating system version corresponds to one system kernel, and one system kernel corresponds to multiple patch files. Thus, multiple patch files corresponding to one image operating system version can be obtained.

[0106] In some implementations, a system kernel corresponding to an image operating system version is compiled according to all patch files corresponding to the image operating system version to obtain an initial image file corresponding to the image operating system version.

[0107] In some implementations, when the mirror operating system does not need to include the DPU service software, the initial mirror file is the mirror file included in the mirror resource module. After executing step S600, the server stores all initial mirror files in the mirror resource module.

[0108] See also Figure 4 , Figure 4 1 is a flow chart of a second implementation of a second method for adapting a DPU to multiple operating systems provided in an embodiment of the present application. Figure 4As shown, in some embodiments, the second method for adapting the DPU to multiple operating systems includes: steps S400 to S800.

[0109] Step S400: Obtain the system kernel corresponding to each mirror operating system version.

[0110] Step S500: Obtain a patch file adapted to each system kernel.

[0111] Step S600: Compile each system kernel according to the patch file to obtain an initial image file corresponding to each image operating system version.

[0112] Steps S400 to S600 refer to the above description.

[0113] Step S700: Obtain the installation file of the DPU service software adapted to each initial image file.

[0114] In some implementations, there are multiple DPU service software that are compatible with one initial image file, and it is necessary to obtain all DPU service software that are compatible with one initial image file.

[0115] In some embodiments, step S700 includes step (700.1) to step (700.2).

[0116] (700.1) Obtain a list of DPU service software files corresponding to each initial image file.

[0117] In some implementations, a DPU service software file list includes identifiers of installation files of all DPU service software that are compatible with a corresponding initial image file.

[0118] (700.2) Obtain the installation file of the DPU business software compatible with each initial image file according to the DPU business software file list.

[0119] In some implementations, for each initial image file, installation files of all DPU service software compatible with the initial image file are obtained according to a DPU service software file list corresponding to the initial image file.

[0120] Optionally, the installation files of all the DPU service software are acquired according to the identifiers of the installation files of all the DPU service software in the DPU service software list.

[0121] Optionally, the server has stored the installation files of all DPU business software, the identifier of the DPU business software is the storage address of the installation file of the DPU business software, and the server obtains the installation file of the DPU business software according to the storage address of the installation file of the DPU business software.

[0122] Optionally, the identifier of the DPU service software is the name or download address of the DPU service software, and the server downloads the installation file of the DPU service software from the Internet according to the name or download address of the DPU service software.

[0123] Step S800: Compile each initial image file according to the installation file of the DPU service software to obtain a final image file corresponding to each image operating system version.

[0124] In some implementations, an initial image file is compiled according to installation files of all DPU service software corresponding to the initial image file to obtain a final image file.

[0125] In some implementations, when the mirror operating system needs to include DPU service software, the final mirror file is the mirror file included in the mirror resource module. After executing step S800, the server stores all final mirror files in the mirror resource module.

[0126] In summary, the method for adapting a DPU to multiple operating systems provided in the embodiment of the present application includes the following advantages:

[0127] 1. By running the target image file in the local operating system and entering the target image operating system, the DPU can be adapted to multiple versions of operating systems without specifying the local operating system pre-installed on the DPU, so that the DPU can meet different usage requirements.

[0128] 2. By including the DPU business software in the target mirror operating system, the DPU can further meet different usage requirements.

[0129] The present application also provides a first device for adapting a DPU to multiple operating systems, which is applied to a DPU and is used to implement the first method for adapting a DPU to multiple operating systems as described above.

[0130] See also Figure 5 , Figure 5 is a schematic diagram of the structure of a first device for adapting a DPU to multiple operating systems provided in an embodiment of the present application. Figure 5 As shown, in some embodiments, the first device 100 for adapting the DPU to multiple operating systems includes an image management module 110.

[0131] In some embodiments, the first device 100 for adapting the DPU to multiple operating systems is a native operating system of the DPU.

[0132] In some implementations, the image management module 110 is connected to the image resource module.

[0133] Optionally, the mirror resource module is stored in a mirror resource server.

[0134] In some implementations, the image management module 110 is used to receive an execution instruction and obtain a target image file from the image resource module according to the execution instruction. The image resource module includes multiple image files, and the target image file is one of the multiple image files.

[0135] In some implementations, the image management module 110 is further configured to run the target image file in the local operating system to enter the target image operating system.

[0136] Optionally, the image management module 110 is a container engine.

[0137] The present application also provides a second device for adapting a DPU to multiple operating systems, which is applied to a server and is used to implement the second method for adapting a DPU to multiple operating systems as described above.

[0138] See also Figure 6 , Figure 6 1 is a schematic diagram of the structure of the first implementation of the second device for adapting the DPU to multiple operating systems provided in the embodiment of the present application. Figure 6 As shown, in some embodiments, the second device 200 for adapting the DPU to multiple operating systems includes a kernel driver adaptation module 210 and a mirror resource module 220.

[0139] In some embodiments, the kernel driver adaptation module 210 is used to obtain a system kernel corresponding to each mirror operating system version; obtain a patch file adapted to each system kernel, wherein the patch file is used to expand the functionality of the mirror operating system; compile each system kernel according to the patch file to obtain an initial image file corresponding to each mirror operating system version.

[0140] In some implementations, the image resource module 220 is used to store multiple image files, and the image resource module 220 is connected to the image management module 110 .

[0141] See also Figure 7 , Figure 7 1 is a schematic diagram of the structure of the second implementation of the second device for adapting the DPU to multiple operating systems provided in the embodiment of the present application. Figure 7 As shown, in some embodiments, the second device 200 for adapting the DPU to multiple operating systems also includes a DPU business software adaptation module 230.

[0142] In some embodiments, the DPU business software adaptation module 230 is used to obtain the installation file of the DPU business software adapted to each initial image file; compile each initial image file according to the installation file of the DPU business software to obtain the final image file corresponding to each image operating system version.

[0143] See also Figure 8 , Figure 8 Schematic diagram of the structure of the DPU provided in the embodiment of the present application. Figure 8 As shown, DPU 400 includes: one or more processors 410 and a memory 420, Figure 8 A processor 410 is taken as an example.

[0144] In some implementations, the processor 410 and the memory 420 may be connected via a bus or other means. Figure 8 The example of connecting through bus is taken in the following.

[0145] In some embodiments, the processor 410 is used to receive an execution instruction, obtain a target image file from an image resource module according to the execution instruction, wherein the image resource module includes multiple image files, and the target image file is one of the multiple image files; run the target image file in a local operating system to enter the target image operating system.

[0146] In some embodiments, the memory 420, as a non-volatile computer-readable storage medium, can be used to store non-volatile software programs, non-volatile computer executable programs and modules, such as the program instructions / modules of the first method for adapting the DPU to multiple operating systems in the embodiment of the present application. The processor 410 executes various functional applications and data processing of the DPU 400 by running the non-volatile software programs, instructions and modules stored in the memory 420, that is, the first method for adapting the DPU to multiple operating systems in the above method embodiment is implemented.

[0147] In some embodiments, the memory 420 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required by at least one function; the data storage area may store data created according to the use of the DPU 400, etc. In addition, the memory 420 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some embodiments, the memory 420 may optionally include a memory remotely arranged relative to the processor 410, and these remote memories may be connected to the controller via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0148] In some embodiments, one or more modules are stored in the memory 420, and when executed by one or more processors 410, the first method for adapting the DPU to multiple operating systems in any of the above method embodiments is executed, for example, the first method described above is executed. Figure 1 The method comprises steps S100 to S200.

[0149] In some embodiments, the present application also provides a server, comprising the DPU as described above.

[0150] See also Fig. 9 , Fig. 9 Schematic diagram of the structure of the server provided in the embodiment of the present application. Fig. 9 As shown, the server 500 includes: one or more processors 510 and a memory 520, Fig. 9 A processor 510 is taken as an example.

[0151] In some implementations, the processor 510 and the memory 520 may be connected via a bus or other means. Fig. 9 The example of connecting through bus is taken in the following.

[0152] In some embodiments, the processor 510 is used to obtain a system kernel corresponding to each image operating system version; obtain a patch file adapted for each system kernel, wherein the patch file is used to expand the functionality of the image operating system; and compile each system kernel according to the patch file to obtain an initial image file corresponding to each image operating system version.

[0153] In some embodiments, the memory 520, as a non-volatile computer-readable storage medium, can be used to store non-volatile software programs, non-volatile computer executable programs and modules, such as the program instructions / modules of the second method for adapting the DPU to multiple operating systems in the embodiment of the present application. The processor 510 executes various functional applications and data processing of the server 500 by running the non-volatile software programs, instructions and modules stored in the memory 520, that is, the second method for adapting the DPU to multiple operating systems in the above method embodiment is implemented.

[0154] In some embodiments, the memory 520 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the server 500, etc. In addition, the memory 520 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some embodiments, the memory 520 may optionally include a memory remotely arranged relative to the processor 510, and these remote memories may be connected to the controller via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0155] In some embodiments, one or more modules are stored in the memory 520, and when executed by one or more processors 510, the second method for adapting the DPU to multiple operating systems in any of the above method embodiments is executed, for example, the second method described above is executed. Figure 3 The method comprises steps S400 to S600.

[0156] Please refer to Fig.10 , Fig.10 6 is a block diagram of a computer-readable storage medium provided in an embodiment of the present application. The computer-readable storage medium 600 stores a program code 610, which can be called by a processor to execute the method for adapting a DPU to multiple operating systems described in the above method embodiment.

[0157] The computer readable storage medium 600 may be an electronic memory such as a flash memory, an EEPROM (Electrically Erasable Programmable Read Only Memory), an EPROM, a hard disk or a ROM. Optionally, the computer readable storage medium includes a non-transitory computer readable storage medium. The computer readable storage medium 600 has storage space for program codes for executing any method steps in the above-mentioned method for adapting a DPU to multiple operating systems. These program codes may be read from or written to one or more computer program products. The program code may be compressed, for example, in an appropriate form.

[0158] In some implementations, the embodiments of the present application further provide a computer program product, including a computer program, which, when executed by a processor, implements the above-mentioned method for adapting a DPU to multiple operating systems.

[0159] In summary, the present application provides a method, device, DPU and server for adapting a DPU to multiple operating systems. The method for adapting a DPU to multiple operating systems includes receiving an execution instruction, obtaining a target image file from an image resource module according to the execution instruction, wherein the image resource module includes multiple image files, and the target image file is one of the multiple image files; running the target image file in a local operating system to enter the target image operating system. The present application can adapt a DPU to multiple versions of operating systems without specifying a local operating system pre-installed on the DPU, thereby enabling the DPU to meet different usage requirements.

[0160] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims

1. A method for adapting a DPU to multiple operating systems, characterized in that: Applied to a DPU, the method comprises: receiving an execution instruction, and acquiring a target image file from an image resource module according to the execution instruction, wherein the image resource module includes a plurality of image files, and the target image file is one of the plurality of image files; The target image file is run in the local operating system to enter the target image operating system.

2. The method for adapting a DPU to multiple operating systems according to claim 1, characterized in that: The method further comprises: An operation instruction is received, and the target DPU service software in the target image operating system is operated according to the operation instruction.

3. The method for adapting a DPU to multiple operating systems according to claim 1, characterized in that: The receiving the execution instruction and obtaining the target image file from the image resource module according to the execution instruction includes: The container engine receives the execution instruction and obtains the target image file from the image resource module; The step of running the target image file in the local operating system to enter the target image operating system includes: The container engine runs the target image file in the local operating system and enters the target image operating system.

4. A method for adapting a DPU to multiple operating systems, applied to a server, characterized in that: The method comprises: Get the system kernel corresponding to each image operating system version; Obtaining a patch file adapted to each of the system kernels, wherein the patch file is used to extend the functions of the mirror operating system; Each of the system kernels is compiled according to the patch file to obtain an initial image file corresponding to each image operating system version.

5. The method for adapting a DPU to multiple operating systems according to claim 4, characterized in that: The step of obtaining a patch file adapted to each of the system kernels includes: Get the patch file list corresponding to each image operating system version; The patch file adapted to each of the system kernels is obtained according to the patch file list.

6. The method for adapting a DPU to multiple operating systems according to claim 4 or 5, characterized in that: The method further comprises: Obtaining an installation file of the DPU service software adapted to each of the initial image files; Each of the initial image files is compiled according to the installation file of the DPU service software to obtain a final image file corresponding to each image operating system version.

7. A device for adapting a DPU to multiple operating systems, applied to a DPU, characterized in that: The device includes an image management module, and the image management module is connected to the image resource module; The image management module is used to receive an execution instruction, and obtain a target image file from the image resource module according to the execution instruction, wherein the image resource module includes a plurality of image files, and the target image file is one of the plurality of image files; The image management module is also used to run the target image file in the local operating system to enter the target image operating system.

8. A device for adapting a DPU to multiple operating systems, applied to a server, characterized in that: The device includes a kernel driver adaptation module and a mirror resource module, wherein the kernel driver adaptation module is used to obtain a system kernel corresponding to each mirror operating system version; obtain a patch file adapted to each of the system kernels, wherein the patch file is used to extend the function of the mirror operating system; compile each of the system kernels according to the patch file to obtain an initial mirror file corresponding to each mirror operating system version; The image resource module is used to store multiple image files.

9. A DPU, characterized in that: The DPU includes: at least one processor; and, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method for adapting the DPU to multiple operating systems as described in any one of claims 1 to 3.

10. A server, characterized in that: Comprising the DPU as claimed in claim 9.

11. A server, characterized in that: The server comprises: at least one processor; and, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method for adapting the DPU to multiple operating systems as described in any one of claims 4 to 6.