CN114675893B - Drive management method and device and computer equipment - Google Patents
Drive management method and device and computer equipment Download PDFInfo
- Publication number
- CN114675893B CN114675893B CN202210413052.6A CN202210413052A CN114675893B CN 114675893 B CN114675893 B CN 114675893B CN 202210413052 A CN202210413052 A CN 202210413052A CN 114675893 B CN114675893 B CN 114675893B
- Authority
- CN
- China
- Prior art keywords
- drive
- driving
- host
- information
- operating system
- 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.)
- Active
Links
- 238000007726 management method Methods 0.000 title claims description 16
- 238000000034 method Methods 0.000 claims abstract description 76
- 238000009434 installation Methods 0.000 claims abstract description 44
- 238000004891 communication Methods 0.000 claims description 24
- 230000004044 response Effects 0.000 claims description 16
- 238000004590 computer program Methods 0.000 claims description 7
- 238000012545 processing Methods 0.000 claims description 4
- 238000000605 extraction Methods 0.000 claims description 3
- 238000012360 testing method Methods 0.000 description 22
- 238000010586 diagram Methods 0.000 description 9
- 230000008569 process Effects 0.000 description 9
- 238000001514 detection method Methods 0.000 description 5
- 230000009471 action Effects 0.000 description 3
- 230000001960 triggered effect Effects 0.000 description 3
- 230000006870 function Effects 0.000 description 2
- 238000012546 transfer Methods 0.000 description 2
- 230000005856 abnormality Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 239000000284 extract Substances 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012795 verification Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/4401—Bootstrapping
- G06F9/4411—Configuring for operating with peripheral devices; Loading of device drivers
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Stored Programmes (AREA)
Abstract
The embodiment of the invention relates to a method and a device for managing a drive and computer equipment, wherein the method comprises the following steps: acquiring a first control instruction, wherein the first control instruction comprises identification information of a first driver in an operating system of a first host; extracting driving information of a first driver corresponding to the first driving identification information; comparing the driving information of the first drive with each driving information of a preset driving library; when the driving information of the first driver is confirmed to be matched with any one of the driving information in the preset driving library, a second control instruction is sent to an operating system of the second host, wherein the second control instruction is used for indicating the operating system in the second host to finish the installation of the first driver, the operating system of the first host is an issued mirror system, and the operating system in the second host is a mirror system to be issued. By the mode, the driving is automatically detected, and is automatically installed through the control instruction, so that the labor cost is saved, and the efficiency is improved.
Description
Technical Field
The embodiment of the invention relates to the technical field of computers, in particular to a method and a device for managing a drive and computer equipment.
Background
The Internet enterprise can provide customized mirror image service for clients, based on client requirements, a standard Esxi operating system (VMware pushes out a virtual machine operating system), a driving package required by the clients is packed, a client mirror image file in an ISO format (a virtual mirror image file format of the operating system, the operating system can be released in the ISO format) is generated, then upgrade test of the released low-version client mirror image system to the currently manufactured high-version client mirror image system is required to be completed, and test items required by the VMware (virtual machine software provider) are executed, and can be submitted to a VMware official network for verification and release.
The upgrade test of the low-version client mirror image system to the high-version client mirror image system is an important step, and when the low-version client mirror image system contains a special driver marked by a VMware official network and the high-version client mirror image system does not contain the special driver, the upgrade test reports errors to prompt the lack of dependence.
When an error occurs, the driver needs to repackage to generate the client image file, and all the upgrading steps and test items required by the VMware need to be manually carried out again, so that repeated work is increased, and time is wasted.
Disclosure of Invention
The application provides a method and a device for managing a drive and computer equipment, so as to solve all or part of problems in the prior art.
In a first aspect, the present application provides a method for managing a driver, where the method is executed by an operating system in a first host, and includes:
acquiring a first control instruction, wherein the first control instruction comprises identification information of a first driver of an operating system in a first host;
extracting driving information of a first driver corresponding to the first driving identification information;
comparing the driving information of the first drive with each driving information of a preset driving library;
when the driving information of the first driver is confirmed to be matched with any one of the driving information in the preset driving library, a second control instruction is sent to an operating system of the second host, wherein the second control instruction is used for indicating the operating system in the second host to finish the installation of the first driver, the operating system of the first host is an issued mirror image system, the operating system in the second host is a mirror image system to be issued, and the first driver is any one of the operating systems of the first host.
In a second aspect, the present application provides a method for managing a driver, the method being performed by a second operating system of a second host, including:
receiving a control instruction sent by an operating system of a first host, wherein the control instruction is used for indicating that a preset driver is installed in the operating system in a second host;
searching driving information corresponding to a preset driving in a pre-built database according to the control instruction;
and when the driving information is stored in the database, finishing the installation of the preset driving according to the driving information.
In a third aspect, the present application provides a management apparatus for driving, the apparatus comprising:
the acquisition module is used for acquiring a first control instruction, wherein the first control instruction comprises identification information of a first driver in a first host operating system;
the extraction module is used for extracting the driving information of the first drive corresponding to the first driving identification information;
the comparison module is used for comparing the driving information of the first drive with each driving information of a preset driving library;
the processing module is used for sending a second control instruction to the operating system of the second host when the driving information of the first drive is confirmed to be matched with any one of the driving information in the preset driving library, wherein the second control instruction is used for indicating the operating system in the second host to complete the installation of the first drive, the operating system of the first host is a published mirror image system, the operating system in the second host is a mirror image system to be published, and the first drive is any one of the operating systems of the first host.
In a fourth aspect, the present application provides a management apparatus for driving, the apparatus comprising:
the receiving module is used for receiving a control instruction sent by the operating system of the first host, wherein the control instruction is used for indicating the installation of a preset driver in the operating system in the second host;
the searching module is used for searching driving information corresponding to the preset driving in the pre-constructed database according to the control instruction;
and the installation module is used for completing the installation of the preset drive according to the drive information when the drive information is stored in the database.
In a fifth aspect, a computer device is provided, including a processor, a communication interface, a memory, and a communication bus, where the processor, the communication interface, and the memory perform communication with each other through the communication bus;
a memory for storing a computer program;
when the computer device is a first host, the processor is configured to perform the steps of the method for managing a drive of any of the embodiments of the first aspect;
or,
when the computer device is a second host, the processor is configured to perform the steps of the method for managing a drive of any of the embodiments of the second aspect.
A processor, configured to implement the steps of the method for managing a drive according to any one of the embodiments of the first aspect or the second aspect when executing a program stored in a memory.
In a sixth aspect, there is provided a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the method of managing a drive as in any of the embodiments of the first aspect, or implements the steps of the method of managing a drive as in any of the embodiments of the second aspect.
Compared with the prior art, the technical scheme provided by the embodiment of the application has the following advantages:
according to the method provided by the embodiment of the application, the first host system acquires the first control instruction, and the first control instruction comprises the identification information of the first driver in the first host operating system; extracting driving information of a first driver corresponding to the first driving identification information; comparing the driving information of the first drive with each driving information of a preset driving library; and when the driving information of the first driving is confirmed to be matched with any one of the driving information in the preset driving library, sending a second control instruction to the operating system of the second host. The second host system searches the preset driving information corresponding to the preset driving in the pre-constructed database according to the control instruction; and when the driving information is stored in the database, the installation of the preset driving is completed according to the driving information. By means of the method, the first drive is compared with the preset drive library, and when the first drive is confirmed to be matched with the drive of the preset drive library, the second host system automatically installs the first drive, so that the automatic detection and the installation of the drive process are realized, the labor cost is saved, and the efficiency is improved.
Drawings
FIG. 1 is a schematic flow chart of a method for managing drivers according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of a management technology architecture of a driver according to the present invention;
FIG. 3 is a schematic flow chart of a method for providing a special drive library according to the present invention;
FIG. 4 is a schematic flow chart of a method for driving matching according to the present invention;
fig. 5 is a schematic diagram of a network cluster according to the present invention;
FIG. 6 is a schematic flow chart of another method for managing drivers according to an embodiment of the present invention;
FIG. 7 is a schematic flow chart of another method for managing drivers according to an embodiment of the present invention;
FIG. 8 is a schematic diagram of an upgrade test flow provided by the present invention;
FIG. 9 is a schematic diagram of a driving management device according to an embodiment of the present invention;
FIG. 10 is a schematic diagram of another driving management device according to an embodiment of the present invention;
fig. 11 is a schematic structural diagram of a computer device according to an embodiment of the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments of the present 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, are intended to be within the scope of the invention.
For the purpose of facilitating an understanding of the embodiments of the present invention, reference will now be made to the following description of specific embodiments, taken in conjunction with the accompanying drawings, which are not intended to limit the embodiments of the invention.
In view of the technical problems mentioned in the background art, the embodiment of the present application provides a method for managing a driver, specifically referring to fig. 1, fig. 1 is a schematic flow chart of a method for managing a driver according to an embodiment of the present invention.
Before describing the steps of the method, the technical architecture of the method is first described, as shown in fig. 2. Fig. 2 is a schematic diagram of a technical architecture of the embodiment of the method, in which VMware issues a request for an image system, that is, completes an upgrade test process from a low-version image system issued to a high-version image system to be issued, and the image system and a driver are in a many-to-many relationship, and the same driver can be installed on a plurality of image systems, and one image system can also be installed with a plurality of drivers. During upgrade testing, the driver of the high-version image system must be guaranteed to include a special driver existing in the published low-version image system, based on this, an upgrade testing environment is built, as shown in fig. 2, an upgrade testing environment is deployed VMware vCenterServer on a control machine, wherein VMware vCenterServer is a management platform of a VMware virtual machine environment, upgrade testing can be performed based on VMware vCenterServer, VMware vCenterServer is connected with an a host and a B host through a switch to realize network connection, the a host installs the published low-version image system, and the B host installs the high-version image system to be published.
In an alternative example, the a host and the B host need to be added into the cluster in advance to realize network communication between the a host and the B host, and when the upgrade test is performed, an image file to be issued is imported into the management module vSphere Lifecycle Manager of VMware vCenterServer, and a reference is created, where the reference is the image file to be upgraded, the a host is associated with the reference created by using the high version image file as a support, and when a special driver required by VMware exists in the image system of the a host, the image system of the a host sends a control instruction to the B host system through communication established by the cluster, and the B host system automatically completes installation of the special driver according to the control instruction.
The specific upgrade testing process includes the following method steps, which are executed by the operating system of the first host machine, including:
Specifically, the first control instruction includes identification information of a first driver in an operating system in the first host.
In an alternative example, for example, in the upgrade test environment shown in fig. 2, the upgrade test is triggered by the controller VMware vCenterServer, and when the upgrade test is triggered, the VMware vCenterServer sends a first control instruction to the operating system of the first host, hereinafter referred to as the first host system, where a drive detection program, for example, a drive detector, may be installed, and the drive detector obtains the first control instruction, where the first control instruction includes drive identification information of the first host system that needs to be detected.
Specifically, in an alternative example, the first drive identifier information includes drive information to be detected, and the drive detector extracts the drive information corresponding to the first drive identifier so as to compare with the drive in the preset drive library.
Specifically, the driver in the preset driver library is a special driver required by the VMware functional network, in an alternative example, because the special driver to be installed is a special driver required by the VMware functional network, and a mirror system may include a plurality of special drivers, each of which needs to be compared with the special driver of the VMware functional network, when there are more drivers, the comparison of the driver information needs to be performed, and when there are more drivers, the frequent operation is considered, and when the update test is unavailable in the case of the network, the special driver required by the VMware functional network can be stored and a special driver library, that is, the preset driver library, is set in a storage module built in the driver detector, for example, a database, and the stored fields include a driver name, a driver version number, a driver description, a driver provider, and the like.
Further, in an implementation example, the update manner of the special driver library may include a manner shown in fig. 3, fig. 3 shows a flowchart of building and updating the special driver library, a master database is deployed on an own server, the master database periodically issues a packet from a special driver issuing website of the VMware service network, obtains and stores an installation packet of the special driver, the special driver library on the driver detector periodically obtains the special driver from the master database through a built representational state transfer service (Representational State Transfer, abbreviated as RESTful) service, and performs online update of the driving information, a release period based on the special driver is longer, and the update periods of the master database and the special driver library may be selected to be a natural month, which may of course completely set a period according to actual requirements. The RESTful service selects, inserts, updates and deletes four resource packages, and each resource package is mapped to the database to operate the table therein, which is mainly used in the application. It should be noted that, the RESTful service is one way to update the special driver library online, and other ways that can implement this function may be used, which is not limited herein.
Further, when network abnormality occurs and online updating is unavailable, the special driving library can be updated in an offline updating mode, and the driving information of the parent database is queried through actively executing a database command, so that the special driving library can be ensured to obtain the latest special driving information all the time.
At the time of the upgrade test, the drive information of the first drive detected by the drive detector is compared with each drive information in the special drive library.
And 140, when the driving information of the first driving is confirmed to be matched with any one of the driving information in the preset driving library, sending a second control instruction to the operating system of the second host.
Specifically, the second control instruction is configured to instruct the operating system in the second host to complete installation of the first driver, where the operating system of the first host is a low-version mirror image system that has been issued, the operating system in the second host is a high-version mirror image system to be issued, and the first driver is any one of the operating systems of the first host.
In an alternative example, when the drive detector detects that the drive of the first host system includes a special drive of the special drive library, a second control instruction is sent to an operating system of the second host, hereinafter referred to as a second host system, that is, a computer on which the high-version mirror system to be issued is installed, where the second control instruction is used to indicate that the second host system needs to install the special drive.
Optionally, determining whether the driving information of the first driving matches any driving information in the preset driving library specifically includes the method steps as shown in fig. 4:
in step 410, the first drive name in the drive information of the first drive is compared with the second drive name of the second drive information in the preset drive library.
Specifically, in an alternative example, the unique driver is determined by the driver name and the driver version, so that the driver detector obtains the driver information of the first driver from the driver of the first host, obtains the driver name and the driver version according to the driver information, compares the driver name of the first driver with the driver name of each driver in the special driver library, and compares the driver version of the first driver with the driver version of each driver in the special driver library. It should be noted that, the step 410 and the step 420 do not have a relation of a front-to-back sequence, and a specific comparison sequence may be determined according to practical situations, for example, the driving information may be compared first or the driving version may be compared first, or the driving information and the driving version may be compared simultaneously, which is not limited herein.
In step 430, when the first drive name is consistent with the second drive name and the first drive version is consistent with the second drive version, it is determined that the drive information of the first drive matches the second drive information in the preset drive library, and the second drive information is any one of the drive information in the preset drive library.
Specifically, in an alternative example, the second drive information is any one of the drive information in the special drive library, and when the drive name of the first drive is consistent with the drive name of one of the drives in the special drive library and the drive version of the first drive is consistent with the drive version of the drive in the special drive library, it is confirmed that the first drive is the same as the second drive in the special drive library, that is, the first drive exists in the special drive library.
Optionally, before confirming that the driving information of the first drive matches any one of the driving information in the preset driving library and sending the second control instruction to the operating system of the second host, the method further includes:
and establishing a communication connection channel between the first host and the second host so that an operating system in the first host sends a second control instruction to the operating system of the second host through the communication connection channel.
Specifically, in an alternative example, for example, in the architecture shown in fig. 2, an a host (first host) and a B host (second host) establish a cluster through the same switch to implement network connection, after the a host and the B host establish the cluster, the a host and the B host may communicate with each other, for example, may use a ping command to access each other, and further may perform operations of sending a control instruction between two host systems, and obtaining status information from each other, as shown in fig. 5. When a drive detector installed in the first host system detects that the first drive matches any one of the drives in the special drive library, a control instruction is sent to the second host through a network connection established by the cluster.
Optionally, after confirming that the driving information of the first drive matches any one of the driving information in the preset driving library and sending the second control instruction to the operating system of the second host, the method further includes a step of specifically, as shown in fig. 6, in which, when the second host receives the second control instruction, the second host system completes the corresponding operation, the method further includes a step of waiting for feedback information of the second host system to perform the next operation according to the feedback information, and the method includes:
Specifically, in an alternative example, after the second host system completes the corresponding operation according to the second control instruction, the first host system obtains, through a network connection established with the second host system, response information fed back by the second host, where the response information is used to indicate whether the installation of the first drive is successful.
And 620, when the response information is that the first drive is successfully installed, acquiring second drive information so as to send a third control instruction to an operating system in the second host when the second drive information is determined to be in a preset drive library, wherein the third control instruction is used for indicating the operating system of the second host to complete the installation of the second drive.
Specifically, the second driver is any driver except the first driver in the operating system of the first host.
In an alternative example, the first host system may include a plurality of special drivers, when the second host system completes the installation of the first driver, the system may be restarted automatically, the first host system monitors information of the second host system through the network connection channel, and when the second host system is monitored to restart successfully, the driver detector of the first host system continues to execute the detection task, so that the second host system performs the installation of other special drivers until all special drivers of the first host system complete, and the detection task is ended when the installation of the second host system is completed.
After receiving the control instruction for installing the special driver, the second host system also needs to complete the installation of the special driver, so the method further provides the method steps shown in fig. 7, fig. 7 shows the method steps performed after the second host system receives the control instruction for installing the special driver, and the method steps include:
Specifically, the control instruction is used for indicating that the preset driver is installed in the operating system in the second host.
In an alternative example, the drive detector of the first host system sends a control instruction to the second host when detecting that the first host system includes a special drive in the special drive library, where the control instruction includes drive information of the special drive that needs to be installed, and the drive information includes a drive name and a drive version. The second host system receives the control instruction to install the special drive according to the control instruction.
Specifically, in an alternative example, for example, the installation packages of all the drives in the special drive library may be stored in the local storage of the second host system, and when the second host system receives an instruction that needs to install the special drive, according to the drive information in the control instruction, specifically, the drive name and the drive version, the installation package of the special drive to be installed, that is, the preset drive, is searched from the local storage. Of course, all the installation packages of the special drives may be stored in other storage media, and the second host system may download or otherwise obtain the installation packages of the special drives through a network.
And step 730, when the drive information is determined to be stored in the database, the installation of the preset drive is completed according to the drive information.
Specifically, in an alternative example, when the second host system searches for an installation package of a special drive, the special drive is automatically installed, and the system is automatically restarted after the installation is completed.
According to the management method of the drive provided by the embodiment of the invention, the first host acquires the first control instruction, wherein the first control instruction comprises the identification information of the first drive in the operating system of the first host; extracting driving information of a first driver corresponding to the first driving identification information; comparing the driving information of the first drive with each driving information of a preset driving library; and when the driving information of the first driving is confirmed to be matched with any one of the driving information in the preset driving library, sending a second control instruction to the operating system of the second host. The second host system searches the preset driving information corresponding to the preset driving in the pre-constructed database according to the control instruction; and when the driving information is stored in the database, the installation of the preset driving is completed according to the driving information. By means of the method, the first drive is compared with the preset drive library, and when the first drive is confirmed to be matched with the drive of the preset drive library, the second host system automatically installs the first drive, so that the automatic detection and the installation of the drive process are realized, the labor cost is saved, and the efficiency is improved.
In an alternative example, to more clearly illustrate the upgrade testing process of the present invention, the present application further provides a flow chart of upgrade testing, as shown in fig. 8, where the drive detector detects the drive information of the low-version image system and compares with the special drive library, when none of the drives in the low-version image system is in the special drive library, the next update test is continuously performed, when there is a drive in the low-version image system in the special drive library, the high-version image system is triggered to install the special drive, the high-version image system is automatically restarted after the special drive is completed, and the upgrade testing is continuously performed until the drive detector completes all the drives of the low-version image system, and the high-version image system is installed to complete all the special drives contained in the low-version image system.
In the foregoing, for embodiments of the method for managing a driver provided in the present application, other embodiments illustrating management of a driver provided in the present application are described below, with particular reference to the following.
Fig. 9 is a schematic diagram of a device for managing a driver according to an embodiment of the present invention, where the device includes: the device comprises an acquisition module 901, an extraction module 902, a comparison module 903 and a processing module 904.
An obtaining module 901, configured to obtain a first control instruction, where the first control instruction includes identification information of a first driver in an operating system of a first host;
an extracting module 902, configured to extract driving information of a first driver corresponding to the first driving identification information;
a comparison module 903, configured to compare the driving information of the first drive with each driving information of a preset driving library;
the processing module 904 is configured to send a second control instruction to an operating system of the second host when it is determined that the driving information of the first drive matches any one of the preset driving libraries, where the second control instruction is used to instruct the operating system in the second host to complete installation of the first drive, the operating system of the first host is a published mirror system, the operating system of the second host is a mirror system to be published, and the first drive is any one of the operating systems of the first host.
Optionally, a determination module 905 is also included.
The comparison module 903 is specifically configured to compare a first drive name in the drive information of the first drive with a second drive name of the second drive information in the preset drive library; comparing a first driving version in the driving information of the first driving with a second driving version in the second driving information in a preset driving library;
the determining module 905 is configured to determine that the driving information of the first drive matches the second driving information in the preset driving library when the first driving name is consistent with the second driving name and the first driving version is consistent with the second driving version, where the second driving information is any driving information in the preset driving library.
Optionally, a setup module 906 is also included.
The establishing module 906 is configured to establish a communication connection channel between the first host and the second host, so that the operating system in the first host sends the second control instruction to the operating system of the second host through the communication connection channel.
Optionally, a receiving module 907 is also included.
A receiving module 907, configured to receive response information fed back by the operating system of the second host;
the obtaining module 901 is further configured to obtain, when the response information is that the first driver is installed successfully, the second driver information, so that when it is determined that the second driver information is in the preset driver library, a third control instruction is sent to an operating system in the second host, where the third control instruction is used to instruct the operating system of the second host to complete installation of the second driver, and the second driver is any one driver in the operating system of the first host except the first driver.
Fig. 10 is a schematic diagram of a device for managing a driver according to an embodiment of the present invention, where the device includes: a receiving module 1001, a searching module 1002, and an installing module 1003.
The receiving module 1001 is configured to receive a control instruction sent by an operating system of the first host, where the control instruction is used to instruct installation of a preset driver in an operating system in the second host.
And a searching module 1002, configured to search the pre-constructed database for driving information corresponding to the preset driving according to the control instruction.
And an installation module 1003, configured to complete the installation of the preset driver according to the driving information when it is determined that the driving information is stored in the database.
Optionally, a sending module 1004 is also included.
The sending module 1004 is configured to send response information to the operating system of the first host, where the response information is used to indicate success or failure of installing the preset driver.
The functions executed by each component in the driving management device provided in the embodiment of the present invention are described in detail in any of the above method embodiments, so that a detailed description is omitted here.
The embodiment of the invention provides a management device for a drive, which comprises a first host system, a second host system and a control system, wherein the first host system acquires a first control instruction, and the first control instruction comprises identification information of a first drive in an operating system of the first host; extracting driving information of a first driver corresponding to the first driving identification information; comparing the driving information of the first drive with each driving information of a preset driving library; and when the driving information of the first driving is confirmed to be matched with any one of the driving information in the preset driving library, sending a second control instruction to the operating system of the second host. The second host system searches the preset driving information corresponding to the preset driving in the pre-constructed database according to the control instruction; and when the driving information is stored in the database, the installation of the preset driving is completed according to the driving information. By means of the method, the first drive is compared with the preset drive library, and when the first drive is confirmed to be matched with the drive of the preset drive library, the second host system automatically installs the first drive, so that the automatic detection and the installation of the drive process are realized, the labor cost is saved, and the efficiency is improved.
As shown in fig. 11, the embodiment of the present application provides a computer device, which includes a processor 111, a communication interface 112, a memory 113, and a communication bus 114, where the processor 111, the communication interface 112, and the memory 113 perform communication with each other through the communication bus 114.
A memory 113 for storing a computer program;
when the computer device is the first host, the processor is configured to perform the method steps shown in fig. 1, see specifically the following:
comprising the following steps: acquiring a first control instruction, wherein the first control instruction comprises identification information of a first driver in an operating system of a first host; extracting driving information of a first driver corresponding to the first driving identification information; comparing the driving information of the first drive with each driving information of a preset driving library; and when the driving information of the first driving is confirmed to be matched with any one of the driving information in the preset driving library, sending a second control instruction to the operating system of the second host.
Optionally, determining whether the driving information of the first driving is matched with any driving information in a preset driving library specifically includes:
comparing a first drive name in the drive information of the first drive with a second drive name of the second drive information in a preset drive library;
comparing a first driving version in the driving information of the first driving with a second driving version in the second driving information in a preset driving library;
when the first drive name is consistent with the second drive name and the first drive version is consistent with the second drive version, determining that the drive information of the first drive is matched with the second drive information in the preset drive library, wherein the second drive information is any one of the drive information in the preset drive library.
Optionally, before confirming that the driving information of the first drive matches any one of the driving information in the preset driving library and sending the second control instruction to the operating system of the second host, the method further includes:
and establishing a communication connection channel between the first host and the second host so that an operating system in the first host sends a second control instruction to the operating system of the second host through the communication connection channel.
Optionally, after confirming that the driving information of the first drive matches any one of the driving information in the preset driving library and sending the second control instruction to the operating system of the second host, the method further includes:
receiving response information fed back by an operating system of the second host;
and when the response information is that the first drive is successfully installed, acquiring second drive information so as to send a third control instruction to an operating system in the second host when the second drive information is determined to be in a preset drive library, wherein the third control instruction is used for indicating the operating system of the second host to complete the installation of the second drive, and the second drive is any drive except the first drive in the operating system of the first host.
Alternatively, when the computer device is the second host, the processor performs the method shown in fig. 7, and the steps are specifically referred to as follows:
receiving a control instruction sent by an operating system of a first host, and searching driving information corresponding to a preset driving in a pre-built database according to the control instruction; and when the driving information is stored in the database, finishing the installation of the preset driving according to the driving information.
Optionally, when it is determined that the driving information is stored in the database, after the installation of the preset driving is completed according to the driving information, the method further includes:
and sending response information to the operating system of the first host, wherein the response information is used for indicating the success or failure of the installation of the preset drive.
The present application further provides a computer readable storage medium, on which a computer program is stored, which when executed by a processor, implements the steps of the method for managing a driver provided by any one of the method embodiments shown in fig. 1, or implements the steps of the method for managing a driver provided by any one of the method embodiments shown in fig. 7.
It should be noted that in this document, relational terms such as "first" and "second" and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises an element.
The foregoing is merely exemplary of embodiments of the present invention to enable those skilled in the art to understand or practice the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims (10)
1. A method of managing a drive, the method performed by an operating system in a first host, the method comprising:
acquiring a first control instruction, wherein the first control instruction comprises identification information of a first driver in an operating system of the first host;
extracting driving information of a first driver corresponding to the first driving identification information;
comparing the driving information of the first driving with each driving information of a preset driving library, wherein the driving in the preset driving library is a special driving required by a VMware official network;
when the driving information of the first driver is confirmed to be matched with any one of the driving information in the preset driving library, a second control instruction is sent to a second host system, wherein the second control instruction is used for indicating an operating system in the second host to finish the installation of the first driver, the operating system of the first host is a distributed mirror system, the operating system in the second host is a mirror system to be distributed, and the first driver is any one of the operating systems of the first host.
2. The method according to claim 1, wherein determining whether the driving information of the first driving matches any driving information in the preset driving library, specifically comprises:
comparing a first drive name in the drive information of the first drive with a second drive name of the second drive information in the preset drive library;
comparing a first drive version in the drive information of the first drive with a second drive version in the second drive information in the preset drive library;
when the first drive name is consistent with the second drive name, and the first drive version is consistent with the second drive version, determining that the drive information of the first drive is matched with the second drive information in the preset drive library, wherein the second drive information is any one of the drive information in the preset drive library.
3. The method according to claim 1 or 2, wherein when it is confirmed that the drive information of the first drive matches any one of the drive information in the preset drive library, the method further comprises, before transmitting the second control instruction to the operating system of the second host:
and establishing a communication connection channel between the first host and the second host, so that an operating system in the first host sends a second control instruction to the operating system of the second host through the communication connection channel.
4. The method according to claim 1 or 2, wherein after confirming that the drive information of the first drive matches any one of the drive information in the preset drive library, the method further comprises, after transmitting a second control instruction to an operating system of a second host:
receiving response information fed back by an operating system of the second host;
and when the response information is that the first drive is successfully installed, acquiring second drive information so as to send a third control instruction to an operating system in the second host when the second drive information is determined to be in the preset drive library, wherein the third control instruction is used for indicating the operating system of the second host to complete the installation of the second drive, and the second drive is any one of the operating systems of the first host except the first drive.
5. A method of managing a drive, the method being performed by an operating system in a second host, the method comprising:
receiving a control instruction sent by an operating system of a first host, wherein the control instruction is used for indicating that a preset driver is installed in the operating system in a second host;
searching driving information corresponding to the preset driving in a pre-constructed database according to the control instruction;
when the driving information is stored in the database, the preset driving is installed according to the driving information, wherein the preset driving is any driving in an operating system of a first host, the driving information of any driving is matched with any driving information in a preset driving library, the driving in the preset driving library is special driving required by a VMware official network, the operating system of the first host is a published mirror system, and the operating system in the second host is a mirror system to be published.
6. The method according to claim 5, wherein after determining that the driving information is stored in the database and installing the preset driving according to the driving information is completed, the method further comprises:
and sending response information to the operating system of the first host, wherein the response information is used for indicating the success or failure of the installation of the preset driver.
7. A management device for a drive, the device comprising:
the system comprises an acquisition module, a control module and a control module, wherein the acquisition module is used for acquiring a first control instruction, and the first control instruction comprises identification information of a first drive of an operating system in a first host;
the extraction module is used for extracting the driving information of the first drive corresponding to the first driving identification information;
the comparison module is used for comparing the driving information of the first driving with each driving information of a preset driving library, wherein the driving in the preset driving library is a special driving required by the VMware official network;
the processing module is used for sending a second control instruction to an operating system of a second host when the driving information of the first drive is confirmed to be matched with any one of the preset driving libraries, wherein the second control instruction is used for indicating the operating system in the second host to finish the installation of the first drive, the operating system of the first host is a distributed mirror system, the operating system in the second host is a mirror system to be distributed, and the first drive is any one of the operating systems of the first host.
8. A management device for a drive, the device comprising:
the receiving module is used for receiving a control instruction sent by an operating system of the first host, wherein the control instruction is used for indicating that a preset driver is installed in the operating system in the second host;
the searching module is used for searching driving information corresponding to the preset driving in a pre-constructed database according to the control instruction;
the installation module is used for completing the installation of the preset drive according to the drive information when the drive information is stored in the database, wherein the preset drive is any drive in an operating system of a first host, the drive information of any drive is matched with any drive information in a preset drive library, the drive in the preset drive library is special drive required by a VMware official network, the operating system of the first host is a published mirror system, and the operating system in the second host is a mirror system to be published.
9. The computer equipment is characterized by comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory are communicated with each other through the communication bus;
the memory is used for storing a computer program;
the processor, when executing a program stored in a memory, implementing the steps of the method for managing a drive according to any one of claims 1 to 4; or, a step of realizing the management method of the drive according to any one of claims 5 to 6.
10. A computer-readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of managing a drive according to any one of claims 1-4 or the steps of the method of managing a drive according to any one of claims 5-6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210413052.6A CN114675893B (en) | 2022-04-19 | 2022-04-19 | Drive management method and device and computer equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210413052.6A CN114675893B (en) | 2022-04-19 | 2022-04-19 | Drive management method and device and computer equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114675893A CN114675893A (en) | 2022-06-28 |
CN114675893B true CN114675893B (en) | 2023-07-14 |
Family
ID=82078669
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210413052.6A Active CN114675893B (en) | 2022-04-19 | 2022-04-19 | Drive management method and device and computer equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114675893B (en) |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2013075514A1 (en) * | 2011-11-22 | 2013-05-30 | 华为技术有限公司 | Installation method and installation device for application software |
CN104881314A (en) * | 2015-06-29 | 2015-09-02 | 北京金山安全软件有限公司 | Method for installing driver and driver installation device |
CN109257399A (en) * | 2017-07-13 | 2019-01-22 | 上海擎感智能科技有限公司 | Cloud platform application management method and management platform, storage medium |
CN111610989A (en) * | 2020-06-17 | 2020-09-01 | 中国人民解放军国防科技大学 | Application release/update method and system for offline container cloud environment |
CN111625834A (en) * | 2020-05-15 | 2020-09-04 | 深圳开源互联网安全技术有限公司 | System and method for detecting vulnerability of Docker mirror image file |
WO2021169114A1 (en) * | 2020-02-26 | 2021-09-02 | 平安科技(深圳)有限公司 | Mirror image test method and apparatus, computer device and storage medium |
-
2022
- 2022-04-19 CN CN202210413052.6A patent/CN114675893B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2013075514A1 (en) * | 2011-11-22 | 2013-05-30 | 华为技术有限公司 | Installation method and installation device for application software |
CN104881314A (en) * | 2015-06-29 | 2015-09-02 | 北京金山安全软件有限公司 | Method for installing driver and driver installation device |
CN109257399A (en) * | 2017-07-13 | 2019-01-22 | 上海擎感智能科技有限公司 | Cloud platform application management method and management platform, storage medium |
WO2021169114A1 (en) * | 2020-02-26 | 2021-09-02 | 平安科技(深圳)有限公司 | Mirror image test method and apparatus, computer device and storage medium |
CN111625834A (en) * | 2020-05-15 | 2020-09-04 | 深圳开源互联网安全技术有限公司 | System and method for detecting vulnerability of Docker mirror image file |
CN111610989A (en) * | 2020-06-17 | 2020-09-01 | 中国人民解放军国防科技大学 | Application release/update method and system for offline container cloud environment |
Also Published As
Publication number | Publication date |
---|---|
CN114675893A (en) | 2022-06-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111666080B (en) | Micro service cluster deployment method and device, computer equipment and storage medium | |
US9465625B2 (en) | Provisioning of operating environments on a server in a networked environment | |
US7448034B2 (en) | Build time determination and installation of drivers on cloned systems | |
US10216514B2 (en) | Identification of a component for upgrade | |
CN101453367B (en) | Software deployment method and system, software deployment server and user server | |
US6751794B1 (en) | Intelligent patch checker | |
US7940407B2 (en) | Image forming apparatus, terminal apparatus and management apparatus | |
CN112199197B (en) | Server management method and system | |
CN102455915A (en) | Method for automatically configuring distributed system, and server | |
CN105871568B (en) | Software upgrading method and system | |
CN103200271A (en) | Advanced Risc machine (ARM) server and method of automatic installation system thereof | |
CN111464603B (en) | Server capacity expansion method and system | |
CN103516735A (en) | Method and apparatus for upgrading network node | |
CN113315754A (en) | Intelligent linkage method, device, equipment and medium for firewall of container visit | |
JP2006338225A (en) | Automatic installation method of computer | |
CN113535262B (en) | Proxy node start control method, device, equipment and storage medium | |
CN111459611A (en) | Mirror image pulling method and device for Kubernetes system | |
CN114675893B (en) | Drive management method and device and computer equipment | |
CN105550342A (en) | Data processing method of completely-transparent distributed database | |
CN112463304A (en) | Rollback method and apparatus for container mirror image, computer device, and storage medium | |
CN111459530B (en) | Patching method, device and storage medium | |
CN104111862A (en) | Method and system for obtaining IP (Internet Protocol) address of virtual machine in cloud computing platform | |
CN112685613B (en) | Resource package query method and device and information processing system | |
CN107968794B (en) | Virtual CD-ROM mounting method and system, server and terminal | |
CN114866517A (en) | Installation file execution method and device and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |