A system installation method and related device

By setting the ghost image and the basic system image on the PXE server, and using the PXE protocol for automated installation, the problem of low ghost image installation efficiency in the existing technology is solved, and efficient system installation and batch updates are achieved.

CN112363737BActive Publication Date: 2024-09-17LANGCHAO ELECTRONIC INFORMATION IND CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202011346983.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-11-26
Publication Date
2024-09-17
Estimated Expiration
2040-11-26

AI Technical Summary

Technical Problem

Existing PXE installation technology cannot effectively install ghost images, resulting in low system installation efficiency. Especially in complex system update scenarios, it cannot cope with batch installation requirements, which increases labor costs and the probability of errors.

Method used

Set the ghost image and basic system image on the PXE server. The client sends an installation request to the server and downloads and installs the image through the PXE protocol to achieve unattended automated system installation.

Benefits of technology

It improves the efficiency of ghost image installation, reduces manual operations, reduces the probability of errors, and adapts to the batch installation requirements of complex system update scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112363737B
    Figure CN112363737B
Patent Text Reader

Abstract

The present application discloses a system installation method, including: a PXE client sends an installation request to a PXE server, so that the PXE server returns address information to the PXE client; wherein the PXE server is a server that has deployed a ghost image and a basic system image; when the PXE client selects a ghost image for installation, the ghost image and the basic system image are queried according to the address information; when the ghost image and the basic system image are queried, the system is installed according to the ghost image and the basic system image through the PXE protocol. The ghost image installation is implemented through the PXE server, and the efficiency of the ghost image installation is improved. The present application also discloses a system installation device, a server, and a computer-readable storage medium, which have the above beneficial effects.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a system installation method, a system installation device, a server, and a computer-readable storage medium. Background Art

[0002] With the continuous development of information technology, server equipment corresponding to computers is currently being used in more and more scenarios. Therefore, in the process of manufacturing computer servers, installing the system for computer equipment and server equipment has become an extremely important operation. Computer installation system is an important and tedious task in SIT (System Integration Testing). Usually, the system for installing several machines is installed by guiding the installation through a CD or USB flash drive. If the installation venue becomes a computer room with dozens or hundreds of machines or a factory production line to install the system, not only a large amount of consumables is required, but also the original technical work becomes repetitive physical labor. At the same time, when installing multiple machines, the installers need to operate and guard one by one, which greatly increases the probability of errors and labor costs.

[0003] In the related art, PXE (Preboot eXecution Environment) installation is generated, which is an unattended automatic installation technology that works in the Client / Server network mode, supports workstations to download images from remote servers through the network, and thus supports booting the operating system through the network. During the boot process, the terminal requires the server to allocate an IP address, and then uses TFTP (trivial file transfer protocol) or MTFTP (multicast trivial file transfer protocol, multicast trivial filetransfer protocol, multipoint simple file transfer protocol) protocol to download a startup software package to the local memory for execution. The startup software package completes the basic software settings of the terminal, thereby booting the terminal operating system pre-installed in the server. However, the existing PXE installation mainly has the problem of being unable to install ghost images. The system can only be installed in batches by copying the mother disk, but the mother disk copy method cannot cope with complex system update scenarios, resulting in reduced efficiency of system installation.

[0004] Therefore, how to improve the efficiency of ghost mirror system installation is a key issue that those skilled in the art are concerned about. Summary of the invention

[0005] The purpose of the present application is to provide a system installation method, a system installation device, a server and a computer-readable storage medium. By setting a ghost image and a corresponding basic system image on a PXE server, and then requesting the image data from the PXE server, the ghost image installation is realized through the PXE server, thereby improving the efficiency of the ghost image installation.

[0006] In order to solve the above technical problems, the present application provides a system installation method, comprising:

[0007] The PXE client sends an installation request to the PXE server, so that the PXE server returns address information to the PXE client; wherein the PXE server is a server on which a ghost image and a basic system image have been deployed;

[0008] When the PXE client selects the ghost image to install, querying the ghost image and the basic system image according to the address information;

[0009] When the ghost image and the basic system image are found, the system is installed according to the ghost image and the basic system image through the PXE protocol.

[0010] Optionally, also include:

[0011] When the ghost image and the basic system image cannot be found, the target directory is determined by all mounted directories and the directory name corresponding to each directory;

[0012] The ghost image and the basic system image are obtained from the target directory through the PXE protocol, and the system is installed.

[0013] Optionally, also include:

[0014] When the target directory cannot be determined, mounting the ghost image and the basic system image to a preset directory;

[0015] The ghost image and the basic system image are obtained from the preset directory through the PXE protocol, and the system is installed.

[0016] Optionally, performing system installation according to the ghost image and the basic system image through a PXE protocol includes:

[0017] Downloading the ghost image and the basic system image to the PXE client through the PXE protocol;

[0018] Perform system deployment and startup processing according to the basic system image to obtain a basic system;

[0019] The ghost image is subjected to system installation processing through the basic system.

[0020] The present application also provides a system installation device, comprising:

[0021] A request sending module, used for sending an installation request to a PXE server so that the PXE server returns address information to the PXE client; wherein the PXE server is a server on which a ghost image and a basic system image have been deployed;

[0022] An image query module, used for querying the ghost image and the basic system image according to the address information when the PXE client selects the ghost image installation;

[0023] The image installation module is used to perform system installation according to the ghost image and the basic system image through the PXE protocol when the ghost image and the basic system image are queried.

[0024] Optionally, also include:

[0025] A directory query module, used for determining a target directory through all mounted directories and the directory name corresponding to each directory when the ghost image and the basic system image cannot be found;

[0026] The directory image installation module is used to obtain the ghost image and the basic system image from the target directory through the PXE protocol and perform system installation.

[0027] Optionally, also include:

[0028] An image mounting module, used for mounting the ghost image and the basic system image to a preset directory when the target directory cannot be determined;

[0029] The mounting image installation module is used to obtain the ghost image and the basic system image from the preset directory through the PXE protocol and perform system installation.

[0030] Optionally, the image installation module includes:

[0031] An image data downloading unit, used for downloading the ghost image and the basic system image to the PXE client through the PXE protocol;

[0032] A basic system deployment unit, used to perform system deployment and startup processing according to the basic system image to obtain a basic system;

[0033] The ghost image installation unit is used to perform system installation processing on the ghost image through the basic system.

[0034] The present application also provides a server, comprising:

[0035] Memory for storing computer programs;

[0036] A processor is used to implement the steps of the system installation method as described above when executing the computer program.

[0037] The present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the system installation method described above are implemented.

[0038] A system installation method provided by the present application includes: a PXE client sends an installation request to a PXE server, so that the PXE server returns address information to the PXE client; wherein the PXE server is a server that has deployed a ghost image and a basic system image; when the PXE client selects a ghost image for installation, the ghost image and the basic system image are queried according to the address information; when the ghost image and the basic system image are queried, the system is installed according to the ghost image and the basic system image through the PXE protocol.

[0039] By setting both the ghost image and the corresponding basic system image on the PXE server and then requesting the image data from the PXE server, the ghost image installation is achieved through the PXE server, thereby improving the efficiency of the ghost image installation.

[0040] The present application also provides a system installation device, a server and a computer-readable storage medium, which have the above beneficial effects and are not elaborated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.

[0042] Figure 1 A flowchart of a system installation method provided in an embodiment of the present application;

[0043] Figure 2 A schematic diagram of the structure of a system installation device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0044] The core of this application is to provide a system installation method, a system installation device, a server and a computer-readable storage medium. By setting the ghost image and the corresponding basic system image on a PXE server, and then requesting the image data from the PXE server, the ghost image installation is realized through the PXE server, thereby improving the efficiency of the ghost image installation.

[0045] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0046] In the related technology, PXE installation is produced, which is an unattended automatic installation technology that works in the Client / Server network mode. It supports workstations to download images from remote servers through the network, and thus supports booting the operating system through the network. During the startup process, the terminal requires the server to allocate an IP address, and then uses the TFTP or MTFTP protocol to download a startup software package to the local memory for execution. This startup software package completes the basic software settings of the terminal, thereby booting the terminal operating system pre-installed in the server. However, the existing PXE installation mainly has the problem of being unable to install ghost images. The system can only be installed in batches by copying the master disk, but the master disk copy method cannot cope with complex system update scenarios, resulting in reduced efficiency of system installation.

[0047] Therefore, the present application provides a system installation method, which realizes ghost image installation through the PXE server by setting both the ghost image and the corresponding basic system image on the PXE server, and then requesting the image data from the PXE server, thereby improving the efficiency of ghost image installation.

[0048] The following describes a system installation method provided by the present application through an embodiment.

[0049] Please refer to Figure 1 , Figure 1 A flowchart of a system installation method provided in an embodiment of the present application.

[0050] In this embodiment, the method may include:

[0051] S101, a PXE client sends an installation request to a PXE server, so that the PXE server returns address information to the PXE client; wherein the PXE server is a server on which a ghost image and a basic system image have been deployed;

[0052] It can be seen that in this step, the PXE client mainly sends an installation request to the PXE server. Among them, the process of the PXE client sending the installation request to the PXE server is the process of the PXE client making a request to the PXE server in the prior art.

[0053] Among them, PXE, also known as the pre-execution environment, provides a mechanism for starting a computer using a network interface (NetworkInterface). This mechanism allows the computer to start without relying on local data storage devices or locally installed operating systems. The term PXE client refers to the role of the machine in the PXE boot process. A PXE client can be a server, desktop computer, laptop, or other machine with PXE boot code installed. The client's firmware receives an available PXE boot server and tries to find the PXE redirection service on the network. After analyzing the returned packet, the firmware asks the appropriate boot server for the path of the network self-test program (NBP), and downloads it to the computer's memory through the TFTP protocol, and may verify it and finally execute it.

[0054] Among them, the PXE server in this embodiment has been deployed with the ghost image and the basic system image. Among them, the ghost image is the system image file used by the ghost system when installing the system. The ghost system refers to the version of the ghost software that clones the image in the installed operating system. Usually, ghost is used for the backup of the operating system and for recovery when the system cannot start normally. The basic method of ghost working is different from other backup software. It operates a partition of the hard disk or the entire hard disk as an object, and can completely copy the object (including the hard disk partition information of the object, the boot area information of the operating system, etc.), and package and compress it into an image file. When needed, the image file can be restored to the corresponding partition or the corresponding hard disk. The efficiency of system installation can be improved and the threshold of system installation can be lowered.

[0055] However, the related art only supports ordinary system installation programs, and when ghost images are used for installation, incompatibility issues will occur. Therefore, in this embodiment, a basic system compatible with ghost image files is also deployed in the PXE server, so that the ghost image can be used to perform system installation operations through the basic system.

[0056] S102, when the PXE client selects the ghost image installation, query the ghost image and the basic system image according to the address information;

[0057] Based on S101, this step is intended to query the ghost image and the basic system image according to the address information when the PXE client selects the ghost image installation. That is, the PXE client selects the ghost image installation in multiple system installation modes. Then, the corresponding ghost image and the basic system image can be queried through the PXE server. That is, the corresponding image file is queried through the PXE server so that the image file can be used for system installation.

[0058] Among them, ghost images and basic system images are generally deployed in several specific directories. Therefore, the query process only needs to query whether the image data is mounted in a specific directory.

[0059] S103, when the ghost image and the basic system image are found, the system is installed according to the ghost image and the basic system image through the PXE protocol.

[0060] Based on S102, this step aims to install the system according to the ghost image and the basic system image through the PXE protocol when the ghost image and the basic system image are queried. That is, when the corresponding ghost image and the basic system image are queried, the data of the ghost image and the basic system image can be obtained through the PXE protocol. And the system is installed in the local computer, that is, the computer installed by the client.

[0061] The process of system installation is to first deploy the corresponding basic system using the basic system image, and then install the ghost image using the basic system. The method of deploying the basic system can adopt any one of the basic system deployment methods provided by the prior art, which is not specifically limited here. The method of installing the ghost image through the basic system can also adopt any one of the installation methods provided by the prior art, which is not specifically limited here.

[0062] Furthermore, in order to adapt the ghost image, the process of system installation in this step may include:

[0063] Step 1: Download the ghost image and the basic system image to the PXE client through the PXE protocol;

[0064] Step 2: Perform system deployment and startup processing according to the basic system image to obtain the basic system;

[0065] Step 3: Install the ghost image using the base system.

[0066] It can be seen that this optional solution mainly describes how to install the system. In this optional solution, the ghost image and the basic system image are first downloaded to the PXE client through the PXE protocol; then, the system deployment and startup processing is performed according to the basic system image to obtain the basic system; finally, the ghost image is installed through the basic system. The installation process of the ghost image is realized, and the installation efficiency of the ghost image is improved.

[0067] Furthermore, in order to avoid the problem of PXE server freezing, this embodiment may further include:

[0068] Step 1: When the ghost image and the basic system image cannot be found, the target directory is determined by all mounted directories and the directory name corresponding to each directory;

[0069] Step 2: Obtain the ghost image and basic system image from the target directory through the PXE protocol and install the system.

[0070] It can be seen that this optional solution mainly explains how to operate when the ghost image and the basic system image cannot be queried. In the related art, a freeze occurs when the ghost image and the basic system image cannot be queried. Therefore, in this optional solution, the target directory is determined by all mounted directories and the directory name corresponding to each directory; then, the ghost image and the basic system image are obtained from the target directory through the PXE protocol, and the system is installed. That is, the target directory with the image data is determined through all mounted directories and the corresponding directory names, and then the corresponding image data is obtained from the target directory through the PXE protocol.

[0071] Furthermore, in order to avoid the problem of PXE server freezing, this embodiment may further include:

[0072] Step 1: When the target directory cannot be determined, mount the ghost image and the basic system image to the preset directory;

[0073] Step 2: Obtain the ghost image and basic system image from the preset directory through the PXE protocol, and install the system.

[0074] It can be seen that this optional solution mainly explains how to operate when the target directory cannot be determined. In this optional solution, when the target directory cannot be determined, the image file is mainly obtained by actively mounting the image file. Specifically, when the target directory cannot be determined, first, the ghost image and the basic system image are mounted to the preset directory; then, the ghost image and the basic system image are obtained from the preset directory through the PXE protocol, and the system is installed.

[0075] In summary, this embodiment realizes ghost image installation through the PXE server by setting both the ghost image and the corresponding basic system image on the PXE server and then requesting the image data from the PXE server, thereby improving the efficiency of ghost image installation.

[0076] The following is a specific example to further illustrate a system installation method provided by the present application.

[0077] In this embodiment, each device is first set up. Among them, the network card of the system machine to be installed needs to support the PXE protocol, and the motherboard needs to support network booting. A DHCP server is required to automatically assign addresses to clients and specify the location of boot files. The server provides downloading of boot image files through the TFTP protocol.

[0078] First, upload the two images to the PXE server. Then, the machine to be installed starts with PXE, and the basic system is selected for booting. Ghost installation is performed through the PXE server, and is generally mounted under media. If it is not found, you can enter sudo su in the terminal to obtain permissions, and then enter df-Th to view the mount directory and directory name. If it is not available, you can manually mount the directory where the image is located to the / mnt directory through mount / dev / sdb / mnt. Finally, there is no need for personnel to be on duty, and you can install the next one. According to on-site inspections, one staff member can install 12 machines at the same time.

[0079] It can be seen that this embodiment can realize ghost image installation through the PXE server by setting both the ghost image and the corresponding basic system image on the PXE server and then requesting the image data from the PXE server, thereby improving the efficiency of ghost image installation.

[0080] The following is an introduction to the system installation device provided in the embodiment of the present application. The system installation device described below and the system installation method described above can be referenced to each other.

[0081] Please refer to Figure 2 , Figure 2 A schematic diagram of the structure of a system installation device provided in an embodiment of the present application.

[0082] In this embodiment, the method may include:

[0083] The request sending module 100 is used to send an installation request to the PXE server so that the PXE server returns address information to the PXE client; wherein the PXE server is a server on which the ghost image and the basic system image have been deployed;

[0084] The image query module 200 is used to query the ghost image and the basic system image according to the address information when the PXE client selects the ghost image installation;

[0085] The image installation module 300 is used to perform system installation according to the ghost image and the basic system image through the PXE protocol when the ghost image and the basic system image are queried.

[0086] Optionally, the device may further include:

[0087] The directory query module is used to determine the target directory through all mounted directories and the directory name corresponding to each directory when the ghost image and the basic system image cannot be found;

[0088] The directory image installation module is used to obtain the ghost image and basic system image from the target directory through the PXE protocol and perform system installation.

[0089] Optionally, the device may further include:

[0090] The image mounting module is used to mount the ghost image and the basic system image to the preset directory when the target directory cannot be determined;

[0091] The mount image installation module is used to obtain the ghost image and basic system image from the preset directory through the PXE protocol and perform system installation.

[0092] Optionally, the image installation module 300 includes:

[0093] An image data downloading unit, used for downloading the ghost image and the basic system image to the PXE client through the PXE protocol;

[0094] A basic system deployment unit, used to perform system deployment and startup processing according to the basic system image to obtain the basic system;

[0095] The ghost image installation unit is used to perform system installation processing on the ghost image through the basic system.

[0096] The present application also provides a server, including:

[0097] Memory for storing computer programs;

[0098] The processor is used to implement the steps of the system installation method as described in the above embodiment when executing the computer program.

[0099] An embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of the system installation method described in the above embodiment are implemented.

[0100] The various embodiments in the specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referred 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.

[0101] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0102] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0103] The above is a detailed introduction to a system installation method, a system installation device, a server, and a computer-readable storage medium provided by the present application. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method and core idea of ​​the present application. It should be pointed out that for ordinary technicians in this technical field, without departing from the principles of the present application, several improvements and modifications can be made to the present application, and these improvements and modifications also fall within the scope of protection of the claims of the present application.

Claims

1. A system installation method, characterized in that: include: The PXE client sends an installation request to the PXE server, so that the PXE server returns address information to the PXE client; wherein the PXE server is a server on which a ghost image and a basic system image have been deployed; When the PXE client selects the ghost image to install, querying the ghost image and the basic system image according to the address information; When the ghost image and the basic system image are found, the system is installed according to the ghost image and the basic system image through the PXE protocol; When the ghost image and the basic system image cannot be found, enter sudo su to obtain permissions, enter df –Th to view all mounted directories and the directory name corresponding to each directory, and determine the target directory where the image data is set through all mounted directories and the directory name corresponding to each directory; Obtain the ghost image and the basic system image from the target directory through the PXE protocol, and perform system installation; When the target directory cannot be determined, mounting the ghost image and the basic system image to a preset directory; Obtain the ghost image and the basic system image from the preset directory through the PXE protocol, and perform system installation; Performing system installation according to the ghost image and the basic system image through the PXE protocol includes: Downloading the ghost image and the basic system image to the PXE client through the PXE protocol; Perform system deployment and startup processing according to the basic system image to obtain a basic system; The ghost image is subjected to system installation processing through the basic system.

2. A system installation device, characterized in that: include: A request sending module, used for sending an installation request to a PXE server so that the PXE server returns address information to the PXE client; wherein the PXE server is a server on which a ghost image and a basic system image have been deployed; An image query module, used for querying the ghost image and the basic system image according to the address information when the PXE client selects the ghost image installation; An image installation module, used for performing system installation according to the ghost image and the basic system image through the PXE protocol when the ghost image and the basic system image are queried; A directory query module, for inputting sudo su to obtain permissions when the ghost image and the basic system image cannot be found, inputting df –Th to view all directories and the directory name corresponding to each directory, and determining the target directory where the image data is set through all mounted directories and the directory name corresponding to each directory; A directory image installation module, used to obtain the ghost image and the basic system image from the target directory through the PXE protocol, and perform system installation; An image mounting module, used for mounting the ghost image and the basic system image to a preset directory when the target directory cannot be determined; The mounting image installation module is used to obtain the ghost image and the basic system image from the preset directory through the PXE protocol and perform system installation; An image data downloading unit, used for downloading the ghost image and the basic system image to the PXE client through the PXE protocol; A basic system deployment unit, used to perform system deployment and startup processing according to the basic system image to obtain a basic system; The ghost image installation unit is used to perform system installation processing on the ghost image through the basic system.

3. A server, characterized in that: include: Memory for storing computer programs; A processor, configured to implement the steps of the system installation method as claimed in claim 1 when executing the computer program.

4. 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 system installation method according to claim 1 are implemented.