Method, apparatus, electronic device and storage medium for system installation
By obtaining device information and network IP addresses, automatically configure independent disk redundant arrays and substrate management controller IP addresses, combined with pre-start execution environment and substrate management controller installation methods, the high cost and inefficiency problems when batch installation of operating systems is solved, and efficient system installation is achieved.
Patent Information
- Application Number
- CN202210004609.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-01-04
- Publication Date
- 2025-07-11
- Estimated Expiration
- 2042-01-04
AI Technical Summary
In a computer room with a large number of hosts, when installing the operating system in batches, operators need to manually install it through optical drive and optical disk media. Each host consumes a lot of energy and time, resulting in high operation and maintenance costs and low work efficiency.
By obtaining device information and the number of dynamic host configuration protocol IP addresses under the network, the independent disk redundant array and the IP address of the substrate management controller are automatically configured, and the system installation is realized by combining the pre-start execution environment and the substrate management controller installation method.
The automated configuration process reduces the energy consumption of operators, reduces operation and maintenance costs, and improves work efficiency.
Smart Images

Figure CN114356358B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular, to a method, device, electronic device, and storage medium for system installation. Background Art
[0002] With the continuous development of Internet technology, the number of servers is also increasing continuously. From a few servers in the initial stage to a huge data center, relying solely on manual labor can no longer meet the requirements in terms of technology, business, management, etc. Factors such as standardization, automation, architecture optimization, and process optimization to reduce service costs are being increasingly emphasized by people.
[0003] In a computer room with a large number of hosts, when installing operating systems in batches, operators need to manually install each host one by one through an optical drive and optical disc medium, which consumes a large amount of energy and time of the operators, resulting in problems such as high operation and maintenance costs and low work efficiency. Summary of the Invention
[0004] In view of this, the present application provides a method, device, electronic device, and storage medium for system installation to solve the problems in the prior art that when installing operating systems in batches, it consumes a large amount of energy and time of operators, resulting in high operation and maintenance costs and low work efficiency.
[0005] To achieve the above object, the present application provides the following technical solutions:
[0006] The first aspect of the present application discloses a method for system installation, including:
[0007] Obtain the device information of the device to be installed, the number of the devices to be installed, and the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network;
[0008] For each device to be installed, based on the device information, configure the Redundant Array of Independent Disks (RAID), the IP address of the Baseboard Management Controller (BMC), and the user information of the BMC for the device to be installed;
[0009] If the number of the devices to be installed is less than the number of DHCP IP addresses in the current network, perform system installation on each of the devices to be installed through the Preboot Execution Environment (PXE) installation method;
[0010] If the number of the devices to be installed is not less than the number of DHCP IP addresses in the current network, combine the PXE installation method and the BMC installation method to perform system installation on each of the devices to be installed.
[0011] Optionally, in the above method, for each device to be installed, based on the device information, configuring the redundant array of independent disks, the baseboard management controller IP address, and the baseboard management controller user information of the device to be installed includes:
[0012] For each device to be installed, based on the device information, determining whether the device to be installed is in a preset memory operating system compatibility list;
[0013] If it is determined that the device to be installed is in the preset memory operating system compatibility list, then call the memory operating system configuration module to configure the redundant array of independent disks, the baseboard management controller IP address, and the baseboard management controller user information of the device to be installed;
[0014] If it is determined that the device to be installed is not in the preset memory operating system compatibility list, then call the baseboard management controller installation module to configure the redundant array of independent disks of the device to be installed, and call the memory operating system configuration module to configure the baseboard management controller IP address and the baseboard management controller user information of the device to be installed.
[0015] Optionally, in the above method, if the number of devices to be installed is not less than the number of Dynamic Host Configuration Protocol IP addresses in the current network, then combining the pre-boot execution environment installation method and the baseboard management controller installation method to perform system installation on each of the devices to be installed, including:
[0016] Obtain the installation priority of each of the devices to be installed;
[0017] Sort the devices to be installed according to the installation priority;
[0018] Perform system installation on the devices to be installed with the first N installation priorities through the pre-boot execution environment installation method; where N is equal to the number of Dynamic Host Configuration Protocol IP addresses in the current network;
[0019] Perform system installation on the devices to be installed after the first N installation priorities through the baseboard management controller installation method.
[0020] Optionally, in the above method, based on the device information, configuring the redundant array of independent disks, the baseboard management controller IP address, and the baseboard management controller user information of the device to be installed further includes:
[0021] Generate a configuration log of the device to be installed.
[0022] A second aspect of the present application discloses a device for system installation, including:
[0023] An acquisition unit, configured to acquire device information of a device to be installed, the number of the devices to be installed, and the number of Dynamic Host Configuration Protocol (DHCP) IP addresses under the current network;
[0024] A configuration unit, configured to, for each device to be installed, configure a redundant array of independent disks (RAID), a baseboard management controller (BMC) IP address, and BMC user information of the device to be installed based on the device information;
[0025] A first installation unit, configured to, if the number of the devices to be installed is less than the number of DHCP IP addresses under the current network, perform system installation on each of the devices to be installed by means of Preboot eXecution Environment (PXE) installation;
[0026] A second installation unit, configured to, if the number of the devices to be installed is not less than the number of DHCP IP addresses under the current network, perform system installation on each of the devices to be installed by combining the PXE installation method and the BMC installation method.
[0027] Optionally, for the above device, the configuration unit includes:
[0028] A judgment subunit, configured to, for each device to be installed, judge whether the device to be installed is in a preset in-memory operating system compatibility list based on the device information;
[0029] A first call subunit, configured to, if it is judged that the device to be installed is in the preset in-memory operating system compatibility list, call an in-memory operating system configuration module to configure the RAID, the BMC IP address, and the BMC user information of the device to be installed;
[0030] A second call subunit, configured to, if it is judged that the device to be installed is not in the preset in-memory operating system compatibility list, call a BMC installation module to configure the RAID of the device to be installed, and call the in-memory operating system configuration module to configure the BMC IP address and the BMC user information of the device to be installed.
[0031] Optionally, for the above device, the second installation unit includes:
[0032] An acquisition subunit, configured to acquire the installation priorities of the devices to be installed;
[0033] A sorting subunit, configured to sort the devices to be installed according to the installation priorities;
[0034] The first installation sub-unit is used to perform system installation on the devices to be installed with the top N installation priorities through the pre-boot execution environment installation method; where N is equal to the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network;
[0035] The second installation sub-unit is used to perform system installation on the devices to be installed after the top N installation priorities through the Baseboard Management Controller (BMC) installation method.
[0036] Optionally, the above device further includes:
[0037] A log generation unit is used to generate the configuration logs of the devices to be installed.
[0038] A third aspect of the present application discloses an electronic device, including:
[0039] One or more processors;
[0040] A storage device storing one or more programs thereon;
[0041] When the one or more programs are executed by the one or more processors, the one or more processors are caused to implement the method described in any one of the first aspect of the present application.
[0042] A fourth aspect of the present application discloses a computer storage medium storing a computer program thereon, where the computer program, when executed by a processor, implements the method described in any one of the first aspect of the present application.
[0043] As can be seen from the above technical solutions, in a system installation method provided by the present application, first, the device information of the devices to be installed, the number of devices to be installed, and the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network are obtained; then, based on the device information, the Redundant Array of Independent Disks (RAID), the Baseboard Management Controller (BMC) IP address, and the BMC user information of the devices to be installed are configured. If the number of devices to be installed is less than the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network, system installation is performed on each device to be installed through the pre-boot execution environment installation method. If the number of devices to be installed is not less than the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network, system installation is performed on each device to be installed by combining the pre-boot execution environment installation method and the Baseboard Management Controller (BMC) installation method. It can be seen that by using the method of the present application, the Redundant Array of Independent Disks (RAID), the Baseboard Management Controller (BMC) IP address, and the BMC user information of the devices to be installed can be automatically configured, and system installation can be automatically performed through different methods according to the number of Dynamic Host Configuration Protocol (DHCP) IP addresses. This solves the problem that when installing operating systems in batches in the prior art, it consumes a large amount of energy and time of operators, resulting in high operation and maintenance costs and low work efficiency. Description of the Drawings
[0044] To more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are only the embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on the provided drawings.
[0045] Figure 1 It is a flowchart of a method for installing a system for an embodiment disclosed in the present application;
[0046] Figure 2 It is a schematic diagram of a device for installing a system for another embodiment disclosed in the present application;
[0047] Figure 3 It is a schematic diagram of an electronic device for another embodiment disclosed in the present application. Detailed implementation manners
[0048] The following will clearly and completely describe the technical solutions in the embodiments of the present application with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the scope of protection of the present application.
[0049] In the present application, the term "including", "comprising" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed, or further includes elements inherent to such a process, method, article or device. Without further limitations, the element defined by the statement "including one..." does not exclude the existence of additional identical elements in the process, method, article or device including the said element.
[0050] And, in this article, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations.
[0051] As can be seen from the background technology, in a computer room with a large number of hosts, when installing operating systems in batches, operators need to manually install each host one by one through an optical drive and optical disc media, which consumes a lot of energy and time of the operators, resulting in problems such as high operation and maintenance costs and low work efficiency.
[0052] In view of this, the present application provides a method, apparatus, electronic device and storage medium for system installation, so as to solve the problems in the prior art that when installing an operating system in batches, it will consume a large amount of energy and time of operators, resulting in high operation and maintenance costs and low work efficiency.
[0053] An embodiment of the present application provides a method for system installation, specifically as Figure 1 shown, including:
[0054] S101. Obtain the device information of the device to be installed, the number of devices to be installed, and the number of Dynamic Host Configuration Protocol IP addresses in the current network.
[0055] It should be noted that for the convenience of understanding, the method of the installation system in this embodiment is described. The installation system includes: an installation parameter database module, a front-end interface module, a total control server module, a memory operating system configuration module, a BMC (Baseboard Management Controller) installation module, a PXE (Preboot Execution Environment) installation module, and an operating system image module.
[0056] It should also be noted that when installing an operating system for a device, the user imports the device information of the already racked server device through the front-end interface module, and then the total control server module of the installation system obtains the device information of the device to be installed, the number of devices to be installed, and the number of Dynamic Host Configuration Protocol IP addresses (DHCP IP) in the current network. Among them, the device information includes: device serial number, device model, network card MAC address, production address to be configured, BMC address to be configured, RAID configuration, kickstart configuration, installation priority and other information. DHCP (Dynamic Host Configuration Protocol) is a network protocol for a local area network. The server controls a range of IP addresses, and the client can automatically obtain the IP address and subnet mask assigned by the server when logging in to the server.
[0057] S102. For each device to be installed, based on the device information, configure the redundant array of independent disks, the IP address of the baseboard management controller, and the user information of the baseboard management controller of the device to be installed.
[0058] It should be noted that after obtaining the device information of the device to be installed, the number of devices to be installed, and the number of Dynamic Host Configuration Protocol IP addresses in the current network, the total control server module configures the redundant array of independent disks, the IP address of the baseboard management controller, and the user information of the baseboard management controller of the device to be installed based on the device information.
[0059] Optionally, in another embodiment of the present application, an implementation manner of step S102 may include:
[0060] For each device to be installed, based on the device information, determine whether the device to be installed is in the preset memory operating system compatibility list;
[0061] If it is determined that the device to be installed is in the preset memory operating system compatibility list, then call the memory operating system configuration module to configure the redundant array of independent disks, the baseboard management controller IP address, and the baseboard management controller user information of the device to be installed;
[0062] If it is determined that the device to be installed is not in the preset memory operating system compatibility list, then call the baseboard management controller installation module to configure the redundant array of independent disks of the device to be installed, and call the memory operating system configuration module to configure the baseboard management controller IP address and the baseboard management controller user information of the device to be installed.
[0063] It should be noted that for each device to be installed, the master control server module reads the device information of the device to be installed and determines whether the current device to be installed is in the preset memory operating system compatibility list. If it is determined that the current device to be installed is in the preset memory operating system compatibility list, then call the memory operating system configuration module to configure the redundant array of independent disks (RAID), the baseboard management controller IP address (BMC IP address), and the baseboard management controller user information (BMC user information) of the current device to be installed. If it is determined that the device to be installed is not in the preset memory operating system compatibility list, then call the baseboard management controller installation module (BMC installation module) to execute the BMC model script to configure the redundant array of independent disks of the device to be installed. The BMC script is as follows:
[0064] Make the first four physical disks on the array card 0 into a RAID1 with a stripe size of 128k, and the available capacity of the logical disk after making the RAID1 is 100G.
[0065] ipmcset -t storage -d createld -v 0 -rl r1 -pd 0,1,2,3 -name example -size100g -ss 128k -rp ra -wp wb -ap rw -iop cio -dcp enabled -init quick.
[0066] Then call the memory operating system configuration module to configure the baseboard management controller IP address and the baseboard management controller user information of the device to be installed.
[0067] Optionally, after executing step S102, it may further include:
[0068] Generate a configuration log for the device to be installed.
[0069] It should be noted that after configuring the redundant array of independent disks, the IP address of the baseboard management controller, and the user information of the baseboard management controller for the device to be installed, a configuration log of the device to be installed is generated for subsequent data query.
[0070] S103. If the number of devices to be installed is less than the number of Dynamic Host Configuration Protocol IP addresses in the current network, the system installation of each device to be installed is performed through the Preboot Execution Environment installation method.
[0071] It should be noted that after executing step S102, the RAID, BMC IP address, and BMC user of the device to be installed have been configured, and the conditions for installing the operating system are met. At this time, it is judged whether the number of devices to be installed is less than the number of Dynamic Host Configuration Protocol IP addresses in the current network. If the number of devices to be installed is less than the number of Dynamic Host Configuration Protocol IP addresses in the current network, the number of Dynamic Host Configuration Protocol IP addresses is sufficient at this time. Since the PXE installation efficiency is much higher than the efficiency of installing through the BMC, the system installation of each device to be installed is performed through the PXE installation method. When the device to be installed installs the operating system, the static IP address of the operating system will be configured according to the kickstart configuration script and directly connected to the production network for use.
[0072] It also should be noted that when entering the operating system installation stage and performing system installation through the PEX installation method, the memory operating system on the device to be installed will report the network card MAC address and the device serial number, notify the master control server module to read the kickstart configuration file and generate the PXE installation file, where the kickstart configuration file is a configuration file that defines the Linux installation process. The memory operating system forces the device to be installed to boot from the network, enters the operating system installation process, runs the kickstart configuration script, and feeds back to the master control server module. When performing system installation through the BMC installation method, the master control server module reads the kickstart configuration script of the device to be installed under the foregoing conditions, makes the operating system image ISO file, and places it in the operating system image module for HTTP service to read and transmit. Considering the BMC network bandwidth limitation of the server device and the read and write limitation of the operating system ISO image file, the number of devices pushed within a certain time period can be restricted. The BMC script adopted by the BMC installation method can be referred to as follows:
[0073] a. Mount the virtual optical drive image file
[0074] ipmcset -t vmm -d connect -v http: / / image path / operating system ISO image name
[0075] b. Set to boot from the optical drive next time
[0076] ipmcset - d bootdevice - v 5 once
[0077] C. Restart the server device
[0078] ipmcset - d fruncontrol - v 0
[0079] S104. If the number of devices to be installed is not less than the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network, combine the Pre - boot Execution Environment (PXE) installation method and the Baseboard Management Controller (BMC) installation method to perform system installation on each device to be installed.
[0080] It should be noted that if the number of devices to be installed is not less than the number of DHCP IP addresses in the current network, combine the Pre - PXE installation method and the BMC installation method to perform system installation on each device to be installed. Select the devices to be installed with the same number as the number of DHCP IP addresses in the current network and use the PXE installation method for system installation, and use the BMC installation method for the remaining devices to be installed to achieve the maximum installation speed.
[0081] Optionally, in another embodiment of the present application, step S104 may include:
[0082] Obtain the installation priority of each device to be installed.
[0083] Sort the installation priorities of each device to be installed.
[0084] Perform system installation on the devices to be installed with the top N installation priorities through the Pre - boot Execution Environment installation method; where N is equal to the number of DHCP IP addresses in the current network.
[0085] Perform system installation on the devices to be installed after the top N installation priorities through the Baseboard Management Controller installation method.
[0086] It should be noted that if the number of devices to be installed is not less than the number of DHCP IP addresses in the current network, first obtain the installation priority of each device to be installed, and sort the installation priorities of each device to be installed from high to low. Select the devices to be installed with the top N installation priorities and perform system installation through the PEX installation method; where N is equal to the number of DHCP IP addresses in the current network. Perform system installation on the devices to be installed after the top N installation priorities through the BMC installation method.
[0087] In a method for system installation provided by this application, first, the device information of the devices to be installed, the number of devices to be installed, and the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network are obtained. Then, based on the device information, the Redundant Array of Independent Disks (RAID) of the devices to be installed, the IP address of the Baseboard Management Controller (BMC), and the user information of the BMC are configured. If the number of devices to be installed is less than the number of DHCP IP addresses in the current network, the system installation is performed on each device to be installed through the Preboot eXecution Environment (PXE) installation method. If the number of devices to be installed is not less than the number of DHCP IP addresses in the current network, the system installation is performed on each device to be installed by combining the PXE installation method and the BMC installation method. It can be seen from this that by using the method of this application, the RAID of the devices to be installed, the IP address of the BMC, and the user information of the BMC can be automatically configured, and the system installation can be automatically performed in different ways according to the number of DHCP IP addresses. This solves the problems in the prior art that when installing operating systems in batches, it will consume a large amount of energy and time of the operators, resulting in high operation and maintenance costs and low work efficiency.
[0088] Another embodiment of this application also provides a device for system installation, specifically as Figure 2 shown, including:
[0089] An obtaining unit 201, configured to obtain the device information of the devices to be installed, the number of devices to be installed, and the number of DHCP IP addresses in the current network;
[0090] A configuration unit 202, configured to, for each device to be installed, based on the device information, configure the RAID of the device to be installed, the IP address of the BMC, and the user information of the BMC;
[0091] A first installation unit 203, configured to, if the number of devices to be installed is less than the number of DHCP IP addresses in the current network, perform system installation on each device to be installed through the PXE installation method;
[0092] A second installation unit 204, configured to, if the number of devices to be installed is not less than the number of DHCP IP addresses in the current network, perform system installation on each device to be installed by combining the PXE installation method and the BMC installation method.
[0093] In this embodiment, for the specific execution processes of the obtaining unit 201, the configuration unit 202, the first installation unit 203, and the second installation unit 204, reference can be made to the content of the corresponding Figure 1 method embodiment, which will not be elaborated here.
[0094] In a device for system installation provided by this application, first, an acquisition unit 201 acquires device information of a device to be installed, the quantity of devices to be installed, and the quantity of Dynamic Host Configuration Protocol (DHCP) IP addresses under the current network. Then, a configuration unit 202 configures a redundant array of independent disks (RAID), a Baseboard Management Controller (BMC) IP address, and BMC user information of the device to be installed based on the device information. If the quantity of devices to be installed is less than the quantity of DHCP IP addresses under the current network, a first installation unit 203 installs the system for each device to be installed through a Pre-Boot Execution Environment (PXE) installation method. If the quantity of devices to be installed is not less than the quantity of DHCP IP addresses under the current network, a second installation unit 204 installs the system for each device to be installed by combining the PXE installation method and the BMC installation method. It can be seen from this that by using the method of this application, the RAID, BMC IP address, and BMC user information of the device to be installed can be automatically configured, and the system can be automatically installed in different ways according to the quantity of DHCP IP addresses. This solves the problem in the prior art that when installing operating systems in batches, it consumes a large amount of energy and time of operators, resulting in high operation and maintenance costs and low work efficiency.
[0095] Optionally, in another embodiment of this application, an implementation manner of the configuration unit 202 may include:
[0096] A judgment subunit, configured to, for each device to be installed, judge whether the device to be installed is in a preset in-memory operating system compatibility list based on the device information;
[0097] A first call subunit, configured to, if it is judged that the device to be installed is in the preset in-memory operating system compatibility list, call an in-memory operating system configuration module to configure the RAID, BMC IP address, and BMC user information of the device to be installed;
[0098] A second call subunit, configured to, if it is judged that the device to be installed is not in the preset in-memory operating system compatibility list, call a BMC installation module to configure the RAID of the device to be installed, and call an in-memory operating system configuration module to configure the BMC IP address and BMC user information of the device to be installed.
[0099] In this embodiment, for the specific execution processes of the judgment subunit, the first call subunit, and the second call subunit, reference may be made to the corresponding method embodiment content described above, which will not be elaborated here.
[0100] Optionally, in another embodiment of this application, an implementation manner of the second installation unit 204 may include:
[0101] An acquisition subunit, configured to acquire the installation priorities of each device to be installed;
[0102] A sorting subunit, configured to sort the installation priorities of each device to be installed;
[0103] A first installation subunit, configured to install the operating system for the devices to be installed whose installation priorities are among the top N through the pre-boot execution environment installation method; where N is equal to the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network;
[0104] A second installation subunit, configured to install the operating system for the devices to be installed whose installation priorities are after the top N through the baseboard management controller installation method.
[0105] In this embodiment, for the specific execution processes of the acquisition subunit, the sorting subunit, the first installation subunit, and the second installation subunit, reference may be made to the corresponding method embodiment described above, which will not be elaborated here.
[0106] Optionally, in another embodiment of the present application, the device for system installation may further include:
[0107] A log generation unit, configured to generate configuration logs of the devices to be installed.
[0108] In this embodiment, for the specific execution process of the log generation unit, reference may be made to the corresponding method embodiment described above, which will not be elaborated here.
[0109] Another embodiment of the present application further provides an electronic device, as Figure 3 shown, specifically including:
[0110] One or more processors 301.
[0111] A storage device 302, on which one or more programs are stored.
[0112] When the one or more programs are executed by the one or more processors 301, the one or more processors 301 are caused to implement any of the methods in the above embodiments.
[0113] Another embodiment of the present application further provides a computer storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements any of the methods in the above embodiments.
[0114] Each embodiment in this specification is described in a progressive manner. For the same or similar parts among the embodiments, reference can be made to each other, and the differences between each embodiment and other embodiments are emphasized. In particular, for a system or system embodiment, since it is basically similar to a method embodiment, the description is relatively simple, and the relevant parts can refer to the description of the method embodiment. The systems and system embodiments described above are only illustrative. The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. A person of ordinary skill in the art can understand and implement it without creative work.
[0115] Those skilled in the art can further realize that the units and algorithm steps of each example described in combination with the embodiments disclosed in this article can be implemented by electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of each example have been generally described according to their functions in the above description. Whether these functions are executed in a hardware or software manner depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present invention.
[0116] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present invention. Various modifications to these embodiments will be obvious to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to these embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for system installation, characterized in that Including: Obtaining the device information of the device to be installed, the quantity of the devices to be installed, and the quantity of Dynamic Host Configuration Protocol (DHCP) IP addresses under the current network; For each device to be installed, based on the device information, configuring the Redundant Array of Independent Disks (RAID) of the device to be installed, the Baseboard Management Controller (BMC) IP address, and the BMC user information; If the quantity of the devices to be installed is less than the quantity of DHCP IP addresses under the current network, then performing system installation on each of the devices to be installed through the Preboot Execution Environment (PXE) installation method; wherein, performing system installation on each of the devices to be installed through the PXE installation method includes: reading a kickstart configuration file and generating a PXE installation file; wherein, the kickstart configuration file is a configuration file that defines the Linux installation process; starting the device to be installed, entering the operating system installation process, and running the kickstart configuration script; If the quantity of the devices to be installed is not less than the quantity of DHCP IP addresses under the current network, then combining the PXE installation method and the BMC installation method to perform system installation on each of the devices to be installed; wherein, selecting the same quantity of devices to be installed as the quantity of DHCP IP addresses under the current network and performing system installation using the PXE installation method, and performing system installation on the remaining devices to be installed using the BMC installation method.
2. The method according to claim 1, wherein The step of, for each device to be installed, based on the device information, configuring the RAID of the device to be installed, the BMC IP address, and the BMC user information includes: For each device to be installed, based on the device information, determining whether the device to be installed is in a preset memory operating system compatibility list; If it is determined that the device to be installed is in the preset memory operating system compatibility list, then calling a memory operating system configuration module to configure the RAID of the device to be installed, the BMC IP address, and the BMC user information; If it is determined that the device to be installed is not in the preset memory operating system compatibility list, then calling a BMC installation module to configure the RAID of the device to be installed, and calling the memory operating system configuration module to configure the BMC IP address and the BMC user information of the device to be installed.
3. The method according to claim 1, characterized in that, The step of, if the quantity of the devices to be installed is not less than the quantity of DHCP IP addresses under the current network, then combining the PXE installation method and the BMC installation method to perform system installation on each of the devices to be installed includes: Obtaining the installation priorities of each of the devices to be installed; Sorting the devices to be installed according to the installation priorities; Performing system installation on the devices to be installed with the top N installation priorities through the PXE installation method; wherein, N is equal to the quantity of DHCP IP addresses under the current network; Install the devices to be installed with installation priorities after the first N devices through the Baseboard Management Controller (BMC) installation method for system installation.
4. The method according to claim 1, wherein Based on the device information, configure the Redundant Array of Independent Disks (RAID), the IP address of the Baseboard Management Controller, and the user information of the Baseboard Management Controller for the devices to be installed. It further includes: Generate the configuration log for the devices to be installed.
5. A device for system installation, characterized in that, It includes: An acquisition unit for acquiring the device information of the devices to be installed, the number of the devices to be installed, and the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network. A configuration unit for, for each device to be installed, configuring the Redundant Array of Independent Disks (RAID), the IP address of the Baseboard Management Controller, and the user information of the Baseboard Management Controller based on the device information. A first installation unit for, if the number of the devices to be installed is less than the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network, performing system installation on each of the devices to be installed through the Preboot eXecution Environment (PXE) installation method. Among them, performing system installation on each of the devices to be installed through the Preboot eXecution Environment (PXE) installation method includes: reading the kickstart configuration file and generating a Preboot eXecution Environment (PXE) installation file; the kickstart configuration file is a configuration file that defines the Linux installation process; starting the device to be installed, entering the operating system installation process, and running the kickstart configuration script. A second installation unit for, if the number of the devices to be installed is not less than the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network, performing system installation on each of the devices to be installed by combining the Preboot eXecution Environment (PXE) installation method and the Baseboard Management Controller (BMC) installation method. Among them, select the devices to be installed with the same number as the number of Dynamic Host Configuration Protocol (DHCP) IP addresses in the current network and perform system installation using the Preboot eXecution Environment (PXE) installation method, and perform system installation on the remaining devices to be installed using the BMC installation method.
6. The device according to claim 5, characterized in that The configuration unit includes: A judgment subunit for, for each device to be installed, judging whether the device to be installed is in a preset memory operating system compatibility list based on the device information. A first call subunit for, if it is judged that the device to be installed is in the preset memory operating system compatibility list, calling the memory operating system configuration module to configure the Redundant Array of Independent Disks (RAID), the IP address of the Baseboard Management Controller, and the user information of the Baseboard Management Controller for the device to be installed. A second call subunit for, if it is judged that the device to be installed is not in the preset memory operating system compatibility list, calling the Baseboard Management Controller (BMC) installation module to configure the Redundant Array of Independent Disks (RAID) for the device to be installed, and calling the memory operating system configuration module to configure the IP address of the Baseboard Management Controller and the user information of the Baseboard Management Controller for the device to be installed.
7. The device according to claim 5, characterized in that, The second installation unit includes: An acquisition subunit for acquiring the installation priorities of each of the devices to be installed. A sorting subunit for sorting each of the devices to be installed according to the installation priorities. The first installation subunit is used to install the devices to be installed with the top N installation priorities through the pre-boot execution environment installation method; where N is equal to the number of Dynamic Host Configuration Protocol IP addresses under the current network; The second installation subunit is used to install the devices to be installed after the top N installation priorities through the baseboard management controller installation method.
8. The device according to claim 5, characterized in that It further includes: A log generation unit for generating configuration logs of the devices to be installed.
9. An electronic device, characterized in that, It includes: One or more processors; A storage device on which one or more programs are stored; When the one or more programs are executed by the one or more processors, the one or more processors are caused to implement the method according to any one of claims 1 to 4.
10. A computer storage medium, characterized in that, A computer program is stored thereon, wherein when the computer program is executed by a processor, the method according to any one of claims 1 to 4 is implemented.
Citation Information
Patent Citations
Method and device for configuring IP address of BMC
CN106657444A
Method and apparatus for remotely mounting operating system of node
CN107341036A