Data processing method, device, electronic device and storage medium

By establishing a LAN connection between the operating system and BMC and using USB to simulate a LAN channel, the complexity and inconsistency of in-band refresh tools for domestic servers were solved, the tools were unified and standardized, and work efficiency was improved.

CN119847570BActive Publication Date: 2025-10-03INSPUR (SHANDONG) COMPUTER TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510329085.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-03-20
Publication Date
2025-10-03
Estimated Expiration
2045-03-20

AI Technical Summary

Technical Problem

The in-band refresh tools of domestic servers are complicated to operate and maintain because they rely on components within the operating system and hardware differences. They need to distinguish between the operating system, flash chip type and tool version, causing inconvenience in R&D, customer service and operation and maintenance.

Method used

By obtaining the chip model of the baseboard management controller, determining the identification file, establishing a local area network connection between the operating system and the BMC, and using the USB function to simulate the LAN channel, the firmware can be refreshed.

Benefits of technology

It has achieved the unification and standardization of in-band refresh tools for domestic servers, reduced the workload of R&D, customer service and operation and maintenance, improved work efficiency, and supported unified refresh of multiple operating systems and BMC chip types.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119847570B_ABST
    Figure CN119847570B_ABST
Patent Text Reader

Abstract

The present disclosure provides a data processing method, apparatus, electronic device, and storage medium, applicable to the field of computer technology. The method comprises: obtaining a baseboard management controller (BMC) chip model based on a first instruction; determining an identification file based on the BMC chip model; copying the identification file to a rule file directory to identify the BMC; controlling the BMC to enable a local area network (LAN) function based on a second instruction; setting network parameters of a universal serial bus (USB) network card (NIC) of the BMC based on a third instruction; and transmitting in-band refresh parameters to the BMC via the LAN. In this manner, a LAN connection can be established between an operating system and the BMC, enabling the BMC to perform firmware refresh based on the in-band refresh parameters, thereby achieving standardization and unification of in-band refresh.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, and in particular to a data processing method, device, electronic device, and storage medium. Background Art

[0002] Currently, common in-band refresh tools for domestic servers include many versions. They rely on various components in the operating system, such as the Library for Cryptographic Operations (libcrypto), the Graphics Development Kit (libgdk), and the GNU Database Manager (libgdbm), as well as server hardware. This leads to the complexity of in-band refresh operations during server operation and maintenance. It is necessary to first distinguish which operating system each server is configured with, which in-band refresh tool it supports, and which flash chip it uses. Then, the corresponding tools must be developed and the user must be familiar with how to use the tools. Sometimes, different operating system versions may change a component, causing the previously adapted in-band refresh tool to be unable to be used normally. This causes great inconvenience to R&D, customer service, factories, and operations and maintenance. Summary of the Invention

[0003] The present disclosure provides a data processing method, device, electronic device and storage medium to at least solve the above technical problems existing in the prior art.

[0004] According to a first aspect of the present disclosure, there is provided a data processing method, which is applied to an operating system, and the method includes:

[0005] Acquire a chip model of a baseboard management controller based on the first instruction;

[0006] Determine an identification file based on the chip model of the baseboard management controller; different chip models correspond to different identification files; the identification file includes a file for identifying the baseboard management controller;

[0007] Copying the identification file to a rule file directory to identify the baseboard management controller;

[0008] Controlling the baseboard management controller to enable a local area network function based on the second instruction; the local area network function includes allowing a universal serial bus to enable a local area network function;

[0009] Setting the network parameters of the universal serial bus network card of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller are connected to the local area network based on the universal serial bus;

[0010] An in-band refresh parameter is transmitted to a baseboard management controller based on the local area network, so that the baseboard management controller performs firmware refresh based on the in-band refresh parameter.

[0011] In the above solution, the step of obtaining the chip model of the baseboard management controller based on the first instruction includes:

[0012] Sending a first instruction to the baseboard management controller based on the intelligent platform management interface;

[0013] Receive the chip model of the baseboard management controller returned by the baseboard management controller based on the first instruction.

[0014] In the above solution, the step of determining the identification file based on the chip model of the baseboard management controller includes:

[0015] In response to the chip model of the baseboard management controller being the first model, determining that the identification file is the first file;

[0016] Configure parameters corresponding to the first model chip in the first file.

[0017] In the above solution, the step of determining the identification file based on the chip model of the baseboard management controller includes:

[0018] In response to the chip model of the baseboard management controller being the second model, determining that the identification file is the second file;

[0019] Configure parameters corresponding to the second model chip in the second file.

[0020] In the above solution, the parameters include at least one of a vendor identification code parameter, a product identification code parameter, a kernel parameter, a symbolic link parameter, and a subsystem parameter.

[0021] In the above solution, copying the identification file to the rule file directory to identify the baseboard management controller includes:

[0022] Copy the recognition file to the rule file directory,

[0023] The rule file directory is loaded so that the operating system can identify the baseboard management controller based on the identification file.

[0024] In the above solution, the step of controlling the baseboard management controller to enable the local area network function based on the second instruction includes:

[0025] The second instruction is sent to the baseboard management controller based on the intelligent platform management interface, so that the baseboard management controller enables the local area network function based on the second instruction.

[0026] In the above solution, the step of setting the network parameters of the universal serial bus network card of the baseboard management controller based on the third instruction includes:

[0027] Sending the third instruction to the baseboard management controller based on the intelligent platform management interface, so that the baseboard management controller sets the network parameters of the universal serial bus network card of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller are connected to the local area network based on the universal serial bus;

[0028] The network parameters include an Internet Protocol address and a gateway.

[0029] In the above solution, the method further includes:

[0030] The network parameters of the virtual universal serial bus network card of the operating system are configured based on the fourth instruction, so that the operating system and the baseboard management controller belong to the same local area network.

[0031] In the above solution, the transmitting of the in-band refresh parameters to the baseboard management controller based on the local area network includes:

[0032] Update the in-band flash parameters of the firmware to be flashed in the configuration file;

[0033] Transmitting the in-band refresh parameters to the baseboard management controller based on the local area network; so that the baseboard management controller writes the in-band refresh parameters;

[0034] A corresponding uniform resource locator in a baseboard management controller is called based on the fifth instruction, so that the baseboard management controller performs firmware refresh based on the in-band refresh parameter.

[0035] According to a second aspect of the present disclosure, a data processing method is provided, which is applied to a baseboard management controller. The method includes:

[0036] receiving a first instruction, and sending a chip model of the baseboard management controller to an operating system based on the first instruction;

[0037] receiving a second instruction, and enabling a local area network function based on the second instruction;

[0038] receiving a third instruction, and setting network parameters of a universal serial bus network card of a baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller are connected to a local area network based on the universal serial bus;

[0039] An in-band refresh parameter is received based on the local area network, and a firmware refresh is performed based on the in-band refresh parameter.

[0040] In the above solution, the receiving of in-band refresh parameters based on the local area network and performing firmware refresh based on the in-band refresh parameters include:

[0041] Writing the in-band refresh parameters into the flash memory in the baseboard management controller;

[0042] The corresponding uniform resource locator in the baseboard management controller is called based on the fifth instruction sent by the operating system, and the firmware is refreshed based on the in-band refresh parameter.

[0043] According to a third aspect of the present disclosure, there is provided a data processing device, applied to a server corresponding to an operating system, the device comprising:

[0044] An acquiring unit, configured to acquire a chip model of a baseboard management controller based on a first instruction;

[0045] A file determining unit, configured to determine an identification file based on a chip model of the baseboard management controller; different chip models correspond to different identification files; the identification file includes a file for identifying the baseboard management controller;

[0046] A loading unit, configured to copy the identification file to a rule file directory to identify the baseboard management controller;

[0047] A first control unit is configured to control the baseboard management controller to enable a local area network function based on the second instruction; the local area network function includes allowing a universal serial bus to enable the local area network function;

[0048] a second control unit, configured to set network parameters of a universal serial bus network card of the baseboard management controller based on a third instruction, so that the operating system and the baseboard management controller are connected to a local area network based on the universal serial bus;

[0049] The third control unit is configured to transmit an in-band refresh parameter to a baseboard management controller based on the local area network, so that the baseboard management controller performs firmware refresh based on the in-band refresh parameter.

[0050] According to a fourth aspect of the present disclosure, a data processing device is provided, which is applied to a baseboard management controller. The device includes:

[0051] A first receiving unit is configured to receive a first instruction, and send a chip model of the baseboard management controller to an operating system based on the first instruction;

[0052] a second receiving unit, configured to receive a second instruction, and enable a local area network function of the universal serial bus based on the second instruction;

[0053] a third receiving unit, configured to receive a third instruction, and set network parameters of a universal serial bus network card of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller are connected to a local area network based on the universal serial bus;

[0054] An in-band refresh unit is configured to receive in-band refresh parameters based on the local area network and perform firmware refresh based on the in-band refresh parameters.

[0055] According to a fifth aspect of the present disclosure, there is provided an electronic device, including:

[0056] at least one processor; and

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

[0058] The memory stores instructions that can be executed by the at least one processor. The instructions are executed by the at least one processor to enable the at least one processor to perform the method described in the present disclosure.

[0059] According to a sixth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute the method described in the present disclosure.

[0060] The data processing method disclosed herein obtains the chip model of a baseboard management controller based on a first instruction; determines an identification file based on the chip model of the baseboard management controller; different chip models correspond to different identification files; the identification file includes a file for identifying the baseboard management controller; the identification file is copied to a rule file directory to identify the baseboard management controller; controls the baseboard management controller to enable a local area network function based on a second instruction; the local area network function includes allowing a universal serial bus to enable the local area network function; sets the network parameters of the universal serial bus network card of the baseboard management controller based on a third instruction so that the operating system and the baseboard management controller establish a local area network connection based on the universal serial bus; transmits an in-band refresh parameter to the baseboard management controller based on the local area network so that the baseboard management controller performs a firmware refresh based on the in-band refresh parameter. In this way, a local area network connection can be established between the operating system and the baseboard management controller based on the universal serial bus LAN function possessed by both the operating system and the baseboard management controller, so that the baseboard management controller performs a firmware refresh based on the in-band refresh parameter, thereby achieving standardization and unification of in-band refresh.

[0061] It should be understood that the contents described in this section are not intended to identify the key or important features of the embodiments of the present disclosure, nor are they intended to limit the scope of the present disclosure. Other features of the present disclosure will become readily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0062] The above and other objects, features and advantages of the exemplary embodiments of the present disclosure will become readily understood by reading the detailed description below with reference to the accompanying drawings, in which several embodiments of the present disclosure are shown by way of example and not limitation, wherein:

[0063] In the drawings, the same or corresponding reference numerals denote the same or corresponding parts.

[0064] Figure 1 A first optional flow chart of the data processing method provided by an embodiment of the present disclosure is shown;

[0065] Figure 2 A second optional flow chart of the data processing method provided by the embodiment of the present disclosure is shown;

[0066] Figure 3 A third optional flow chart of the data processing method provided by the embodiment of the present disclosure is shown;

[0067] Figure 4 A fourth optional flow chart of the data processing method provided by an embodiment of the present disclosure is shown;

[0068] Figure 5 A first optional structural diagram of a data processing device provided by an embodiment of the present disclosure is shown;

[0069] Figure 6 A second optional structural diagram of the data processing device provided by an embodiment of the present disclosure is shown;

[0070] Figure 7 A schematic diagram of the structure of an electronic device according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION

[0071] To make the purposes, features, and advantages of the present disclosure more apparent and understandable, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present disclosure, not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of the present disclosure without creative work shall fall within the scope of protection of the present disclosure.

[0072] In the following description, reference is made to “some embodiments”, which describes a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0073] In the following description, the terms "first\second" are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It is understandable that "first\second" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present disclosure described herein can be implemented in an order other than that illustrated or described herein.

[0074] Unless otherwise defined, all technical and scientific terms used in this disclosure have the same meaning as commonly understood by those skilled in the art in the art of this disclosure. The terms used in this disclosure are only for the purpose of describing the embodiments of this disclosure and are not intended to limit this disclosure.

[0075] It should be understood that in the various embodiments of the present disclosure, the size of the serial number of each implementation process does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present disclosure.

[0076] Figure 1 A first optional flow chart of the data processing method provided by an embodiment of the present disclosure is shown, and will be explained according to each step.

[0077] Step S101: Obtain a chip model of a baseboard management controller based on a first instruction.

[0078] In some embodiments, the operating system sends a first instruction to the baseboard management controller, so that the baseboard management controller returns a chip model of the baseboard management controller based on the first instruction.

[0079] The chip model of the baseboard management controller is used by the operating system to identify the baseboard management controller.

[0080] Step S102: determining an identification file based on the chip model of the baseboard management controller.

[0081] In some embodiments, different baseboard management controller chip models correspond to different identification files; the identification file is used by the operating system to identify the baseboard management controller, so that the local area network connection between the baseboard management controller and the operating system can be realized based on the identification result, and the operating system can subsequently control the baseboard management controller to perform in-band refresh.

[0082] Step S103 : copying the identification file to a rule file directory to identify the baseboard management controller.

[0083] In some embodiments, the operating system copies the identification file to a rule file directory, reads and applies the rule file directory, and identifies and manages the baseboard management controller and the device corresponding to the baseboard management controller according to the identification file.

[0084] Step S104: controlling the baseboard management controller to enable the local area network function based on the second instruction.

[0085] In some embodiments, the operating system enables a LAN function of the baseboard management controller based on the second instruction, wherein the LAN function includes allowing a universal serial bus to enable the LAN function, that is, implementing the LAN function based on the universal serial bus.

[0086] Step S105 : setting network parameters of the universal serial bus network card of the baseboard management controller based on the third instruction.

[0087] In some embodiments, the operating system sets the network parameters of the universal serial bus network card of the baseboard control manager based on the third instruction so that the operating system and the baseboard management controller belong to the same local area network, and the operating system and the baseboard management controller are connected to the local area network based on the universal serial bus.

[0088] Step S106: transmitting in-band refresh parameters to a baseboard management controller based on the local area network.

[0089] In some embodiments, the operating system updates the in-band refresh parameters of the firmware to be refreshed in the configuration file, the configuration file is located in the operating system, and the operating system transmits the in-band refresh parameters to the baseboard management controller based on the local area network. Optionally, the operating system can also control the baseboard management controller to refresh the firmware based on the in-band refresh parameters based on a fifth instruction.

[0090] Thus, the disclosed embodiments provide a data processing method designed to address the in-band firmware upgrade issue for common domestic servers. This method requires no specialized hardware design and simply simulates a LAN over USB driver between the operating system and the BMC via a virtual Universal Serial Bus (USB) device. The BMC chip is then treated as a network card plugged into the server device, enabling in-band communication between the operating system and the BMC via a LAN channel. The baseboard management controller's internal web server can be used to transmit the firmware version file to the BMC's kernel system and verify its legitimacy via a Representational State Transfer (RESTful) interface related to firmware upload and refresh, along with a specific Uniform Resource Locator (URL), enabling the BMC to update the firmware version to the corresponding device. The disclosed embodiments can use this tool for upgrades on domestic servers using the open source baseboard management controller (OpenBMC), regardless of the type of chip or central processing unit platform, the domestic operating system, the ASPEED chip or the domestic HAM chip, etc., and its functions cover all types of firmware supported by BMC, including BMC, basic input and output system, mainboard complex programmable logic device (MBCPLD), backplane complex programmable logic device (BPCPLD), system control module complex programmable logic device (SCMCCPLD) and power supply unit, etc., thereby achieving the unification and standardization of in-band upgrade tools for domestic servers as much as possible.

[0091] Figure 2 A second optional flow chart of the data processing method provided by an embodiment of the present disclosure is shown, and will be explained according to each step.

[0092] Step S201: Send a first instruction to a baseboard management controller based on an intelligent platform management interface.

[0093] In some embodiments, an operating system sends a first instruction to a baseboard management controller (BMC) based on an Intelligent Platform Management Interface (IPMI); the first instruction is used to instruct the BMC to send the chip model of the BMC to the operating system. The BMC may return the chip model of the BMC based on a platform identifier (PlantformId).

[0094] In some embodiments, the operating system receives a chip model of the baseboard management controller based on the IPMI.

[0095] After confirming the chip model of the baseboard management controller, the baseboard management controller needs to be identified. The operating system determines the chip model of the baseboard management controller. If it is the first model, step S202 is executed; if it is the second model, step S203 is executed.

[0096] Step S202: Determine whether the identified file is the first file.

[0097] In some embodiments, if the baseboard management controller chip model is a first model, the identification file for identifying the baseboard management controller is determined to be a first file, wherein the first model may be ASPEED; and correspondingly, the first file may be a 10-bmc-eth-ast.rules file.

[0098] In some embodiments, the operating system configures parameters corresponding to the ASPEED chip in the first file; the parameters include at least one of a vendor identification code (Vendor ID) parameter, a product identification code (Product ID) parameter, a kernel (KERNEL) parameter, a symbolic link (SYMLINK) parameter, and a subsystem (SubSystem) parameter.

[0099] Step S203: Determine whether the identified file is the second file.

[0100] In some embodiments, if the baseboard management controller chip model is a second model, the identification file for identifying the baseboard management controller is determined to be a second file, wherein the second model may be HAM; and correspondingly, the second file may be the 10-bmc-eth-ham.rules file.

[0101] In some embodiments, the operating system configures parameters corresponding to the HAM chip in the second file; the parameters include at least one of a vendor identification code parameter, a product identification code parameter, a kernel parameter, a symbolic link parameter, and a subsystem parameter.

[0102] Step S204 : copying the identification file to a rule file directory to identify the baseboard management controller.

[0103] In some embodiments, the operating system copies the identification file to a rule file directory and loads the rule file directory, so that the operating system identifies the baseboard management controller based on the identification file.

[0104] The rule file directory may be / etc / udev / rules.d / , which is used to identify and manage the BMC. Managing the BMC may include configuring a virtual USB network of the BMC.

[0105] Step S205 : Controlling the baseboard management controller to enable the local area network function based on the second instruction.

[0106] In some embodiments, the operating system sends the second instruction to the baseboard management controller based on the intelligent platform management interface, so that the baseboard management controller enables a local area network function based on the second instruction. The local area network function is a LAN over USB function, that is, enabling USB support for the local area network function to prepare for a subsequent connection between the operating system and the BMC via the local area network.

[0107] Step S206 : setting the network parameters of the universal serial bus network card of the baseboard management controller based on the third instruction.

[0108] In some embodiments, in order to enable the BMC to access the local area network, it is necessary to configure the IP address, gateway and other network-related parameters of USB0 on ​​the BMC side to ensure that it can be connected to the network configured on the operating system side.

[0109] During specific implementation, the operating system sends the third instruction to the baseboard management controller based on the intelligent platform management interface, so that the baseboard management controller sets the network parameters of the universal serial bus network card (i.e., USB0) of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller are connected to a local area network based on the universal serial bus.

[0110] Step S207: configuring the network parameters of the virtual universal serial bus network card of the operating system based on the fourth instruction.

[0111] In some embodiments, the operating system configures network parameters of the USB network card of the operating system based on the fourth instruction, so that the operating system and the baseboard management controller belong to the same local area network.

[0112] The fourth instruction may be an ifconfig / IP command.

[0113] Step S208: transmitting in-band refresh parameters to a baseboard management controller based on the local area network.

[0114] In some embodiments, the operating system updates the in-band refresh parameters of the firmware to be refreshed in a configuration file, which may be update_config.sh. The in-band refresh parameters are transmitted to the baseboard management controller via the local area network, causing the baseboard management controller to write the in-band refresh parameters. A corresponding uniform resource locator in the baseboard management controller is called based on a fifth instruction, causing the baseboard management controller to perform a firmware refresh based on the in-band refresh parameters. The fifth instruction may be a curl command, specifically used to call a URL related to firmware refresh in the BMC to perform the firmware refresh.

[0115] In this way, for the current non-uniform operating systems, non-uniform chips and non-uniform tools corresponding to the operating systems, when the operating system is refreshed in-band through the BMC, it may encounter a situation where there is no corresponding tool and it needs to be downloaded and configured separately, or there is no tool and a connection between the operating system and the BMC cannot be established, resulting in an inability to refresh. The embodiment of the present disclosure creates a LAN connection between the operating system and the USB through the USB function possessed by both the operating system and the BMC, so that regardless of the operating system type, chip type, or BMC chip type, a LAN can be uniformly established based on the USB, so that the operating system and the BMC can transmit data based on the LAN, realize in-band refresh, and realize the unification and standardization of in-band upgrade tools.

[0116] Figure 3 A third optional flow chart of the data processing method provided in an embodiment of the present disclosure is shown, and will be explained according to each step.

[0117] Step S301: The server is powered on, and the BMC and the operating system are running normally.

[0118] In some embodiments, multiple related instructions (IPMI OEM commands) are developed on the BMC side, including a command for obtaining PlatformId (a first instruction), a command for controlling the opening and closing of LAN over USB on the BMC side (a second instruction), and a command for controlling the connection and disconnection of the BMC's USB network (a third instruction).

[0119] In other embodiments, multiple related instructions (IPMI OEM commands) are developed on the operating system side, including a command for obtaining PlatformId (a first instruction), a command for controlling the opening and closing of LAN over USB on the BMC side (a second instruction), and a command for controlling the connection and disconnection of the BMC's USB network (a third instruction).

[0120] The operating system and BMC correspond to the same server.

[0121] Step S302: Run the script lan-over-USB-set.sh, and obtain the PlantformId through the IPMI protocol in the script.

[0122] In some embodiments, the operating system, or a server corresponding to the operating system, runs the script lan-over-USB-set.sh. The script sends a first instruction, i.e., a command to obtain PlatformId, to the BMC through the IPMI protocol. In response to receiving the first instruction, the BMC sends a return value to the operating system. The operating system can distinguish the chip model of the BMC through the return value.

[0123] In step S303, the script determines the BMC chip used by the current server, copies the corresponding rules configuration file to the / etc / udev / rules / directory, and loads the rules.

[0124] In some embodiments, the script determines the chip model used by the BMC of the current server based on the return value, copies the corresponding rules configuration file to the / etc / udev / rules / directory, and loads the rules to enable the operating system to recognize the BMC.

[0125] In some embodiments, if the return value is 1, it is determined that the chip used by the server is the second model, that is, the HAM chip. The 10-bmc-eth-ham.rules file is edited, and the Vendorld and Productld related to the ham chip, as well as parameters such as KERNEL, SYMLINK and SUBSYSTEM are configured in the file. The rule file is copied to the / etc / udev / rules.d / directory, and udevadm contorl --reload is executed to load the rules.

[0126] In other embodiments, if the return value is not 1, it is determined that the chip used by the server is the first model, that is, the ASPEED chip, and the 10-bmc-eth-ast.rules file is edited, and the Vendorld and Productld related to the ast chip, as well as various parameters such as KERNEL, SYMLINK and SUBSYSTEM are configured in the file; the rule file is copied to the / etc / udev / rules.d / directory, and udevadm contorl --reload is executed to load the rules.

[0127] For implementation, prepare the corresponding 10-bmc-eth-ast.rules file for the ASPEED chip; prepare the corresponding 10-bmc-eth-ham.rules file for the HAM chip. Copy the file to the rule file directory in / etc / udev / rules.d / to configure the virtual USB network. Their purpose is the same: to configure the network environment on the operating system side and establish a connection between the operating system and the BMC.

[0128] Step S304: The script uses IPMI commands to enable the LAN OVER USB function under the BMC, and configures the IP and gateway of the BMC's USB network card to connect to the local area network.

[0129] In some embodiments, the script sends a second instruction to the BMC to enable a LAN OVER USB function on the BMC side.

[0130] In some embodiments, the script sends a third instruction to the BMC to set the IP and gateway of the USB0 network card on the BMC side and connect the BMC to the local area network.

[0131] Step S305: Use the ifconfig / IP command in the script to configure the IP and gateway of the virtual USB network card under the OS to ensure that the network is connected.

[0132] In some embodiments, the script uses the fourth instruction (ifconfig / IP command) to configure the IP and gateway of the virtual USB network card under the OS, so that the operating system can access the local area network. The operating system and the BMC are connected through the local area network.

[0133] Step S306: Modify the configuration file update_config.sh according to the instructions and modify the parameters related to the required firmware refresh.

[0134] In some embodiments, the operating system edits update_config.sh based on preset refresh parameters and selects various parameters related to firmware refresh corresponding to the preset refresh parameters.

[0135] In a specific implementation, the operating system can modify the configuration file update_config.sh based on preset refresh parameters, and select parameters such as synchronous / asynchronous refresh, whether to retain the configuration, whether to record logs, and whether to record the BMC administrator username and password.

[0136] The preset refresh parameters can be set according to user needs.

[0137] Step S307: execute upgrade_by_lob.sh, which uses the curl command internally to call the URL related to the BMC firmware update to perform the firmware update.

[0138] In some embodiments, upgrade_by_lob.sh is executed, and BMC ipImage_path flashitem is called based on the fifth instruction (curl command) to refresh the firmware, thereby performing the firmware refresh.

[0139] After the refresh is completed, the network configuration will be automatically restored without affecting the related configurations under the operating system.

[0140] It should be noted that the disclosed embodiments utilize the LAN functionality of both the operating system and the BMC chip to establish a network connection between the operating system and the BMC, transforming in-band operations into something similar to out-of-band operations. This approach not only enables the unification of in-band flash tools but also provides a solution for other operations that need to be performed within the operating system.

[0141] In this way, the data processing method provided by the embodiment of the present disclosure solves the complexity and non-uniformity of the current domestic server in-band refresh tools. For the server in-band firmware refresh function, a unified refresh method and device are proposed, which reduces the workload of R&D, customer service, production line and maintenance personnel and improves work efficiency. In addition, the data processing method provided by the embodiment of the present disclosure solves the problem of the diversity and singleness of the in-band refresh tools in the field of domestic servers. By utilizing the LAN function possessed by both the operating system and the BMC chip, the network connection between the operating system and the BMC is realized through script configuration and IPMI protocol execution and function development, and the in-band operation is transformed into an out-of-band operation, which greatly enriches the limitations of the in-band operation and realizes that one tool can refresh all firmware types supported by the BMC, greatly enhancing the functional perfection of the in-band firmware refresh tool. This invention supports various domestic operating systems and platforms, reduces the workload of R&D personnel for maintaining the in-band refresh tool, and improves the work efficiency of the product in the early factory production and later customer service maintenance.

[0142] Figure 4 A fourth optional flow chart of the data processing method provided in an embodiment of the present disclosure is shown, and will be explained according to each step.

[0143] Step S401: Receive a first instruction, and send the chip model of the baseboard management controller to the operating system based on the first instruction.

[0144] Step S402: Receive a second instruction, and enable the local area network function based on the second instruction.

[0145] Step S403: receiving a third instruction, and setting network parameters of the universal serial bus network card of the baseboard management controller based on the third instruction.

[0146] The operating system and the baseboard management controller are connected to a local area network based on a universal serial bus.

[0147] Step S404: receiving in-band refresh parameters based on the local area network, and performing firmware refresh based on the in-band refresh parameters.

[0148] In a specific implementation, the BMC writes the in-band refresh parameters into the flash memory in the baseboard management controller; based on the fifth instruction sent by the operating system, the corresponding uniform resource locator in the baseboard management controller is called, and the firmware is refreshed based on the in-band refresh parameters.

[0149] Specifically, the operating system executes upgrade_by_lob.sh, which uses the curl command internally to call the URL related to the BMC firmware refresh to perform the firmware refresh.

[0150] In this way, for the current non-uniform operating systems, non-uniform chips and non-uniform tools corresponding to the operating systems, when the operating system is refreshed in-band through the BMC, it may encounter a situation where there is no corresponding tool and it needs to be downloaded and configured separately, or there is no tool and a connection between the operating system and the BMC cannot be established, resulting in an inability to refresh. The embodiment of the present disclosure creates a LAN connection between the operating system and the USB through the USB function possessed by both the operating system and the BMC, so that regardless of the operating system type, chip type, or BMC chip type, a LAN can be uniformly established based on the USB, so that the operating system and the BMC can transmit data based on the LAN, realize in-band refresh, and realize the unification and standardization of in-band upgrade tools.

[0151] Figure 5 A first optional structural diagram of the data processing device provided by an embodiment of the present disclosure is shown, and will be explained according to each part.

[0152] In some embodiments, the data processing unit 500 is applied to a server corresponding to the operating system, and the device includes: an acquisition unit 501, a file determination unit 502, a loading unit 503, a first control unit 504, a second control unit 505 and a third control unit 506.

[0153] The acquiring unit 501 is configured to acquire a chip model of a baseboard management controller based on a first instruction;

[0154] The file determination unit 502 is configured to determine an identification file based on the chip model of the baseboard management controller; different chip models correspond to different identification files; the identification file includes a file for identifying the baseboard management controller;

[0155] The loading unit 503 is used to copy the identification file to the rule file directory to identify the baseboard management controller;

[0156] The first control unit 504 is configured to control the baseboard management controller to enable a local area network function based on the second instruction; the local area network function includes allowing a universal serial bus to enable a local area network function;

[0157] The second control unit 505 is configured to set the network parameters of the universal serial bus network card of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller are connected to the local area network based on the universal serial bus;

[0158] The third control unit 506 is configured to transmit an in-band refresh parameter to a baseboard management controller based on the local area network, so that the baseboard management controller performs firmware refresh based on the in-band refresh parameter.

[0159] The acquisition unit 501 is specifically configured to send a first instruction to a baseboard management controller based on an intelligent platform management interface; and receive a chip model of the baseboard management controller returned by the baseboard management controller based on the first instruction.

[0160] The file determining unit 502 is specifically configured to determine that the identification file is a first file in response to the chip model of the baseboard management controller being a first model;

[0161] Configure parameters corresponding to the first model chip in the first file.

[0162] The file determining unit 502 is specifically configured to determine that the identification file is a second file in response to the chip model of the baseboard management controller being a second model;

[0163] Configure parameters corresponding to the second model chip in the second file.

[0164] In some embodiments, the parameters include at least one of a vendor identification code parameter, a product identification code parameter, a kernel parameter, a symbolic link parameter, and a subsystem parameter.

[0165] The loading unit 503 is specifically configured to copy the identification file to a rule file directory; and load the rule file directory so that the operating system can identify the baseboard management controller based on the identification file.

[0166] The first control unit 504 is specifically configured to send the second instruction to the baseboard management controller based on the intelligent platform management interface, so that the baseboard management controller enables the local area network function based on the second instruction.

[0167] The second control unit 505 is specifically configured to send the third instruction to the baseboard management controller based on the intelligent platform management interface, so that the baseboard management controller sets the network parameters of the universal serial bus network card of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller are connected to the local area network based on the universal serial bus;

[0168] The network parameters include an Internet Protocol address and a gateway.

[0169] The second control unit 505 is further configured to configure network parameters of the virtual universal serial bus network card of the operating system based on the fourth instruction, so that the operating system and the baseboard management controller belong to the same local area network.

[0170] The third control unit 506 is specifically used to update the in-band refresh parameters of the firmware to be refreshed in the configuration file;

[0171] Transmitting the in-band refresh parameters to the baseboard management controller based on the local area network; so that the baseboard management controller writes the in-band refresh parameters;

[0172] A corresponding uniform resource locator in a baseboard management controller is called based on the fifth instruction, so that the baseboard management controller performs firmware refresh based on the in-band refresh parameter.

[0173] Figure 6 A second optional structural diagram of the data processing device provided by an embodiment of the present disclosure is shown, and will be explained according to each part.

[0174] In some embodiments, the data processing device 600 is applied to a baseboard management controller, and the device includes: a first receiving unit 601 , a second receiving unit 602 , a third receiving unit 603 and an in-band refresh unit 604 .

[0175] The first receiving unit 601 is configured to receive a first instruction and send the chip model of the baseboard management controller to the operating system based on the first instruction;

[0176] The second receiving unit 602 is configured to receive a second instruction and enable the universal serial bus to enable the local area network function based on the second instruction;

[0177] The third receiving unit 603 is configured to receive a third instruction and set network parameters of a universal serial bus network card of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller are connected to a local area network based on the universal serial bus;

[0178] The in-band refresh unit 604 is configured to receive in-band refresh parameters based on the local area network, and perform firmware refresh based on the in-band refresh parameters.

[0179] The in-band refresh unit 604 is specifically configured to write the in-band refresh parameters into the flash memory in the baseboard management controller;

[0180] The corresponding uniform resource locator in the baseboard management controller is called based on the fifth instruction sent by the operating system, and the firmware is refreshed based on the in-band refresh parameter.

[0181] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device and a readable storage medium.

[0182] Figure 7 A schematic block diagram of an example electronic device 800 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are provided as examples only and are not intended to limit the implementation of the present disclosure described and / or claimed herein.

[0183] like Figure 7 As shown, electronic device 800 includes a computing unit 801, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 802 or a computer program loaded from a storage unit 808 into a random access memory (RAM) 803. RAM 803 may also store various programs and data required for the operation of electronic device 800. Computing unit 801, ROM 802, and RAM 803 are interconnected via a bus 804. An input / output (I / O) interface 805 is also connected to bus 804.

[0184] Multiple components in the electronic device 800 are connected to the I / O interface 805, including an input unit 806, such as a keyboard, a mouse, etc.; an output unit 807, such as various types of displays, speakers, etc.; a storage unit 808, such as a magnetic disk, an optical disk, etc.; and a communication unit 809, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 809 allows the electronic device 800 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.

[0185] The computing unit 801 can be any general-purpose and / or specialized processing component with processing and computing capabilities. Some examples of the computing unit 801 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various specialized artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 801 performs the various methods and processes described above, such as the data processing method. For example, in some embodiments, the data processing method may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as the storage unit 808. In some embodiments, part or all of the computer program may be loaded and / or installed onto the electronic device 800 via the ROM 802 and / or the communication unit 809. When the computer program is loaded into the RAM 803 and executed by the computing unit 801, one or more steps of the data processing method described above may be performed. Alternatively, in other embodiments, the computing unit 801 may be configured to perform the data processing method by any other suitable means (e.g., via firmware).

[0186] Various embodiments of the systems and techniques described above can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), system-on-chip systems (SOCs), programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include being implemented in one or more computer programs that are executable and / or interpreted on a programmable system that includes at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0187] The program code for implementing the method of the present disclosure can be written in any combination of one or more programming languages. These program codes can be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device so that when the program code is executed by the processor or controller, the functions / operations specified in the flow chart and / or block diagram are implemented. The program code can be executed entirely on the machine, partially on the machine, as a stand-alone software package, partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0188] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of machine-readable storage media may include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), optical fibers, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0189] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0190] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), and the Internet.

[0191] A computer system may include a client and a server. The client and server are generally remote from each other and typically interact through a communication network. The client-server relationship arises through computer programs running on the respective computers and having a client-server relationship with each other. The server may be a cloud server, a server in a distributed system, or a server integrated with a blockchain.

[0192] It should be understood that various forms of the processes shown above can be used to order, add, or delete steps. For example, the steps described in this disclosure can be performed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document is not limited here.

[0193] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features being referred to. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. Throughout the present disclosure, "plurality" means two or more, unless otherwise specifically defined.

[0194] The above description is merely a specific embodiment of the present disclosure, but the scope of protection of the present disclosure is not limited thereto. Any changes or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in this disclosure should be included in the scope of protection of the present disclosure. Therefore, the scope of protection of the present disclosure should be based on the scope of protection of the claims.

Claims

1. A data processing method, characterized in that: Applied to an operating system, the method includes: Acquire a chip model of a baseboard management controller based on the first instruction; Determine an identification file based on the chip model of the baseboard management controller; different chip models correspond to different identification files; the identification file includes a file for identifying the baseboard management controller; Copying the identification file to a rule file directory to identify the baseboard management controller; Controlling the baseboard management controller to enable a local area network function based on the second instruction; the local area network function includes allowing a universal serial bus to enable a local area network function; sending a third instruction to the baseboard management controller based on the intelligent platform management interface, so that the baseboard management controller sets network parameters of a universal serial bus network card of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller establish a local area network connection based on the universal serial bus; wherein the network parameters include an Internet Protocol address and a gateway; An in-band refresh parameter is transmitted to a baseboard management controller based on the local area network, so that the baseboard management controller performs firmware refresh based on the in-band refresh parameter.

2. The method according to claim 1, characterized in that The obtaining the chip model of the baseboard management controller based on the first instruction includes: Sending a first instruction to the baseboard management controller based on the intelligent platform management interface; Receive the chip model of the baseboard management controller returned by the baseboard management controller based on the first instruction.

3. The method according to claim 1, characterized in that The determining of the identification file based on the chip model of the baseboard management controller includes: In response to the chip model of the baseboard management controller being the first model, determining that the identification file is the first file; Configure parameters corresponding to the first model chip in the first file.

4. The method according to claim 1, wherein The determining of the identification file based on the chip model of the baseboard management controller includes: In response to the chip model of the baseboard management controller being the second model, determining that the identification file is the second file; Configure parameters corresponding to the second model chip in the second file.

5. The method according to claim 3 or 4, characterized in that The parameters include at least one of a vendor identification code parameter, a product identification code parameter, a kernel parameter, a symbolic link parameter, and a subsystem parameter.

6. The method according to claim 1, wherein The step of copying the identification file to a rule file directory to identify the baseboard management controller includes: Copy the recognition file to the rule file directory; The rule file directory is loaded so that the operating system can identify the baseboard management controller based on the identification file.

7. The method according to claim 1, characterized in that The controlling the baseboard management controller to enable the local area network function based on the second instruction includes: The second instruction is sent to the baseboard management controller based on the intelligent platform management interface, so that the baseboard management controller enables the local area network function based on the second instruction.

8. The method according to claim 1, characterized in that The method further comprises: The network parameters of the virtual universal serial bus network card of the operating system are configured based on the fourth instruction, so that the operating system and the baseboard management controller belong to the same local area network.

9. The method according to claim 1, characterized in that The transmitting the in-band refresh parameter to the baseboard management controller based on the local area network includes: Update the in-band flash parameters of the firmware to be flashed in the configuration file; Transmitting the in-band refresh parameters to the baseboard management controller based on the local area network; so that the baseboard management controller writes the in-band refresh parameters; A corresponding uniform resource locator in a baseboard management controller is called based on the fifth instruction, so that the baseboard management controller performs firmware refresh based on the in-band refresh parameter.

10. A data processing method, characterized in that: Applied to a baseboard management controller, the method includes: receiving a first instruction, and sending a chip model of the baseboard management controller to an operating system based on the first instruction; receiving a second instruction, and enabling a local area network function based on the second instruction; receiving a third instruction, and setting network parameters of a universal serial bus network card of a baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller establish a local area network connection based on the universal serial bus; wherein the network parameters include an Internet Protocol address and a gateway; An in-band refresh parameter is received based on the local area network, and a firmware refresh is performed based on the in-band refresh parameter.

11. The method according to claim 10, characterized in that The receiving an in-band refresh parameter based on the local area network and performing firmware refresh based on the in-band refresh parameter includes: Writing the in-band refresh parameters into the flash memory in the baseboard management controller; The corresponding uniform resource locator in the baseboard management controller is called based on the fifth instruction sent by the operating system, and the firmware is refreshed based on the in-band refresh parameter.

12. A data processing device, characterized in that: Applied to a server corresponding to an operating system, the device includes: An acquiring unit, configured to acquire a chip model of a baseboard management controller based on a first instruction; A file determining unit, configured to determine an identification file based on a chip model of the baseboard management controller; different chip models correspond to different identification files; the identification file includes a file for identifying the baseboard management controller; A loading unit, configured to copy the identification file to a rule file directory to identify the baseboard management controller; A first control unit is configured to control the baseboard management controller to enable a local area network function based on the second instruction; the local area network function includes allowing a universal serial bus to enable the local area network function; a second control unit, configured to send a third instruction to the baseboard management controller based on the intelligent platform management interface, so that the baseboard management controller sets network parameters of a universal serial bus network card of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller establish a local area network connection based on the universal serial bus; wherein the network parameters include an Internet Protocol address and a gateway; The third control unit is configured to transmit an in-band refresh parameter to a baseboard management controller based on the local area network, so that the baseboard management controller performs firmware refresh based on the in-band refresh parameter.

13. A data processing device, characterized in that: Applied to a baseboard management controller, the device includes: A first receiving unit is configured to receive a first instruction, and send a chip model of the baseboard management controller to an operating system based on the first instruction; a second receiving unit, configured to receive a second instruction, and enable a local area network function of the universal serial bus based on the second instruction; a third receiving unit, configured to receive a third instruction and set network parameters of a universal serial bus network card of the baseboard management controller based on the third instruction, so that the operating system and the baseboard management controller establish a local area network connection based on the universal serial bus; wherein the network parameters include an Internet Protocol address and a gateway; An in-band refresh unit is configured to receive in-band refresh parameters based on the local area network and perform firmware refresh based on the in-band refresh parameters.

14. An electronic device, characterized in that: include: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable 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 perform the method according to any one of claims 1 to 9; Alternatively, the method according to any one of claims 10 to 11 is performed.

15. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to make a computer execute the method according to any one of claims 1 to 10; Alternatively, the method according to any one of claims 11 to 12 is performed.

Citation Information

Patent Citations

  • Chip updating method based on BMC (Baseband Management Controller), equipment and storage medium

    CN108363583A

  • Method, device and equipment for in-band refreshing of BMC firmware and medium

    CN114840233A