CN112527398A - Personalized installation method and system of operating system - Google Patents

Personalized installation method and system of operating system Download PDF

Info

Publication number
CN112527398A
CN112527398A CN202011468491.4A CN202011468491A CN112527398A CN 112527398 A CN112527398 A CN 112527398A CN 202011468491 A CN202011468491 A CN 202011468491A CN 112527398 A CN112527398 A CN 112527398A
Authority
CN
China
Prior art keywords
operating system
file
server
memory
configuration data
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
CN202011468491.4A
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.)
Beijing Didi Infinity Technology and Development Co Ltd
Original Assignee
Beijing Didi Infinity Technology and Development Co Ltd
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 Beijing Didi Infinity Technology and Development Co Ltd filed Critical Beijing Didi Infinity Technology and Development Co Ltd
Priority to CN202011468491.4A priority Critical patent/CN112527398A/en
Publication of CN112527398A publication Critical patent/CN112527398A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4406Loading of operating system

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The embodiment of the specification provides a method and a system for personalized installation of an operating system. The method is applied to equipment to be installed, and comprises the following steps: acquiring a first compressed file from a first server, wherein the first compressed file comprises a memory operating system compressed file; starting a memory operating system based on the first compressed file; acquiring operating system configuration data from a second server through the memory operating system, wherein the operating system configuration data reflects operating system configuration requirements of the equipment to be installed; acquiring an operating system image file matched with the operating system configuration data from the first server through the memory operating system; and executing the installation of the operating system based on the operating system image file and the operating system configuration data through the memory operating system.

Description

Personalized installation method and system of operating system
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a method and a system for personalized installation of an operating system.
Background
With the increasing demand of the society for Internet Technology (IT) services, the number of IT hardware devices such as servers is also increasing greatly. When the new server device is shipped, the new server device is generally a bare computer without any operating system, and when the new server device is used, the corresponding operating system needs to be manually installed one by one according to specific planning of a user. The operating system has large installation files, and when the operating systems are installed on a large batch of bare computers at the same time, considerable manpower is required, and the consumed time is long.
It is therefore desirable to provide a method and system for the quick and personalized installation of operating systems.
Disclosure of Invention
One aspect of the present specification provides a method for personalized installation of an operating system, which is applied to a device to be installed, and the method for personalized installation of an operating system includes: acquiring a first compressed file from a first server, wherein the first compressed file comprises a memory operating system compressed file; starting a memory operating system based on the first compressed file; acquiring operating system configuration data from a second server through the memory operating system, wherein the operating system configuration data reflects operating system configuration requirements of the equipment to be installed; acquiring an operating system image file matched with the operating system configuration data from the first server through the memory operating system; and executing the installation of the operating system based on the operating system image file and the operating system configuration data through the memory operating system.
In some embodiments, the first compressed file includes a kernel compressed file of a memory operating system, a toolkit compressed file, and a memory hard disk file corresponding to the kernel compressed file; and at least part of the first compressed file is a compressed file in a squashfs mode.
In some embodiments, the obtaining the first compressed file from the first server comprises: acquiring the IP address and the position of the guide file from the third server; acquiring a guide file according to the position of the guide file based on the IP address; and acquiring the first compressed file from the first server through an iPXE protocol according to the guide file.
In some embodiments, the operating system configuration data includes at least hard disk partition configuration data or disk array configuration data.
In some embodiments, the executing, by the memory operating system, an operating system installation based on the operating system image file and the operating system configuration data includes: installing and configuring an operating system based on the operating system configuration data through the memory operating system; and executing the installation of the operating system based on the operating system image file according to the installation configuration of the operating system.
Another aspect of the specification provides a system for personalized installation of an operating system. The system is applied to equipment to be installed, and comprises: the first acquisition module is used for acquiring a first compressed file from a first server, wherein the first compressed file comprises a memory operating system compressed file; the loading module is used for starting a memory operating system based on the first compressed file; a second obtaining module, configured to obtain, by using the memory operating system, operating system configuration data from a second server, where the operating system configuration data reflects an operating system configuration requirement of the device to be installed; a third obtaining module, configured to obtain, from the first server through the memory operating system, an operating system image file that matches the operating system configuration data; and the installation module is used for executing the installation of the operating system based on the operating system image file and the operating system configuration data through the memory operating system.
In some embodiments, the first compressed file includes a kernel compressed file of a memory operating system, a toolkit compressed file, and a memory hard disk file corresponding to the kernel compressed file; and at least part of the first compressed file is a compressed file in a squashfs mode.
In some embodiments, the first obtaining module is further configured to: acquiring the IP address and the position of the guide file from the third server; acquiring a guide file according to the position of the guide file based on the IP address; and acquiring the first compressed file from the first server through an iPXE protocol according to the guide file.
In some embodiments, the operating system configuration data includes at least hard disk partition configuration data or disk array configuration data.
In some embodiments, the installation module is further configured to: installing and configuring an operating system based on the operating system configuration data through the memory operating system; and executing the installation of the operating system based on the operating system image file according to the installation configuration of the operating system.
Another aspect of the present specification provides an electronic device comprising: one or more processors; memory for storing one or more computer programs, wherein the one or more computer programs, when executed by the one or more processors, cause the one or more processors to implement the method for personalized installation of an operating system as previously described.
Another aspect of the present specification provides a computer-readable storage medium storing computer instructions, wherein when the computer instructions in the storage medium are read by a computer, the computer executes the method for personalized installation of an operating system as described above.
Drawings
The present description will be further explained by way of exemplary embodiments, which will be described in detail by way of the accompanying drawings. These embodiments are not intended to be limiting, and in these embodiments like numerals are used to indicate like structures, wherein:
FIG. 1 is a schematic diagram of an application scenario of a method for personalized installation of an operating system, according to some embodiments of the present description;
FIG. 2 is an exemplary block diagram of a system for personalized installation of an operating system, according to some embodiments of the present description;
FIG. 3 is an exemplary flow diagram of a method for personalized installation of an operating system in accordance with some embodiments of the present description;
FIG. 4 is a schematic diagram of an exemplary method of personalized installation of an operating system, according to some embodiments of the present description.
Detailed Description
In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings used in the description of the embodiments will be briefly described below. It is obvious that the drawings in the following description are only examples or embodiments of the present description, and that for a person skilled in the art, the present description can also be applied to other similar scenarios on the basis of these drawings without inventive effort. Unless otherwise apparent from the context, or otherwise indicated, like reference numbers in the figures refer to the same structure or operation.
It should be understood that "system", "apparatus", "unit" and/or "module" as used herein is a method for distinguishing different components, elements, parts, portions or assemblies at different levels. However, other words may be substituted by other expressions if they accomplish the same purpose.
As used in this specification and the appended claims, the terms "a," "an," "the," and/or "the" are not intended to be inclusive in the singular, but rather are intended to be inclusive in the plural, unless the context clearly dictates otherwise. In general, the terms "comprises" and "comprising" merely indicate that steps and elements are included which are explicitly identified, that the steps and elements do not form an exclusive list, and that a method or apparatus may include other steps or elements.
Although various references are made herein to certain modules or units in a system according to embodiments of the present description, any number of different modules or units may be used and run on the client and/or server. The modules are merely illustrative and different aspects of the systems and methods may use different modules.
Flow charts are used in this description to illustrate operations performed by a system according to embodiments of the present description. It should be understood that the preceding or following operations are not necessarily performed in the exact order in which they are performed. Rather, the various steps may be processed in reverse order or simultaneously. Meanwhile, other operations may be added to the processes, or a certain step or several steps of operations may be removed from the processes.
In some embodiments, in the installation process of the operating system of the device with the X86 architecture, because the operating system has a large installation file, an engineer needs to perform analysis while installing hardware to adapt to install a suitable driver, and a physical machine device needs to be restarted many times to enable the driver to take effect, a lot of labor cost and time cost are required to be consumed to complete the installation of the operating system of one device, and the installation efficiency is low. In some embodiments, the operating system may be installed on the device by generating an image of the adjusted operating system. However, different devices may have different configuration requirements for the operating system due to different device configurations, user requirements, and the like, and the requirement for different operating system configurations cannot be met by directly copying the image file of the same operating system.
The embodiment of the present specification provides a method for installing an operating system in a personalized manner, which can perform personalized installation of the operating system according to different operating system configuration requirements of different devices to be installed. In some embodiments, the device to be installed may be configured by a memory operating system (ramos) in a pre-installation manner, and then the operating system installation may be performed on the device to be installed based on operating system configuration data corresponding to the device to be installed and an operating system image file matched with the operating system configuration data. In some embodiments, the device to be installed may boot the memory operating system based on the compressed file associated with the memory operating system to perform the operating system installation. In some embodiments, the memory operating system is started through a compressed file related to the memory operating system, so that the loading rate can be increased; the operating system is installed based on the operating system configuration data corresponding to the equipment to be installed and the operating system image file matched with the operating system configuration data, so that the configuration requirements of different equipment to be installed can be met, the disk space occupancy rate can be reduced, and the operating system installation efficiency can be improved.
Fig. 1 is a schematic diagram of an application scenario of a method for personalized installation of an operating system according to some embodiments of the present description.
As shown in fig. 1, in some embodiments, the scenario 100 may include a device to be installed 110, a first server 120, a second server 130, and a third server 140.
In some embodiments, the device to be installed 110 may obtain the allocated network IP address and the boot file from the third server 140, and obtain a compressed file (e.g., a first compressed file) of the memory operating system based on the boot file; loading a memory operating system in a memory based on the compressed file; and obtains the operating system configuration data matched with the device to be installed 110 from the second server 130 through the memory operating system, obtains the operating system image file matched with the operating system configuration data from the first server 120, and executes the operating system installation based on the obtained operating system configuration data and the operating system image file.
In some embodiments, the device to be installed 110 may comprise a bare metal without any operating system installed. In some embodiments, the device to be installed 110 may comprise an electronic device that has an operating system installed. After the new operating system is installed, the new operating system can coexist with the original installed operating system to form a multi-operating-system environment, or replace the original installed operating system.
In some embodiments, the device to be installed 110 may include, but is not limited to, a personal computer, a network computer, a supercomputer, an embedded computer, an industrial personal computer, and the like. For example, a personal computer may include a notebook 110-1, a desktop 110-2, a personal computer, a palmtop, a tablet, and so forth. Also for example, a network computer may include a server, a workstation, a cluster of computers, and the like. In some embodiments, the device to be installed 110 may be an X86 architecture electronic device. In some embodiments, the device to be installed 110 may be an ARM-architecture electronic device. In some embodiments, the number of devices 110 to be installed in the scenario 100 may be one or more. The one or more devices to be mounted may be the same or different types of electronic devices. One or more devices to be installed may install the same or different types of operating systems simultaneously or in batches.
In some embodiments, the operating system to be installed may include different versions of operating systems of Windows, Linux, Unix, etc. platforms, e.g., personal version, professional version, server version, enterprise version, etc., or any combination thereof. In some embodiments, the operating systems that need to be installed by the multiple devices to be installed 110 may be different releases of the same operating system platform, such as Ubuntu, RedHat, CentOS, etc. of a Linux system platform. In some embodiments, the operating systems that the multiple devices to be installed 110 need to be installed may be different versions of the same operating system, e.g., 20.10, 20.04LTS, 19.10, 18.04LTS, etc. of Ubuntu. In some embodiments, the operating systems that the multiple devices to be installed 110 need to be installed may be different versions of operating systems of different operating system platforms.
The third server 140 may be used to assign a network IP address to the device to be installed 110 and provide a boot file or a location of the boot file. In some embodiments, the boot file may be a file for booting the device to be installed 110 through a network and booting a memory operating system. In some embodiments, the boot file may be located on the third server 140. In some embodiments, the boot file may be located on a storage device, such as a database server, that is external to the third server. In some embodiments, the third server 140 may allocate an IP address and a network location of the boot file to the device to be installed 110 in response to the IP address allocation request of the device to be installed 110. The device to be installed 110 may obtain the bootstrap file according to the network location of the bootstrap file through the allocated IP address. In some embodiments, the third server 140 may include a router, a personal computer, a server, or the like that runs the DHCP protocol.
The second server 130 may be used to provide operating system configuration data required for operating system installation for the device to be installed 110. In some embodiments, the operating system installation configuration data may include partition configuration, disk array, boot information, operating system image file location, etc. data associated with the operating system installation. In some embodiments, second server 130 may store operating system configuration data in a local storage device, or a remote storage device.
In some embodiments, the second server 130 may provide the operating system configuration data corresponding to the to-be-installed device 110 in response to the operating system configuration data acquisition request of the to-be-installed device 110. For example, the second server 130 may return the operating system configuration data matching the device identifier, which is stored in advance, to the device 110 to be installed according to the device identifier of the device 110 to be installed. In some embodiments, the second server 130 may include electronic devices such as a personal computer, a server, a workstation, a mainframe, and so on.
In some embodiments, the first server 120 may be used to provide the operating system image files required for operating system installation for the device to be installed 110. In some embodiments, the operating system image files may include system files and other files of the operating system required by the device to be installed 110. In some embodiments, the first server 120 may provide a memory operating system related compressed file (e.g., a first compressed file) for the device to be installed 110. For example, the first server 120 may provide the device to be installed 110 with a compressed file including a kernel compressed file of a memory operating system, a compressed file of a toolkit, and a compressed file of a memory hard disk corresponding to the kernel compressed file. In some embodiments, first server 120 may be a server supporting the HTTP protocol.
In some embodiments, first server 120, second server 130, and third server 140 may each be a single server or a server farm. In some embodiments, the server farm may be centralized or distributed. In some embodiments, the server may be local or remote. In some embodiments, the server may be implemented on a cloud platform. By way of example only, the cloud platform may include a private cloud, a public cloud, a hybrid cloud, a community cloud, a distributed cloud, across clouds, multiple clouds, the like, or any combination of the above. In some embodiments, the server may be implemented on a computing device, such as a computer, a mobile device, or any device with computing processing capabilities.
In some embodiments, the first server 120, the second server 130, and the third server 140 may be the same server or separate servers. For example, the functions of the first server 120, the second server 130, and the third server 140 may be implemented by different functional modules of the same server. In some embodiments, the boot files, the memory operating system compressed files, the operating system configuration data, the operating system image files, and other data provided by the first server 120, the second server 130, and the third server 140 to the device to be installed 110 may be stored on a dedicated storage device such as a database.
In some embodiments, the scenario 100 may also include a network and a storage device.
The network may facilitate the exchange of information and/or data. In some embodiments, one or more components in the scenario 100 may send information and/or data to other components in the scenario 100 over a network. For example, the device to be installed 110 may acquire an IP address from the third server 140 through a network. For another example, the device to be installed 110 may obtain operating system configuration data from the second server 130 through a network. In some embodiments, the network may be any one or combination of a wired network or a wireless network. By way of example only, the network may include a cable network, a wired network, a fiber optic network, a remote communication network, an intranet, the internet, a Local Area Network (LAN), a Wide Area Network (WAN), a Wireless Local Area Network (WLAN), a Metropolitan Area Network (MAN), a Wide Area Network (WAN), a Public Switched Telephone Network (PSTN), a bluetooth network, a ZigBee network, a Near Field Communication (NFC) network, the like, or any combination of the above. In some embodiments, the network may include one or more network switching points. For example, the network may include a wired or wireless network switching point through which one or more components of the scenario 100 may connect to the network to exchange data and/or information.
The memory device may be used to store data and/or instructions. For example, the storage device may store a system compressed file of a memory operating system. As another example, the storage device may store an operating system image file. In some embodiments, the storage device may include mass storage, removable storage, volatile read-write memory, read-only memory (ROM), the like, or any combination of the above. Exemplary mass storage devices may include magnetic disks, optical disks, solid state disks, and the like. Exemplary removable memory may include flash drives, floppy disks, optical disks, memory cards, compact disks, magnetic tape, and the like. In some embodiments, the storage may be implemented on a cloud platform. By way of example only, the cloud platform may include a private cloud, a public cloud, a hybrid cloud, a community cloud, a distributed cloud, across clouds, multiple clouds, the like, or any combination of the above.
In some embodiments, the storage may be connected to a network to communicate with one or more components in the scenario 100 (e.g., the device to be installed 110, the first server 120, the second server 130, etc.). One or more components in the scenario 100 may access data or instructions stored in a storage device over a network. In some embodiments, the storage device may be directly connected or in communication with one or more components (e.g., second server 130, third server 140) in the scenario 100. In some embodiments, the storage device may be part of first server 120, second server 130, and/or third server 140.
In some alternative embodiments, the scenario 100 may further include other components for operating system installation, for example, a server dedicated to providing the in-memory operating system compressed file, and the like, which is not limited in this specification.
FIG. 2 is an exemplary block diagram of a system for personalized installation of an operating system, according to some embodiments of the present description.
As shown in fig. 2, in some embodiments, the system 200 may include a first acquisition module 210, a loading module 220, a second acquisition module 230, a third acquisition module 240, and an installation module 250. These modules may also be implemented as an application or a set of instructions that are read and executed by a processing engine. Further, a module may be any combination of hardware circuitry and applications/instructions. For example, a module may be part of a processor when a processing engine or processor executes an application/set of instructions. In some embodiments, the system 200 may be part of a terminal device (e.g., the device 110 to be installed).
The first obtaining module 210 may be configured to obtain a memory operating system compressed file. For example, the first obtaining module 210 may obtain a first compressed file from the first server 120, where the first compressed file includes a memory operating system compressed file. For example only, the first obtaining module 210 may obtain the IP address and the location of the boot file from the third server 140; acquiring a guide file according to the position of the guide file based on the IP address; and according to the guide file, acquiring the first compressed file from the first server 120 through an iPXE protocol. In some embodiments, the first compressed file may include a kernel compressed file of a memory operating system, a toolkit compressed file, a memory hard disk file corresponding to the kernel compressed file, and the like. In some embodiments, at least a portion of the first compressed file may be a squashfs style compressed file.
The loading module 220 may be used to load programs or data. For example, the loading module 220 may start the memory operating system based on the first compressed file.
The second obtaining module 230 may be used to obtain operating system configuration data. For example, the second obtaining module 230 may obtain the operating system configuration data from the second server 130 through the memory operating system. The operating system configuration data reflects operating system configuration requirements of the device to be installed. In some embodiments, the operating system configuration data may include hard disk partition configuration data or disk array configuration data.
The third obtaining module 240 may be configured to obtain the operating system image file. For example, the third obtaining module 240 may obtain, from the first server 120, an operating system image file matching the operating system configuration data through the memory operating system.
Installation module 250 may be used to perform operating system installation. For example, the installation module 250 may execute, through the memory operating system, the operating system installation based on the operating system image file and the operating system configuration data corresponding to the device to be installed 110. In some embodiments, the installation module 250 may perform operating system installation configuration on the device to be installed (e.g., the device to be installed 110) through the memory operating system based on the operating system configuration data, and execute operating system installation based on the operating system image file according to the operating system installation configuration.
It should be understood that the illustrated system and its modules may be implemented in a variety of ways. For example, in some embodiments, system 200 and its modules may be implemented in hardware, software, or a combination of software and hardware. Wherein the hardware portion may be implemented using dedicated logic; the software portions may be stored in a memory for execution by a suitable instruction execution system, such as a microprocessor or specially designed hardware. Those skilled in the art will appreciate that the methods and systems described above may be implemented using computer executable instructions and/or embodied in processor control code, such code being provided, for example, on a carrier medium such as a diskette, CD-or DVD-ROM, a programmable memory such as read-only memory (firmware), or a data carrier such as an optical or electronic signal carrier. The system and its modules in this specification may be implemented not only by hardware circuits such as very large scale integrated circuits or gate arrays, semiconductors such as logic chips, transistors, or programmable hardware devices such as field programmable gate arrays, programmable logic devices, etc., but also by software executed by various types of processors, for example, or by a combination of the above hardware circuits and software (e.g., firmware).
It should be noted that the above description of the system 200 and its modules is merely for convenience of description and should not limit the present disclosure to the illustrated embodiments. It will be appreciated by those skilled in the art that, given the teachings of the present system, any combination of modules or sub-system configurations may be used to connect to other modules without departing from such teachings. In some embodiments, the first obtaining module 210, the loading module 220, the second obtaining module 230, the third obtaining module 240, and the installing module 250 may be different modules in one system, or may be one module to implement the functions of two or more modules described above. In some embodiments, the first obtaining module 210, the loading module 220, the second obtaining module 230, the third obtaining module 240, and the installing module 250 may share one storage module, and each module may also have its own storage module. Such variations are within the scope of the present disclosure.
FIG. 3 is an exemplary flow diagram of a method for personalized installation of an operating system, according to some embodiments of the present description.
As shown in fig. 3, in some embodiments, the method 300 may be performed by a device to be installed (e.g., the device to be installed 110). For example, the method 300 may be stored in the form of a program or instructions in a storage of the device to be installed 110, which when executed by the device to be installed 110, may implement the method 300. In some embodiments, the method 300 may be performed by the personalization installation system 200 of the operating system. For ease of understanding, the method 300 will be described with respect to installation of a Linux operating system as an example.
Step 310, the IP address and the location of the boot file are obtained from the third server. In some embodiments, step 310 may be performed by the first acquisition module 210.
An IP Address (Internet Protocol Address), which is an Internet Protocol Address and may also be referred to as an Internet Protocol Address, is a way to Address a host on the Internet. IP addresses are a unified address format provided by internet protocol that can mask differences in physical addresses by assigning a logical address to each network and/or each host on a computer network, thereby enabling all computer devices connected to the network to communicate with each other.
Boot files refer to files that are loaded or used at boot-up of a device or some process, which may be used to indicate desired operations in the boot. In some embodiments, the boot file may be a file that is loaded when the iPXE is started. In some embodiments, the boot file may be a file that boots a memory operating system boot. In some embodiments, the location of the boot file may be preconfigured on a third server (e.g., third server 140).
In some embodiments, the device to be installed may initiate a request for obtaining the IP address and the location of the boot file to the third server through network initiation, and the third server may allocate the IP address to the device to be installed according to the request and send the location of the boot file at the same time. In some embodiments, the third server may comprise a DHCP server. In some embodiments, the network boot may include the PXE protocol and the iPXE protocol. The Preboot eXecution Environment (PXE) protocol provides a mechanism for booting a computer using a Network Interface (Network Interface). This mechanism may enable the computer to boot without relying on a local data storage device (e.g., hard disk) or a locally installed operating system. The iPXE protocol is an extended and improved version of the PXE protocol, and compared with the PXE protocol, the iPXE protocol has richer functions and faster starting speed. In some embodiments, the iPXE protocol may be initiated by HTTP, ISCSI SAN, Fibre Channel SAN via FCoE, AoE SAN, wireless network, Infiniband network, or the like.
For example only, the device to be installed 110 may be started through a PXE network of the network card, and broadcast a DHCP discovery message in the network to find a DHCP server (i.e., a third server), and after receiving the discovery message, the DHCP server sends a DHCPOFFER to the device to be installed 110 in response; after receiving the response message from the DHCP server, the device to be installed 110 requests the DHCP server to obtain the IP address and the location of the boot file, and after receiving the request, the DHCP server allocates the IP address and the location of the boot file to the device to be installed 110.
And step 320, acquiring the boot file according to the position of the boot file based on the IP address. In some embodiments, step 320 may be performed by the first acquisition module 210.
In some embodiments, the boot file may be stored on the third server, or on a server other than the third server. In some embodiments, the device to be installed may obtain the corresponding boot file from the specified location according to the location of the boot file. In some embodiments, the boot file may include an iPXE boot file and a configuration file associated with a memory operating system, for example, the iPXE boot file unidionly. The configuration file may be used to specify the location of kernel files, memory disk files, and other files of the memory operating system.
In some embodiments, the location of the boot file may be an IP address based network file path. The device to be installed may obtain the boot file from the device storing the file through the file path based on the IP address assigned by the third server.
Step 330, according to the boot file, obtaining a first compressed file from the first server through an iPXE protocol. In some embodiments, step 330 may be performed by the first acquisition module 210.
The first compressed file is a compressed file of a file related to the memory operating system. For example, the first compressed file may include one or more of a memory operating system kernel compressed file, a memory disk file corresponding to the kernel compressed file, a toolkit compressed file, and the like. The kernel of the memory operating system is a core file of the memory operating system and comprises the most basic and core functions of the memory operating system; the memory disk file comprises system files of other memory operating systems except the kernel of the memory operating system; the tool pack compressed file contains applications such as tools required when using the memory operating system.
In some embodiments, the first compressed file may include only the memory operating system kernel compressed file and the corresponding memory disk file, and applications such as tools required when using the memory operating system may be included in the memory disk file.
In some embodiments, the first compressed file may be obtained by separately packaging a compressed memory operating system kernel, a memory disk file, an application tool file, and the like. In some embodiments, the first compressed file may be in the form of various compressed packages, e.g., img, tar, zip, iso, etc., or any combination thereof.
In some embodiments, at least a portion of the first compressed file may be packed and compressed using a squashfs approach, e.g., the toolkit compressed file may be squashfs. squashfs is a read-only file system that can compress the entire file system together, either in a device, a partition, or a common file. Taking Linux operating system as an example, packing applications in the squashfs mode may include dependency between Linux applications, so that the applications can be completely packed.
In some embodiments, the first compressed file may be located at or obtained by the first server. For example, the device to be installed 110 may obtain the first compressed file from the storage device in the first server 120, or obtain the first compressed file obtained by the first server 120 from other devices from the first server 120. In some embodiments, the device to be installed may obtain a location of the first compressed file according to the configuration file in the boot file, and obtain the first compressed file from the first server according to the location. In some embodiments, the device to be installed may obtain the first compressed file from another server.
In some embodiments, after the iPXE is booted, the device to be installed may obtain the first compressed file and/or other files in other manners supported by the HTTP protocol or the iPXE protocol.
Step 340, starting the memory operating system based on the first compressed file. In some embodiments, step 340 may be performed by load module 220.
In some embodiments, the device to be installed may load the first compressed file, release the file therein to the memory of the device to be installed, and then start the memory operating system. In some embodiments, the device to be installed may directly start the memory operating system based on the content in the first compressed file.
Step 350, obtaining operating system configuration data from the second server through the memory operating system. In some embodiments, step 350 may be performed by the second acquisition module 230.
The operating system configuration data may reflect operating system configuration requirements of the device to be installed. In some embodiments, the operating system configuration data may include operating system installation configuration, operating system image file configuration, and the like. For example, the operating system installation configuration may include information such as disk partition configuration data or disk array configuration data, and the operating system image file configuration may include information such as the location of the operating system image file.
A RAID (Redundant Arrays of Independent Disks) is a disk assembly with a large capacity, which can improve the performance of the entire disk system by utilizing the additive effect of data provided by individual Disks.
Operating system installation configuration is the configuration work before the operating system is installed, and the work comprises one or more of disk array configuration, disk partitioning, file system creation, system directory creation and the like. The disk partition configuration data may include a partition format, a partition size, a partition volume label, and the like of the disk, which determine a specific partition condition of the disk. The disk array configuration data may include whether a disk array is created, the type of disk array (e.g., RAID 0, RAID 1, RAID 5, etc.), the composition of the disk array, etc., which determines how the disk array is configured.
In some embodiments, after the device to be installed is started up in the memory operating system, the operating system configuration data required for installing the operating system may be acquired from the second server through an HTTP protocol or other methods according to a preset server address.
In some embodiments, the operating system configuration data corresponding to the device to be installed may be determined according to the identification characteristics of the device. For example, the device to be installed 110 may request the second server 130 to obtain the operating system configuration data, and the second server 130 may determine the operating system configuration data corresponding to the device to be installed 110 according to the hardware configuration and/or the serial number of the device to be installed 110, and return the operating system configuration data to the device to be installed 110. In some embodiments, the device to be installed may look up and obtain its corresponding operating system configuration data from the second server directly based on its identification characteristics. For example, the device to be installed 110 may search the second server 130 for a file name matching its serial number based on the file name of the second server 130, and obtain corresponding operating system configuration data from the corresponding file.
And step 360, acquiring an operating system image file matched with the operating system configuration data from the first server through the memory operating system. In some embodiments, step 360 may be performed by the third acquisition module 240.
In some embodiments, the device to be installed may obtain, through the memory operating system, an operating system image file matching the configuration from the first server according to the operating system image file configuration in the obtained operating system configuration data. For example, the device to be installed 110 may obtain the os image from the corresponding location of the first server 120 according to the location information of the os image in the os image configuration, and store the os image in a directory of the memory os, that is, in the memory of the device to be installed 110. In some embodiments, the first server (e.g., first server 120) may be an HTTP server.
In some embodiments, the operating system image file configuration may include identifying information for the operating system image file, such as a file name, a file number, and the like. Through the identification file, the operating system image file can be acquired. In some embodiments, the operating system image file configuration may include the type of operating system that the device to be installed needs to install. The device to be installed can acquire the matched operating system image file from the first server according to the operating system type.
In some embodiments, the operating system image file may be an operating system compressed file (also referred to as a second compressed file). In some embodiments, the operating system image file may be an operating system root file.
In general, an image file of an operating system is a complete copy of a disk or a partition where the operating system is located, and this way strictly copies the current state of the disk or the partition where the operating system is located, which may contain a lot of useless data, and may result in a large file size and a long time consuming release of the image file. In the embodiment of the description, when the operating system image file is obtained, the operating system file and other necessary files required by the equipment to be installed are copied and compressed, so that redundant data is reduced, the image file is small in size and short in release time, and the operating system installation efficiency can be improved.
Step 370, executing operating system installation by the memory operating system based on the operating system image file and the operating system configuration data. In some embodiments, step 370 may be performed by installation module 250.
In some embodiments, the device to be installed may perform configuration before installation of the operating system according to operating system installation configuration data in the operating system configuration data through the memory operating system, and then execute operating system installation based on the operating system image file according to the operating system installation configuration.
By way of example only, the configuration of the operating system prior to installation may include: creating sda partition volume labels, creating boot partitions (the necessary boot partitions of Linux kernel and kernel files are all in this directory), creating other partitions according to the partition configuration corresponding to the device to be installed, setting boot partitions as active records (the purpose is to make the boot loader know that an operating system is on this partition when starting up), creating file systems for partitions (for reading and writing files), making exchange partitions (for preparation of Linux virtual memory management), creating operating system installation directories (for temporarily storing operating system image files), creating boot file systems (for normal writing when operating system image files are released), binding device directories of image operating systems to device directories of memory operating systems (for operating hardware devices in the operating system image files), creating proc directories (when operating system image files are packaged, proc directories are memory directories, so packaging is not needed, and a proc directory is needed after system boot), etc.
In some embodiments, after the operating system installation configuration is completed, the operating system image file in the memory operating system may be downloaded to a temporary directory on the hard disk of the device to be installed, for example, a system installation directory, and then the operating system image file is released to the hard disk of the device to be installed, so as to execute the operating system installation.
In some embodiments, after releasing the operating system image file onto the hard disk of the device to be installed, generating a bootloader may be further included so that a loader (e.g., loading module 220) of the device to be installed may find the kernel.
In the embodiment of the present description, bare computers configured by the same hardware may use different operating system installation configuration data to perform configuration before installation, such as booting, partitioning, raid, and the like, according to specific requirements, so that each bare computer may use a specific configuration scheme and has good adaptability to different scenarios; the installation configuration of the operating system is separated from the actual installation of the operating system, the same or different installation configurations of the operating system and the same or different image file configurations of the operating system can be combined randomly for bare computers with the same configuration, the flexibility is higher, the application range is wider, and the specific requirements can be better met; the memory operating system is used for completing the operating system installation configuration and the operating system installation work, the function is stronger, more installation configuration functions can be realized, the running speed is high, and the disk space is not occupied.
It should be noted that the above description of method 300 is for purposes of example and illustration only and is not intended to limit the scope of applicability of the present description. Various modifications and alterations to method 300 will become apparent to those skilled in the art in light of the present description. However, such modifications and variations are intended to be within the scope of the present description.
FIG. 4 is a schematic diagram of an exemplary method of personalized installation of an operating system, according to some embodiments of the present description.
As shown in fig. 4, in a specific embodiment, the device to be installed 110 may request the third server 140 to obtain an IP address and an address of the boot file by sending a message; the third server 140 may return the IP address and the location of the boot file to the device to be installed 110 according to the request of the device to be installed 110. The device to be installed 110 may obtain the bootstrap files uncondionly. Further, the device to be installed 110 may request the first server 120 to obtain a first compressed file according to the location of the memory operating system compressed file in the boot file realboot. The first server 120 may return the first compressed file thereto according to a request of the to-be-installed device 110. Illustratively, the first compressed file may include a kernel compressed file vmlinux and a corresponding memory disk file initrd.img of a memory operating system, and a toolkit compressed file squashfs.img. The device to be installed 110 may load and start the memory operating system based on the obtained first compressed file. After the memory operating system is started, the device to be installed 110 may request the second server 130 to obtain operating system configuration data; the second server 130 may search for operating system configuration data corresponding to the device to be installed 110 based on its device number (e.g., device serial number) according to the request of the device to be installed 110 and return the operating system configuration data to the device to be installed 110. Then, the to-be-installed device 110 after the memory os is started may obtain, from the first server 120, an os image file matching the os configuration data based on the os configuration data. Finally, the device to be installed 110 may perform operating system installation configuration based on the operating system configuration data through the memory operating system, for example, create an sda partition, a boot partition, an operating system installation directory, and execute operating system installation after releasing the operating system image file to the disk according to the operating system installation configuration.
It should be understood that the above-described embodiments are illustrative only and not limiting to the present application, and that various modifications and changes to fig. 4 and its related description may be made by those skilled in the art in light of the present disclosure. However, such modifications and variations are intended to be within the scope of the present description.
The beneficial effects that may be brought by the embodiments of the present description include, but are not limited to: (1) the operating system image file which is matched with the operating system configuration data of the equipment to be installed and only comprises necessary system files is used, so that the occupation of disk space and network resources can be reduced, and the installation efficiency of the operating system is improved; (2) according to the specific requirements of the equipment to be installed, corresponding operating system configuration data and operating system image files are obtained, and operating system installation is executed, so that the adaptability is good, and the flexibility is high; (3) the memory operating system is started by using the compressed file of the memory operating system instead of acquiring the file of the whole memory operating system, so that the loading speed and the installation efficiency can be improved. Different embodiments may produce different advantages, and in different embodiments, the advantages may be any one or combination of the above, or any other advantages that may be obtained.
Having thus described the basic concept, it will be apparent to those skilled in the art that the foregoing detailed disclosure is to be regarded as illustrative only and not as limiting the present specification. Various modifications, improvements and adaptations to the present description may occur to those skilled in the art, although not explicitly described herein. Such modifications, improvements and adaptations are proposed in the present specification and thus fall within the spirit and scope of the exemplary embodiments of the present specification.
Also, the description uses specific words to describe embodiments of the description. Reference throughout this specification to "one embodiment," "an embodiment," and/or "some embodiments" means that a particular feature, structure, or characteristic described in connection with at least one embodiment of the specification is included. Therefore, it is emphasized and should be appreciated that two or more references to "an embodiment" or "one embodiment" or "an alternative embodiment" in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, some features, structures, or characteristics of one or more embodiments of the specification may be combined as appropriate.
Additionally, the order in which the elements and sequences of the process are recited in the specification, the use of alphanumeric characters, or other designations, is not intended to limit the order in which the processes and methods of the specification occur, unless otherwise specified in the claims. While various presently contemplated embodiments of the invention have been discussed in the foregoing disclosure by way of example, it is to be understood that such detail is solely for that purpose and that the appended claims are not limited to the disclosed embodiments, but, on the contrary, are intended to cover all modifications and equivalent arrangements that are within the spirit and scope of the embodiments herein. For example, although the system components described above may be implemented by hardware devices, they may also be implemented by software-only solutions, such as installing the described system on an existing server or mobile device.
Similarly, it should be noted that in the preceding description of embodiments of the present specification, various features are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the disclosure aiding in the understanding of one or more of the embodiments. This method of disclosure, however, is not intended to imply that more features than are expressly recited in a claim. Indeed, the embodiments may be characterized as having less than all of the features of a single embodiment disclosed above.
Numerals describing the number of components, attributes, etc. are used in some embodiments, it being understood that such numerals used in the description of the embodiments are modified in some instances by the use of the modifier "about", "approximately" or "substantially". Unless otherwise indicated, "about", "approximately" or "substantially" indicates that the number allows a variation of ± 20%. Accordingly, in some embodiments, the numerical parameters used in the specification and claims are approximations that may vary depending upon the desired properties of the individual embodiments. In some embodiments, the numerical parameter should take into account the specified significant digits and employ a general digit preserving approach. Notwithstanding that the numerical ranges and parameters setting forth the broad scope of the range are approximations, in the specific examples, such numerical values are set forth as precisely as possible within the scope of the application.
For each patent, patent application publication, and other material, such as articles, books, specifications, publications, documents, etc., cited in this specification, the entire contents of each are hereby incorporated by reference into this specification. Except where the application history document does not conform to or conflict with the contents of the present specification, it is to be understood that the application history document, as used herein in the present specification or appended claims, is intended to define the broadest scope of the present specification (whether presently or later in the specification) rather than the broadest scope of the present specification. It is to be understood that the descriptions, definitions and/or uses of terms in the accompanying materials of this specification shall control if they are inconsistent or contrary to the descriptions and/or uses of terms in this specification.
Finally, it should be understood that the embodiments described herein are merely illustrative of the principles of the embodiments of the present disclosure. Other variations are also possible within the scope of the present description. Thus, by way of example, and not limitation, alternative configurations of the embodiments of the specification can be considered consistent with the teachings of the specification. Accordingly, the embodiments of the present description are not limited to only those embodiments explicitly described and depicted herein.

