CN114237638A - Operating system installation method and device, computer equipment and storage medium - Google Patents

Operating system installation method and device, computer equipment and storage medium Download PDF

Info

Publication number
CN114237638A
CN114237638A CN202111476505.1A CN202111476505A CN114237638A CN 114237638 A CN114237638 A CN 114237638A CN 202111476505 A CN202111476505 A CN 202111476505A CN 114237638 A CN114237638 A CN 114237638A
Authority
CN
China
Prior art keywords
operating system
target
installation
debian
service
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111476505.1A
Other languages
Chinese (zh)
Inventor
尧永贤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen United Imaging Research Institute of Innovative Medical Equipment
Original Assignee
Shenzhen United Imaging Research Institute of Innovative Medical Equipment
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen United Imaging Research Institute of Innovative Medical Equipment filed Critical Shenzhen United Imaging Research Institute of Innovative Medical Equipment
Priority to CN202111476505.1A priority Critical patent/CN114237638A/en
Publication of CN114237638A publication Critical patent/CN114237638A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The application relates to an operating system installation method, an operating system installation device, computer equipment and a storage medium. The method comprises the following steps: setting a target server based on a preset Debian operating system, and building a PXE server; constructing a target installation package based on the Debian operating system; the target installation package contains an installation program of the Debian operating system; and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package. By adopting the method, the installation efficiency of the operating system can be improved.

Description

Operating system installation method and device, computer equipment and storage medium
Technical Field
The present application relates to the field of operating system technologies, and in particular, to an operating system installation method and apparatus, a computer device, and a storage medium.
Background
Magnetic Resonance Imaging (MRI) is one of the most advanced medical Imaging methods today and is increasingly used in clinical and scientific research.
At present, the method of installing the operating system in the magnetic resonance device generally downloads an operating system installation image file from an official website of the operating system, then makes the operating system image file into a system boot disk such as a DVD/CD/U disk, and then uses the system boot disk to install the system.
However, the installation of the image file of the operating system is generally larger, and if the installation of the image file of the operating system always needs to be downloaded, the installation efficiency is lower; and, if the network is unstable, the downloading speed is slow and the installation efficiency is lower.
Disclosure of Invention
In view of the above, it is necessary to provide an operating system installation method, an operating system installation apparatus, a computer device, and a storage medium, which can improve installation efficiency.
In a first aspect, the present application provides a method for installing an operating system. The method comprises the following steps:
setting a target server based on a preset Debian operating system, and building a PXE server;
constructing a target installation package based on a Debian operating system; the target installation package contains an installation program of a Debian operating system;
and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package.
In one embodiment, the setting of the target server based on the preinstalled Debian operating system to build the PXE server includes:
setting a source file and a static network address of the installation of the Debian operating system on the target server based on the Debian operating system;
setting DHCP service, TFTP service and httpd service for a target server based on a Debian operating system, a Debian operating system installation source file and a static network address;
and automatically configuring and starting the DHCP service, the TFTP service and the httpd service based on a Debian operating system, and constructing a PXE server.
In one embodiment, the setting of the DHCP service for the target server based on the Debian operating system, the Debian operating system installation source file, and the static network address includes:
installing a DHCP service by using a DHCP installation program;
carrying out environment configuration on the DHCP service;
and setting a network interface for the DHCP service according to the static network address.
In one embodiment, the setting of TFTP service for the target server based on the Debian operating system, the Debian operating system installation source file, and the static network address includes:
installing the TFTP service by using a TFTP installation program to obtain a root path of the TFTP service;
and acquiring a bootstrap program and mounting the bootstrap program under a root path of the TFTP service.
In one embodiment, the setting of the httpd service for the target server based on the Debian operating system, the Debian operating system installation source file, and the static network address includes:
installing httpd service by using an httpd installer;
and mounting the installation source file of the Debian operating system under the file directory of the httpd service.
In one embodiment, the building of the target installation package based on the Debian operating system includes:
generating a basic file system of the Debian operating system based on a file system construction program of the Debian operating system;
installing a development kit of the virtual root file system, and adding a target tool and a target script file in the virtual root file system by using the development kit;
installing a software toolset to provide a tftp transfer tool;
and packaging and compressing the basic file system, the target tool, the target script file and the software tool set to obtain a target installation package.
In one embodiment, before the above-mentioned packing and compressing the basic file system, the object tool, the object script file, and the software toolset to obtain the object installation package, the method further includes:
setting a software installation source file and a starting service based on a basic file system;
correspondingly, the above-mentioned packing and compressing the basic file system, the target tool, the target script file and the software tool set to obtain the target installation package includes:
acquiring a software installation package according to a software installation source file;
and packaging and compressing the basic file system, the target tool, the target script file, the software tool set and the software installation package to obtain the target installation package.
In a second aspect, the present application further provides an operating system installation apparatus. The device includes:
the server building module is used for setting a target server based on a preset Debian operating system and building a PXE server;
the target installation package construction module is used for constructing a target installation package based on a Debian operating system; the target installation package contains an installation program of a Debian operating system;
and the system installation module is used for sending the target installation package to the PXE terminal after detecting that the PXE terminal is started through the PXE network, so that the PXE terminal can install the Debian operating system according to the target installation package.
In one embodiment, the server building module includes:
the file address setting submodule is used for setting a source file and a static network address installed by the Debian operating system on the target server based on the Debian operating system;
the service setting submodule is used for setting DHCP service, TFTP service and httpd service for the target server based on the Debian operating system, the installation source file of the Debian operating system and the static network address;
and the starting configuration setting submodule is used for carrying out automatic configuration and starting setting on the DHCP service, the TFTP service and the httpd service based on the Debian operating system and establishing the PXE server.
In one embodiment, the service setting submodule is specifically configured to install a DHCP service using a DHCP installer; carrying out environment configuration on the DHCP service; and setting a network interface for the DHCP service according to the static network address.
In one embodiment, the service setting submodule is specifically configured to install a TFTP service using a TFTP installer to obtain a root path of the TFTP service; and acquiring a bootstrap program and mounting the bootstrap program under a root path of the TFTP service.
In one embodiment, the service setting submodule is specifically configured to install an httpd service using an httpd installer; and mounting the installation source file of the Debian operating system under the file directory of the httpd service.
In one embodiment, the target installation package building module is specifically configured to generate a basic file system of a Debian operating system based on a file system building program of the Debian operating system; installing a development kit of the virtual root file system, and adding a target tool and a target script file in the virtual root file system by using the development kit; installing a software toolset to provide a tftp transfer tool; and packaging and compressing the basic file system, the target tool, the target script file and the software tool set to obtain a target installation package.
In one embodiment, the target installation package building module is further configured to set a software installation source file and a boot service based on a basic file system; acquiring a software installation package according to a software installation source file; and packaging and compressing the basic file system, the target tool, the target script file, the software tool set and the software installation package to obtain the target installation package.
In a third aspect, the present application also provides a computer device. The computer device comprises a memory storing a computer program and a processor implementing the following steps when executing the computer program:
setting a target server based on a preset Debian operating system, and building a PXE server;
constructing a target installation package based on a Debian operating system; the target installation package contains an installation program of a Debian operating system;
and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package.
In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of:
setting a target server based on a preset Debian operating system, and building a PXE server;
constructing a target installation package based on a Debian operating system; the target installation package contains an installation program of a Debian operating system;
and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package.
In a fifth aspect, the present application further provides a computer program product. The computer program product comprising a computer program which when executed by a processor performs the steps of:
setting a target server based on a preset Debian operating system, and building a PXE server;
constructing a target installation package based on a Debian operating system; the target installation package contains an installation program of a Debian operating system;
and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package.
The operating system installation method, the operating system installation device, the computer equipment and the storage medium set a target server based on a preset Debian operating system, and build a PXE server; constructing a target installation package based on a Debian operating system; and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package. The PXE server and the target installation package are firstly constructed in the embodiment of the disclosure, so that when the Debian operating system is installed on the PXE terminal, only the target installation package needs to be obtained from the PXE server, and the operating system installation image file does not need to be downloaded from an official website, so that the installation efficiency of the operating system can be improved.
Drawings
FIG. 1 is a diagram of an application environment for a method of operating system installation in one embodiment;
FIG. 2 is a flowchart illustrating a method for operating system installation according to one embodiment;
FIG. 3 is a flow diagram illustrating steps for building a PXE server in one embodiment;
FIG. 4 is a flowchart illustrating one of the steps of building a target installation package in one embodiment;
FIG. 5 is a second flowchart illustrating the step of constructing the target installation package according to an embodiment;
FIG. 6 is a block diagram showing the construction of an operating system installation apparatus according to one embodiment;
FIG. 7 is a diagram illustrating an internal structure of a computer device according to an embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
The operating system installation method provided by the embodiment of the application can be applied to the application environment shown in fig. 1. The application Environment comprises a server 101 and a terminal 102, wherein the server 101 is used for building a PXE (Preboot eXecution Environment) server and building a target installation package, the terminal 102 is a terminal to be installed with a Debian operating system and magnetic resonance software, and the terminal 102 can communicate with the server 101 through a network. The server 101 may be implemented by a stand-alone server or a server cluster composed of a plurality of servers. The terminal 102 may be, but is not limited to, various personal computers, notebook computers, and tablet computers.
In one embodiment, the server 101 may include two servers, one for building a PXE server and the other for building an object installation package. The embodiment of the present disclosure does not limit this, and may be set according to actual situations.
The above-described PXE, also known as a pre-execution environment, provides a mechanism for booting a computer using a Network Interface (Network Interface). This mechanism allows the computer to boot without relying on a local data storage device (e.g., hard disk) or a locally installed operating system.
In one embodiment, as shown in fig. 2, an operating system installation method is provided, which is described by taking the method as an example applied to the server in fig. 1, and includes the following steps:
step 201, setting a target server based on a preset Debian operating system, and building a PXE server.
Before the PXE server is built, a Debian operating system is installed in a target server. The installation process may include: manufacturing a system installation disc according to an installation image file of a Debian operating system; establishing a communication connection between the system installation disk and the target server, for example, the system installation disk is a U disk, and inserting the U disk into a USB (Universal Serial Bus) interface of the target server. And setting a target server to start from a system installation disk, and installing the Debian operating system into the target server.
And setting a source file, a static network address, DHCP service, TFTP service and httpd service for a target server provided with a Debian operating system, and constructing a PXE server.
The Debian operating system mainly adopts a Linux kernel or a FreeBSD kernel. Linux, which is called GNU/Linux in its entirety, is a Unix-like operating system that can be used freely and spread freely, and is a POSIX-based multi-user, multi-task, multi-thread and multi-CPU (Central Processing Unit) supporting operating system. FreeBSD is an operating system that includes a kernel and other software.
Step 202, constructing a target installation package based on the Debian operating system.
Wherein, the target installation package contains an installation program of the Debian operating system.
Usually, the complete Debian operating system occupies a large space, however, for example, for the magnetic resonance system software, a large number of software packages are not used. Therefore, the target server can construct a simplified operating system based on the complete Debian operating system, and the simplified operating system comprises the basic functions of the Debian operating system and can also comprise a necessary software package of partial magnetic resonance system software. And then, the target server packs and compresses the simplified operating system, the installation program of the operating system and some common tool packages to construct a target installation package.
Step 203, after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal, so that the PXE terminal can install the Debian operating system according to the target installation package.
The PXE terminal is a terminal for installing a Debian operating system.
The PXE terminal is started through the PXE network, and then the PXE terminal acquires the starting bootstrap program from the built PXE server and executes the starting bootstrap program. And after determining that the PXE terminal executes the starting bootstrap program, the PXE server sends the target installation package to the PXE terminal. And after the PXE terminal acquires the target installation package, installing the Debian operating system according to the installation program of the Debian operating system in the target installation package.
In the operating system installation method, a target server is set based on a previously installed Debian operating system, and a PXE server is set up; constructing a target installation package based on a Debian operating system; and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package. The PXE server and the target installation package are firstly constructed in the embodiment of the disclosure, so that when the Debian operating system is installed on the PXE terminal, only the target installation package needs to be obtained from the PXE server, and the operating system installation image file does not need to be downloaded from an official website, so that the installation efficiency of the operating system can be improved.
In an embodiment, as shown in fig. 3, the process of setting the target server based on the preinstalled Debian operating system and building the PXE server may include the following steps:
step 301, setting a source file and a static network address of the installation of the Debian operating system on the target server based on the Debian operating system.
The installation source file of the Debian operating system is a source file required by installation of the Debian operating system, the static network address is a network address of the PXE terminal, and based on the network address, the PXE server can perform network communication with the PXE terminal.
And setting a Debian operating system installation source file in the Debian operating system of the target server. For example, by modifying/etc/apt/sources files to take the system installation disk as a local installation source and executing the apt-get update command, the target server determines that the installation source file of the Debian operating system is positioned in the system installation disk according to the modification of the files. If the Debian operating system needs to be reinstalled, the installation source file can be acquired from the system installation disk.
Setting a static network address in a Debian operating system of the target server. For example, modifying/etc/network/interfaces files, and allocating static network addresses to PXE terminals.
And step 302, setting DHCP service, TFTP service and httpd service for the target server based on the Debian operating system, installation source file of the Debian operating system and the static network address.
After setting a Debian operating system installation source file and a static network address, acquiring an instruction input by a user through an interface, and setting DHCP service, TFTP service and httpd service for a target server; and a preset script can be called to automatically set the DHCP service, the TFTP service and the httpd service for the target server. The embodiments of the present disclosure do not limit this.
In one embodiment, the process of setting the DHCP service for the target server based on the Debian operating system, the Debian operating system installation source file, and the static network address may include: installing a DHCP service by using a DHCP installation program; carrying out environment configuration on the DHCP service; and setting a network interface for the DHCP service according to the static network address.
For example, the DHCP installer is apt-get install, which installs the DHCP service using apt-get install. And then, configuring an isc-DHCP-server software package and carrying out environment configuration on the DHCP service. After that, the DHCP configuration file/etc/DHCP/dhcpd.conf is modified to make the DHCP service provide the IP address related information; then, the/etc/default/isc-dhcp-server file is modified, and the network interface configured with the static network address is added to the interrupt 4.
In one embodiment, the process of setting the TFTP service for the target server based on the Debian operating system, the Debian operating system installation source file, and the static network address may include: installing the TFTP service by using a TFTP installation program to obtain a root path of the TFTP service; and acquiring a bootstrap program and mounting the bootstrap program under a root path of the TFTP service.
For example, installing a TFTP-hpa software package on a Debian system to obtain a root path/srv/TFTP of the TFTP service; and then, acquiring a netboot. tar. gz file of the bootstrap program, and decompressing the file to be under a root path of the TFTP service, thereby realizing mounting the bootstrap program to be under the root path of the TFTP service. Wherein the bootstrap program can realize the network startup of the Debian.
In one embodiment, the process of setting httpd service for the target server based on the Debian operating system, the Debian operating system installation source file and the static network address may include: installing httpd service by using an httpd installer; and mounting the installation source file of the Debian operating system under the file directory of the httpd service.
For example, the httpd installer is set in the apache2 package, and the installation of the apache2 package is completed with the httpd service. And then, mounting the installation source file (such as a system installation disk) of the Debian operating system under the file directory of the httpd service.
Step 303, based on the setting of automatic configuration and startup of the DHCP service, the TFTP service, and the httpd service by the Debian operating system, a PXE server is set up.
After the target server is set with the DHCP service, the TFTP service and the httpd service, a preset configuration file can be set, and the preset configuration file can realize automatic configuration. And, set up the boot-up in isc-dhcp-server/tftp-hpa. After the setting is completed, the target server is built into the PXE server.
In the embodiment, the installation source file and the static network address of the Debian operating system are set for the target server based on the Debian operating system; setting DHCP service, TFTP service and httpd service for a target server based on a Debian operating system, a Debian operating system installation source file and a static network address; and automatically configuring and starting the DHCP service, the TFTP service and the httpd service based on a Debian operating system, and constructing a PXE server. According to the method and the device for installing the Debian operating system, the PXE server is set up through the installation source file, the static network address, the DHCP service, the TFTP service and the httpd service of the Debian operating system, the PXE server can provide installation programs of the Debian operating system for a plurality of PXE terminals, especially when the PXE terminals are distributed at different positions, the installation mirror image files of the Debian operating system do not need to be downloaded from an official website one by the PXE terminals, and installation of the Debian operating system can be achieved only by obtaining the installation programs of the Debian operating system from the PXE server. Therefore, the construction of the PXE server can obviously improve the efficiency of the batch installation of the Debian operation.
In an embodiment, as shown in fig. 4, the process of building the target installation package based on the Debian operating system may include:
step 401, generating a basic file system of the Debian operating system based on a file system construction program of the Debian operating system.
The target server is provided with a complete Debian operating system, and a system builder can be used for generating a basic file system of the Debian operating system. For example, a system builder debootstrap is used to generate directories, i.e., a base file system, that conform to the Linux file system standard, including/boot,/etc,/bin,/usr. The directory of the basic file system is not limited in the embodiment of the present disclosure.
Compared with a complete Debian operating system, the basic file system occupies a lot of reduced space, and the data volume of the target installation package is relatively small when the target installation package is constructed; when the PXE server sends the target installation package to the PXE terminal, the transmission speed can be increased, and therefore the installation efficiency is improved.
Step 402, installing a development kit of the virtual root file system, and adding a target tool and a target script file in the virtual root file system by using the development kit.
Wherein the development toolkit is used for developing the virtual root file system.
The method comprises the steps that when a basic file system is constructed, a target server can also install a development tool package initramfs-tools of a virtual root file system, target tools are added under an/etc/initramfs-tools/hooks directory by utilizing the development tool package initramfs-tools, and target script files are added under the/etc/initramfs-tools/scripts/directory.
The development toolkit initramfs-tools is used for compiling scripts in mkittramfs, and the mkittramfs is a tool for developing a virtual root file system of initramfs. The development kit is not limited in the embodiments of the present disclosure.
At step 403, the software toolset is installed to provide the tftp transfer tool.
The software toolset may be a busybox, which may combine small versions of many common Linux tools into one small executable file.
While the basic file system is being built, the target server may also install a software toolset busy providing a tftp transfer tool. In practical applications, the magnetic resonance system may transfer files using the tftp transfer tool provided by the software toolset busy.
And step 404, packaging and compressing the basic file system, the target tool, the target script file and the software tool set to obtain a target installation package.
After the basic file system is built, the target tool and the target script file are added and the software tool set is installed, the target server packs and compresses the basic file system, the target tool, the target script file and the software tool set to obtain a target installation package.
In one embodiment, as shown in fig. 5, before performing packing and compressing processing on the basic file system, the object tool, the object script file, and the software tool set to obtain the object installation package, an embodiment of the present disclosure may further include:
step 405, setting a software installation source file and a boot service based on the basic file system.
The software installation source file is provided with a storage position of installation packages of various magnetic resonance software used by the magnetic resonance system.
And the target server downloads a plurality of software installation packages of the magnetic resonance software by using the apt-get command, and then sets a software installation source file in the constructed basic file system according to the software installation packages.
The target server may also set a boot-up service. After the PXE terminal is provided with a plurality of magnetic resonance software, the plurality of magnetic resonance software can be automatically started when the PXE terminal is started.
Correspondingly, the step 404 may include: acquiring a software installation package according to a software installation source file; and packaging and compressing the basic file system, the target tool, the target script file, the software tool set and the software installation package to obtain the target installation package.
And the target server acquires the software installation package according to the software installation source file, and then packages and compresses the basic file system, the target tool, the target script file, the software tool set and the software installation package together to obtain the target installation package.
After the PXE terminal obtains the target installation package from the PXE server, a basic file system of a Debian operating system can be installed according to the target installation package; or acquiring a target tool and a target script file from a directory of the virtual root file system; the magnetic resonance software can also be installed according to the software installation package, and the file transfer is carried out by using a tftp transfer tool provided by the software toolset.
In the above embodiment, the file system building program based on the Debian operating system generates the basic file system of the Debian operating system; installing a development kit of the virtual root file system, and adding a target tool and a target script file in the virtual root file system by using the development kit; installing a software toolset to provide a tftp transfer tool; and packaging and compressing the basic file system, the target tool, the target script file and the software tool set to obtain a target installation package. The basic file system contained in the target installation package is a simplified operating system, so that the transmission efficiency can be improved during transmission on the basis of ensuring the basic functions of the operating system, and the installation efficiency of the operating system is improved. The target installation package also comprises a target tool, a target script file, a development tool package and the like, and can assist the PXE terminal to realize corresponding functions and realize related configuration. Therefore, the target installation package is constructed, so that the installation efficiency of the operating system and the software can be improved.
It should be understood that, although the steps in the flowcharts related to the embodiments as described above are sequentially displayed as indicated by arrows, the steps are not necessarily performed sequentially as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least a part of the steps in the flowcharts related to the embodiments described above may include multiple steps or multiple stages, which are not necessarily performed at the same time, but may be performed at different times, and the execution order of the steps or stages is not necessarily sequential, but may be rotated or alternated with other steps or at least a part of the steps or stages in other steps.
Based on the same inventive concept, the embodiment of the present application further provides an operating system installation apparatus for implementing the operating system installation method mentioned above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme described in the above method, so specific limitations in one or more embodiments of the operating system installation device provided below can be referred to the limitations in the above operating system installation method, and are not described herein again.
In one embodiment, as shown in fig. 6, there is provided an operating system installation apparatus including:
a server building module 501, configured to set a target server based on a previously installed Debian operating system, and build a PXE server;
a target installation package construction module 502, configured to construct a target installation package based on a Debian operating system; the target installation package contains an installation program of a Debian operating system;
the system installation module 503 is configured to send the target installation package to the PXE terminal after detecting that the PXE terminal is started through the PXE network, so that the PXE terminal can install the Debian operating system according to the target installation package.
In one embodiment, the server building module 501 includes:
the file address setting submodule is used for setting a source file and a static network address installed by the Debian operating system on the target server based on the Debian operating system;
the service setting submodule is used for setting DHCP service, TFTP service and httpd service for the target server based on the Debian operating system, the installation source file of the Debian operating system and the static network address;
and the starting configuration setting submodule is used for carrying out automatic configuration and starting setting on the DHCP service, the TFTP service and the httpd service based on the Debian operating system and establishing the PXE server.
In one embodiment, the service setting submodule is specifically configured to install a DHCP service using a DHCP installer; carrying out environment configuration on the DHCP service; and setting a network interface for the DHCP service according to the static network address.
In one embodiment, the service setting submodule is specifically configured to install a TFTP service using a TFTP installer to obtain a root path of the TFTP service; and acquiring a bootstrap program and mounting the bootstrap program under a root path of the TFTP service.
In one embodiment, the service setting submodule is specifically configured to install an httpd service using an httpd installer; and mounting the installation source file of the Debian operating system under the file directory of the httpd service.
In one embodiment, the target installation package building module 502 is specifically configured to generate a basic file system of a Debian operating system based on a file system building program of the Debian operating system; installing a development kit of the virtual root file system, and adding a target tool and a target script file in the virtual root file system by using the development kit; installing a software toolset to provide a tftp transfer tool; and packaging and compressing the basic file system, the target tool, the target script file and the software tool set to obtain a target installation package.
In one embodiment, the target installation package building module 502 is further configured to set a software installation source file and a boot service based on a basic file system; acquiring a software installation package according to a software installation source file; and packaging and compressing the basic file system, the target tool, the target script file, the software tool set and the software installation package to obtain the target installation package.
The respective modules in the operating system installation apparatus described above may be implemented in whole or in part by software, hardware, and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, a computer device is provided, which may be a server, the internal structure of which may be as shown in fig. 7. The computer device includes a processor, a memory, and a network interface connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The database of the computer device is used to store the XX data. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement an operating system installation method.
Those skilled in the art will appreciate that the architecture shown in fig. 7 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In one embodiment, a computer device is provided, comprising a memory and a processor, the memory having a computer program stored therein, the processor implementing the following steps when executing the computer program:
setting a target server based on a preset Debian operating system, and building a PXE server;
constructing a target installation package based on a Debian operating system; the target installation package contains an installation program of a Debian operating system;
and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
setting a source file and a static network address of the installation of the Debian operating system on the target server based on the Debian operating system;
setting DHCP service, TFTP service and httpd service for a target server based on a Debian operating system, a Debian operating system installation source file and a static network address;
and automatically configuring and starting the DHCP service, the TFTP service and the httpd service based on a Debian operating system, and constructing a PXE server.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
installing a DHCP service by using a DHCP installation program;
carrying out environment configuration on the DHCP service;
and setting a network interface for the DHCP service according to the static network address.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
installing the TFTP service by using a TFTP installation program to obtain a root path of the TFTP service;
and acquiring a bootstrap program and mounting the bootstrap program under a root path of the TFTP service.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
installing httpd service by using an httpd installer;
and mounting the installation source file of the Debian operating system under the file directory of the httpd service.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
generating a basic file system of the Debian operating system based on a file system construction program of the Debian operating system;
installing a development kit of the virtual root file system, and adding a target tool and a target script file in the virtual root file system by using the development kit;
installing a software toolset to provide a tftp transfer tool;
and packaging and compressing the basic file system, the target tool, the target script file and the software tool set to obtain a target installation package.
In one embodiment, the processor, when executing the computer program, further performs the steps of:
setting a software installation source file and a starting service based on a basic file system;
acquiring a software installation package according to a software installation source file;
and packaging and compressing the basic file system, the target tool, the target script file, the software tool set and the software installation package to obtain the target installation package.
In one embodiment, a computer-readable storage medium is provided, having a computer program stored thereon, which when executed by a processor, performs the steps of:
setting a target server based on a preset Debian operating system, and building a PXE server;
constructing a target installation package based on a Debian operating system; the target installation package contains an installation program of a Debian operating system;
and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package.
In one embodiment, the computer program when executed by the processor further performs the steps of:
setting a source file and a static network address of the installation of the Debian operating system on the target server based on the Debian operating system;
setting DHCP service, TFTP service and httpd service for a target server based on a Debian operating system, a Debian operating system installation source file and a static network address;
and automatically configuring and starting the DHCP service, the TFTP service and the httpd service based on a Debian operating system, and constructing a PXE server.
In one embodiment, the computer program when executed by the processor further performs the steps of:
installing a DHCP service by using a DHCP installation program;
carrying out environment configuration on the DHCP service;
and setting a network interface for the DHCP service according to the static network address.
In one embodiment, the computer program when executed by the processor further performs the steps of:
installing the TFTP service by using a TFTP installation program to obtain a root path of the TFTP service;
and acquiring a bootstrap program and mounting the bootstrap program under a root path of the TFTP service.
In one embodiment, the computer program when executed by the processor further performs the steps of:
installing httpd service by using an httpd installer;
and mounting the installation source file of the Debian operating system under the file directory of the httpd service.
In one embodiment, the computer program when executed by the processor further performs the steps of:
generating a basic file system of the Debian operating system based on a file system construction program of the Debian operating system;
installing a development kit of the virtual root file system, and adding a target tool and a target script file in the virtual root file system by using the development kit;
installing a software toolset to provide a tftp transfer tool;
and packaging and compressing the basic file system, the target tool, the target script file and the software tool set to obtain a target installation package.
In one embodiment, the computer program when executed by the processor further performs the steps of:
setting a software installation source file and a starting service based on a basic file system;
acquiring a software installation package according to a software installation source file;
and packaging and compressing the basic file system, the target tool, the target script file, the software tool set and the software installation package to obtain the target installation package.
In one embodiment, a computer program product is provided, comprising a computer program which, when executed by a processor, performs the steps of:
setting a target server based on a preset Debian operating system, and building a PXE server;
constructing a target installation package based on a Debian operating system; the target installation package contains an installation program of a Debian operating system;
and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package.
In one embodiment, the computer program when executed by the processor further performs the steps of:
setting a source file and a static network address of the installation of the Debian operating system on the target server based on the Debian operating system;
setting DHCP service, TFTP service and httpd service for a target server based on a Debian operating system, a Debian operating system installation source file and a static network address;
and automatically configuring and starting the DHCP service, the TFTP service and the httpd service based on a Debian operating system, and constructing a PXE server.
In one embodiment, the computer program when executed by the processor further performs the steps of:
installing a DHCP service by using a DHCP installation program;
carrying out environment configuration on the DHCP service;
and setting a network interface for the DHCP service according to the static network address.
In one embodiment, the computer program when executed by the processor further performs the steps of:
installing the TFTP service by using a TFTP installation program to obtain a root path of the TFTP service;
and acquiring a bootstrap program and mounting the bootstrap program under a root path of the TFTP service.
In one embodiment, the computer program when executed by the processor further performs the steps of:
installing httpd service by using an httpd installer;
and mounting the installation source file of the Debian operating system under the file directory of the httpd service.
In one embodiment, the computer program when executed by the processor further performs the steps of:
generating a basic file system of the Debian operating system based on a file system construction program of the Debian operating system;
installing a development kit of the virtual root file system, and adding a target tool and a target script file in the virtual root file system by using the development kit;
installing a software toolset to provide a tftp transfer tool;
and packaging and compressing the basic file system, the target tool, the target script file and the software tool set to obtain a target installation package.
In one embodiment, the computer program when executed by the processor further performs the steps of:
setting a software installation source file and a starting service based on a basic file system;
acquiring a software installation package according to a software installation source file;
and packaging and compressing the basic file system, the target tool, the target script file, the software tool set and the software installation package to obtain the target installation package.
It should be noted that, the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, presented data, etc.) referred to in the present application are information and data authorized by the user or sufficiently authorized by each party.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, database, or other medium used in the embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high-density embedded nonvolatile Memory, resistive Random Access Memory (ReRAM), Magnetic Random Access Memory (MRAM), Ferroelectric Random Access Memory (FRAM), Phase Change Memory (PCM), graphene Memory, and the like. Volatile Memory can include Random Access Memory (RAM), external cache Memory, and the like. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM), among others. The databases referred to in various embodiments provided herein may include at least one of relational and non-relational databases. The non-relational database may include, but is not limited to, a block chain based distributed database, and the like. The processors referred to in the embodiments provided herein may be general purpose processors, central processing units, graphics processors, digital signal processors, programmable logic devices, quantum computing based data processing logic devices, etc., without limitation.
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present application. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present application shall be subject to the appended claims.

