CN117850832A - Automatic hard disk firmware upgrading method and device adapting to multi-type memory chips - Google Patents

Automatic hard disk firmware upgrading method and device adapting to multi-type memory chips Download PDF

Info

Publication number
CN117850832A
CN117850832A CN202311733500.1A CN202311733500A CN117850832A CN 117850832 A CN117850832 A CN 117850832A CN 202311733500 A CN202311733500 A CN 202311733500A CN 117850832 A CN117850832 A CN 117850832A
Authority
CN
China
Prior art keywords
hard disk
firmware
version
configuration file
upgrading
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311733500.1A
Other languages
Chinese (zh)
Inventor
周庆
张翼鹏
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tianyi Cloud Technology Co Ltd
Original Assignee
Tianyi Cloud Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tianyi Cloud Technology Co Ltd filed Critical Tianyi Cloud Technology Co Ltd
Priority to CN202311733500.1A priority Critical patent/CN117850832A/en
Publication of CN117850832A publication Critical patent/CN117850832A/en
Pending legal-status Critical Current

Links

Landscapes

  • Stored Programmes (AREA)

Abstract

The invention relates to a hard disk firmware automatic upgrading method and device adapting to multiple types of memory chips, belonging to the technical field of computers, wherein the method comprises the following steps: generating a configuration file of a hard disk, wherein the configuration file records a hard disk identifier, a hard disk version, a firmware version and a firmware name of the hard disk; obtaining the chip type of the storage chip corresponding to the hard disk; determining the driving type of the memory chip according to the chip type; and upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file. In this way, firmware upgrades to hard disks under multiple types of memory chip connections can be automated.

Description