Claims (12)

1. A personalized installation method of an operating system is applied to equipment to be installed, and is characterized by comprising the following steps:
acquiring a first compressed file from a first server, wherein the first compressed file comprises a memory operating system compressed file;
starting a memory operating system based on the first compressed file;
acquiring operating system configuration data from a second server through the memory operating system, wherein the operating system configuration data reflects operating system configuration requirements of the equipment to be installed;
acquiring an operating system image file matched with the operating system configuration data from the first server through the memory operating system;
and executing the installation of the operating system based on the operating system image file and the operating system configuration data through the memory operating system.
2. The method of claim 1, wherein the first compressed file comprises a kernel compressed file of a memory operating system, a toolkit compressed file, and a memory hard disk file corresponding to the kernel compressed file; and
at least part of the first compressed file is a compressed file in a squashfs mode.
3. The method of claim 1, wherein obtaining the first compressed file from the first server comprises:
acquiring the IP address and the position of the guide file from the third server;
acquiring a guide file according to the position of the guide file based on the IP address;
and acquiring the first compressed file from the first server through an iPXE protocol according to the guide file.
4. The method of claim 1, wherein the operating system configuration data comprises at least hard disk partition configuration data or disk array configuration data.
5. The method of claim 1, wherein performing, by the memory operating system, an operating system installation based on the operating system image file and the operating system configuration data comprises: by means of the memory operating system, it is possible to,
performing operating system installation configuration based on the operating system configuration data;
and executing the installation of the operating system based on the operating system image file according to the installation configuration of the operating system.
6. A personalized installation system of an operating system is applied to equipment to be installed, and is characterized by comprising:
the first acquisition module is used for acquiring a first compressed file from a first server, wherein the first compressed file comprises a memory operating system compressed file;
the loading module is used for starting a memory operating system based on the first compressed file;
a second obtaining module, configured to obtain, by using the memory operating system, operating system configuration data from a second server, where the operating system configuration data reflects an operating system configuration requirement of the device to be installed;
a third obtaining module, configured to obtain, from the first server through the memory operating system, an operating system image file that matches the operating system configuration data;
and the installation module is used for executing the installation of the operating system based on the operating system image file and the operating system configuration data through the memory operating system.
7. The system of claim 6, wherein the first compressed file comprises a kernel compressed file of a memory operating system, a toolkit compressed file, and a memory hard disk file corresponding to the kernel compressed file; and
at least part of the first compressed file is a compressed file in a squashfs mode.
8. The system of claim 6, wherein the first acquisition module is further to:
acquiring the IP address and the position of the guide file from the third server;
acquiring a guide file according to the position of the guide file based on the IP address;
and acquiring the first compressed file from the first server through an iPXE protocol according to the guide file.
9. The system of claim 6, wherein the operating system configuration data includes at least hard disk partition configuration data or disk array configuration data.
10. The system of claim 6, wherein the installation module is to: by means of the memory operating system, it is possible to,
performing operating system installation configuration based on the operating system configuration data;
and executing the installation of the operating system based on the operating system image file according to the installation configuration of the operating system.
11. An electronic device, comprising:
one or more processors;
a memory for storing one or more computer programs,
wherein the one or more computer programs, when executed by the one or more processors, cause the one or more processors to implement the method of any of claims 1-5.
12. A computer-readable storage medium storing computer instructions which, when read by a computer, cause the computer to perform the method of any one of claims 1-5.
CN202011468491.4A 2020-12-14 2020-12-14 Personalized installation method and system of operating system Pending CN112527398A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011468491.4A CN112527398A (en) 2020-12-14 2020-12-14 Personalized installation method and system of operating system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011468491.4A CN112527398A (en) 2020-12-14 2020-12-14 Personalized installation method and system of operating system

Publications (1)

Publication Number Publication Date
CN112527398A true CN112527398A (en) 2021-03-19

Family

ID=74999635

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011468491.4A Pending CN112527398A (en) 2020-12-14 2020-12-14 Personalized installation method and system of operating system

Country Status (1)

Country Link
CN (1) CN112527398A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113495732A (en) * 2021-06-21 2021-10-12 中国普天信息产业股份有限公司 Server deployment method, device, equipment and readable storage medium
CN113821264A (en) * 2021-10-11 2021-12-21 成都统信软件技术有限公司 Operating system installation control method, installation control system and computing equipment
CN114911650A (en) * 2022-07-19 2022-08-16 浩鲸云计算科技股份有限公司 Method and system for retrogradable security reinforcement based on RAMOS system
CN116016159A (en) * 2022-12-16 2023-04-25 北京云端智度科技有限公司 Tamper-proof installation method, tamper-proof installation system, tamper-proof installation medium and tamper-proof installation equipment for application system

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113495732A (en) * 2021-06-21 2021-10-12 中国普天信息产业股份有限公司 Server deployment method, device, equipment and readable storage medium
CN113821264A (en) * 2021-10-11 2021-12-21 成都统信软件技术有限公司 Operating system installation control method, installation control system and computing equipment
CN113821264B (en) * 2021-10-11 2023-09-12 成都统信软件技术有限公司 Operating system installation control method, installation control system and computing device
CN114911650A (en) * 2022-07-19 2022-08-16 浩鲸云计算科技股份有限公司 Method and system for retrogradable security reinforcement based on RAMOS system
CN114911650B (en) * 2022-07-19 2022-10-18 浩鲸云计算科技股份有限公司 Method and system for retrogradable security reinforcement based on RAMOS
CN116016159A (en) * 2022-12-16 2023-04-25 北京云端智度科技有限公司 Tamper-proof installation method, tamper-proof installation system, tamper-proof installation medium and tamper-proof installation equipment for application system

Similar Documents

Publication Publication Date Title
CN112527398A (en) Personalized installation method and system of operating system
US9286098B1 (en) Using master file template area to increase density of virtual machines in a computer system
US9811369B2 (en) Method and system for physical computer system virtualization
US20080235482A1 (en) Live Migration of a Logical Partition
US8185684B1 (en) Method and apparatus for resolving volume identifiers associated with a virtual machine
US9817592B1 (en) Using an intermediate virtual disk format for virtual disk conversion
CN113835644B (en) Complete machine migration method, device, equipment and storage medium
CN110806911B (en) Cloud desktop management and control method, device and system
CN111124286A (en) Libcloud-based multi-cloud management implementation method
CN109960569B (en) Virtualization processing method and device
CN104182257A (en) Application software installation method and device
CN115390996A (en) Virtual machine migration method and device, computing equipment and storage medium
CN108459822B (en) Installation method and device of operating system
US20200257569A1 (en) Methods for operating storage driver in container environment and storage driver apparatuses
US20130024856A1 (en) Method and apparatus for flexible booting virtual storage appliances
US11249780B2 (en) VM creation by installation media probe
CN113918274A (en) Docker container-based KVM virtual machine migration method
US11915024B2 (en) Pool management for in-vehicle device application startup
CN111683145A (en) Configuration method of client device, electronic device and medium
JP6745405B2 (en) Storage system and mapping method
WO2010014080A1 (en) Resource deployment management
JP6497157B2 (en) Information management apparatus, information management method, information management program, data structure, and software asset management system
US20210271427A1 (en) Extracting drive letters for partitions in an offline virtual disk
US20200050440A1 (en) Application upgrading through sharing dependencies
KR101554554B1 (en) Method for driving verture machine and and system thereof

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