Driving program installation method and electronic equipment

By reading and loading pre-stored server device driver files during operating system image installation, the problem of operating system publisher update speed not matching hardware iteration is solved, enabling rapid driver updates and installation for new server components.

CN121387313APending Publication Date: 2026-01-23INSPUR (SHANDONG) COMPUTER TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202511676015.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-14
Publication Date
2026-01-23

AI Technical Summary

Technical Problem

Operating system distributors have a long cycle for releasing new ISO images, which makes it difficult to meet the driver update needs of rapidly evolving new server components.

Method used

The driver files for all server devices are pre-stored in a pre-configured storage medium. During operating system image installation, the target driver files for undriven devices are read and loaded based on the target installation environment. The operating system image and target driver files are then installed, and the system is restarted after installation.

Benefits of technology

It eliminates the need to integrate driver files into the operating system image in advance, solving the problems of long release cycles for new ISO images and delayed driver updates by system distributors, thus ensuring the rapid promotion and application of new components.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121387313A_ABST
    Figure CN121387313A_ABST
Patent Text Reader

Abstract

The invention discloses a drive program installation method and electronic equipment, and relates to the technical field of software. According to the scheme, the driver files of all the devices of the server are stored in the preset storage medium in advance, so that the completeness of driver programs of all the devices is ensured, which is the premise of executing device driver updating and installation; meanwhile, when the operation system mirror image is installed, the target drive file of the undriven device in the storage medium can be read, loaded and installed based on the target installation environment of the operation system mirror image, the drive file does not need to be integrated into the operation system mirror image in advance, and the operation system mirror image version release is not depended on; therefore, the problems that the period of releasing the new ISO mirror image by the system issuer is long, and the new parts cannot be used due to the update lag of the drive program are solved, and the rapid popularization and application of the new parts of the server are facilitated.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of software, and particularly relates to a driver installation method and an electronic device. BACKGROUND

[0002] With the rapid development of semiconductor technology, artificial intelligence, high-performance computing and other fields, new server components are emerging, and their architecture and functions have far exceeded traditional hardware. However, the update speed of drivers in the operating system (OS) often lags behind the rapid iteration of hardware, causing a series of problems.

[0003] During the operating system installation stage, the installation process may be blocked and cannot proceed smoothly due to the lack of adaptive driver support. During the operating system startup and use stage, some components may not be able to function properly due to the lack of drivers. In some cases, both problems may occur at the same time. Currently, the common method to solve these problems is to wait for the operating system vendor to include the drivers of the relevant components and release a new ISO image version. However, since the release cycle of the ISO image is usually in "years", this obviously cannot meet the rapid development pace of server components.

[0004] In view of the above, how to solve the problem that the current operating system vendor releases new ISO images with a long cycle and cannot meet the rapid development of new server components in terms of driver updates is a problem that needs to be solved by technical personnel in this field. SUMMARY

[0005] The present application provides a driver installation method and an electronic device to at least solve the problem that the current operating system vendor releases new ISO images with a long cycle and cannot meet the rapid development of new server components in terms of driver updates.

[0006] The present application provides a driver installation method applied to a server; the method comprises:

[0007] Starting a target installation environment of an operating system image, and querying un-driven devices in all devices of the server;

[0008] Identifying a pre-set storage medium; wherein the storage medium contains driver files of all devices in the server;

[0009] Based on the target installation environment, reading and loading target driver files of the un-driven devices in the storage medium;

[0010] Based on the target installation environment, installing the operating system image and the target driver files, and restarting the system after installation is completed.

[0011] The application further provides an electronic device, comprising a memory for storing a computer program, and a processor for executing the computer program to implement the steps of any of the drive program installation methods.

[0012] The application has the advantages that the drive files of all devices of the server are stored in the pre-set storage medium in advance, the integrity of the device drive programs is ensured, and this is a prerequisite for performing device drive updating and installation; meanwhile, when the operating system image installation is performed, the target drive files of the un-driven devices in the storage medium can be read, loaded and installed based on the target installation environment of the operating system image, the drive files do not need to be integrated into the operating system image in advance, and the application does not depend on the release of the operating system image version, thereby solving the problem that the new components cannot be used due to the long period of releasing the new ISO image by the system publisher and the lag of the drive program updating, and facilitating the rapid promotion and application of the new components of the server.

[0013] In addition, the application further provides an electronic device, and the effects are the same as above. BRIEF DESCRIPTION OF DRAWINGS

[0014] In order to more clearly illustrate the embodiments of the application, the drawings needed in the embodiments will be briefly introduced as follows. Obviously, the drawings in the following description are only some embodiments of the application, and other drawings can be obtained by those skilled in the art without creative labor on the basis of these drawings.

[0015] Figure 1 A flowchart of a drive program installation method provided for the embodiments of the application;

[0016] Figure 2 A flowchart of an operating system image and drive program installation provided for the embodiments of the application;

[0017] Figure 3 A schematic diagram of a drive program installation device provided for the embodiments of the application. DETAILED DESCRIPTION

[0018] The technical solutions in the embodiments of the application will be described clearly and completely below with reference to the drawings in the embodiments of the application. Obviously, the described embodiments are only some of the embodiments of the application, but not all the embodiments. Based on the embodiments in the application, all other embodiments obtained by those skilled in the art without creative labor are within the protection scope of the application.

[0019] It should be noted that in the description of the present application, the terms "comprising", "including" or any other variant thereof are intended to cover non-exclusive inclusion, so that processes, methods, articles or devices including a series of elements not only include those elements, but also include other elements not explicitly listed, or further include elements inherent to such processes, methods, articles or devices. The terms "first", "second" and the like in the present application are used to distinguish similar objects, not to describe a specific order or sequence.

[0020] In order for those skilled in the art to better understand the present application, the present application will be further described in detail below in conjunction with the accompanying drawings and specific embodiments.

[0021] At present, the updating speed of the driver in the operating system often cannot match the iteration rhythm of the hardware, which usually leads to the following two problems: 1. Lack of driver support in the operating system installation stage, which causes the OS installation to be blocked. For example, a server uses an integrated graphics card A, but due to the lack of the driver of this graphics card in some operating systems, the operating system installation interface cannot be displayed, and the operating system installation cannot be completed. 2. Lack of driver support in the operating system startup and use stage, which causes a certain component under the system to be unable to use. For example, a server uses a network card B, and after installing the operating system, the operating system does not have the driver of the network card B, so that the system does not recognize the network port, and the network setting cannot be performed, and the server cannot access the network. In the case of using some components, the above two problems may also exist at the same time. For example, a server uses a redundant array of independent disks (RAID) card C, and when installing some operating systems, due to the lack of driver support, the RAID hard disk is not recognized in the system installation interface, and the RAID hard disk cannot be selected as the system disk, and the operating system can only be installed on other hard disks (non-RAID hard disks, such as motherboard direct hard disks). Even if the system installation is completed, the driver support of this RAID card is still lacking in the system startup and use stage, so that after the system is started and enters the operating system, the RAID hard disk is still not recognized under the system, and the RAID hard disk cannot be used as a data disk.

[0022] For the above problems, the current common solution is to wait for the operating system publisher to include the driver of the related component into the new version of ISO image and publish it, but since the release cycle of the ISO image is relatively long, it cannot meet the rapid development rhythm of the server components. Therefore, the present application provides a driver installation method, which aims to solve the above problems. It should be noted that the method provided by the present application is applied to servers, and can also be applied to other devices capable of installing operating systems and running various software, depending on the specific implementation.

[0023] Figure 1 A flowchart of a driver installation method provided by an embodiment of the present application is shown in FIG. 1. As shown in the figure, the method comprises the following steps. Figure 1

[0024] S10: Start a target installation environment of an operating system image, and query all uninstalled devices in the server.

[0025] When installing an operating system, the target installation environment of the operating system image needs to be started first. In this embodiment, the specific type of the target installation environment is not limited, for example, it can be an Anaconda installation environment, which is specifically implemented by an Anaconda installer. Anaconda is an open source system installer for Linux systems, which is responsible for core tasks such as disk partitioning, software package selection, network configuration, user account settings, etc. in the operating system installation process. In this embodiment, the specific process of starting the target installation environment is not limited, and is determined according to the specific implementation.

[0026] At the same time, all uninstalled devices in the server are queried. For example, there are generally network cards, RAID cards, graphics cards and other component devices in the server, which are uniformly identified as Peripheral Component Interconnect Express (PCIE) devices in the system. Among these devices, there are already installed devices, and there are also uninstalled devices, which need to be installed with drivers in the process of executing the operating system installation.

[0027] S11: Identify a pre-set storage medium; wherein the storage medium contains the driver files of all devices in the server.

[0028] In order to ensure the integrity of the device drivers, a storage medium is pre-set in this embodiment, which contains the driver files of all devices in the server. Specifically, since it is not possible to determine in advance what version of operating system the user will install, and the device drivers included in these operating systems are different, in order to ensure the complete installation of the driver files, the driver files under each operating system should be considered and added as much as possible when setting the storage medium. In addition, the specific type of the storage medium is not limited in this embodiment, for example, it can be a U disk, a hard disk, etc., and is determined according to the specific implementation.

[0029] S12: Based on the target installation environment, read and load the target driver files of the uninstalled devices in the storage medium.

[0030] ​It is worth mentioning that the reading and loading of the drive file in the storage medium in the embodiment is realized by the target installation environment; for example, when the target installation environment is Anaconda, the target drive file of the un-driven device in the storage medium is read and loaded based on the Anaconda installation environment, so as to install the target drive file of the un-driven device synchronously when the operating system installation is performed. It should be noted that the reading and loading process of the target drive file in the embodiment is not limited, and is determined according to the specific implementation.

[0031] S13: Based on the target installation environment, the installation of the operating system image and the target drive file is performed, and the system is restarted after the installation is completed.

[0032] Finally, after loading the target drive file, based on the target installation environment, the installation of the operating system image and the target drive file is performed, and the system is restarted after the installation is completed. The device driver can be successfully loaded during the startup of the hard disk system, and it is ensured that all components can be normally used after the system is successfully started.

[0033] In the embodiment, the drive files of all devices of the server are stored in the pre-set storage medium in advance, which ensures the integrity of the device driver programs and is the prerequisite for performing the device driver update and installation. At the same time, when the operating system image installation is performed, the target drive file of the un-driven device in the storage medium can be read, loaded and installed based on the target installation environment of the operating system image, without the need to integrate the drive file into the operating system image in advance, and without the dependence on the release of the operating system image version. The problem that the new components cannot be used due to the long period of the system publisher releasing the new ISO image and the lag of the drive program update is solved, which is beneficial to the rapid promotion and application of the new components of the server.

[0034] Figure 2 The flowchart of the operating system image and the drive program installation provided by the embodiment of the application is shown in the above embodiment. In some embodiments, as shown in Figure 2 the target installation environment of the operating system image is started, which includes:

[0035] S101: Mounting the installation startup disk containing the operating system image to the server and starting the firmware.

[0036] S102: Reading the boot program file in the installation startup disk based on the firmware.

[0037] S103: Starting the compressed kernel image and the initialization disk image based on the boot program file.

[0038] S104: Loading the installation image file based on the initialization disk image, and starting the target installation environment through the installation image file.

[0039] In order to start the target installation environment, it is necessary to first prepare an installation startup disk containing an operating system image, such as a U disk startup disk or an optical disk startup disk, in the embodiment, mount the installation startup disk to the server, and start the firmware (Basic Input / Output System, BIOS). Then, the installation startup disk is selected to start in the BIOS, the BIOS reads the Bootstrap file in the installation startup disk; the Bootstrap file starts and loads the OS installation menu, and starts the compressed kernel image (vmlinuz) and the initialization disk image (initrd.img), thereby providing a hardware driver for the OS installation process. After the vmlinuz and initrd.img are started, the initrd.img is mounted and switched to the installation image file (install.img), and finally the Anaconda program integrated in the install.img is started, thereby realizing the start of the target installation environment and providing a basic installation environment for the subsequent installation of the OS and device drivers.

[0040] On the basis of the above embodiment, in some embodiments, the query server for all devices includes:

[0041] S111: Based on the device information query interface, the attribute information of all devices in the server is queried through the device information query command; wherein the attribute information at least includes the kernel driver in use attribute.

[0042] S112: Determine whether the value of each kernel driver in use attribute is empty; if yes, it is confirmed that the corresponding device is an uninstalled device. If not, it is confirmed that the corresponding device is not an uninstalled device.

[0043] In order to query the driven device, the device information query interface of the system is specifically used in the embodiment, and the attribute information of all devices in the server is queried through the device information query command (such as the lspci-vvvv command). It should be noted that the attribute information of the device at least includes the kernel driver in use attribute, which represents the driver name being used by the device; meanwhile, other attribute information such as the manufacturer identifier (Identification, ID), the device ID, etc. can also be included, which is determined according to the specific implementation. Finally, it is determined whether the value of each kernel driver in use attribute is empty; if it is confirmed that the value of the kernel driver in use attribute is empty, it is confirmed that the corresponding device has not been successfully driven, and the device is an uninstalled device. If it is confirmed that the value of the kernel driver in use attribute is not empty, it is confirmed that the corresponding device has been successfully driven, and the device is not an uninstalled device.

[0044] In the embodiment, the base device information query interface realizes the accurate and fast query of the undriven device with the device information query command, so as to facilitate the subsequent reading of the drive file of the corresponding device in the storage medium.

[0045] On the basis of the above embodiment, in some embodiments, the setting process of the storage medium includes:

[0046] S121: generating a virtual optical drive through the management controller.

[0047] S122: storing the drive files of all devices in the server into the virtual optical drive.

[0048] In order to facilitate the setting and management of the storage medium, in the embodiment, the physical storage medium is not used when setting the storage medium, but is realized based on the virtual optical drive. Specifically, based on the Baseboard Management Controller (BMC), a Small Computer System Interface (SCSI) Compact Disc Read-Only Memory (CD-ROM) block device is simulated at the hardware level, which can be identified as a / dev / sr0 block device in the system, that is, a virtual optical drive. The third-party device driver is stored in the device, and is subsequently passed to the Anaconda installation environment. It should be noted that the process can be fixed in the BMC firmware and loaded with the server startup, without the need for additional user operations, realizing the rapid deployment and management convenience of the storage medium.

[0049] Table 1: Index file table

[0050]

[0051] As shown in Table 1, in order to better manage each drive file in the virtual optical drive, after storing the drive files of all devices in the server into the virtual optical drive, the attribute information of each drive file can be further obtained. It should be noted that the attribute information at least includes the manufacturer identifier, the device identifier, the drive name and the storage path in the virtual optical drive. It can be understood that the storage path is the storage path under the virtual optical drive. Finally, an index file is generated according to the attribute information of each drive file, and the index file is stored in the virtual optical drive. In this way, when reading the target drive file subsequently, the position of the corresponding drive file can be quickly located according to the index file, and the reading efficiency is higher.

[0052] On the basis of the above embodiment, in some embodiments, reading the target drive file of the undriven device in the storage medium includes:

[0053] S131: Obtain the vendor identifier and the device identifier of the un-driven device.

[0054] S132: Match in the index file according to the vendor identifier and the device identifier of the un-driven device to determine the target storage path of the drive file corresponding to the un-driven device.

[0055] S133: Read the target drive file based on the target storage path.

[0056] Specifically, in the process of reading the target drive file, first, the vendor ID and the device ID of the un-driven device are obtained, then the index file is matched according to the vendor ID and the device ID of the un-driven device to determine the target storage path of the drive file corresponding to the un-driven device. Finally, the target drive file is read based on the target storage path. In this way, through the index file matching, the accurate and fast reading of the target drive file is realized.

[0057] On the basis of the above embodiment, in some embodiments, before obtaining the vendor identifier and the device identifier of the un-driven device, it further includes:

[0058] S141: Obtain the drive file built-in in the operating system image.

[0059] S142: Determine whether the drive file corresponding to each un-driven device exists in the drive file built-in in the operating system image; if yes, go to step S143; if no, go to the step of obtaining the vendor identifier and the device identifier of the un-driven device.

[0060] S143: Exclude the un-driven device corresponding from all un-driven devices.

[0061] When the OS installation interface appears, the vmlinuz and initrd.img in the installation startup disk have been loaded into the memory, a Linux kernel has been started in the memory, and the component drive built-in in the OS image has also been loaded and completed, ready for installation. It should be noted that the component drive built-in in the OS image here is the device drive that the operating system comes with when it is released, which will automatically install the built-in device drive when the corresponding OS image is installed.

[0062] Therefore, in order to prevent reading the existing driver file, improve the installation efficiency of the device driver, before reading the target driver file from the storage medium, the driver file built in the OS image needs to be acquired, and it is determined whether the driver file corresponding to each undriven device exists in the driver file built in the OS image. If it is confirmed that the driver file corresponding to the undriven device exists in the driver file built in the OS image, it is indicated that the corresponding driver file of the device does not need to be read from the storage medium additionally, and the device can be directly excluded from all undriven devices, so as to reduce the number of driver file reading under the premise of ensuring complete driving of the device. If it is confirmed that the driver file corresponding to the undriven device does not exist in the driver file built in the OS image, the step of acquiring the vendor identifier and the device identifier of the undriven device is entered, and the target driver file of the undriven device in the storage medium is continued to be read. In this way, by considering the existing built-in driver file of the OS image, the number of driver files read from the storage medium can be effectively reduced, and the installation efficiency of the driver is improved.

[0063] On the basis of the above embodiment, in some embodiments, loading the target driver file of the undriven device in the storage medium comprises:

[0064] S151: It is determined whether the driver file built in the operating system image is loaded. If it is confirmed that the driver file built in the operating system image is not loaded, the step of determining whether the driver file built in the operating system image is loaded is returned after a first preset time. If it is confirmed that the driver file built in the operating system image is loaded, the target driver file is loaded through a module insertion command.

[0065] Specifically, when the target driver file of the undriven device in the storage medium is loaded, it is first determined whether the driver file built in the OS image is loaded. If it is confirmed that the driver file built in the OS image is not loaded, the built-in driver file is waited to be loaded, and the step of determining whether the driver file built in the OS image is loaded is returned after a first preset time. In this embodiment, the size of the first preset time is not limited, and is determined according to the specific implementation. If it is confirmed that the driver file built in the OS image is loaded, the target driver file is loaded through a module insertion command (insmod driver_path). In this way, after it is confirmed that the built-in driver file of the OS is loaded, the third-party device driver file is loaded, and it is ensured that all devices are successfully driven in the OS installation process.

[0066] On the basis of the above embodiment, in some embodiments, based on the target installation environment, the installation of the operating system image and the target driver file is performed, comprising:

[0067] S161: The installation of the operating system image and the driver file built in the operating system image is performed.

[0068] S162: judging whether the installation of the driver file built in the operating system image is completed; if not, returning to the step of judging whether the installation of the driver file built in the operating system image is completed after a second preset time; if yes, entering step S163.

[0069] S163: copying the target driver file to the system hard disk.

[0070] S164: creating the dependency relationship between the target driver file and the remaining driver files by a dependency module management command.

[0071] In order to realize the installation of the OS and the driver program, in the embodiment, the installation of the OS image and the driver file built in the OS image is performed under the Anaconda installation environment. It is judged whether the installation of the driver file built in the OS image is completed; if it is confirmed that the installation of the driver file built in the OS image is not completed, the step of judging whether the installation of the driver file built in the OS image is completed is returned to after a second preset time. In the embodiment, the size of the second preset time is not limited and is determined according to the specific implementation. If it is confirmed that the installation of the driver file built in the OS image is completed, the target driver file is copied to the system hard disk, and the dependency relationship between the target driver file and the remaining driver files is created by a dependency module management command (depmod). In this way, after the OS is installed, the system is restarted, and in the process of starting the hard disk system, the third-party driver can be successfully loaded, and it is ensured that all devices can be normally used after the system is successfully started.

[0072] In addition, after the installation of the server OS image and the device driver is completed, detecting whether the installation of the driver is successful is an important step to ensure the stable operation of the system, which can be completed by the device manager and the system log. Specifically, the device manager of the server is opened, each device category is expanded, and the device state is checked. If there is an abnormal flag for the device, it is indicated that the driver may not be correctly installed or there is other problem for the device. In addition, the event viewer can be used to find the events related to the installation of the driver, especially the events with the “warning” or “error” level, and the detailed information of the events is viewed to confirm whether there is a record of the failed installation of the driver. In this way, it is ensured that the installation of the driver is successful, and the timely processing is ensured when the installation fails.

[0073] Through the description of the above embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be realized by means of software and the necessary general hardware platform, of course, it can also be realized by hardware, but in many cases, the former is a better embodiment.

[0074] Figure 3 A schematic diagram of a driver program installation device provided by the embodiment of the application is shown. The device is applied to a server; as shown in the figure, the device comprises: Figure 3 as shown in the figure, the device comprises:

[0075] The starting module 10 is configured to start a target installation environment of an operating system image and query uninstalled devices in all devices of the server.

[0076] The identifying module 11 is configured to identify a pre-set storage medium, wherein the storage medium contains driver files of all devices in the server.

[0077] The loading module 12 is configured to read and load target driver files of uninstalled devices in the storage medium based on the target installation environment.

[0078] The installing module 13 is configured to install the operating system image and the target driver files based on the target installation environment and restart the system after the installation is completed.

[0079] In some embodiments, the starting module 10 comprises:

[0080] The mounting module is configured to mount an installation boot disk containing the operating system image to the server and start firmware.

[0081] The reading module is configured to read a boot program file in the installation boot disk based on the firmware.

[0082] The booting module is configured to start a compressed kernel image and an initialization disk image based on the boot program file.

[0083] The environment starting module is configured to load an installation image file based on the initialization disk image and start the target installation environment through the installation image file.

[0084] In some embodiments, the starting module 10 comprises:

[0085] The querying module is configured to query attribute information of all devices in the server through a device information query command based on a device information query interface, wherein the attribute information at least includes kernel driver usage attributes.

[0086] The first judging module is configured to judge whether the values of the kernel driver usage attributes are empty, and if the values of the kernel driver usage attributes are confirmed to be empty, the corresponding devices are confirmed to be uninstalled devices.

[0087] In some embodiments, the setting process of the storage medium comprises: generating a virtual CD-ROM through a management controller; and storing driver files of all devices in the server to the virtual CD-ROM.

[0088] In some embodiments, after the driver files of all devices in the server are stored to the virtual CD-ROM, the process further comprises: obtaining attribute information of each driver file, wherein the attribute information at least includes a vendor identifier, a device identifier, a driver name and a storage path in the virtual CD-ROM; generating an index file according to the attribute information of each driver file and storing the index file to the virtual CD-ROM.

[0089] In some embodiments, the loading module 12 comprises:

[0090] an identifier obtaining module, configured to obtain the vendor identifier and the device identifier of the un-driven device;

[0091] a matching module, configured to match the vendor identifier and the device identifier of the un-driven device in the index file to determine the target storage path of the drive file corresponding to the un-driven device;

[0092] a drive file reading module, configured to read the target drive file based on the target storage path.

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

[0094] an in-built drive file obtaining module, configured to obtain the drive file in-built in the operating system image;

[0095] a second judging module, configured to judge whether the drive file corresponding to each un-driven device exists in the drive file in-built in the operating system image; if yes, the corresponding un-driven device is excluded from all un-driven devices.

[0096] In some embodiments, the loading module 12 comprises:

[0097] a third judging module, configured to judge whether the drive file in-built in the operating system image is loaded completely; if it is confirmed that the drive file in-built in the operating system image is not loaded completely, the step of judging whether the drive file in-built in the operating system image is loaded completely is returned to after a first preset time; if it is confirmed that the drive file in-built in the operating system image is loaded completely, the target drive file is loaded through the module insertion command.

[0098] In some embodiments, the installation module 13 comprises:

[0099] a first installation sub-module, configured to execute the installation of the operating system image and the drive file in-built therein;

[0100] a fourth judging module, configured to judge whether the drive file in-built in the operating system image is installed completely; if it is confirmed that the drive file in-built in the operating system image is not installed completely, the step of judging whether the drive file in-built in the operating system image is installed completely is returned to after a second preset time; if it is confirmed that the drive file in-built in the operating system image is installed completely, the copying module is triggered;

[0101] a copying module, configured to copy the target drive file to the system hard disk;

[0102] a dependency creating module, configured to create the dependency relationship between the target drive file and the remaining drive files through the dependency module management command.

[0103] The features of the embodiments of the driving program installation device can be referred to the related descriptions of the embodiments of the driving program installation method, which will not be repeated here.

[0104] The embodiments of the present application also provide an electronic device, comprising a memory and a processor, 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 driving program installation method embodiments.

[0105] The embodiments of the present application also provide a computer readable storage medium, which stores a computer program, wherein the computer program is configured to execute the steps in any of the above driving program installation method embodiments when running.

[0106] In an example embodiment, the above computer readable storage medium can include but is not limited to: a U disk, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk, and various media that can store computer programs.

[0107] The embodiments of the present application also provide a computer program product, which comprises a computer program, and the computer program is configured to execute the steps in any of the above driving program installation method embodiments when running by a processor.

[0108] The embodiments of the present application also provide another computer program product, which comprises a non-volatile computer readable storage medium, and the non-volatile computer readable storage medium stores a computer program, and the computer program is configured to execute the steps in any of the above driving program installation method embodiments when running by a processor.

[0109] The skilled person can further realize that the units and algorithm steps of the examples described in combination with the embodiments disclosed herein can be realized in electronic hardware, computer software or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the components and steps of the examples have been described in general terms in the above description. Whether the functions are realized in hardware or software depends on the specific application and design constraints of the technical solution. The skilled person can use different methods to realize the described functions for each specific application, but such implementation should not be considered beyond the scope of the present application.

[0110] The above describes in detail the driving program installation method and the electronic device provided by the present application. The principles and implementation manners of the present application are described by using specific examples in this paper, and the above description of the examples is only applicable to help understand the method of the present application and the core idea thereof. It should be pointed out that, for those skilled in the art, some improvements and modifications can be made to the present application without departing from the principles of the present application, and these improvements and modifications also fall within the protection scope of the present application.

Claims

1. A driver installation method characterized by comprising: The application is applied to a server, and the method comprises: starting a target installation environment of an operating system image, and querying uninstalled devices in all devices of the server; identifying a pre-set storage medium, wherein the storage medium contains driver files of all devices in the server; based on the target installation environment, reading and loading target driver files of the uninstalled devices in the storage medium; based on the target installation environment, executing installation of the operating system image and the target driver files, and restarting the system after the installation is completed.

2. The driver installation method according to claim 1, characterized by, starting a target installation environment of an operating system image comprises: mounting an installation boot disk containing the operating system image to the server, and starting firmware; based on the firmware, reading a boot program file in the installation boot disk; based on the boot program file, starting a compressed kernel image and an initialization disk image; based on the initialization disk image, loading an installation image file, and starting the target installation environment through the installation image file.

3. The driver installation method according to claim 1, wherein querying uninstalled devices in all devices of the server comprises: based on a device information query interface, querying attribute information of all devices in the server through a device information query command, wherein the attribute information at least includes kernel driver usage attributes; judging whether the values of the kernel driver usage attributes are empty or not; if it is confirmed that the values of the kernel driver usage attributes are empty, confirming that the corresponding devices are the uninstalled devices.

4. The driver installation method according to Claim 1, characterized by the setting process of the storage medium comprises: generating a virtual CD-ROM through a management controller; storing driver files of all devices in the server to the virtual CD-ROM.

5. The driver installation method according to claim 4, wherein after storing the driver files of all devices in the server to the virtual CD-ROM, further comprising: obtaining attribute information of each driver file, wherein the attribute information at least includes a vendor identifier, a device identifier, a driver name and a storage path in the virtual CD-ROM; generating an index file according to the attribute information of each driver file, and storing the index file to the virtual CD-ROM.

6. The driver installation method according to Claim 5, characterized by reading the target driver files of the uninstalled devices in the storage medium comprises: obtaining a vendor identifier and a device identifier of the uninstalled device; matching the index file according to the vendor identifier and the device identifier of the uninstalled device to determine a target storage path of the driver file corresponding to the uninstalled device; based on the target storage path, reading the target driver file.

7. The driver installation method according to claim 6, wherein before obtaining the vendor identifier and the device identifier of the uninstalled device, further comprising: obtaining driver files built-in the operating system image; judging whether there are driver files corresponding to each of the uninstalled devices in the driver files built-in the operating system image or not; if yes, excluding the uninstalled devices corresponding to the uninstalled devices from all the uninstalled devices.

8. The driver installation method according to Claim 1, characterized by loading the target driver files of the uninstalled devices in the storage medium comprises: judging whether the driver files built-in the operating system image are loaded completely or not; If it is confirmed that the driver file built in the operating system image is not loaded completely, the step of judging whether the driver file built in the operating system image is loaded completely is returned to after a first preset time; If it is confirmed that the driver file built in the operating system image is loaded completely, the target driver file is loaded through a module insertion command.

9. The driver installation method according to any one of claims 1 to 8, characterized by, Based on the target installation environment, installation of the operating system image and the target driver file is executed, including: Installation of the operating system image and the driver file built in the operating system image is executed; It is judged whether the driver file built in the operating system image is installed completely; If it is confirmed that the driver file built in the operating system image is not installed completely, the step of judging whether the driver file built in the operating system image is installed completely is returned to after a second preset time; If it is confirmed that the driver file built in the operating system image is installed completely, the target driver file is copied to a system hard disk; A dependency relationship between the target driver file and the rest of the driver files is created through a dependency module management command.

10. An electronic device, comprising: It includes: A memory for storing a computer program; A processor for executing the computer program to realize the steps of the driver program installation method according to any one of claims 1 to 9.

Citation Information

Cited By

  • Mirror image and peripheral drive decoupling method based on Linux operating system

    CN122195520A