Network card firmware refreshing method, electronic equipment and storage medium
Through the preset refresh program, data verification, backup and simulation of restart/interruption network scenarios are carried out, which solves the service interruption problem during network card firmware update, realizes online hot refresh, and ensures network stability and update reliability.
Patent Information
- Application Number
- CN202510732294.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-03
- Publication Date
- 2025-09-12
AI Technical Summary
Existing technologies require restarting the server or interrupting the network connection when updating the network card firmware, resulting in business interruption and affecting enterprise operations.
The network card firmware can be refreshed online by performing data verification, backup, matching, and simulating restart/interruption network scenarios through a preset refresh program, ensuring that the firmware refresh is completed without affecting the normal operation of the server.
It enables updating network card firmware without restarting the server or interrupting the network connection, ensuring the continuous stability of the network connection, improving the security and reliability of firmware updates, reducing server downtime, and improving system availability and maintenance efficiency.
Smart Images

Figure CN120639611A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a method for refreshing network card firmware, an electronic device, and a storage medium. Background Art
[0002] In modern data centers and enterprise networks, network interface cards (NICs) are critical hardware devices that connect servers and other computing devices to the network. NIC firmware controls hardware functionality and ensures efficient data transmission and processing. Regularly refreshing and upgrading NIC firmware is necessary to improve performance, fix vulnerabilities, or add new features. However, traditional firmware refresh methods often require restarting the server or interrupting the network connection, resulting in business interruptions and negatively impacting normal business operations.
[0003] Therefore, how to complete the firmware refresh without restarting the server or interrupting the network connection is an urgent problem to be solved. Summary of the Invention
[0004] The present application provides a network card firmware refresh method, electronic device and storage medium to at least solve the problem in the related art of how to complete firmware refresh without restarting the server or interrupting the network connection.
[0005] This application provides a method for refreshing network card firmware, including:
[0006] Performing data verification processing on the acquired multiple upgrade package data and multiple image data to obtain a data verification result;
[0007] When it is determined according to the data verification result that the multiple upgrade package data and the multiple image data meet the preset verification conditions, receiving the uploaded preset refresh program, linking the network card firmware to be refreshed into the preset refresh program, and backing up the network card firmware to be refreshed based on the preset refresh program;
[0008] Performing data matching processing on the network card firmware to be refreshed in multiple upgrade package data and multiple image data based on a preset refresh program to obtain target upgrade package data and target image data corresponding to the network card firmware to be refreshed;
[0009] In the preset refresh program, the network card firmware to be refreshed is refreshed using the target upgrade package data and the target image data to obtain the target network card firmware, wherein the preset refresh program is used to simulate the server restart and network interruption scenarios during the firmware refresh process.
[0010] The present application also provides a network card firmware refresh device, comprising:
[0011] A verification unit, configured to perform data verification processing on the acquired multiple upgrade package data and multiple image data to obtain a data verification result;
[0012] a processing unit configured to receive an uploaded preset refresh program and link the network card firmware to be refreshed into the preset refresh program if it is determined based on the data verification result that the plurality of upgrade package data and the plurality of image data meet the preset verification conditions;
[0013] A backup unit, configured to perform a backup process on the network card firmware to be refreshed based on a preset refresh program;
[0014] a matching unit, configured to perform data matching processing on the network card firmware to be refreshed in the plurality of upgrade package data and the plurality of image data based on a preset refresh program, and obtain target upgrade package data and target image data corresponding to the network card firmware to be refreshed;
[0015] The refresh unit is used to perform firmware refresh processing on the network card firmware to be refreshed through target upgrade package data and target image data in a preset refresh program to obtain target network card firmware, wherein the preset refresh program is used to simulate server restart and network interruption scenarios during the firmware refresh process.
[0016] The present application also provides an electronic device, comprising: a memory for storing a computer program; and a processor for implementing the steps of any of the above-mentioned methods for refreshing network card firmware when executing the computer program.
[0017] The present application also provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the steps of any of the above-mentioned methods for refreshing the network card firmware are implemented.
[0018] The present application also provides a computer program product, including a computer program, which implements the steps of any of the above-mentioned methods for refreshing network card firmware when executed by a processor.
[0019] The network card firmware refresh method, electronic device and storage medium of the present application simulate the server restart and network interruption scenarios during the firmware refresh process through a preset refresh program, allowing the network card firmware to be updated without affecting the normal operation of the server. At the same time, the existing firmware is backed up during the firmware refresh process, which can ensure that data is not lost when the refresh fails, thereby ensuring the continuous stability of the network connection, improving the security and reliability of the firmware update, avoiding network interruption due to refresh failure, realizing online hot refresh, reducing server downtime, and improving the system availability and maintenance efficiency. Therefore, it can solve the technical problem of how to complete the firmware refresh without restarting the server or interrupting the network connection, and achieve the technical effect of updating the network card firmware without affecting the normal operation of the server. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0021] Figure 1 A flowchart of a method for refreshing network card firmware provided in an embodiment of the present application;
[0022] Figure 2 A schematic diagram of the principle of link-in processing of a network card firmware to be refreshed provided in an embodiment of the present application;
[0023] Figure 3 A schematic diagram of a data verification process provided in an embodiment of the present application;
[0024] Figure 4 A prompt information diagram of a firmware refresh process provided in an embodiment of the present application;
[0025] Figure 5 A schematic diagram of the structure of a network card firmware refresh device provided in an embodiment of the present application;
[0026] Figure 6 A schematic structural diagram of another network card firmware refresh device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0027] The following will be combined with the accompanying drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0028] It should be noted that, in the description of this application, the terms "comprises," "includes," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or device. The terms "first," "second," etc., in this application are used to distinguish similar objects, and are not used to describe a particular order or sequence.
[0029] In order to enable those skilled in the art to better understand the present application, the present application is further described in detail below with reference to the accompanying drawings and specific implementation methods.
[0030] Figure 1 A flowchart of a method for refreshing network card firmware is provided in an embodiment of the present application, and the method is described in detail in conjunction with the execution process of the method for refreshing network card firmware.
[0031] like Figure 1 As shown, the method for refreshing the network card firmware includes:
[0032] Step 101 : performing data verification processing on the acquired multiple upgrade package data and multiple image data to obtain a data verification result.
[0033] In the embodiments of the present application, multiple upgrade package data refers to a collection of software packages containing the code, instructions, and possible configuration information required to update the network card firmware, typically provided by the network card manufacturer. Multiple image data refers to a collection of complete firmware program files that can be directly written to the non-volatile memory (e.g., Electrically Erasable Programmable Read-Only Memory (EEPROM)) of the network card, representing the target firmware state of the network card.
[0034] Data verification processing refers to the process of checking multiple upgrade package data and image data to ensure the integrity of the upgrade package data and image data (not damaged), the reliability of the source (from a trusted supplier), and the compatibility with the network card hardware model, the currently running driver version, etc.
[0035] Preset verification conditions are a set of pre-defined rules used to determine data eligibility, such as checksum matching, digital signature validity, and version number compatibility. The resulting data verification result is a clear indicator of whether all upgrade package data and image data have passed the pre-set verification conditions.
[0036] Step 102, when it is determined according to the data verification result that the multiple upgrade package data and the multiple image data meet the preset verification conditions, receive the uploaded preset refresh program, link the network card firmware to be refreshed into the preset refresh program, and back up the network card firmware to be refreshed based on the preset refresh program.
[0037] In the embodiment of the present application, subsequent operations will be performed only when it is confirmed through the data verification result that the multiple upgrade package data and the multiple image data meet the preset verification conditions (ie, all data are valid and compatible).
[0038] At this point, the target server will receive the uploaded preset flash program. This preset flash program is a software tool specifically designed to perform network card firmware flash tasks. It includes, but is not limited to, code logic for core functions such as hot flash, backup, and rollback of the network card firmware to be flashed. The target server is the server that has the network card firmware to be flashed installed and needs to perform the firmware flash operation.
[0039] After receiving the preset refresh program, the target server deploys the preset refresh program on the target server, and the target server links the network card firmware to be refreshed (ie, the target physical network card that currently needs to update the firmware, ie, the network card to be refreshed) into the deployed preset refresh program.
[0040] Specifically, in order to facilitate understanding of the principle and method of linking the network card firmware to be refreshed into the preset refresh program, the embodiment of the present application provides a schematic diagram of the principle of linking the network card firmware to be refreshed, as shown in FIG. Figure 2 As shown, when the network card firmware to be refreshed is linked into the preset refresh program, specific technical means can be used (for example, utilizing the hardware pass-through capability provided by the Virtual Function Input / Output (VFIO) kernel module) to enable the preset refresh program to directly and securely access and control the network card hardware to be refreshed corresponding to the network card firmware to be refreshed, bypassing the conventional driver of the operating system in the target server, and laying the foundation for subsequently refreshing the network card firmware without affecting the target server.
[0041] Backup processing involves the scheduled flash program reading the current firmware version and related configuration information of the network card to be flashed and saving the backup data intact to a secure storage location (e.g., the scheduled flash program's built-in storage or a specific partition on the target server). This backup process is essential for subsequent safe rollbacks, ensuring that the original state can be restored in the event of a firmware flash failure.
[0042] Step 103 : performing data matching processing on the network card firmware to be refreshed in the multiple upgrade package data and the multiple image data based on a preset refresh program to obtain target upgrade package data and target image data corresponding to the network card firmware to be refreshed.
[0043] In an embodiment of the present application, the intelligent matching logic built into the preset refresh program can be used to perform data matching processing on the network card firmware to be refreshed (wherein the hardware model, current firmware version and other information of the network card firmware to be refreshed have been identified when linked in) with multiple verified upgrade package data and multiple image data.
[0044] The data matching process includes but is not limited to the analysis and comparison process, the purpose of which is to screen out the target file that is fully compatible with the hardware model of the network card firmware to be refreshed, meets the upgrade path requirements (for example: upgrading from the current version to the target version is supported), and contains the required driver or function from multiple available upgrade packages and images (multiple upgrade package data and multiple image data).
[0045] The target upgrade package data is the specific upgrade package that has been matched and determined to be suitable for the network card firmware to be updated. The target image data is the final firmware image file that corresponds to the network card firmware to be updated and is to be written into the firmware to be updated. This ensures the accuracy and security of the update, preventing incorrect files from causing update failures or hardware damage.
[0046] Step 104 , in a preset refresh program, the target network card firmware to be refreshed is refreshed using the target upgrade package data and the target image data to obtain the target network card firmware, wherein the preset refresh program is used to simulate server restart and network interruption scenarios during the firmware refresh process.
[0047] In an embodiment of the present application, in a secure execution environment of a preset refresh program (i.e., a server restart and network interruption scenario simulated by the preset refresh program), the target upgrade package data and target image data are used to perform firmware refresh processing on the network card firmware to be refreshed.
[0048] Firmware refresh processing refers to the process of securely writing new firmware code and data (target upgrade package data and target image data) to the non-volatile memory of the network card to be refreshed. When executing the firmware refresh process, the preset refresh program can simulate server restart and network interruption scenarios during the firmware refresh process. Simulating server restart and network interruption scenarios is a prerequisite for implementing hot refresh or online refresh. It does not mean physically restarting the target server or disconnecting the target server's network connection. Instead, it means that the preset refresh program executes operation instructions equivalent to power off, reset, or reinitialization on the target network card in an isolated and controllable environment (for example: using the user space of the preset refresh program after VFIO passthrough, or a miniature, tool-built operating system instance).
[0049] At this point, the network card firmware to be refreshed undergoes a simulated physical restart or network interruption and recovery process, which allows the newly written firmware to take effect and completes the firmware refresh process. Since the operation occurs in a space isolated and controlled by the preset refresh program, and is isolated from the target server operating system and the business applications running on it through technologies such as VFIO, the target server itself remains in a continuous operating state, and the target server network connection (especially other network cards that have not undergone firmware refresh) also remains unobstructed. After successfully completing the firmware refresh process, obtaining the target network card firmware means that the network card is running on the updated firmware version.
[0050] Through the VFIO kernel module, the network card firmware to be refreshed is directly linked to the network card refresh tool (preset refresh program). By simulating the user state of the network card to be refreshed, a simulated power off or restart operation is performed within the preset refresh program. The target upgrade package data and target image data are written to the actual network card to be refreshed. This allows the firmware to be refreshed during normal server operation without restarting or powering off the physical server.
[0051] Through rigorous data verification, secure backups, precise data matching, and innovative simulated environment refresh technology, this system enables efficient and reliable updates of network card firmware. This eliminates the server downtime required for traditional firmware upgrades, ensures continuous network connectivity, and significantly improves system maintenance efficiency and business continuity. The combination of backup mechanisms and simulated environment refresh significantly enhances the security and reliability of firmware updates, effectively reducing the risk of upgrade failures and their impact on production environments. This optimizes the operational experience of online firmware updates, reducing maintenance complexity and labor costs.
[0052] The network card firmware refresh method of the present application simulates the server restart and network interruption scenarios during the firmware refresh process through a preset refresh program, allowing the network card firmware to be updated without affecting the normal operation of the server. At the same time, the existing firmware is backed up during the firmware refresh process, which can ensure that data is not lost when the refresh fails, thereby ensuring the continuous stability of the network connection, improving the security and reliability of the firmware update, avoiding network interruption due to refresh failure, realizing online hot refresh, reducing server downtime, and improving the system availability and maintenance efficiency. Therefore, it can solve the technical problem of how to complete the firmware refresh without restarting the server or interrupting the network connection, and achieve the technical effect of updating the network card firmware without affecting the normal operation of the server.
[0053] In one implementable manner of the embodiment of the present application, when performing data verification processing on multiple upgrade package data and multiple image data, the following manner may also be adopted but is not limited to: obtaining the upgrade package size corresponding to the first upgrade package data and the upgrade package size corresponding to the first image data, and calculating the upgrade package checksum corresponding to the first upgrade package data and the upgrade package checksum corresponding to the first image data, wherein the first upgrade package data is any upgrade package data among the multiple upgrade package data, and the first image data is any image data among the multiple image data; receiving the standard upgrade package size and standard upgrade package checksum corresponding to the uploaded first upgrade package data, and the standard upgrade package checksum corresponding to the first image data; the standard image size and the standard image checksum of the upgrade package; comparing the upgrade package size with the corresponding standard upgrade package size, and comparing the upgrade package checksum with the standard upgrade package checksum, comparing the image size with the corresponding standard image size, and comparing the image checksum with the standard image checksum; when the upgrade package size is consistent with the corresponding standard upgrade package, and the upgrade package checksum is consistent with the standard upgrade package checksum, determining that the first upgrade package data meets the preset verification condition; when the image size is consistent with the corresponding standard image size, and the image checksum is consistent with the standard image checksum, determining that the first image data meets the preset verification condition.
[0054] In the embodiments of the present application, the first upgrade package data refers to a single upgrade package data instance arbitrarily selected from a plurality of upgrade package data sets; similarly, the first image data refers to a single image data instance arbitrarily selected from a plurality of image data sets. The upgrade package size refers to the number of bytes of storage space occupied by the first upgrade package data itself, and the image size refers to the number of bytes of storage space occupied by the first image data. The upgrade package checksum (and image checksum) is a fixed-length, unique digital fingerprint (hash value) obtained by calculating the entire content of the first upgrade package data (or first image data) using a specific cryptographic hash algorithm (e.g., Secure Hash Algorithm 256-bit (SHA-256) or Message Digest Algorithm 5 (MD5)). The checksum is extremely sensitive to any slight changes to the file; any change in the content will result in a completely different calculated checksum, making it a key indicator for verifying file integrity and consistency.
[0055] The standard upgrade package size and standard upgrade package checksum (as well as the standard image size and standard image checksum) are certified benchmark values provided by the network card firmware provider (usually the network card manufacturer or a trusted software distribution source) when releasing the first upgrade package data or the first image data. They represent the correct size and checksum of the first upgrade package data or the first image data in its original, unchanged, complete and error-free state, and serve as the standard for verifying whether the files obtained by users are qualified.
[0056] When the upgrade package size is consistent with the corresponding standard upgrade package size, and the upgrade package checksum is consistent with the standard upgrade package checksum, it means that the size and content of the first upgrade package data file are completely consistent with the standard, without any damage, truncation or tampering, and is therefore judged to be valid and safe, meeting the requirements for integrity and authenticity in the preset verification conditions. Similarly, when the image size is consistent with the corresponding standard image size, and the image checksum is consistent with the standard image checksum, the first image data file is also confirmed to be valid because its size and content match the standard value. It should be emphasized that the data verification process needs to independently execute the acquisition, calculation, reception, comparison and judgment steps for each of the multiple upgrade package data and multiple image data. Only when all data have passed their respective verifications will the final data verification result indicate that all data meet the preset verification conditions.
[0057] Through a dual verification mechanism based on file size and password checksum, a solid security barrier is established at the initial stage of the firmware flash process, effectively ensuring that every software package and firmware image used for flashing is a complete, intact, and untampered standard file. This reduces the risk of flash failure, device damage, and even system security vulnerabilities caused by file corruption or mismatches, lays a solid and reliable foundation for subsequent backup, matching, and online hot flash operations, and significantly improves the security and success rate of the entire firmware update process.
[0058] In one implementable method of an embodiment of the present application, after verifying multiple upgrade package data and multiple image data, if a situation occurs that does not meet the preset verification conditions, the following method can also be used but is not limited to: when it is determined based on the data verification results that any data in the multiple upgrade package data and multiple image data does not meet the preset verification conditions, a data error prompt information is generated based on the data that does not meet the preset verification conditions, and the data error prompt information is visualized; updated data uploaded based on the data error prompt information is received, and the data that does not meet the preset verification conditions is replaced based on the updated data.
[0059] In the embodiment of the present application, in order to facilitate understanding of the verification process of the upgrade package data and the image data, the embodiment of the present application provides a flow chart of data verification, such as Figure 3As shown, when multiple upgrade package data and multiple image data all meet the preset verification conditions, that is, the data are available, the multiple upgrade package data and the multiple image data are output as pre-refresh data; when any data among the multiple upgrade package data and the multiple image data does not meet the preset verification conditions, that is, the data is unavailable, the error reason is output.
[0060] Any data that does not meet the preset verification conditions means that at least one upgrade package data file in multiple upgrade package data sets, or at least one image data file in multiple image data sets, fails to meet the preset verification conditions (for example: file size mismatch, checksum inconsistency, invalid signature, version incompatibility, etc.).
[0061] A data error message is a structured error report directly tied to the specific verification failure. The process of generating a data error message includes, but is not limited to, precisely identifying the data that failed verification (e.g., identifying the specific upgrade package or image data by file name, unique identifier, or location within a collection) and describing in detail the specific pre-defined verification condition that was not met (e.g., file size discrepancy, checksum verification failure, invalid signature, or version incompatibility).
[0062] Visualization refers to the clear and intuitive presentation of generated data error messages, including specific error details, to administrators or users through a human-computer interaction interface (e.g., graphical user interface (GUI) command line terminal output, pop-up warning windows, warning information bars in the World Wide Web (Web) management interface, or highlighted entries in system log files). The purpose of visualization is to ensure that data error information can be perceived and understood promptly and clearly, preventing errors from being overlooked or confused.
[0063] After the data error information is visualized, the target server enters a state where it awaits a user response. Update data uploaded based on the data error message is received. Update data refers to new data files that are re-provided or uploaded by the user or operator based on the visualized data error information (such as the error file and the cause of the error) to replace the original file. For example, if the prompt indicates that the checksum of upgrade package A has failed, the user might download and upload upgrade package A again; if the prompt indicates that image B is incompatible, the user might upload a compatible image.
[0064] After receiving the uploaded update data, the data that does not meet the preset verification conditions will be replaced based on the updated data. Replacement means that the data identified as not meeting the preset verification conditions is overwritten or replaced with the uploaded update data.
[0065] After the replacement process is complete, data verification is typically triggered again (either for the newly replaced files only, or for the entire set) to confirm whether the replaced updated data meets the preset verification criteria. If the new data verification results confirm that all data (including the updated data) meets the preset verification criteria, the preset flash program is received and linked to the network card firmware to be flashed.
[0066] By generating precise error prompts, visually displaying errors, and implementing a closed-loop process for receiving and replacing updated data, the system enhances fault tolerance during the data preparation phase before a firmware refresh. This allows for proactive and clear notification of errors when the initial data source is faulty, guiding users to quickly provide new files for replacement. This effectively avoids the risk of subsequent refresh failures caused by invalid input data. This improves the success rate and efficiency of the entire refresh process, reduces confusion and delays caused by data issues, and further strengthens the security and reliability of the method.
[0067] In one possible implementation method of the embodiment of the present application, when backing up the network card firmware to be refreshed, it can also be implemented by, but not limited to, the following methods: extracting the firmware information of the network card firmware to be refreshed through a preset refresh program, and backing up the firmware information to obtain backup data corresponding to the network card firmware to be refreshed; and storing the backup data in a preset memory.
[0068] In the embodiments of the present application, firmware information refers to the set of key data stored in the non-volatile memory of the network card firmware to be refreshed in its current running state, including but not limited to: the complete binary image of the firmware (i.e., the firmware code itself), the firmware version number, network card-specific configuration parameters (such as Media Access Control (MAC) address, interrupt configuration, hardware feature switch status, etc.), and specific configuration information of the driver compatible with or bound to the firmware.
[0069] The preset flash program uses the secure access rights to the network card hardware obtained through VFIO technology to execute preset instructions (for example, executing the ethtool -e eth0> eth0_config_backup.bin command) and read the firmware information from the storage chip of the network card to be flashed.
[0070] After extracting the firmware information, the preset refresh program backs it up. This backup process includes, but is not limited to, performing checksum calculations on the firmware binary data to ensure the integrity of the backup and adding necessary metadata (such as the backup timestamp, source network card identifier, and firmware version number) for easy management and identification. The backup data, which is a collection of data packets or files that represent the pre-flash firmware state of the network card to be refreshed, is the only reliable basis for performing a rollback operation.
[0071] The preset memory is a physical or logical storage location that is pre-designated or configured for secure and persistent storage of data. The characteristics of the preset memory include at least: non-volatility (ensuring that the backup data will not be lost even if the target server loses power), reliability (such as using enterprise-level storage devices or independent partitions with redundant protection), and strong association with the preset refresh program (ensuring that the preset refresh program can reliably access the backup data when a rollback is required). The specific form of the preset memory may include, but is not limited to: a specific protected hard disk partition local to the target server, a dedicated storage module built into the preset refresh program (such as a built-in Flash memory), or a specific directory on a secure remote storage server connected via a network. Specifically, this application does not impose any restrictions on the preset memory.
[0072] By extracting firmware information, backing it up, and securely storing it in a preset memory, the original state of the device is completely and accurately captured and preserved before any firmware changes are implemented. This provides a means of rapid recovery from possible unexpected situations (such as refresh failures or new firmware defects), eliminates the risk of permanent device failures or long-term business interruptions due to upgrades, and improves the manageability of the system maintenance process.
[0073] In one implementable method of the embodiment of the present application, when performing data matching processing to determine the target upgrade package data and target image data corresponding to the network card firmware to be refreshed, it can also be implemented by but not limited to the following methods: obtaining upgrade package information corresponding to each of the multiple upgrade package data, and image information corresponding to each of the multiple image data; performing information comparison processing on the multiple upgrade package information according to the firmware information to obtain the target upgrade package information, and determining the upgrade package data corresponding to the target upgrade package information as the target upgrade package data, wherein the comparison result between the target upgrade package information and the firmware information meets the first preset comparison condition; performing information comparison processing on the multiple image information according to the firmware information to obtain the target image information, and determining the image data corresponding to the target image information as the target image data, wherein the comparison result between the target image information and the firmware information meets the second preset comparison condition.
[0074] In an embodiment of the present application, upgrade package information refers to a set of metadata parsed or extracted from each individual upgrade package data in a plurality of upgrade package data. The upgrade package information includes, but is not limited to: a list of network card hardware models applicable to the upgrade package, a range of supported firmware starting versions, a target upgrade version number, an upgrade package type (such as: functional update, security patch), dependencies (such as: required driver version), and a description of the specific update content included. Image information refers to a set of metadata parsed or extracted from each individual image data file in a plurality of image data. The image information includes, but is not limited to: a network card hardware model applicable to the firmware image, a firmware version number, a firmware build date, a checksum of the firmware image, a firmware image size, and hardware feature identifiers included.
[0075] Information comparison processing refers to the process in which the preset refresh program compares and analyzes the firmware information of the network card firmware to be refreshed (as a matching source) with all the collected upgrade package information (as a matching target set) one by one. The first preset comparison condition is a set of predefined rules used to determine whether a specific upgrade package information is compatible and applicable with the current network card firmware to be refreshed. The first preset comparison condition includes but is not limited to: the upgrade package information clearly lists the hardware models that support the network card firmware to be refreshed, the starting version range specified in the upgrade package information includes the current firmware version of the network card firmware to be refreshed, the upgrade package information does not contain known conflicting items with the network card hardware or the current driver environment, and meets other necessary compatibility requirements. The target upgrade package information is the upgrade package metadata that is unique or most consistent with the first preset comparison condition among multiple upgrade package information. Determining the upgrade package data corresponding to the target upgrade package information as the target upgrade package data means that the upgrade package data associated with the target upgrade package information is selected as the specific operation file for refreshing the network card firmware.
[0076] According to the firmware information, information comparison processing is performed in multiple image information, and the firmware information (the status of the network card firmware to be refreshed) is also used as the matching source, but the comparison is performed on multiple image information (the metadata set of all verified image files). The second preset comparison condition is another set of predefined rules, which is used to determine whether a specific image information is compatible with the current network card firmware to be refreshed and is the target image specified by the target upgrade package. The second preset comparison condition includes but is not limited to: the hardware model that supports the network card firmware to be refreshed is clearly listed in the image information, the firmware version number in the image information is strictly consistent with the target upgrade version specified in the target upgrade package information, the feature identifier contained in the image information matches the network card hardware capability, and the integrity identifier of the image information itself is correct. Determining the image data corresponding to the target image information as the target image data means that the image data associated with the target image information is selected as the final binary image file for refreshing the network card firmware.
[0077] By obtaining metadata information, performing dual information comparison processing, and ultimately determining the target upgrade package data and target image data, accurate and intelligent matching of firmware refresh materials is achieved, ensuring that the selected upgrade package and image are not only complete and valid at the file level, but also accurately match the network card hardware model, current status, and upgrade path requirements at the logic and compatibility level. This avoids the risk of refresh failure, device incompatibility, or functional abnormality due to incorrect file selection, and improves the intelligence level and execution efficiency of the firmware refresh process.
[0078] In one implementable method of the embodiment of the present application, after obtaining the target network card firmware, the following method can also be used but is not limited to: obtaining refresh information during the firmware refresh process, and storing the refresh information in a preset memory; extracting the target firmware information of the target network card firmware, and verifying whether the target firmware information meets the preset firmware conditions; when it is determined that the target firmware information does not meet the preset firmware conditions, extracting the backup data in the preset memory; based on the preset refresh program, rolling back the target network card firmware according to the backup data to obtain the network card firmware to be refreshed.
[0079] In an embodiment of the present application, refresh information refers to a set of detailed operation data generated and recorded by a preset refresh program during the entire process of firmware refresh processing, including but not limited to: the specific start and end timestamps of the refresh, each step of the refresh operation instruction executed and its status (success / failure), real-time recording of the refresh progress, the response status of the network card hardware during the simulated power off and restart phase, any warning or error log information that may be generated, the actual write status report of the target upgrade package data and the target image data, etc.
[0080] Extracting the target firmware information of the target network card firmware means that the preset refresh program reuses the access rights to the network card hardware to read the current firmware image data, version number, configuration parameters and other key status information from the refreshed network card. The target firmware information represents the actual operating status of the network card after the refresh. The preset firmware conditions are a set of pre-set standards for judging whether the firmware refresh is successful and functions normally. The preset firmware conditions include but are not limited to: whether the firmware version number reported in the target firmware information is completely consistent with the expected version number specified by the target upgrade package / target image data, whether the checksum of the firmware image data read from the target network card firmware matches the standard checksum of the target image data file, whether the hardware function identification and configuration parameters are in the expected state, and whether the target network card firmware can respond to basic diagnostic commands, etc. Specifically, this application does not impose any restrictions on the preset firmware conditions.
[0081] The result of the verification determines the subsequent operations. If it is determined that the target firmware information does not meet the preset firmware conditions, it means that the firmware refresh has failed to achieve the expected goal. The new firmware may not be correctly effective, has defects, or is incompatible with the hardware. At this time, the automatic recovery program will be started immediately, that is, the backup data in the preset memory will be extracted, and the target network card firmware will be rolled back according to the backup data based on the preset refresh program.
[0082] Fallback processing refers to the preset refresh program using the ability to control the network card to safely write the original firmware image and configuration information stored in the backup data back to the non-volatile memory of the network card. In essence, it is a reverse firmware refresh operation. The original firmware image contained in the backup data is first read, and it is written to the network card through the secure channel of the preset refresh program (such as VFIO and other technologies). If necessary, a simulated power off and restart operation is performed to make the original firmware take effect again. The final result of the network card firmware to be refreshed means that the network card has successfully recovered from the target network card firmware (new firmware) state that may have problems to the original network card firmware to be refreshed (old firmware) state before the refresh operation started.
[0083] By recording refresh information, verifying the firmware status after refreshing, and automatically triggering the extraction of backup data from the preset storage and executing rollback processing when verification fails, a complete record of the refresh operation process is ensured for review, providing automated and fast-response fault recovery capabilities, eliminating the hidden dangers of device failure or business interruption caused by firmware refresh failure, controlling potential risks to a minimum, and greatly improving the ultimate success rate of the entire firmware online upgrade process and the overall resilience and availability of the system.
[0084] In one implementable manner of an embodiment of the present application, before obtaining the target network card firmware, the following method may also be adopted but is not limited to: determining whether the network card firmware to be refreshed meets the preset refresh conditions based on the firmware information; when it is determined that the network card firmware to be refreshed meets the preset refresh conditions, the preset refresh program responds to the triggered firmware refresh instruction, simulates restarting the server and interrupting the network scenario, and performs firmware refresh processing on the network card firmware to be refreshed to obtain the target network card firmware; when it is determined that the network card firmware to be refreshed does not meet the preset refresh conditions, firmware problem information is generated based on the firmware information and the preset refresh conditions, and the firmware problem information is visualized.
[0085] In an embodiment of the present application, the preset refresh conditions are a set of predefined, comprehensive hard standards used to determine whether the network card firmware to be refreshed is suitable for immediate firmware refresh operation. The preset refresh conditions cover multiple dimensions, including but not limited to: hardware health status (such as: no hardware fault report of the network card, the temperature is within the safe range, and the key register status is normal); software environment compatibility (such as: the currently loaded operating system driver version is compatible with the network card firmware to be refreshed, and there are no known conflicting processes or services occupying the network card firmware to be refreshed); firmware status stability (such as: the network card firmware to be refreshed runs stably without frequent error logs, and is not in an intermediate upgrade or rollback state); hot refresh mechanism readiness (such as: the VFIO pass-through function has been confirmed to be effectively enabled on the network card firmware to be refreshed and there is no conflict), etc. Specifically, this application does not impose any restrictions.
[0086] When the network card firmware to be refreshed meets all the preset refresh conditions, it means that the network card firmware to be refreshed is in the optimal, safe and refreshable state. The preset refresh program responds to the triggered firmware refresh instruction, simulates the restart of the server and the network interruption scenario, and performs firmware refresh processing on the network card firmware to be refreshed. Responding to the triggered firmware refresh instruction means that the preset refresh program receives and executes the clear refresh start command issued by the user (such as: the operator clicks the start refresh button on the tool interface) or the automated process. At the same time, when performing the firmware refresh process, the preset refresh program will feedback the current firmware refresh progress percentage according to the current progress and prompt high-risk operations, such as Figure 4 As shown, Figure 4 A prompt information diagram of the firmware refresh process provided in an embodiment of the present application.
[0087] If the preset refresh program detects that one or more of the preset refresh conditions for the network card firmware to be refreshed are not met (for example: the network card reports a hardware error, the current driver version is too old and incompatible with the target firmware, the network card temperature is too high, or a critical business process is monopolizing the network card resources), forcing the refresh at this time indicates that there is a high risk (which may cause refresh failure, device damage, business interruption, or data loss). At this time, a firmware problem message will be generated based on the firmware information and the preset refresh conditions.
[0088] Firmware problem information is a structured diagnostic report that identifies when preset refresh conditions were not met and describes the specific cause in detail, combined with specific firmware information. For example, firmware problem information might indicate hardware status anomalies: the network card temperature exceeds the safety threshold; software incompatibility: the current driver version is lower than the minimum version required by the target firmware; or resource conflicts: a process is monopolizing network card resources.
[0089] Firmware problem information can pinpoint the root cause of the problem and then visualize the firmware problem information, ensuring that users or operators can immediately and accurately understand why the refresh was blocked and the specific issues that need to be resolved (such as replacing faulty hardware, upgrading drivers, terminating specific processes, or waiting for a business downturn) to meet the preset refresh conditions, thereby safely retrying the refresh operation.
[0090] By performing a final pre-check based on firmware information, the firmware refresh is executed only when the preset refresh conditions are fully met, and precise problem information is generated and visualized when the conditions are not met. This allows full use of pre-backed-up network card status information for in-depth analysis, combined with real-time diagnostic data to make comprehensive judgments. This effectively prevents the reckless initiation of refresh operations when the network card status is unstable, the environment is incompatible, or there are potential conflicts, and nips the risks that may cause serious failures in the bud. At the same time, the generation and visualization of detailed firmware problem information provides a clear troubleshooting guide, significantly shortening the time to locate and resolve problems, and improving overall maintenance efficiency and system reliability.
[0091] In one possible implementation of the embodiment of the present application, when linking the network card firmware to be refreshed into the preset refresh program, it can also be implemented by, but not limited to, the following method: linking the network card firmware to be refreshed into the preset refresh program through a preset virtual function input and output module.
[0092] In an embodiment of the present application, the preset virtual function input and output module refers to the VFIO kernel module. VFIO is a powerful and secure framework provided by modern operating systems (especially systems based on virtualization technology). It allows user-mode programs (i.e., applications running outside the operating system kernel) to securely and directly access and control specific hardware devices (such as Peripheral Component Interconnect (PCI) / Peripheral Component Interconnect Extended (PCIExpress, PCIe) devices, including network cards) while strictly isolating this access to prevent it from affecting the stability of the host system.
[0093] When the preset refresh program runs, it actively calls and utilizes the VFIO framework interface provided by the operating system to request control of the network card firmware to be refreshed from the operating system kernel. The VFIO module unbinds the original driver of the network card firmware to be refreshed (if it has been bound) and brings the network card firmware to be refreshed under the management scope of VFIO. The VFIO module creates a secure Input-Output Memory Management Unit (IOMMU) protection domain to ensure that all memory accesses by the preset refresh program to the network card firmware to be refreshed are strictly limited to the authorized scope, preventing any unauthorized operations from interfering with the target server or other devices.
[0094] Linking the NIC firmware to be flashed into the default flash program establishes a direct channel from the default flash program to the NIC firmware to be flashed through VFIO. Once successfully linked, the default flash program gains direct, exclusive, and secure access to the NIC firmware to be flashed. The default flash program can bypass the operating system's standard network driver stack and directly send commands to the NIC's registers, read and write to the NIC's configuration space, and access the NIC's non-volatile memory. This linking ensures that the default flash program's operations on the NIC are isolated within the VFIO-provided zone, completely shielded from the target server's operating system and the critical services running on it.
[0095] By leveraging the secure hardware pass-through capability provided by the pre-set virtual function input and output module, the pre-set refresh program can directly manipulate the network card hardware in a completely isolated environment, eliminating the traditional firmware upgrade method's reliance on server restarts or business interruptions, significantly improving system availability and the efficiency of maintenance operations.
[0096] In summary, this application can achieve the following technical effects:
[0097] 1. By presetting the refresh program to simulate the server restart and network interruption scenarios during the firmware refresh process, the network card firmware can be updated without affecting the normal operation of the server. At the same time, the existing firmware is backed up during the firmware refresh process to ensure that data is not lost when the refresh fails, thereby ensuring the continuous stability of the network connection, improving the security and reliability of the firmware update, avoiding network interruption due to refresh failure, realizing online hot refresh, reducing server downtime, and improving system availability and maintenance efficiency. Therefore, it can solve the technical problem of how to complete the firmware refresh without restarting the server or interrupting the network connection, and achieve the technical effect of updating the network card firmware without affecting the normal operation of the server.
[0098] 2. By updating the network card firmware without affecting the normal operation of the server, the security and reliability of the firmware update are improved, network interruption caused by update failure is avoided, online hot update is realized, server downtime is reduced, and system availability and maintenance efficiency are improved.
[0099] 3. Back up the existing firmware during the firmware update process and automatically roll back to the previous stable version when the update fails, thereby ensuring the continued stability of the network connection and ensuring that the system can quickly return to normal when an abnormality occurs during the update process, avoiding serious consequences caused by update failure.
[0100] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus the necessary general hardware platform, and of course it can also be implemented by hardware, but in many cases the former is a better implementation method.
[0101] The embodiment of the present application also provides a device for refreshing the network card firmware. Figure 5 A schematic diagram of the structure of a network card firmware refresh device provided for application, such as Figure 5 Shown, including:
[0102] The verification unit 51 is used to perform data verification processing on the acquired multiple upgrade package data and multiple image data to obtain a data verification result;
[0103] The processing unit 52 is configured to receive an uploaded preset refresh program and link the network card firmware to be refreshed into the preset refresh program if it is determined based on the data verification result that the multiple upgrade package data and the multiple image data meet the preset verification conditions;
[0104] A backup unit 53 is configured to perform a backup process on the network card firmware to be refreshed based on a preset refresh program;
[0105] A matching unit 54 is configured to perform data matching processing on the network card firmware to be refreshed in the multiple upgrade package data and the multiple image data based on a preset refresh program, and obtain target upgrade package data and target image data corresponding to the network card firmware to be refreshed;
[0106] The refresh unit 55 is used to perform firmware refresh processing on the network card firmware to be refreshed using the target upgrade package data and the target image data in a preset refresh program to obtain the target network card firmware, wherein the preset refresh program is used to simulate the restart server and network interruption scenarios during the firmware refresh process.
[0107] In one embodiment of the present application, the verification unit 51 is further configured to:
[0108] Obtaining an upgrade package size corresponding to the first upgrade package data and an upgrade package size corresponding to the first image data, and calculating an upgrade package checksum corresponding to the first upgrade package data and an upgrade package checksum corresponding to the first image data, wherein the first upgrade package data is any upgrade package data from the plurality of upgrade package data, and the first image data is any image data from the plurality of image data;
[0109] Receive the uploaded standard upgrade package size and standard upgrade package checksum corresponding to the first upgrade package data, and the standard image size and standard image checksum corresponding to the first image data;
[0110] Comparing the upgrade package size with the corresponding standard upgrade package size, and comparing the upgrade package checksum with the standard upgrade package checksum, comparing the image size with the corresponding standard image size, and comparing the image checksum with the standard image checksum;
[0111] If the size of the upgrade package is consistent with that of the corresponding standard upgrade package, and the checksum of the upgrade package is consistent with that of the standard upgrade package, determining that the first upgrade package data meets the preset verification condition;
[0112] When the image size is consistent with the corresponding standard image size, and the image checksum is consistent with the standard image checksum, it is determined that the first image data meets the preset verification condition.
[0113] In one embodiment of the present application, the processing unit 52 is further configured to:
[0114] When it is determined according to the data verification result that any data among the multiple upgrade package data and the multiple image data does not meet the preset verification conditions, a data error prompt message is generated according to the data that does not meet the preset verification conditions, and the data error prompt message is visualized;
[0115] Receive updated data uploaded according to data error prompt information, and replace data that does not meet the preset verification conditions according to the updated data.
[0116] In one embodiment of the present application, the backup unit 53 is further configured to:
[0117] Extracting firmware information of the network card firmware to be refreshed through a preset refresh program, and backing up the firmware information to obtain backup data corresponding to the network card firmware to be refreshed;
[0118] Store the backup data in the preset memory.
[0119] In one embodiment of the present application, the matching unit 54 is further configured to:
[0120] Obtaining upgrade package information corresponding to each of the plurality of upgrade package data, and image information corresponding to each of the plurality of image data;
[0121] performing information comparison processing on multiple upgrade package information according to the firmware information to obtain target upgrade package information, and determining upgrade package data corresponding to the target upgrade package information as target upgrade package data, wherein a comparison result between the target upgrade package information and the firmware information meets a first preset comparison condition;
[0122] Information comparison processing is performed on multiple image information according to the firmware information to obtain target image information, and image data corresponding to the target image information is determined as the target image data, wherein the comparison result between the target image information and the firmware information meets the second preset comparison condition.
[0123] In one embodiment of the present application, Figure 6 As shown, the network card firmware refresh device also includes:
[0124] An acquiring unit 56 is configured to acquire the refresh information during the firmware refresh process and store the refresh information in a preset memory;
[0125] An extraction unit 57 is used to extract target firmware information of the target network card firmware and verify whether the target firmware information meets the preset firmware conditions;
[0126] The extraction unit 57 is further configured to extract the backup data in the preset memory when it is determined that the target firmware information does not meet the preset firmware condition;
[0127] The refreshing unit 55 is further configured to roll back the target network card firmware according to the backup data based on a preset refreshing program to obtain the network card firmware to be refreshed.
[0128] In one embodiment of the present application, Figure 6 As shown, the network card firmware refresh device also includes:
[0129] A determination unit 58 is configured to determine whether the network card firmware to be refreshed meets a preset refresh condition based on the firmware information;
[0130] The refresh unit 55 is further configured to, when it is determined that the network card firmware to be refreshed meets the preset refresh conditions, simulate the server restart and network interruption scenarios in response to the triggered firmware refresh instruction, and perform firmware refresh processing on the network card firmware to be refreshed to obtain the target network card firmware;
[0131] The determining unit 58 is further configured to, when it is determined that the network card firmware to be refreshed does not meet the preset refresh condition, generate firmware problem information according to the firmware information and the preset refresh condition, and visualize the firmware problem information.
[0132] In one embodiment of the present application, the processing unit 52 is further configured to:
[0133] The network card firmware to be refreshed is linked into the preset refresh program through the preset virtual function input and output module.
[0134] For the description of the features in the embodiment corresponding to the network card firmware refresh device, please refer to the relevant description of the embodiment corresponding to the network card firmware refresh method, which will not be repeated here.
[0135] An embodiment of the present application further provides an electronic device, comprising a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute the steps in any of the above-mentioned embodiments of the network card firmware refresh method.
[0136] An embodiment of the present application further provides a computer-readable storage medium, in which a computer program is stored. The computer program is configured to execute the steps of any of the above-mentioned network card firmware refresh method embodiments when running.
[0137] In an exemplary embodiment, the computer-readable storage medium may include, but is not limited to, various media that can store computer programs, such as a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk, or an optical disk.
[0138] An embodiment of the present application further provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the steps of any of the above-mentioned network card firmware refresh method embodiments are implemented.
[0139] An embodiment of the present application further provides another computer program product, comprising a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of any of the above-mentioned network card firmware refresh method embodiments are implemented.
[0140] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the above description has generally described the components and steps of each example according to their functions. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0141] The above is a detailed introduction to the network card firmware refresh method, electronic device, and storage medium provided by the present application. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only intended to help understand the method and core ideas of the present application. It should be pointed out that, for those skilled in the art, without departing from the principles of the present application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the scope of protection of the claims of the present application.
Claims
1. A method for refreshing network card firmware, characterized in that: include: Performing data verification processing on the acquired multiple upgrade package data and multiple image data to obtain a data verification result; If it is determined according to the data verification result that the multiple upgrade package data and the multiple image data all meet the preset verification conditions, receiving an uploaded preset refresh program, linking the network card firmware to be refreshed into the preset refresh program, and backing up the network card firmware to be refreshed based on the preset refresh program; Based on the preset refresh program, the network card firmware to be refreshed is subjected to data matching processing in the multiple upgrade package data and the multiple image data to obtain target upgrade package data and target image data corresponding to the network card firmware to be refreshed; In the preset refresh program, the network card firmware to be refreshed is refreshed using the target upgrade package data and the target image data to obtain the target network card firmware, wherein the preset refresh program is used to simulate server restart and network interruption scenarios during the firmware refresh process.
2. The method for refreshing the network card firmware according to claim 1, wherein: The data verification process is performed on the acquired multiple upgrade package data and multiple image data to obtain the data verification result, which includes: Obtaining an upgrade package size corresponding to first upgrade package data and an upgrade package size corresponding to first image data, and calculating an upgrade package checksum corresponding to the first upgrade package data and an upgrade package checksum corresponding to the first image data, wherein the first upgrade package data is any upgrade package data among the multiple upgrade package data, and the first image data is any image data among the multiple image data; Receive the uploaded standard upgrade package size and standard upgrade package checksum corresponding to the first upgrade package data, and the standard image size and standard image checksum corresponding to the first image data; Comparing the upgrade package size with the corresponding standard upgrade package size, and comparing the upgrade package checksum with the standard upgrade package checksum, comparing the image size with the corresponding standard image size, and comparing the image checksum with the standard image checksum; If the size of the upgrade package is consistent with the corresponding standard upgrade package, and the checksum of the upgrade package is consistent with the checksum of the standard upgrade package, determining that the first upgrade package data meets the preset verification condition; When the image size is consistent with the corresponding standard image size, and the image checksum is consistent with the standard image checksum, it is determined that the first image data meets the preset verification condition.
3. The method for refreshing the network card firmware according to claim 1, wherein: Before receiving the uploaded preset refresh program and linking the network card firmware to be refreshed into the preset refresh program, the method further includes: If it is determined according to the data verification result that any data among the plurality of upgrade package data and the plurality of image data does not meet the preset verification condition, generating data error prompt information according to the data that does not meet the preset verification condition, and visualizing the data error prompt information; Receive updated data uploaded according to the data error prompt information, and replace the data that does not meet the preset verification conditions according to the updated data.
4. The method for refreshing the network card firmware according to claim 1, wherein: The backing up of the network card firmware to be refreshed based on the preset refresh program includes: Extracting the firmware information of the network card firmware to be refreshed through the preset refresh program, and performing backup processing on the firmware information to obtain backup data corresponding to the network card firmware to be refreshed; The backup data is stored in a preset memory.
5. The method for refreshing the network card firmware according to claim 4, wherein: The step of performing data matching processing on the network card firmware to be refreshed in the plurality of upgrade package data and the plurality of image data based on the preset refresh program to obtain target upgrade package data and target image data corresponding to the network card firmware to be refreshed includes: Obtaining upgrade package information corresponding to each of the plurality of upgrade package data, and image information corresponding to each of the plurality of image data; performing information comparison processing on the plurality of upgrade package information according to the firmware information to obtain target upgrade package information, and determining upgrade package data corresponding to the target upgrade package information as the target upgrade package data, wherein a comparison result between the target upgrade package information and the firmware information meets a first preset comparison condition; According to the firmware information, information comparison processing is performed in the multiple image information to obtain target image information, and image data corresponding to the target image information is determined as the target image data, wherein the comparison result between the target image information and the firmware information meets the second preset comparison condition.
6. The method for refreshing the network card firmware according to claim 4, wherein: In the preset refresh program, after performing firmware refresh processing on the network card firmware to be refreshed using the target upgrade package data and the target image data to obtain the target network card firmware, the method further includes: Acquiring refresh information during the firmware refresh process, and storing the refresh information in the preset memory; Extracting target firmware information of the target network card firmware, and verifying whether the target firmware information meets a preset firmware condition; If it is determined that the target firmware information does not meet the preset firmware condition, extracting the backup data in the preset memory; Based on the preset refresh program, the target network card firmware is rolled back according to the backup data to obtain the network card firmware to be refreshed.
7. The method for refreshing the network card firmware according to claim 4, wherein: In the preset refresh program, before performing firmware refresh processing on the network card firmware to be refreshed using the target upgrade package data and the target image data to obtain the target network card firmware, the method further includes: Determining whether the network card firmware to be refreshed meets a preset refresh condition according to the firmware information; When it is determined that the network card firmware to be refreshed meets the preset refresh condition, the preset refresh program responds to the triggered firmware refresh instruction, simulates restarting the server and interrupting the network, and performs firmware refresh processing on the network card firmware to be refreshed to obtain the target network card firmware; When it is determined that the network card firmware to be refreshed does not meet the preset refresh condition, firmware problem information is generated according to the firmware information and the preset refresh condition, and the firmware problem information is visualized.
8. The method for refreshing the network card firmware according to claim 1, wherein: The receiving of the uploaded preset refresh program and linking the network card firmware to be refreshed into the preset refresh program includes: The network card firmware to be refreshed is linked into the preset refresh program through a preset virtual function input and output module.
9. An electronic device, characterized in that: include: memory for storing computer programs; A processor, configured to implement the steps of the network card firmware refresh method according to any one of claims 1 to 8 when executing the computer program.
10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, wherein when the computer program is executed by a processor, the steps of the method for refreshing the network card firmware according to any one of claims 1 to 8 are implemented.