Claims (10)

1. An operating system installation method, the method comprising:
setting a target server based on a preset Debian operating system, and building a PXE server;
constructing a target installation package based on the Debian operating system; the target installation package contains an installation program of the Debian operating system;
and after detecting that the PXE terminal is started through the PXE network, sending the target installation package to the PXE terminal so that the PXE terminal can install the Debian operating system according to the target installation package.
2. The method as claimed in claim 1, wherein the setting of the target server based on the preinstalled Debian operating system and the building of the PXE server comprise:
setting a source file and a static network address of the installation of the Debian operating system on the target server based on the Debian operating system;
setting DHCP service, TFTP service and httpd service for the target server based on the Debian operating system, the installation source file of the Debian operating system and the static network address;
and setting the automatic configuration and the startup of the DHCP service, the TFTP service and the httpd service based on the Debian operating system, and constructing the PXE server.
3. The method of claim 2, wherein the setting of the DHCP service for the target server based on the Debian operating system, the Debian operating system installation source file, and the static network address comprises:
installing a DHCP service by using a DHCP installation program;
carrying out environment configuration on the DHCP service;
and setting a network interface of the DHCP service according to the static network address.
4. The method of claim 2, wherein the setting of the TFTP service for the target server based on the Debian operating system, the Debian operating system installation source file and the static network address comprises:
installing TFTP service by using a TFTP installation program to obtain a root path of the TFTP service;
and acquiring a bootstrap program and mounting the bootstrap program to a root path of the TFTP service.
5. The method of claim 2, wherein the setting of the httpd service for the target server based on the Debian operating system, the Debian operating system installation source file, and the static network address comprises:
installing httpd service by using an httpd installer;
and mounting the installation source file of the Debian operating system under the file directory of the httpd service.
6. The method as claimed in claim 1, wherein the building of the target installation package based on the Debian operating system comprises:
generating a basic file system of the Debian operating system based on a file system construction program of the Debian operating system;
installing a development kit of a virtual root file system, and adding a target tool and a target script file in the virtual root file system by using the development kit;
installing a software toolset to provide a tftp transfer tool;
and packaging and compressing the basic file system, the target tool, the target script file and the software tool set to obtain the target installation package.
7. The method of claim 6, wherein before the packaging and compressing the basic file system, the object tool, the object script file, and the software tool set to obtain the object installation package, the method further comprises:
setting a software installation source file and a starting service based on the basic file system;
correspondingly, the step of performing packing and compression processing on the basic file system, the target tool, the target script file and the software tool set to obtain the target installation package comprises:
acquiring a software installation package according to the software installation source file;
and packaging and compressing the basic file system, the target tool, the target script file, the software tool set and the software installation package to obtain the target installation package.
8. An operating system installation apparatus, the apparatus comprising:
the server building module is used for setting a target server based on a preset Debian operating system and building a PXE server;
the target installation package construction module is used for constructing a target installation package based on the Debian operating system; the target installation package contains an installation program of the Debian operating system;
and the system installation module is used for sending the target installation package to the PXE terminal after detecting that the PXE terminal is started through the PXE network, so that the PXE terminal can install the Debian operating system according to the target installation package.
9. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor, when executing the computer program, implements the steps of the method of any of claims 1 to 7.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 7.
CN202111476505.1A 2021-12-06 2021-12-06 Operating system installation method and device, computer equipment and storage medium Pending CN114237638A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111476505.1A CN114237638A (en) 2021-12-06 2021-12-06 Operating system installation method and device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111476505.1A CN114237638A (en) 2021-12-06 2021-12-06 Operating system installation method and device, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114237638A true CN114237638A (en) 2022-03-25

Family

ID=80753277

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111476505.1A Pending CN114237638A (en) 2021-12-06 2021-12-06 Operating system installation method and device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114237638A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115174556A (en) * 2022-06-29 2022-10-11 浪潮云信息技术股份公司 Configuration method and system of server operating system, storage medium and electronic equipment

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115174556A (en) * 2022-06-29 2022-10-11 浪潮云信息技术股份公司 Configuration method and system of server operating system, storage medium and electronic equipment

Similar Documents

Publication Publication Date Title
CN111492347B (en) System and method for updating a container
US9507604B2 (en) Boot method and boot system
US7631173B2 (en) Method and system for performing pre-boot operations from an external memory including memory address and geometry
US8914785B2 (en) Providing virtual appliance system firmware images
US6842856B2 (en) System and method for dynamic management of a startup sequence
US20060242395A1 (en) Operating system boot from network location
EP3518099B1 (en) Installation of operating system
US20050044348A1 (en) Method and apparatus for booting a computer system
US9678767B2 (en) Unified extensible firmware interface (UEFI) driver and protocol
US11144328B2 (en) System method to update failover process by running basic input/output (BIOS) system boot code from non-volatile memory express device (NVME)
WO2005029325A1 (en) Method and apparatus for booting a computer system
US20040199758A1 (en) Information handling system manufacture method and system
US9619340B1 (en) Disaster recovery on dissimilar hardware
US10642623B1 (en) Preserving firmware settings during firmware updates
CN113934445B (en) Device firmware upgrading system, method, device, computer device and storage medium
US10795769B2 (en) Facilitating the identification of a service operating system when a main operating system fails
CN106462442B (en) System and method for loading virtual machine
TWI813887B (en) Method and system for booting from a split bios image
CN110825419A (en) Firmware refreshing method and device, electronic equipment and storage medium
US20060059327A1 (en) Method to reset an image to a known state
CN114385251A (en) Operating system booting method, system, terminal and storage medium based on memory
CN114237638A (en) Operating system installation method and device, computer equipment and storage medium
CN109190367B (en) Method and device for running application program installation package by utilizing sandbox
CN117555563B (en) Method and device for constructing platform mirror image, computer equipment and storage medium
EP1685482A4 (en) Method and apparatus for booting a computer system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination