Server deployment method, system, equipment, device and medium
By using the first operating system to collect hardware information in the server deployment method to generate a configuration table, and combined with the pre-start execution environment installation configuration files, personalized deployment and installation of each server is achieved, and the consumption caused by the fixed configuration file during PXE configuration is solved. There was an error problem, which improved installation efficiency and accuracy.
Patent Information
- Application Number
- CN202411498875.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-25
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2044-10-25
AI Technical Summary
In the pre-start execution environment (PXE) stage, due to the large differences in the deployment configuration information of each server, the configuration file is fixed. Automatically installing the same configuration file cannot distinguish the individual configuration information of each server. The configuration process is time-consuming and error-prone. Reduce configuration efficiency.
Provide a server deployment method, including pre-deploying the first operating system to be installed server, collecting hardware information and generating configuration tables, restarting the server for pre-starting execution environment installation, generating installation configuration files, and comparing the installation configuration files with the configuration table , obtain the corresponding deployment files for each server to achieve personalized deployment and installation.
Through two boots, we can achieve a high degree of personalization and adaptation of system configuration, avoid the inability to distinguish and time-consuming errors caused by configuration file fixation, improve installation efficiency and accuracy, and realize an intelligent and personalized server operating system Installation process.
Smart Images

Figure CN119415163A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of server deployment, and in particular to a server deployment method, system, equipment, device and medium. Background Art
[0002] Preboot Execution Environment (PXE) is a technology that allows computers to boot operating systems over the network without the need for local storage devices. It is integrated into the computer's Basic Input / Output System (BIOS) or Unified Extensible Firmware Interface (UEFI), allowing computers to download and boot operating systems or other software from a network server.
[0003] In the PXE stage, due to the different types of servers, their corresponding deployment configuration information varies greatly. However, during the PXE configuration process, the configuration file is fixed, and the same installation result is obtained by automatically installing the same configuration file. The individual configuration information corresponding to each server cannot be distinguished, and the configuration process is even time-consuming and prone to errors, reducing configuration efficiency.
[0004] Therefore, how to implement personalized configuration of each server to improve the configuration quality is an urgent problem to be solved by those skilled in the art. Summary of the invention
[0005] The purpose of the present invention is to provide a server deployment method, system, equipment, device and medium to solve the problem that the configuration files of various servers are the same and the individual configuration information cannot be distinguished, resulting in a time-consuming and error-prone configuration process.
[0006] In order to solve the above technical problems, the present invention provides a server deployment method, comprising:
[0007] Pre-deploy a first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs;
[0008] Generate a configuration table according to the configuration information returned by each of the servers to be installed;
[0009] Restarting each of the servers to be installed, and performing a pre-startup execution environment installation on the second operating system of each of the servers to be installed to generate an installation configuration file;
[0010] The installation configuration file is compared with the configuration table to obtain a deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed.
[0011] On the one hand, after generating the configuration table and before restarting each of the servers to be installed, the method further includes:
[0012] Obtaining initial configuration information corresponding to each of the servers to be installed;
[0013] Comparing the configuration information of the configuration table with the initial configuration information;
[0014] If the configuration information in the configuration table is the same as the initial configuration information, the process proceeds to the step of restarting each of the servers to be installed.
[0015] On the other hand, after generating the configuration table, the method further includes:
[0016] Obtaining first configuration information after running in the first operating system according to the hardware information of each server to be installed;
[0017] Comparing the configuration information of the configuration table with the first configuration information;
[0018] If the configuration information of the configuration table is different from the first configuration information, marking the different configuration information of the configuration table; and determining that the marked configuration information corresponds to the hardware information of the server to be installed that fails;
[0019] Determine whether the hardware information of the server to be installed corresponding to the failure is key hardware information of the business scenario corresponding to the server to be installed;
[0020] If it is critical hardware information, the server to be installed is marked as a faulty server;
[0021] If it is not critical hardware information, the critical hardware information is marked, and the process proceeds to the step of restarting each of the servers to be installed, and the configuration information of the critical hardware information corresponding to the generated installation configuration file is not compared.
[0022] On the other hand, after generating the configuration table and before restarting each of the servers to be installed, the method further includes:
[0023] The first operating system is deleted from the memory corresponding to each of the servers to be installed, so as to proceed to the step of restarting each of the servers to be installed.
[0024] On the other hand, the comparison of the installation configuration file with the configuration table to obtain the deployment file corresponding to each of the servers to be installed includes:
[0025] The configuration information corresponding to the installation configuration file and the configuration table is classified in advance to obtain a first common type and a second personalized type; wherein the configuration information of the first common type is the basic configuration information of all servers to be installed; and the configuration information of the second personalized type is the personalized configuration information corresponding to each server to be installed;
[0026] Determine whether the configuration information corresponding to the first common type of the installation configuration file and the first common type of the configuration table are the same;
[0027] If the configuration information corresponding to the first common type of the installation configuration file and the first common type of the configuration table are the same, determining whether the configuration information of the second personality type of the installation configuration file and the second personality type of the configuration table are the same;
[0028] If the second personality type of the installation configuration file is the same as the configuration information of the second personality type of the configuration table, determining to use the configuration information of the second personality type of the installation configuration file as the deployment file of the current server to be installed;
[0029] If the second personality type of the installation configuration file is different from the configuration information of the second personality type of the configuration table, judging whether it is the key configuration information of the current server to be installed according to the configuration information of the different second personality type;
[0030] If it is not the key configuration information of the server to be installed currently, the configuration information of the second personality type of the installation configuration file is used as the deployment file of the server to be installed currently.
[0031] On the other hand, before performing a pre-startup execution environment installation on the second operating system of each server to be installed to generate an installation configuration file, the method further includes:
[0032] The host configuration protocol service, the file transfer protocol service and the file service deployed with the startup execution environment are concentrated in a deployment server in advance;
[0033] Add mainstream image open source driver files and image files to the deployment server.
[0034] In order to solve the above technical problems, the present invention also provides a cluster system, including a deployment server and servers to be installed;
[0035] The deployment server is used to pre-deploy the first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs; generating a configuration table according to the configuration information returned by each server to be installed; restarting each server to be installed, and performing a pre-start execution environment installation on the second operating system of each server to be installed to generate an installation configuration file; comparing the installation configuration file with the configuration table to obtain a deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed;
[0036] The server to be installed is used to receive deployment and installation instructions and perform deployment and installation according to the corresponding deployment file.
[0037] In order to solve the above technical problems, the present invention further provides a server deployment device, comprising:
[0038] A first deployment module, used to pre-deploy a first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs;
[0039] A generating module, used for generating a configuration table according to the configuration information returned by each of the servers to be installed;
[0040] A restart module, used for restarting each of the servers to be installed, and performing a pre-start execution environment installation on the second operating system of each of the servers to be installed to generate an installation configuration file;
[0041] The second deployment module is used to compare the installation configuration file with the configuration table to obtain the deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed.
[0042] In order to solve the above technical problems, the present invention further provides a server deployment device, comprising:
[0043] Memory for storing computer programs;
[0044] A processor is used to implement the steps of the server deployment method as described above when executing the computer program.
[0045] In order to solve the above technical problems, the present invention also provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the server deployment method as described above are implemented. The present invention provides a server deployment method, which pre-deploys a first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs; generates a configuration table according to the configuration information returned by each server to be installed; restarts each server to be installed, and performs a pre-start execution environment installation on the second operating system of each server to be installed to generate an installation configuration file; compares the installation configuration file with the configuration table to obtain a deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed.
[0046] The beneficial effect of the present invention is that the system configuration is highly personalized and adaptive through two boots. The first boot is to deploy a streamlined first operating system that retains the basic functions of the server, so as to automatically generate a configuration table based on the management node that provides PXE services. The configuration table is compared with the configuration file under the actual second operating system (formal operating system) in the subsequent boot to generate a personalized deployment file composed of the installation configuration of each server to be installed. The deployment file has different execution conditions corresponding to each server to be installed, so as to realize the personalization of server deployment. It avoids the problem of time-consuming errors caused by the inability to distinguish separate configuration information or even the occurrence of fixed configuration files in the PXE configuration process, improves installation efficiency and accuracy, and also realizes an intelligent and personalized server operating system installation process.
[0047] Secondly, the configuration information of the configuration table is compared with the initial configuration information. The first comparison is performed before restarting each server to be installed, and the accuracy of the configuration information of the current configuration table generated by the first operating system is verified in advance, so as to improve the accuracy during the comparison with the installation deployment file under the subsequent formal operating system. The first configuration information generated after the first operating system is running is compared with the configuration information of the configuration table generated when the first operating system is running, ensuring a preliminary comparison of the current configuration information to improve the accuracy of the configuration table. The configuration information of the installation configuration file and the configuration table is divided into a first common type and a second personalized type. When the configuration information of the first common type is the same, the key configuration information of the configuration information of the second personalized type is continued to be compared, so that the comparison accuracy of the server to be installed can be clearly known, and the accuracy of the personalized configuration can be improved. The three types of services are integrated in one deployment server to improve the simplicity and automation of the configuration, while improving the efficiency of configuration installation.
[0048] In addition, the present invention also provides a cluster system, server deployment equipment, device and medium, which have the same beneficial effects as the above-mentioned server deployment method. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] In order to more clearly illustrate the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0050] Figure 1 A flow chart of a server deployment method provided by an embodiment of the present invention;
[0051] Figure 2 An architecture diagram of a cluster system provided by an embodiment of the present invention;
[0052] Figure 3 A schematic diagram of interaction between a deployment server and a server to be installed provided in an embodiment of the present invention;
[0053] Figure 4 A structural diagram of a server deployment device provided by an embodiment of the present invention;
[0054] Figure 5 A structural diagram of a server deployment device provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0055] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0056] The core of the present invention is to provide a server deployment method, system, equipment, device and medium to solve the problem that the configuration files of various servers are the same and the individual configuration information cannot be distinguished, resulting in a time-consuming and error-prone configuration process.
[0057] In order to enable those skilled in the art to better understand the solution of the present invention, the present invention is further described in detail below in conjunction with the accompanying drawings and specific implementation methods.
[0058] PXE is an important remote boot protocol that allows administrators to remotely boot servers and install and configure operating systems over the network. PXE can improve deployment efficiency, reduce human errors, save time and costs, and greatly simplify the process of server deployment and maintenance. With the rapid development of cloud computing and data centers, automated installation technology has become the key to improving efficiency.
[0059] In a server cluster system, including PXE deployment servers and other servers to be installed, there is no limit on the number of PXE deployment servers, which can be one or more. In addition, there is usually more than one type of server to be installed, and there may be management nodes, computing nodes, storage nodes, etc. The corresponding computing nodes may be central processing units (CPU) or graphics processing units (GPU), etc. The hardware between each node may be greatly different, resulting in great differences in the final use, and the installation cannot be completed using only the same configuration file.
[0060] When multiple servers to be installed enter the PXE deployment workflow at the same time, they have the same automatic installation configuration file, which corresponds to the same installation result. It is difficult to distinguish the servers after installation, and the subsequent multiple servers forming a cluster need to be configured separately for each server, resulting in time-consuming and error-prone configuration processes. The server deployment method provided by the present invention can solve the above technical problems.
[0061] Figure 1 A flow chart of a server deployment method provided by an embodiment of the present invention, such as Figure 1 As shown, the method includes:
[0062] S11: pre-deploy a first operating system on each server to be installed;
[0063] The first operating system includes a function of collecting hardware information of the server to which it belongs;
[0064] S12: Generate a configuration table according to the configuration information returned by each server to be installed;
[0065] S13: restart each server to be installed, and perform a pre-start execution environment installation on the second operating system of each server to be installed to generate an installation configuration file;
[0066] S14: Compare the installation configuration file with the configuration table to obtain the deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed.
[0067] Specifically, the first operating system is different from the second operating system. The first operating system is a temporary operating system, and the second operating system is an inherent operating system. Compared with the inherent operating system (formal operating system) of the server, the temporary operating system is relatively streamlined and only retains some basic functions. It can be used to collect the hardware system of the server to be installed, such as: motherboard serial number, CPU, GPU, network card model, storage, etc. The first operating system usually refers to an operating system set up to meet certain short-term needs. It can be a physical server or a virtual server. This system does not require long-term operation and management, and is usually used for development and testing, temporary projects, emergency handling, or network load balancing. There are many ways to create the first operating system, including using cloud service providers, physical servers, or virtualization technology. The operational process of building a temporary server usually includes determining needs, selecting a suitable cloud service provider or virtualization software, creating a server instance or virtual machine, configuring network and security settings, installing and configuring software, testing server functions, and using and maintaining the server. The first operating system can also be quickly deployed through some tools and services, and its selection and management need to consider the purpose, configuration requirements, storage capacity, etc. of the server.
[0068] The purpose of pre-deploying the first operating system on each server to be installed is to quickly start a temporary, disposable computing environment so as to obtain the configuration table. The hardware information is transmitted back to the management node that provides the PXE service, that is, the deployment server, and the configuration table is automatically generated according to the returned configuration information. The configuration information here is generated by the first operating system. The configuration table includes automatic installation configuration such as serial number, host name, user password, network information (such as Internet Protocol (IP), Domain Name System (DNS), etc.), storage allocation information and required driver information (such as GPU, server interconnect processing (Infini Band, IB) card, etc.).
[0069] Step S13 restarts each server to be installed, performs PXE installation under the second operating system of each server to be installed to generate an installation configuration file, and compares and screens the installation configuration file and the configuration table to determine the personalized configuration deployment file corresponding to each server to be installed, so as to perform accurate and personalized installation. The corresponding installation configuration file is the same as the conventional configuration installation process, which is not limited here.
[0070] In traditional PXE deployment, the following workflow is usually followed:
[0071] 1. The server to be installed will automatically enter the network installation state when the bare metal is started, or it will enter the network installation state through the BIOS, Baseboard Management Controller (BMC), etc. At this time, the PXE-supported network card will send a DHCP request to the Dynamic Host Configuration Protocol Service (DHCP) server (usually the PXE deployment server) in the network to obtain the IP address and other network configuration information.
[0072] 2. After receiving the request, the DHCP server will send a DHCP response to the server to be installed. This response contains network configuration information such as IP address, subnet mask, gateway, as well as the IP address of the PXE deployment server and the boot file name (such as bootx64.efi).
[0073] 3. After receiving the DHCP response, the server to be installed will send a TFTP request to the PXE deployment server to download the boot file. The boot file requested to be downloaded is usually a PXE bootloader. The PXE bootloader is a specific software, usually located on the PXE server, used to help the computer complete the boot process in a network environment.
[0074] 4. The PXE deployment server responds to the Trivial File Transfer Protocol Service (TFTP) request of the server to be installed and transfers the boot file to the server to be installed.
[0075] 5. After the server to be installed successfully downloads the boot file, it will load the file and execute the program in it, thereby starting the process of remotely booting the operating system. During the boot process, the server to be installed will download the installation image and configuration file from the PXE deployment server. The content of the configuration file is to replace the steps that need to be manually entered in the installation interface during the manual installation process.
[0076] The comparison and screening in step S14 stores the information of all servers to be installed in a configuration table, and compares and screens the unique installation configuration files of each server to be installed with the configuration information in the configuration table to find the corresponding deployment files in each server to be installed for subsequent deployment and installation loading. The comparison and screening here can be performed one by one based on the installation configuration files, or the basic configuration information of the installation configuration files can be compared with the basic configuration information in the configuration table. If the comparison is successful, it means that the basic configuration information of the server is common in the subsequent deployment and installation, and then the individual configuration information of each server to be installed (different from the configuration information of other servers to be installed) is further refined for comparison. If the comparison is successful, the configuration information that has been successfully compared is used as the current deployment file to facilitate the subsequent deployment and installation of the server to be installed.
[0077] The embodiment of the present invention provides a server deployment method, which pre-deploys a first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs; generates a configuration table according to the configuration information returned by each server to be installed; restarts each server to be installed, and performs a pre-start execution environment installation on the second operating system of each server to be installed to generate an installation configuration file; compares the installation configuration file with the configuration table to obtain a deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed. High personalization and adaptability of system configuration are achieved through two boots, the first boot is to deploy a streamlined first operating system that retains the basic functions of the server, so as to automatically generate a configuration table based on the management node that returns to provide PXE services, and the configuration table is compared with the configuration file under the actual second operating system (formal operating system) in the subsequent boot to generate a personalized deployment file composed of the installation configuration of each server to be installed, and the execution status of the deployment file is different for each server to be installed, so as to realize the personalization of server deployment. The problem of individual configuration information being unable to be distinguished or even time-consuming errors caused by the fixed configuration file in the PXE configuration process is avoided, the installation efficiency and accuracy are improved, and the installation process of the intelligent and personalized server operating system is also realized. In some embodiments, after generating the configuration table and before restarting each server to be installed, the process further includes:
[0078] Obtain the initial configuration information corresponding to each server to be installed;
[0079] Compare the configuration information in the configuration table with the initial configuration information;
[0080] If the configuration information in the configuration table is the same as the initial configuration information, proceed to the step of restarting each server to be installed.
[0081] Specifically, the initial configuration information can be configuration information provided by the manufacturer or manually counted configuration information. In this embodiment, the configuration information of the configuration table is compared with the initial configuration information. The first comparison is performed before restarting each server to be installed to verify in advance the accuracy of the configuration information of the current configuration table generated by the first operating system, so as to improve the accuracy during the comparison with the installation deployment file under the subsequent formal operating system.
[0082] In some embodiments, after generating the configuration table, the method further includes:
[0083] Obtaining first configuration information after running in the first operating system according to the hardware information of each server to be installed;
[0084] Comparing the configuration information in the configuration table with the first configuration information;
[0085] If the configuration information of the configuration table is different from the first configuration information, the configuration information of the different configuration table is marked; and it is determined that the hardware information of the server to be installed corresponding to the marked configuration information fails;
[0086] Determine whether the hardware information of the server to be installed corresponding to the failure is key hardware information of the business scenario corresponding to the server to be installed;
[0087] If it is critical hardware information, the server to be installed will be marked as a faulty server;
[0088] If it is not critical hardware information, the critical hardware information is marked, and the process proceeds to the step of restarting the server to be installed, and the configuration information of the critical hardware information corresponding to the generated installation configuration file is not compared.
[0089] Specifically, this embodiment is different from the above embodiment in the comparison of configuration information after generating the configuration table. The first configuration information in this embodiment is obtained after running under the first operating system. The configuration information of the configuration table is to collect the hardware information of the node to be installed, which is generated in the deployment and operation process of the first operating system, such as the pre-configuration stage, and the configuration parameters are defined before starting the first operating system. When the first operating system starts, its resource usage, network configuration, and installed software packages are automatically detected and recorded. In this embodiment, the first configuration information is obtained after running under the first operating system, and the configuration information of the configuration table is compared with the first configuration information. If different, the configuration information of the different configuration table is marked, and it is determined that the hardware information corresponding to the marked configuration information fails. In order to ensure whether the key hardware information of the subsequent business scenario corresponding to the server to be installed is the hardware information that fails, if so, it means that the server to be installed has failed and cannot be deployed and installed subsequently. If it is not key hardware information, it is necessary to mark the key hardware information, and the configuration information of the key hardware information does not need to be compared in the subsequent installation configuration file to ignore the configuration information of the key hardware information.
[0090] The first configuration information generated after the first operating system provided in this embodiment is run is compared with the configuration information of the configuration table generated when the first operating system is run, ensuring a preliminary comparison of the current configuration information to improve the accuracy of the configuration table.
[0091] In some embodiments, after generating the configuration table and before restarting each server to be installed, the process further includes:
[0092] The first operating system is deleted from the memory corresponding to each server to be installed, so as to enter the step of restarting each server to be installed.
[0093] In order to reduce the space occupied by the server, the memory of each server to be installed is deleted when the first operating system is not needed, thereby improving the utilization rate of subsequent memory.
[0094] In some embodiments, the installation configuration file and the configuration table are compared to obtain the deployment files corresponding to each server to be installed, including:
[0095] The configuration information corresponding to the installation configuration file and the configuration table is classified in advance to obtain a first common type and a second individual type; wherein the configuration information of the first common type is the basic configuration information of all servers to be installed; and the configuration information of the second individual type is the individual configuration information corresponding to each server to be installed;
[0096] Determine whether the configuration information corresponding to the first common type of the installation configuration file and the first common type of the configuration table are the same;
[0097] If the configuration information corresponding to the first common type of the installation configuration file and the first common type of the configuration table are the same, then determining whether the configuration information of the second personality type of the installation configuration file and the second personality type of the configuration table are the same;
[0098] If the configuration information of the second personality type of the installation configuration file is the same as the configuration information of the second personality type of the configuration table, determining to use the configuration information of the second personality type of the installation configuration file as the deployment file of the current server to be installed;
[0099] If the configuration information of the second personality type of the installation configuration file is different from the configuration information of the second personality type of the configuration table, judging whether it is the key configuration information of the current server to be installed according to the configuration information of the different second personality type;
[0100] If it is not the key configuration information of the server to be installed currently, the configuration information of the second personality type of the installation configuration file is used as the deployment file of the server to be installed currently.
[0101] Specifically, in this embodiment, the configuration information corresponding to the installation configuration file and the configuration table is divided into two categories, a first common type and a second individual type. The first common type is used to configure the basic configuration information of all servers to be installed, and the second individual type is used for the individual configuration information corresponding to each server to be installed. It should be noted that the configuration information of the first common type is the same and universal in all servers to be installed. The configuration information corresponding to the second individual type is different for each server to be installed.
[0102] First, compare the configuration information of the first common type of the installation configuration file and the first common type of the configuration table. If they are the same, it means that the configuration information of each server to be installed is compatible and can be installed normally. Continue to determine whether the configuration information of the second personality type of the installation configuration file is the same as the configuration information of the second personality type of the configuration table. If they are the same, it means that the second personality type of the installation configuration file and the configuration information of the second personality type corresponding to the server to be installed in the configuration table are the same, which can trigger subsequent deployment and installation. If they are different, it is necessary to check whether the configuration information of the second personality type is the key configuration information of the current server to be installed. If not, it means that the business scenario corresponding to the deployment file of the current server to be installed does not need to pay attention to the key configuration information, resulting in the difference of the key configuration information does not affect the deployment and installation of the current server to be installed. If so, it needs to be put on hold temporarily. You can try to compare again, or you can directly report a repair. There is no limitation here, and you can set it according to the actual situation.
[0103] The configuration information of the installation configuration file and configuration table provided in this embodiment is divided into a first common type and a second personalized type. When the configuration information of the first common type is the same, the key configuration information of the configuration information of the second personalized type continues to be compared, so as to clearly know the comparison accuracy of the server to be installed and improve the accuracy of the personalized configuration.
[0104] In other embodiments, the installation configuration file and the configuration table are compared to obtain the deployment files corresponding to each server to be installed, including:
[0105] Obtain the characteristic configuration information corresponding to the installation configuration file of the current server to be installed;
[0106] The configuration information in the configuration table is filtered according to the characteristic configuration information to determine the deployment file of the current server to be installed.
[0107] It should be noted that the characteristic configuration information is based on the personalized characteristic parameters of the current server to be installed, which is different from the configuration information of other servers to be installed. Based on the characteristic configuration information, the configuration information in the configuration table is screened to determine the deployment file of the current server to be installed. The screening process here can be screened according to the feature extraction algorithm, or it can be screened and determined one by one, which can be set according to the actual situation.
[0108] The deployment file obtained by screening based on the characteristic configuration information provided in this embodiment can accurately determine the personalized deployment file of the current server to be installed, so as to simplify the screening process and improve the accuracy of the deployment file.
[0109] In some embodiments, before performing a pre-boot execution environment installation on the second operating system of each server to be installed to generate an installation configuration file, the method further includes:
[0110] The host configuration protocol service, the file transfer protocol service and the file service deployed with the startup execution environment are concentrated in a deployment server in advance;
[0111] Add mainstream image open source driver files and image files to the deployment server.
[0112] It should be noted that the PXE deployment server requires a host configuration protocol service (such as Dynamic Host Configuration Protocol Service (DHCP)), a file transfer protocol service (such as Trivial File Transfer Protocol Service (TFTP)) and a file service (such as Hypertext Transfer Protocol (HTTP), Network File System (NFS) and File Transfer Protocol (FTP), etc.), which are conventionally distributed on different deployment servers, resulting in the three types of servers required to be installed and configured separately, which is prone to configuration errors or incompatibility between software, incompatibility between software and system, etc. In addition. PXE deployment also requires multiple files, some of which need to be downloaded from the Internet, and some of which need to be manually written. Therefore, in this embodiment, the three services are located on one PXE deployment server. Figure 2 An architecture diagram of a cluster system provided by an embodiment of the present invention, such as Figure 2 As shown, the three services are combined together, and mainstream image open source drivers are added. One-click configuration can be achieved without manually configuring multiple services and downloading additional image drivers. Multiple servers to be installed are represented by 1' to n'.
[0113] The three types of services provided in this embodiment are integrated into one deployment server, thereby improving the simplicity and automation of configuration, and at the same time improving the efficiency of configuration and installation.
[0114] Figure 3 A schematic diagram of interaction between a deployment server and a server to be installed provided in an embodiment of the present invention, such as Figure 3 As shown, the deployment server receives a dynamic host configuration protocol service request sent by the server to be installed, and the deployment server responds to the network configuration request to perform subsequent network configuration. The deployment server receives a simple file transfer protocol service request sent by the server to be installed to download the boot file, and the deployment server responds to the request to transfer the boot file. The deployment server receives the boot program sent by the server to be installed and requests the files required for installation. Here, automatic installation configuration needs to be performed according to the deployment file generated by the personalized configuration table.
[0115] Furthermore, the present invention also provides a cluster system, including a deployment server and servers to be installed;
[0116] A deployment server is used to pre-deploy a first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs; generating a configuration table according to the configuration information returned by each server to be installed; restarting each server to be installed, and performing a pre-start execution environment installation on the second operating system of each server to be installed to generate an installation configuration file; comparing the installation configuration file with the configuration table to obtain a deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed;
[0117] The server to be installed is used to receive deployment and installation instructions and perform deployment and installation according to the corresponding deployment files.
[0118] like Figure 2 As shown, different servers correspond to different functions. In this embodiment, the deployment work is performed through the deployment server and the servers to be installed.
[0119] For an introduction to a cluster system provided by the present invention, please refer to the above method embodiment, which will not be described in detail herein. It has the same beneficial effects as the above server deployment method.
[0120] The above describes in detail various embodiments corresponding to the server deployment method. On this basis, the present invention also discloses a server deployment device corresponding to the above method. Figure 4 The structure diagram of a server deployment device provided by an embodiment of the present invention. Figure 4 As shown, the server deployment equipment includes:
[0121] The first deployment module 11 is used to pre-deploy the first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs;
[0122] A generating module 12, used to generate a configuration table according to the configuration information returned by each server to be installed;
[0123] A restart module 13, used to restart each server to be installed, and perform a pre-start execution environment installation on the second operating system of each server to be installed to generate an installation configuration file;
[0124] The second deployment module 14 is used to compare the installation configuration file with the configuration table to obtain the deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed.
[0125] Since the embodiments of the device part correspond to the above embodiments, please refer to the description of the embodiments of the method part for the embodiments of the device part, and will not be repeated here.
[0126] For an introduction to a server deployment device provided by the present invention, please refer to the above method embodiment, and the present invention will not be repeated here. It has the same beneficial effects as the above server deployment method.
[0127] Figure 5 A structural diagram of a server deployment device provided by an embodiment of the present invention, such as Figure 5 As shown, the device comprises:
[0128] A memory 21, used for storing computer programs;
[0129] The processor 22 is used to implement the steps of the server deployment method when executing the computer program.
[0130] The server deployment device provided in this embodiment may include but is not limited to a smart phone, a tablet computer, a laptop computer, or a desktop computer.
[0131] Among them, the processor 22 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 22 can be implemented in at least one hardware form of a digital signal processor (DSP), a field-programmable gate array (FPGA), and a programmable logic array (PLA). The processor 22 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a CPU; the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 22 may be integrated with a GPU, which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 22 may also include an artificial intelligence (AI) processor, which is used to process computing operations related to machine learning.
[0132] The memory 21 may include one or more computer-readable storage media, which may be non-transitory. The memory 21 may also include a high-speed random access memory, and a non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In this embodiment, the memory 21 is at least used to store the following computer program 211, wherein, after the computer program is loaded and executed by the processor 22, the relevant steps of the server deployment method disclosed in any of the aforementioned embodiments can be implemented. In addition, the resources stored in the memory 21 may also include an operating system 212 and data 213, etc., and the storage method may be temporary storage or permanent storage. Among them, the operating system 212 may include Windows, Unix, Linux, etc. The data 213 may include, but is not limited to, data involved in the server deployment method, etc.
[0133] In some embodiments, the server deployment device may further include a display screen 23 , an input / output interface 24 , a communication interface 25 , a power supply 26 , and a communication bus 27 .
[0134] Those skilled in the art can understand that Figure 5 The structure shown in the figure does not constitute a limitation on the server deployment device, and may include more or fewer components than shown in the figure.
[0135] The processor 22 implements the server deployment method provided by any of the above embodiments by calling the instructions stored in the memory 21.
[0136] For an introduction to a server deployment device provided by the present invention, please refer to the above method embodiment, and the present invention will not be repeated here. It has the same beneficial effects as the above server deployment method.
[0137] Furthermore, the present invention also provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by the processor 22, the steps of the above-mentioned server deployment method are implemented.
[0138] It is understandable that if the method in the above embodiment is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium to execute all or part of the steps of the methods of each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program codes.
[0139] For an introduction to a computer-readable storage medium provided by the present invention, please refer to the above method embodiment, and the present invention will not be repeated here. It has the same beneficial effects as the above server deployment method.
[0140] Furthermore, the present invention also provides a computer program product, including a computer program / instruction, which implements the steps of the server deployment method when executed by a processor.
[0141] For an introduction to a computer program product provided by the present invention, please refer to the above method embodiment, and the present invention will not be repeated here. It has the same beneficial effects as the above server deployment method.
[0142] The efficiency of large-scale cluster operating system deployment is greatly increased. The cluster network can be planned in advance and configured in one step, and additional drivers can also be installed with the operating system. A PXE deployment test was carried out using the technical solution of the present invention. In the test, a PXE deployment server and 200 bare metal servers to be installed were used. After the PXE deployment server started the service, the node to be installed was started. After 21 minutes and 32 seconds of installation, the 200 servers began to restart. The installation success rate reached 100%. After the restart, the connectivity test of the 200 servers was subsequently carried out to verify the correctness of their network configuration. In addition, the system environment of the 200 servers was checked to confirm that their personalized configuration had successfully taken effect. This series of test results show that the technical solution of the present invention performs well in the PXE deployment process and provides a reliable solution for the personalized installation of large-scale server operating systems.
[0143] The above is a detailed introduction to a server deployment method, system, equipment, device and medium provided by the present invention. The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same and similar parts between the embodiments can be referenced to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part description. It should be pointed out that for ordinary technicians in this technical field, without departing from the principle of the present invention, the present invention can also be improved and modified in several ways, and these improvements and modifications also fall within the scope of protection of the present invention.
[0144] It should also be noted that, in this specification, relational terms such as first and second, etc. are used only 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. Moreover, the terms "comprises", "comprising" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device including the element.
Claims
1. A server deployment method, characterized in that: include: Pre-deploy a first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs; Generate a configuration table according to the configuration information returned by each of the servers to be installed; Restarting each of the servers to be installed, and performing a pre-startup execution environment installation on the second operating system of each of the servers to be installed to generate an installation configuration file; The installation configuration file is compared with the configuration table to obtain a deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed.
2. The server deployment method according to claim 1, characterized in that: After generating the configuration table and before restarting each of the servers to be installed, the method further includes: Obtaining initial configuration information corresponding to each of the servers to be installed; Comparing the configuration information of the configuration table with the initial configuration information; If the configuration information in the configuration table is the same as the initial configuration information, the process proceeds to the step of restarting each of the servers to be installed.
3. The server deployment method according to claim 2, characterized in that: After generating the configuration table, the method further includes: Obtaining first configuration information after running in the first operating system according to the hardware information of each server to be installed; Comparing the configuration information of the configuration table with the first configuration information; If the configuration information of the configuration table is different from the first configuration information, marking the different configuration information of the configuration table; and determining that the marked configuration information corresponds to the hardware information of the server to be installed that fails; Determine whether the hardware information of the server to be installed corresponding to the failure is key hardware information of the business scenario corresponding to the server to be installed; If it is critical hardware information, the server to be installed is marked as a faulty server; If it is not critical hardware information, the critical hardware information is marked, and the process proceeds to the step of restarting each of the servers to be installed, and the configuration information of the critical hardware information corresponding to the generated installation configuration file is not compared.
4. The server deployment method according to claim 2, characterized in that: After generating the configuration table and before restarting each of the servers to be installed, the method further includes: The first operating system is deleted from the memory corresponding to each of the servers to be installed, so as to proceed to the step of restarting each of the servers to be installed.
5. The server deployment method according to claim 1, characterized in that: The step of comparing the installation configuration file with the configuration table to obtain the deployment files corresponding to the servers to be installed includes: The configuration information corresponding to the installation configuration file and the configuration table is classified in advance to obtain a first common type and a second personalized type; wherein the configuration information of the first common type is the basic configuration information of all servers to be installed; and the configuration information of the second personalized type is the personalized configuration information corresponding to each server to be installed; Determine whether the configuration information corresponding to the first common type of the installation configuration file and the first common type of the configuration table are the same; If the configuration information corresponding to the first common type of the installation configuration file and the first common type of the configuration table are the same, determining whether the configuration information of the second personality type of the installation configuration file and the second personality type of the configuration table are the same; If the second personality type of the installation configuration file is the same as the configuration information of the second personality type of the configuration table, determining to use the configuration information of the second personality type of the installation configuration file as the deployment file of the current server to be installed; If the second personality type of the installation configuration file is different from the configuration information of the second personality type of the configuration table, judging whether it is the key configuration information of the current server to be installed according to the configuration information of the different second personality type; If it is not the key configuration information of the server to be installed currently, the configuration information of the second personality type of the installation configuration file is used as the deployment file of the server to be installed currently.
6. The server deployment method according to claim 1, characterized in that: Before performing a pre-startup execution environment installation on the second operating system of each server to be installed to generate an installation configuration file, the method further includes: The host configuration protocol service, the file transfer protocol service and the file service deployed with the startup execution environment are concentrated in a deployment server in advance; Add mainstream image open source driver files and image files to the deployment server.
7. A cluster system, characterized in that: Including deployment server and servers to be installed; The deployment server is used to pre-deploy the first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs; generating a configuration table according to the configuration information returned by each server to be installed; restarting each server to be installed, and performing a pre-start execution environment installation on the second operating system of each server to be installed to generate an installation configuration file; comparing the installation configuration file with the configuration table to obtain a deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed; The server to be installed is used to receive deployment and installation instructions and perform deployment and installation according to the corresponding deployment file.
8. A server deployment device, characterized in that: include: A first deployment module, used to pre-deploy a first operating system on each server to be installed; wherein the first operating system includes a function of collecting hardware information of the server to which it belongs; A generating module, used for generating a configuration table according to the configuration information returned by each of the servers to be installed; A restart module, used for restarting each of the servers to be installed, and performing a pre-start execution environment installation on the second operating system of each of the servers to be installed to generate an installation configuration file; The second deployment module is used to compare the installation configuration file with the configuration table to obtain the deployment file corresponding to each server to be installed, so as to deploy and install each server to be installed.
9. A server deployment device, characterized in that: include: Memory for storing computer programs; A processor, configured to implement the steps of the server deployment method according to any one of claims 1 to 6 when executing the computer program.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the server deployment method according to any one of claims 1 to 6 are implemented.
Citation Information
Patent Citations
One-key deployment method and device for cloud system
CN103458002A
Method for server cluster system network test
CN104639402A
System configuration information processing method and device
CN110334248A
Automatic deployment method and system for large-scale test bed nodes
CN111786810A
Whole cabinet server use environment deployment method, device, equipment and medium
CN115291902A