Automatic hard disk firmware upgrading method and device adapting to multi-type memory chips
Technical Field
The invention belongs to the technical field of computers, and particularly relates to an automatic hard disk firmware upgrading method and device adapting to multiple types of memory chips.
Background
With the rapid development of internet technology, more and more data needs to be stored. For data with different storage requirements, storage media such as a high-capacity HDD (hard disk drive) and an SSD (solid state disk) are presented. The HDD is mainly due to the fact that the HDD is used for large-capacity cold storage and pursues a low TCO (total cost) service scenario, while the SSD has the advantages of stable performance (fast read-write speed, low time delay and low power consumption), so that many disadvantages of the HDD are effectively overcome, and the HDD is mainly used for hot storage and pursues a high-performance service scenario.
The hardware part of the HDD mainly comprises a disc, a magnetic head, a disc rotating shaft, a control motor, a magnetic head controller and a data converter, and the software part is firmware. In the hard disk, the firmware is responsible for driving, controlling, decoding, transmitting, detecting, etc. operations, such as managing storage locations of data, recording defective sectors that have been damaged, recording temperatures of the hard disk in operation or errors occurring, etc.
The SSD consists of a main control chip, NANDflash (solid state disk storage medium) and firmware, wherein the firmware is the most important component for ensuring the SSD performance and is used for driving a controller. The master uses control programs in the firmware algorithm to perform tasks such as automatic signal processing, wear leveling, error Correction Code (ECC), bad block management, garbage collection algorithms, communication with the host device (e.g., server), and data encryption. There are many brands of enterprise-level SSDs on the market, and SSDs that employ the same master may also exhibit completely different performance and durability due to differences in firmware development from different vendors. If the number is used, the influence of the solid state disk storage medium in one SSD on the performance is about 60%, and the influence of the firmware and the main control chip is about 20%.
In the use process of cloud computing service, when serious problems are encountered, the HDD and the SSD may drop the disk and even lose data, and a hard disk manufacturer positions and analyzes the failure cause according to the problems, and reissues and updates new firmware to improve the performance of the HDD and the SSD and solve some once-occurring known problems.
The cloud computing company data center purchases a large number of HDDs and SSDs, is various in brands and models, can be used with storage array card chips of various models, and is a problem of how to identify the HDD and SSD models, manage and upgrade hard disk firmware versions and is called as increasing protrusion under the very complex hardware scene. .
At present, two methods for upgrading hard disk firmware are mainly provided, one is that a manufacturer provides an upgrading tool and a firmware package to perform offline upgrading, and the method is only suitable for a hard disk through connection mode and cannot transmit RAID (redundant array of independent disks) in a penetrating way. Another is to upgrade the firmware with an array card specific tool.
The inventor finds that in the process of implementing the application, the existing firmware upgrading method has the following defects: only aiming at a single array card and a hard disk brand model, a complex cloud computing equipment type scene is not considered, and firmware of hardware connected with multiple types of memory chips cannot be automatically upgraded.
Disclosure of Invention
In view of the above drawbacks of the prior art, an object of the present invention is to provide an automatic upgrade method and apparatus for hard disk firmware adapted to multiple types of memory chips, so as to automatically upgrade the firmware of the hard disk connected to the multiple types of memory chips.
In a first aspect, an embodiment of the present invention provides an automatic hard disk firmware upgrade method adapted to multiple types of memory chips, which is applied to a server, and includes:
s1, generating a configuration file of a hard disk, wherein the configuration file records a hard disk identifier, a hard disk version, a firmware version and a firmware name of the hard disk;
s2, acquiring the chip type of the storage chip corresponding to the hard disk;
s3, determining the driving type of the memory chip according to the chip type;
s4, upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file.
Further, the upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file may include:
judging whether the driving type is array card driving;
if the driver is an array card driver, the firmware of the hard disk is upgraded according to the driving type of the memory chip and the configuration file.
Further, the method may further include:
and if the hard disk is not the array card drive, directly connecting the hard disk to the server so as to control the firmware of the hard disk to be upgraded through the operating system of the server.
Further, the upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file includes:
deleting RAID algorithm corresponding to the array card drive;
acquiring a hard disk version and a firmware version of the hard disk in the configuration file;
and calling a firmware upgrading version matched with the obtained hard disk version and the firmware version, and upgrading the firmware.
Further, the method further comprises:
and when the hard disk is a solid state disk, safely erasing the solid state disk.
In a second aspect, an embodiment of the present invention further provides an apparatus for automatically upgrading hard disk firmware adapted to multiple types of memory chips, where the apparatus is applied to a server, and the apparatus includes:
the generating module is used for generating a configuration file of the hard disk, wherein the configuration file records a hard disk identifier, a hard disk version, a firmware version and a firmware name of the hard disk;
the first acquisition module is used for acquiring the chip type of the storage chip corresponding to the hard disk;
the first determining module is used for determining the driving type of the memory chip according to the chip type;
and the upgrading module is used for upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file.
Further, the upgrade module is specifically configured to:
judging whether the driving type is array card driving;
if the driver is an array card driver, the firmware of the hard disk is upgraded according to the driving type of the memory chip and the configuration file.
Further, the upgrade module is further configured to:
and if the hard disk is not the array card drive, directly connecting the hard disk to the server so as to control the firmware of the hard disk to be upgraded through the operating system of the server.
Further, the upgrade module is specifically configured to:
deleting RAID algorithm corresponding to the array card drive;
acquiring a hard disk version and a firmware version of the hard disk in the configuration file;
and calling a firmware upgrading version matched with the obtained hard disk version and the firmware version, and upgrading the firmware.
Further, the apparatus further comprises:
and the erasing module is used for safely erasing the solid state disk when the hard disk is the solid state disk.
The invention has the following beneficial effects:
the method and the device can generate the configuration file of the hard disk, wherein the configuration file records the hard disk identification, the hard disk version, the firmware version and the firmware name of the hard disk;
obtaining the chip type of the storage chip corresponding to the hard disk; determining the driving type of the memory chip according to the chip type; and upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file. In this way, firmware upgrades to hard disks under multiple types of memory chip connections can be automated.
Drawings
The drawings are only for purposes of illustrating particular embodiments and are not to be construed as limiting the invention, like reference numerals being used to refer to like parts throughout the several views. It is apparent that the drawings in the following description are only some of the embodiments described in the embodiments of the present invention, and that other drawings may be obtained from these drawings by those of ordinary skill in the art.
FIG. 1 is a flowchart of an automatic upgrade method for hard disk firmware adapting to multiple types of memory chips according to an embodiment of the present invention;
FIG. 2 is a flowchart of another method for automatically upgrading hard disk firmware of adapting to multiple types of memory chips according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of an automatic upgrade device for hard disk firmware adapting to multiple types of memory chips according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a server according to an embodiment of the present invention.
Detailed Description
In order to make the technical solutions of the embodiments of the present invention better understood by those skilled in the art, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments. It should be understood that the description is only illustrative and is not intended to limit the scope of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, shall fall within the scope of the invention.
In addition, in the following description, descriptions of well-known structures and techniques are omitted so as not to unnecessarily obscure the concepts of the present disclosure.
In the description of the present invention, it should be noted that unless explicitly stated and limited otherwise, the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc. indicate orientations or positional relationships based on the orientations or positional relationships shown in the drawings, are merely for convenience in describing the present invention and simplifying the description, and do not indicate or imply that the devices or elements referred to must have a specific orientation, be configured and operated in a specific orientation, and thus should not be construed as limiting the present invention. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. The terms "mounted," "connected," "coupled," and "connected" are to be construed broadly, and may be, for example, fixedly connected, detachably connected, or integrally connected; can be mechanically or electrically connected; can be directly connected or indirectly connected through an intermediate medium, and can be communication between two elements. The specific meaning of the above terms in the present invention will be understood in specific cases by those of ordinary skill in the art.
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples do not represent all implementations consistent with the invention. Rather, they are merely examples of methods and systems that are consistent with aspects of the invention as detailed in the accompanying claims.
Currently, hard disks commonly used are HDD (hard disk drive), SATA (serial ATA), SAS (serial attached SCSI), SSD (solid state disk), and the like.
There are two general ways to connect hard disks, one is to connect to the hard disk backplane through a mainstream storage array card, which is further divided into a RAID (redundant array of independent disks) card and an HBA (host bus adapter) pass-through card. The hard disk hung under the RAID card can not directly identify the drive symbol, and the driving and management tools of the array cards of different brands are different, and each time the information of the hard disk needs to be checked, the corresponding array card type is firstly inquired and then the corresponding management tool is used; the other is to connect directly to the hard disk backplane via the chipset PCH and FCH, in such a way that the disk drive can be identified directly. However, both of the two methods cannot automatically upgrade the firmware of the hard disk connected with the multiple types of memory chips.
The invention provides an automatic upgrading method and device for hard disk firmware adapting to multiple types of memory chips, which aim to solve the problems that the firmware of the hard disk connected with the multiple types of memory chips cannot be automatically upgraded and the like.
Method embodiment
In a first aspect, an embodiment of the present invention provides an automatic hard disk firmware upgrade method adapted to multiple types of memory chips, which is applied to a server, referring to fig. 1, and the method may include:
s1, generating a configuration file of a hard disk, wherein the configuration file records a hard disk identifier, a hard disk version, a firmware version and a firmware name of the hard disk;
it will be appreciated that after purchasing the hard disk, a configuration file corresponding to each hard disk may be generated. The configuration file may include: hard disk identification of the hard disk, hard disk version, firmware version, and firmware name.
For example, the configuration file of the purchased HDD may be recorded with:
HDD.SEAGATE_Makara_plus\bST\w+NM0055\bSN05SN05.lod
the HDD is a hard disk product produced by Seagate company, and the SEAGATE_Makara_plus is a hard disk identifier; b, wherein b, w+NM0055 b is the version or model of the hard disk matched with the regular expression; SN05 represents the firmware version of the hard disk. The sn05.Lod represents a firmware name or a firmware package name.
S2, acquiring the chip type of the storage chip corresponding to the hard disk;
it will be appreciated that the server may be connected to each hard disk via a memory chip. In the embodiment of the invention, the chip type of the storage chip corresponding to each hard disk can be obtained. Specifically, the chip type of the memory chip can be obtained by the lspci command. The lspci command is an existing computer technology command and is not described herein.
S3, determining the driving type of the memory chip according to the chip type;
it will be appreciated that the entry associated with the memory chip may be looked up based on the chip type, and in particular, the driver currently used by the memory chip, i.e., the driver type corresponding to the memory chip, may be looked up.
S4, upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file.
Fig. 2 is a flowchart of another method for automatically upgrading hard disk firmware adapted to multiple types of memory chips according to an embodiment of the present invention, see fig. 2:
after the flow starts, the inventors named the environment entry ramos, entering PXE (Preboot Execution Environment, pre-boot execution environment). Thereafter, the run code and toolkit may be loaded to check the memory chip type and the drive version (i.e., the drive type). Specifically, there may be the following six cases:
for the first five cases, the upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file may include:
judging whether the driving type is array card driving; if the driver is an array card driver, the firmware of the hard disk is upgraded according to the driving type of the memory chip and the configuration file. Specifically:
case one: if the driving type of the memory chip is mpt3 SAS driving, the main program of the server can call the function of detecting and upgrading the hard disk firmware hung under the Broadcom LSI SAS3HBA card, so as to detect and upgrade the version of the hard disk firmware.
Among other things, mpt SAS drive modules are typically associated with SAS controllers (e.g., LSI SAS3008, 3108) commonly found in servers and storage devices for managing SAS hard drives and providing RAID functionality.
The Broadcom LSI SAS3HBA card is a Host Bus Adapter card produced by Broadcom corporation (previously purchased from LSI) and is a device dedicated to supporting the SAS3 (Serial Attached SCSI, serial attached SCSI 3) protocol.
Specifically, the following operations may be performed on the hard disk connected to the Broadcom LSI SAS3HBA card:
deleting the RAID array using the sas3ircu tool: the sas3ircu tool is used to delete the RAID arrays that may be present, configuring the hard disk as a stand-alone device.
Matching the hard disk model and detecting the firmware version: the hard disk model in the configuration file of the hard disk is automatically matched, and then the firmware version of the hard disk is detected by using a smartctl tool. If the firmware version of the hard disk is not matched with the new firmware version (namely, the firmware upgrading version), executing firmware upgrading operation; if the firmware version of the hard disk matches the new firmware version (i.e., the firmware upgrade version), the process ends.
Firmware upgrades using hdchart tools: firmware upgrades are performed on the hard disk using an hdchart tool. Firmware upgrades may be to improve hard disk performance, fix known problems, or add new functionality. Specifically, the upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file may include: deleting RAID algorithm corresponding to the array card drive; acquiring a hard disk version and a firmware version of the hard disk in the configuration file; and calling a firmware upgrading version matched with the obtained hard disk version and the firmware version, and upgrading the firmware.
If the hard disk is SSD, secure erasure can be performed: for Solid State Drives (SSDs), a secure erase operation may be performed after a firmware upgrade is completed. Secure erase is a method of completely erasing data on a storage medium, and is generally used to secure data against unauthorized access.
It should be noted that the above mentioned tools are all common software code tools in the existing computer technology, and are similar to the above, and will not be specifically described herein.
And a second case: if the driving type of the memory chip is megaraid_sas driving, the main program of the server may call the function of detecting and upgrading the hard disk firmware hung under the Broadcom LSI SAS3 card, so as to detect and upgrade the hard disk firmware version.
Wherein, the megaraid_sas driver module is a Linux kernel module for supporting LSI (now Broadcom) MegaRAID SAS RAID controller. The MegaRAID SAS controller is a type of hardware RAID controller for managing hard disk drives connected to a server and providing RAID functions such as data redundancy and performance optimization.
Specifically, the following operations may be performed on a hard disk connected to a broadcom isias 3HBA card:
deleting the RAID array using a garcali tool: using the garcili tool, which may be a Broadcom or Avago RAID controller configuration tool, the existing RAID array is deleted. In this way, the hard disk will no longer be in a RAID configuration.
Opening JBOD function and setting hard disk as JBOD: the JBOD function is turned on the RAID controller, configuring all hard disks into JBOD mode. JBOD means that the hard disk will be a stand-alone device rather than making up a RAID array.
In the field of computer storage, JBOD (Justa Bunch Of Disks, just a stack of disks) is a disk configuration in which multiple independent hard disk drives are combined together to form a logical volume, but they do not form a RAID array.
Automatic matching of hard disk model: automatically matching the model in the hard disk configuration file facilitates subsequent firmware detection and upgrade steps.
Firmware version is detected using the smartctl tool: the current firmware version of the hard disk is checked using the smartctl tool. smartctl is typically used to monitor and analyze the health of hard disks. If the firmware version of the hard disk is not matched with the new firmware version (namely, the firmware upgrading version), executing firmware upgrading operation; if the firmware version of the hard disk matches the new firmware version (i.e., the firmware upgrade version), the process ends.
Firmware upgrades using hdchart tools: and upgrading the firmware of the hard disk by using an hdchart tool. Firmware upgrades may be to fix problems, improve performance, or add new functionality.
If SSD, then secure erase: for a Solid State Disk (SSD), after firmware upgrade is completed, a secure erase operation is performed.
And a third case: if the drive type of the memory chip is mpi3mr, the main program of the server can call the hard disk firmware detection and upgrade program function hung under the Broadcom LSI SAS4 card, so as to be capable of detecting and upgrading the hard disk firmware version.
Among them, mpi mr is a driver of a SAS (Serial Attached SCSI ) controller for managing storage devices supporting SAS interfaces, such as hard disk drives.
Broadcom LSI SAS4 array card: this is a SAS (Serial Attached SCSI ) array card, commonly manufactured by Broadcom or LSI (now Broadcom), for connecting a computer host system to SAS storage devices.
Hard disk firmware detection and upgrade: the following operations are performed on the hard disk connected to the Broadcom LSI SAS4 array card:
RAID arrays were deleted using the garcali 2 tool: using the garcili 2 tool, which may be a Broadcom or Avago RAID controller configuration tool, the existing RAID array is deleted. This will ensure that the hard disk is operating in a non-RAID mode.
Opening JBOD function and setting hard disk as JBOD: the JBOD function is turned on the RAID controller, configuring all hard disks into JBOD mode. JBOD means that the hard disk will be a stand-alone device rather than making up a RAID array.
Automatic matching of hard disk model: automatically matching the model in the hard disk configuration file facilitates subsequent firmware detection and upgrade steps.
Firmware version is detected using the smartctl tool: the current firmware version of the hard disk is checked using the smartctl tool. smartctl is typically used to monitor and analyze the health of hard disks. If the firmware version of the hard disk is not matched with the new firmware version (namely, the firmware upgrading version), executing firmware upgrading operation; if the firmware version of the hard disk matches the new firmware version (i.e., the firmware upgrade version), the process ends.
Firmware upgrades using hdchart tools: and upgrading the firmware of the hard disk by using an hdchart tool. Firmware upgrades may be to fix problems, improve performance, or add new functionality.
If SSD, then secure erase: for a Solid State Disk (SSD), after firmware upgrade is completed, a secure erase operation is performed.
Case four: if the driving type of the storage chip is an aacid driving, the main program of the server can call the Microchip Adaptec RAID card down-hanging hard disk firmware detection and upgrading program function so as to detect and upgrade the hard disk firmware version.
The aaacid is a Linux kernel module of a RAID controller card (RAID Adapter) manufactured by an Adapter company. The RAID controller of the Adaptec is used for managing the hard disk array and providing data redundancy and performance optimization functions.
Microchip Adaptec RAID card: this is a RAID controller card manufactured by Microchip, which is specifically designed to manage the hard disk array, providing data redundancy and performance optimization functions.
Specifically, the following operations may be performed on a hard disk connected to a Microchip Adaptec RAID card:
deleting RAID arrays using an arcconf tool: the existing RAID array is deleted using the arcconf tool, the configuration tool of Microchip Adaptec RAID controller. This will ensure that the hard disk is operating in a non-RAID mode.
Setting RAID card controller mode to Hide Raw mode: the controller mode of the RAID card is set to Hide Raw mode. This may be to hide the original access of the underlying hard disk for subsequent operations.
Automatic matching of hard disk model: automatically matching the model in the hard disk configuration file facilitates subsequent firmware detection and upgrade steps.
Firmware version is detected using the smartctl tool: the current firmware version of the hard disk is checked using the smartctl tool. smartctl is typically used to monitor and analyze the health of hard disks. If the firmware version of the hard disk is not matched with the new firmware version (namely, the firmware upgrading version), executing firmware upgrading operation; if the firmware version of the hard disk matches the new firmware version (i.e., the firmware upgrade version), the process ends.
Firmware upgrades using hdchart tools: and upgrading the firmware of the hard disk by using an hdchart tool. Firmware upgrades may be to fix problems, improve performance, or add new functionality.
If SSD, then secure erase: for a Solid State Disk (SSD), after firmware upgrade is completed, a secure erase operation is performed. Secure erase is a method of completely erasing data on a storage medium, and is generally used to secure data against unauthorized access.
Case five: if the driving type of the storage chip is a smartpqi driving, the main program of the server can call the Microchip Adaptec card down-hanging hard disk firmware detection and upgrading program function so as to be capable of detecting and upgrading the hard disk firmware version.
The smartpqi driver module is used to support the Linux kernel driver of a RAID controller of Microsemi (now Microchip) corporation. This driver is responsible for communicating with the RAID controller card of Microsemi to manage and operate the hard disk array connected to the controller in the Linux operating system.
The BROADCOM card is an array card manufactured by Broadcom corporation for managing hard disk arrays. The array card provides RAID functionality, combines multiple hard disks into logical volumes, and provides data redundancy and performance optimization.
Specifically, the following operations are performed on a hard disk connected to a BROADCOM array card:
deleting RAID arrays using an arcconf tool: using the arcconf tool, which is a configuration tool for Broadcom array cards, existing RAID arrays are deleted. This will ensure that the hard disk is operating in a non-RAID mode.
Setting the array card controller mode to Mixed mode: the controller mode of the array card is set to Mixed mode. This may be to enable the array card to support different modes of operation at the same time.
Automatic matching of hard disk model: automatically matching the model in the hard disk configuration file facilitates subsequent firmware detection and upgrade steps.
Firmware version is detected using the smartctl tool: the current firmware version of the hard disk is checked using the smartctl tool. smartctl is typically used to monitor and analyze the health of hard disks. If the firmware version of the hard disk is not matched with the new firmware version (namely, the firmware upgrading version), executing firmware upgrading operation; if the firmware version of the hard disk matches the new firmware version (i.e., the firmware upgrade version), the process ends.
Firmware upgrades using hdchart tools: and upgrading the firmware of the hard disk by using an hdchart tool. Firmware upgrades may be to fix problems, improve performance, or add new functionality.
If SSD, then secure erase: for a Solid State Disk (SSD), after firmware upgrade is completed, a secure erase operation is performed.
For the following case, if the hard disk is not an array card drive, the hard disk is directly connected to the server so as to control the firmware of the hard disk to upgrade through the operating system of the server.
Specifically:
case six:
array-free card detection: if no array card is detected in the system, it is indicated that the hard disk is directly connected to the PCH/FCH chip (host bus controller on the motherboard) rather than through a dedicated array card.
Specifically, for a direct-connection hard disk, the system will call a special program function to perform the following operations:
firmware version is detected using the smartctl tool: the current firmware version of the direct-connect hard disk is detected by the smartctl tool. smartctl is typically used to monitor and analyze the health of hard disks. If the firmware version of the hard disk is not matched with the new firmware version (namely, the firmware upgrading version), executing firmware upgrading operation; if the firmware version of the hard disk matches the new firmware version (i.e., the firmware upgrade version), the process ends.
Firmware upgrades using hdchart tools: and carrying out firmware upgrading on the direct-connected hard disk through an hdchart tool. Firmware upgrades may be to fix problems, improve performance, or add new functionality.
If SSD, then secure erase: for a Solid State Disk (SSD), after firmware upgrade is completed, a secure erase operation is performed.
The method can generate the configuration file of the hard disk, wherein the configuration file records the hard disk identification, the hard disk version, the firmware version and the firmware name of the hard disk; obtaining the chip type of the storage chip corresponding to the hard disk; determining the driving type of the memory chip according to the chip type; and upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file. In this way, firmware upgrades to hard disks under multiple types of memory chip connections can be automated.
Device embodiment
In a second aspect, an embodiment of the present invention further provides an apparatus for automatically upgrading hard disk firmware adapted to multiple types of memory chips, which is applied to a server, referring to fig. 3, including:
the generating module 301 is configured to generate a configuration file of a hard disk, where the configuration file records a hard disk identifier, a hard disk version, a firmware version and a firmware name of the hard disk;
the first obtaining module 302 is configured to obtain a chip type of a memory chip corresponding to the hard disk;
a first determining module 303, configured to determine a driving type of the memory chip according to the chip type;
and the upgrade module 304 is configured to upgrade the firmware of the hard disk according to the driving type of the storage chip and the configuration file.
By applying the device provided by the invention, the configuration file of the hard disk can be generated, wherein the configuration file records the hard disk identification, the hard disk version, the firmware version and the firmware name of the hard disk; obtaining the chip type of the storage chip corresponding to the hard disk; determining the driving type of the memory chip according to the chip type; and upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file. In this way, firmware upgrades to hard disks under multiple types of memory chip connections can be automated.
Further, the upgrade module is specifically configured to:
judging whether the driving type is array card driving;
if the driver is an array card driver, the firmware of the hard disk is upgraded according to the driving type of the memory chip and the configuration file.
Further, the upgrade module is further configured to:
and if the hard disk is not the array card drive, directly connecting the hard disk to the server so as to control the firmware of the hard disk to be upgraded through the operating system of the server.
Further, the upgrade module is specifically configured to:
deleting RAID algorithm corresponding to the array card drive;
acquiring a hard disk version and a firmware version of the hard disk in the configuration file;
and calling a firmware upgrading version matched with the obtained hard disk version and the firmware version, and upgrading the firmware.
Further, the apparatus further comprises:
and the erasing module is used for safely erasing the solid state disk when the hard disk is the solid state disk.
In a third aspect, the present invention proposes a server, as shown in fig. 4, including: a memory and one or more processors.
The memory has stored therein one or more applications adapted to be executed by the one or more processors to implement the method of the first aspect.
The server can generate the configuration file of the hard disk, wherein the configuration file records the hard disk identification, the hard disk version, the firmware version and the firmware name of the hard disk; obtaining the chip type of the storage chip corresponding to the hard disk; determining the driving type of the memory chip according to the chip type; and upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file. In this way, firmware upgrades to hard disks under multiple types of memory chip connections can be automated.
As shown in fig. 4, the server includes: a processor 401 and a memory 402. Wherein the processor 401 is connected to a memory 402, e.g. via a bus.
The structure of the server is not limited to the embodiment of the present invention.
The processor 401 may be a CPU, general purpose processor, DSP, ASIC, FPGA or other programmable logic device, transistor logic device, hardware components, or any combination thereof. Which may implement or perform the various exemplary logic blocks, modules and circuits described in connection with this disclosure. Processor 401 may also be a combination that implements computing functionality, such as a combination comprising one or more microprocessors, a combination of a DSP and a microprocessor, or the like.
A bus may include a path that communicates information between the components. The bus may be a PCI bus or an EISA bus, etc. The buses may be divided into address buses, data buses, control buses, etc. For ease of illustration, only one thick line is shown in fig. 4, but not only one bus or one type of bus.
Memory 402 may be, but is not limited to, ROM or other type of static storage device, RAM or other type of dynamic storage device, which may store static information and instructions, EEPROM, CD-ROM or other optical disk storage, optical disk storage (including compact disk, laser disk, optical disk, digital versatile disk, blu-ray disc, etc.), magnetic disk storage or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer.
In a fourth aspect, the present invention proposes a computer readable storage medium having stored thereon a computer program which is loadable and executable by a processor for the method according to the first aspect.
While the applicant has described and illustrated the embodiments of the present invention in detail with reference to the drawings, it should be understood by those skilled in the art that the above embodiments are only preferred embodiments of the present invention, and the detailed description is only for the purpose of helping the reader to better understand the spirit of the present invention, and not to limit the scope of the present invention, but any improvements or modifications based on the spirit of the present invention should fall within the scope of the present invention.
Finally, it should be noted that the above embodiments are merely for illustrating the technical solution of the embodiments of the present invention, and are not limiting. Although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the embodiments of the invention, and any changes and substitutions that would be apparent to one skilled in the art are intended to be included within the scope of the present invention.

Claims (10)

1. An automatic hard disk firmware upgrading method adapting to a plurality of types of memory chips is characterized by being applied to a server and comprising the following steps:
s1, generating a configuration file of a hard disk, wherein the configuration file records a hard disk identifier, a hard disk version, a firmware version and a firmware name of the hard disk;
s2, acquiring the chip type of the storage chip corresponding to the hard disk;
s3, determining the driving type of the memory chip according to the chip type;
s4, upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file.
2. The method of claim 1, wherein the upgrading the firmware of the hard disk according to the drive type of the memory chip and the configuration file comprises:
judging whether the driving type is array card driving;
if the driver is an array card driver, the firmware of the hard disk is upgraded according to the driving type of the memory chip and the configuration file.
3. The method according to claim 2, wherein the method further comprises:
and if the hard disk is not the array card drive, directly connecting the hard disk to the server so as to control the firmware of the hard disk to be upgraded through the operating system of the server.
4. The method of claim 2, wherein the upgrading the firmware of the hard disk according to the drive type of the memory chip and the configuration file comprises:
deleting RAID algorithm corresponding to the array card drive;
acquiring a hard disk version and a firmware version of the hard disk in the configuration file;
and calling a firmware upgrading version matched with the obtained hard disk version and the firmware version, and upgrading the firmware.
5. The method according to claim 4, wherein the method further comprises:
and when the hard disk is a solid state disk, safely erasing the solid state disk.
6. An automatic hard disk firmware upgrading device adapting to multiple types of memory chips is characterized by being applied to a server and comprising:
the generating module is used for generating a configuration file of the hard disk, wherein the configuration file records a hard disk identifier, a hard disk version, a firmware version and a firmware name of the hard disk;
the first acquisition module is used for acquiring the chip type of the storage chip corresponding to the hard disk;
the first determining module is used for determining the driving type of the memory chip according to the chip type;
and the upgrading module is used for upgrading the firmware of the hard disk according to the driving type of the storage chip and the configuration file.
7. The apparatus of claim 6, wherein the upgrade module is specifically configured to:
judging whether the driving type is array card driving;
if the driver is an array card driver, the firmware of the hard disk is upgraded according to the driving type of the memory chip and the configuration file.
8. The apparatus of claim 7, wherein the upgrade module is further to:
and if the hard disk is not the array card drive, directly connecting the hard disk to the server so as to control the firmware of the hard disk to be upgraded through the operating system of the server.
9. The apparatus of claim 7, wherein the upgrade module is specifically configured to:
deleting RAID algorithm corresponding to the array card drive;
acquiring a hard disk version and a firmware version of the hard disk in the configuration file;
and calling a firmware upgrading version matched with the obtained hard disk version and the firmware version, and upgrading the firmware.
10. The apparatus of claim 9, wherein the apparatus further comprises:
and the erasing module is used for safely erasing the solid state disk when the hard disk is the solid state disk.
CN202311733500.1A 2023-12-15 2023-12-15 Automatic hard disk firmware upgrading method and device adapting to multi-type memory chips Pending CN117850832A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311733500.1A CN117850832A (en) 2023-12-15 2023-12-15 Automatic hard disk firmware upgrading method and device adapting to multi-type memory chips

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311733500.1A CN117850832A (en) 2023-12-15 2023-12-15 Automatic hard disk firmware upgrading method and device adapting to multi-type memory chips

Publications (1)

Publication Number Publication Date
CN117850832A true CN117850832A (en) 2024-04-09

Family

ID=90528159

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311733500.1A Pending CN117850832A (en) 2023-12-15 2023-12-15 Automatic hard disk firmware upgrading method and device adapting to multi-type memory chips

Country Status (1)

Country Link
CN (1) CN117850832A (en)

Similar Documents

Publication Publication Date Title
US8751862B2 (en) System and method to support background initialization for controller that supports fast rebuild using in block data
US8086896B2 (en) Dynamically tracking virtual logical storage units
US8250401B2 (en) Storage device realignment
US8839026B2 (en) Automatic disk power-cycle
JP2006146833A (en) Consistency check support method for disk device and consistency check method for disk array device
US20070080205A1 (en) System and method for testing a card reader of a computer
US8843781B1 (en) Managing drive error information in data storage systems
TW201629785A (en) Management controller
CN102222033A (en) Method and device for saving small computer system interface access error
US11237893B2 (en) Use of error correction-based metric for identifying poorly performing data storage devices
US10437270B2 (en) Systems and methods for reporting of excessive vibration conditions in a storage resource
US8627054B2 (en) Method and apparatus to create single firmware image for multiple server platforms
CN117850832A (en) Automatic hard disk firmware upgrading method and device adapting to multi-type memory chips
JP6287613B2 (en) Control device and diagnostic control program
JPH11212792A (en) Processor for removable medium
US20210349775A1 (en) Method of data management and method of data analysis
US7398416B2 (en) Proactive driver response to an operating system if a drive is removed from a RAID configuration
US7975136B1 (en) Hardware-independent detection of SAN logical volumes
US20080281992A1 (en) Method for detecting order of attached devices and computer readable storage media storing program thereof
US8924351B2 (en) Method and apparatus to share a single storage drive across a large number of unique systems when data is highly redundant
JP2001076422A (en) Judgment and test method for replacement processing time of storage device
US9639417B2 (en) Storage control apparatus and control method
CN111512280A (en) Customizing configuration of one or more storage devices for an operating environment
TWI832173B (en) Method and system for monitoring flash memory device and computer system thereof
CN116383012B (en) Method and device for acquiring boot log and method for transmitting boot log

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination