CN113867825A - Multi-system operation method, computing equipment and storage medium - Google Patents

Multi-system operation method, computing equipment and storage medium Download PDF

Info

Publication number
CN113867825A
CN113867825A CN202111448513.5A CN202111448513A CN113867825A CN 113867825 A CN113867825 A CN 113867825A CN 202111448513 A CN202111448513 A CN 202111448513A CN 113867825 A CN113867825 A CN 113867825A
Authority
CN
China
Prior art keywords
boot
operating system
file
manager
starting
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.)
Granted
Application number
CN202111448513.5A
Other languages
Chinese (zh)
Other versions
CN113867825B (en
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.)
Uniontech Software Technology Co Ltd
Original Assignee
Uniontech Software Technology 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 Uniontech Software Technology Co Ltd filed Critical Uniontech Software Technology Co Ltd
Priority to CN202111448513.5A priority Critical patent/CN113867825B/en
Publication of CN113867825A publication Critical patent/CN113867825A/en
Application granted granted Critical
Publication of CN113867825B publication Critical patent/CN113867825B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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
    • G06F9/441Multiboot arrangements, i.e. selecting an operating system to be loaded
    • 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/445Program loading or initiating
    • G06F9/44505Configuring for program initiating, e.g. using registry, configuration files
    • 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/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • 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/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45575Starting, stopping, suspending or resuming virtual machine instances

Landscapes

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

Abstract

The invention discloses a multi-system operation method, a computing device and a storage medium, and the method comprises the following steps: installing a second operating system and generating a second boot file; generating a second starting configuration file; generating a first boot manager; starting a second operating system according to the second boot file, the first starting manager and the second starting configuration file; constructing a virtual operating environment in a second operating system, constructing a third boot file and a third start configuration file in the virtual operating environment, and constructing a second start manager according to the first start manager and the third start configuration file; running the first operating system in the virtual running environment according to the third boot file, the second starting manager and the third starting configuration file; generating a fourth boot file; generating a fourth starting configuration file; and generating a third starting manager and a fourth starting manager according to the second starting manager. When a computer runs a plurality of operating systems, the boot path between each operating system is isolated.

Description

Multi-system operation method, computing equipment and storage medium
Technical Field
The present invention relates to the field of operating systems, and in particular, to a multi-system operating method, a computing device, and a storage medium.
Background
With the development of computer technology, people sometimes need to run multiple operating systems in a computer. When a plurality of operating systems are run, the operating systems are all stored in the external memory and need to be started through the external memory.
In the operation mode, because the boot paths are the same and share one set of boot modes, modification of boot of one operating system can affect another operating system; and easily causes one system to enter twice the corrupted file system, causing the system to crash.
For this reason, a new method of multi-system operation is required.
Disclosure of Invention
To this end, the present invention provides a method of multi-system operation in an attempt to solve or at least alleviate the above-identified problems.
According to an aspect of the present invention, there is provided a multi-system operation method, adapted to be executed in a computing device, the computing device being operated with a first operating system and storing a first boot configuration file and a first boot file adapted to boot the first operating system, the method comprising the steps of: installing a second operating system, and adding a second boot item of the second operating system in the first boot file to generate a second boot file; adding a second starting configuration item of a second operating system in the first starting configuration file to generate a second starting configuration file; generating a first starting manager according to the second starting configuration file; starting a second operating system according to the second boot file, the first starting manager and the second starting configuration file; constructing a virtual operating environment in a second operating system, constructing a third boot file and a third start configuration file in the virtual operating environment, and constructing a second start manager according to the first start manager and the third start configuration file so as to start the first operating system in the virtual operating environment according to the third boot file, the second start manager and the third start configuration file; and generating a third starting manager and a fourth starting manager according to the second starting manager so as to start the second operating system according to the fourth starting manager and start the first operating system in the virtual running environment according to the third starting manager.
Optionally, in the method according to the present invention, further comprising the step of: generating a fourth boot file according to the second boot file, wherein the fourth boot file comprises a boot item of the second operating system; and generating a fourth starting configuration file according to the second starting configuration file, wherein the fourth starting configuration file comprises a starting configuration item of the second operating system so as to start the second operating system according to the fourth boot file, the fourth starting configuration file and the fourth starting manager, and start the first operating system in the virtual running environment according to the third boot file, the third starting manager and the third starting configuration file.
Optionally, in the method according to the present invention, the first boot file includes a first boot entry for booting to start the first operating system, and the second boot file includes the first boot entry and a second boot entry for booting to start the second operating system.
Optionally, in the method according to the present invention, the first boot configuration file includes a first boot configuration item for loading the first operating system kernel, and the second boot configuration file includes the first boot configuration item and a second boot configuration item for loading the second operating system kernel.
Optionally, in the method according to the present invention, generating the first boot manager according to the second boot profile includes: generating an option for selecting to start the first operating system according to the first starting configuration item, so that when the user selects, executing the first starting configuration item of the first operating system to run the first operating system; generating an option for selecting to start the second operating system according to the second starting configuration item, so that when the user selects, the first starting configuration item of the second operating system is executed to run the second operating system; and generating a first starting manager according to the option of selecting to start the first operating system and the option of selecting to start the second operating system.
Optionally, in a method according to the present invention, the computing device includes an external memory, and booting the second operating system according to the second boot file, the first boot manager, and the second boot configuration file includes the steps of: reading the second boot file, and determining a storage partition of the external memory of the first boot manager according to a second boot item of the second boot file; running the first boot manager according to the memory partition of the first boot manager; and executing a second starting configuration item of the second starting configuration file according to the first starting manager to start the second operating system.
Optionally, in the method according to the present invention, building a virtual execution environment in the second operating system, building a third boot file and a third boot configuration file in the virtual execution environment includes the steps of: obtaining a virtual disk address stored in a virtual disk by a first operating system according to a physical disk address stored in an external memory of the first operating system; and generating a third boot file and a third start configuration file according to the virtual disk address, and storing the third boot file and the third start configuration file in the virtual disk.
Optionally, in the method according to the present invention, the third boot file includes a third boot item for booting the first operating system, and the third boot configuration file includes a third boot configuration item for loading the first operating system.
Optionally, in the method according to the present invention, building the second boot manager according to the first boot manager and the third boot profile includes the steps of: generating an option for selecting to start the first operating system according to a third start configuration item of the third start configuration file, so that when the user selects, the third start configuration item of the first operating system is executed to run the first operating system; and combining the option for starting the first operating system generated according to the third starting configuration item with the option for starting the second operating system in the first starting manager to obtain a third starting manager.
Optionally, in the method according to the present invention, starting the first operating system in the virtual execution environment according to the third boot file, the second boot manager, and the third boot configuration file includes the steps of: reading a third boot file, and determining a storage partition of a second boot manager in the virtual disk according to a third boot item of the third boot file; operating the second starting manager according to the storage partition of the second starting manager; and executing the third boot configuration item of the third boot configuration file according to the second boot manager to boot the first operating system.
Optionally, in the method according to the present invention, generating the fourth boot file according to the second boot file includes: and deleting the first guide item in the second guide file to obtain a fourth guide file.
Optionally, in the method according to the present invention, generating a fourth startup profile according to the second startup profile includes: and deleting the first starting configuration item in the second starting configuration file to obtain a fourth starting configuration file.
Optionally, in the method according to the present invention, generating a third boot manager and a fourth boot manager from the second boot manager comprises the steps of: deleting options for selecting to start the second operating system in the second starting manager to obtain a third starting manager; and deleting the option used for selecting to start the first operating system in the second starting manager to obtain a fourth starting manager.
Optionally, in the method according to the present invention, the first operating system includes a Windows operating system, and the second operating system includes a linux operating system.
According to another aspect of the present invention, there is provided a computing device comprising: one or more processors; a memory; and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the one or more programs including instructions for performing the method for multiple system operation according to the present invention.
According to a further aspect of the invention there is provided a computer readable storage medium storing one or more programs, the one or more programs comprising instructions, which when executed by a computing device, cause the computing device to perform a method of multi-system operation according to the invention.
The multi-system running method is suitable for being executed in computing equipment, the computing equipment runs with a first operating system and stores a first starting configuration file and a first boot file which are suitable for starting the first operating system, and the method comprises the following steps: installing a second operating system, and adding a second boot item of the second operating system in the first boot file to generate a second boot file; adding a second starting configuration item of a second operating system in the first starting configuration file to generate a second starting configuration file; generating a first starting manager according to the second starting configuration file; and starting the second operating system according to the second boot file, the first boot manager and the second boot configuration file, wherein the second boot file, the first boot manager and the second boot configuration file can start the first operating system and the second operating system, the boot paths of the first operating system and the first operating system are the same, and the boot paths share one set of boot modes. Then, a virtual operating environment is built in the second operating system, a third boot file and a third boot configuration file are built in the virtual operating environment, a second boot manager is built according to the first boot manager and the third boot configuration file, so that the first operating system is started in the virtual operating environment according to the third boot file, the second boot manager and the third boot configuration file, and the first operating system can be operated in the virtual machine according to the deployment. And generating a third boot manager and a fourth boot manager according to the second boot manager so as to boot the second operating system according to the fourth boot manager, and booting the first operating system in a virtual operating environment according to the third boot manager. The invention can isolate the guide path between each operating system when a plurality of operating systems are operated in the computer, avoids mutual interference by using respective starting managers, and improves the stability of the common starting and operation of the operating systems.
Drawings
To the accomplishment of the foregoing and related ends, certain illustrative aspects are described herein in connection with the following description and the annexed drawings, which are indicative of various ways in which the principles disclosed herein may be practiced, and all aspects and equivalents thereof are intended to be within the scope of the claimed subject matter. The above and other objects, features and advantages of the present disclosure will become more apparent from the following detailed description when read in conjunction with the accompanying drawings. Throughout this disclosure, like reference numerals generally refer to like parts or elements.
FIG. 1 illustrates a schematic diagram of a prior art multi-system boot approach in accordance with an exemplary embodiment of the present invention;
FIG. 2 illustrates a block diagram of a computing device 200, according to an exemplary embodiment of the invention;
FIG. 3 illustrates a flow diagram of a method 300 of multi-system operation according to an exemplary embodiment of the invention;
FIG. 4 is a diagram illustrating booting of a first operating system and a second operating system after installation of the second operating system according to an exemplary embodiment of the invention; and
fig. 5 illustrates a schematic diagram of a first operating system and a second operating system separately booting process according to an exemplary embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art. Like reference numerals generally refer to like parts or elements.
FIG. 1 illustrates a prior art multi-system boot approach in accordance with an exemplary embodiment of the present invention. As shown in FIG. 1, two operating systems of a computer in the prior art, such as a windows operating system and an uos operating system, are provided. Both the windows operating system and the uos operating system boot from external memory. However, the operation mode has the same guide path, and the guide of the two operating systems is not separated because the guide paths share one set of guide mode. Thus, a modification to the boot of one operating system may affect another operating system; and easily causes one system to enter twice the corrupted file system, causing the system to crash. To this end, the present invention proposes a new multi-system operation method 300, and the multi-system operation method 300 of the present invention is suitable for being executed in a computing device.
FIG. 2 illustrates a block diagram of a computing device 200, according to an exemplary embodiment of the invention. As shown in FIG. 2, in a basic configuration 202, a computing device 200 typically includes a system memory 206 and one or more processors 204. A memory bus 208 may be used for communication between the processor 204 and the system memory 206.
Depending on the desired configuration, the processor 204 may be any type of processing, including but not limited to: a microprocessor (μ P), a microcontroller (μ C), a digital information processor (DSP), or any combination thereof. The processor 204 may include one or more levels of cache, such as a level one cache 210 and a level two cache 212, a processor core 214, and registers 216. Example processor cores 214 may include Arithmetic Logic Units (ALUs), Floating Point Units (FPUs), digital signal processing cores (DSP cores), or any combination thereof. The example memory controller 218 may be used with the processor 204, or in some implementations the memory controller 218 may be an internal part of the processor 204.
Depending on the desired configuration, system memory 206 may be any type of memory, including but not limited to: volatile memory (such as RAM), non-volatile memory (such as ROM, flash memory, etc.), or any combination thereof. System memory 206 may include an operating system 220, one or more programs 222, and program data 228. In some embodiments, the program 222 may be arranged to execute the instructions 223 of the method 300 according to the invention on an operating system by one or more processors 204 using the program data 228.
Computing device 200 may also include a storage interface bus 234. The storage interface bus 234 enables communication from the storage devices 232 (e.g., removable storage 236 and non-removable storage 238) to the basic configuration 202 via the bus/interface controller 230. Operating system 220, programs 222, and at least a portion of data 224 can be stored on removable storage 236 and/or non-removable storage 238, and loaded into system memory 206 via storage interface bus 234 and executed by one or more processors 204 when computing device 200 is powered on or programs 222 are to be executed.
Computing device 200 may also include an interface bus 240 that facilitates communication from various interface devices (e.g., output devices 242, peripheral interfaces 244, and communication devices 246) to the basic configuration 202 via the bus/interface controller 230. The example output device 242 includes a graphics processing unit 248 and an audio processing unit 250. They may be configured to facilitate communication with various external devices, such as a display or speakers, via one or more a/V ports 252. Example peripheral interfaces 244 can include a serial interface controller 254 and a parallel interface controller 256, which can be configured to facilitate communications with external devices such as input devices (e.g., keyboard, mouse, pen, voice input device, touch input device) or other peripherals (e.g., printer, scanner, etc.) via one or more I/O ports 258. An example communication device 246 may include a network controller 260, which may be arranged to communicate with one or more other computing devices 200 over a network communication link via one or more communication ports 264.
A network communication link may be one example of a communication medium. Communication media may typically be embodied by computer readable instructions, data structures, program modules, and may include any information delivery media, such as carrier waves or other transport mechanisms, in a modulated data signal. A "modulated data signal" may be a signal that has one or more of its data set or its changes made in such a manner as to encode information in the signal. By way of non-limiting example, communication media may include wired media such as a wired network or private-wired network, and various wireless media such as acoustic, Radio Frequency (RF), microwave, Infrared (IR), or other wireless media. The term computer readable media as used herein may include both storage media and communication media.
In a computing device 200 according to the invention, the program 222 comprises program instructions of the multi-system execution method 300 that may direct the processor 204 to perform steps of the parts of the multi-system execution method 300 executed in the computing device 200 of the invention, such that the parts of the computing device 200 execute operating systems by performing the multi-system execution method 300 of the invention.
Computing device 200 may be implemented as a server, e.g., file server 240, database 250, a server, an application server, etc., which may be a device such as a Personal Digital Assistant (PDA), a wireless web-browsing device, an application-specific device, or a hybrid device that include any of the above functions. May be implemented as a personal computer including both desktop and notebook computer configurations, and in some embodiments computing device 200 is configured to perform multi-system execution method 300.
FIG. 3 shows a flow diagram of a method 300 for multi-system operation according to an exemplary embodiment of the invention. The multi-system operation method 300 of the present invention is suitable for execution in a computing device 200. A first operating system is running in the computing device. The computing device includes an internal memory and an external memory, and a first boot configuration file and a first boot file adapted to boot a first operating system are stored in the external memory. The present invention does not limit the kind of the first operating system. A first boot file is stored in a first sector of the external memory and includes a first boot entry for booting the first operating system. The first boot entry records the location where the external memory stores the first operating system, i.e., the location of the sector in the external memory. The first boot file is used for determining the position of the external memory for storing the first operating system according to the first boot item. The first boot file may be implemented as an mbr file, and the type of the first boot file is not limited in the present invention.
The first boot profile is stored in a location where the first operating system is stored, i.e., a sector storage where the first operating system is stored in an external memory. The first startup configuration file comprises a first startup configuration item, the first startup configuration file is used for being started in advance when the operating system is started, and the kernel of the first operating system is loaded into the internal memory according to the first startup configuration item so as to start the first operating system. The first startup configuration file may be implemented as a bcd file, and the type of the first startup configuration file is not limited by the present invention.
When the first operating system is started in the computing device 200, the first boot file is read first, and the location in the external memory where the first operating system is stored is determined according to the first boot entry of the first boot file. And then storing a first starting configuration file of the first operating system from the external memory, and loading the kernel of the first operating system into the internal memory according to a first starting configuration item of the first starting configuration file so as to start the first operating system.
In the method 300 of the present invention, step S310 is executed first, a second operating system is installed, and a second boot item of the second operating system is added to the first boot file to generate a second boot file. The second boot entry states the location where the external memory stores the second operating system, i.e., the location of the sector in the external memory. The second boot file includes a first boot item and a second boot item for booting the second operating system. The second boot file may be configured to boot the first operating system according to the first boot entry, and may be further configured to determine a location of the external memory where the second operating system is stored according to the second boot entry.
Subsequently, step S320 is executed to add a second boot configuration item of the second operating system to the first boot configuration file to generate a second boot configuration file. The second boot configuration file comprises a first boot configuration item and a second boot configuration item for loading the second operating system kernel. The second boot configuration file may, in addition to booting the first operating system according to the first boot configuration item, load a kernel of the second operating system into the internal memory according to the second boot configuration item to boot the second operating system.
Subsequently, step S330 is executed to generate a first boot manager according to the second boot configuration file. When the first starting manager is generated, an option for selecting to start the first operating system is generated according to the first starting configuration item, so that when a user selects the option, the first starting configuration item of the first operating system is executed to run the first operating system. And generating an option for selecting to start the second operating system according to the second starting configuration item, so that when the user selects, executing the first starting configuration item of the second operating system to run the second operating system, and then generating a first starting manager according to the option for selecting to start the first operating system and the option for selecting to start the second operating system.
Since a plurality of operating systems including a first operating system and a second operating system are installed in the computing device 200, a boot manager is introduced to manage which operating system is booted. The first boot manager may be implemented as a grub manager, and the present invention does not limit the type of the first boot manager. The first boot manager may be stored in a location where the first operating system is stored or a location where the second operating system is stored, and the present invention does not limit the location where the first operating system is stored in the external memory. After the boot manager is introduced, the first boot entry and the second boot entry of the second boot file are further used to determine a storage location of the first boot manager in the external memory.
Subsequently, step S340 is executed to boot the second operating system according to the second boot file, the first boot manager, and the second boot configuration file. When the second operating system is started, the second boot file is read, the storage partition of the external memory of the first boot manager is determined according to the second boot item of the second boot file, then the first boot manager is operated according to the storage partition of the first boot manager, and then the second boot configuration item of the second boot configuration file is executed according to the first boot manager to start the second operating system. When the first boot manager executes the second boot configuration item of the second boot configuration file, the second operating system needs to be booted, so that the option for selecting the boot of the second operating system is selected by default, and the user does not need to select the option.
Fig. 4 is a diagram illustrating booting of the first operating system and the second operating system after installing the second operating system according to an exemplary embodiment of the present invention. As shown in FIG. 4, the first operating system may be implemented as a windows7 operating system and the second operating system may be implemented as a uos operating system. The first operating system and the second operating system have the same guide path when starting and share one set of guide mode. Specifically, when the first operating system is started, after the bios self-test program is executed, the second boot file is read, the storage partition of the external memory of the first boot manager is determined according to the first boot entry of the second boot file, then the first boot manager (not shown in the figure) is run according to the storage partition of the first boot manager, and then the first boot configuration entry of the second boot configuration file is executed according to the first boot manager to start the second operating system. The second boot file may be implemented as an mbr file and the second boot configuration file may be implemented as a bcd file.
When a second operating system is started, after a bios self-check program, a second boot file is read, a storage partition of a first boot manager in an external memory is determined according to a second boot item of the second boot file, then the first boot manager is run according to the storage partition of the first boot manager, and then a second boot configuration item of a second boot configuration file is executed according to the first boot manager to start the second operating system.
When the first operating system and the second operating system are started, the guide paths are the same and share one set of guide mode. And in the manner of booting an operating system shown in FIG. 4, modifications to the boot of one operating system may affect another operating system; and easily causes one system to enter twice the corrupted file system, causing the system to crash.
Therefore, it is necessary to separate the booting of the first operating system and the second operating system to avoid mutual interference. Subsequently, step S350 is executed to construct a virtual operating environment in the second operating system, construct a third boot file and a third boot configuration file in the virtual operating environment, and construct a second boot manager according to the first boot manager and the third boot configuration file, so as to boot the first operating system in the virtual operating environment according to the third boot file, the second boot manager, and the third boot configuration file. Specifically, a virtual disk address is obtained according to a physical disk address stored in the external memory of the first operating system, then a third boot file and a third boot configuration file are generated according to the virtual disk address, and the third boot file and the third boot configuration file are stored in the virtual disk. When the virtual disk address is obtained according to the physical disk address stored in the external memory of the first operating system, the first operating system stored in the external memory is mapped to the virtual disk file, a virtual machine is constructed, the first operating system stored in the virtual disk of the virtual machine is obtained, and the virtual disk address of the first operating system stored in the virtual disk is obtained.
The third boot file includes a third boot item for booting the first operating system, and the third boot configuration file includes a third boot configuration item for loading the first operating system. And when a third boot file and a third boot configuration file are generated according to the virtual disk address, a third boot item is generated according to the virtual disk address, so that the virtual disk address stored in the virtual disk by the first operating system is determined according to the third boot item of the third boot file. And then generating a third startup configuration item according to the virtual disk address, and generating a third startup configuration file according to the third startup configuration item so as to run the first operating system according to the third startup configuration item of the third startup configuration file.
And when a second boot manager is constructed according to the first boot manager and the third boot configuration file, generating an option for selecting to boot the first operating system according to a third boot configuration item of the third boot configuration file, so that when the user selects, the third boot configuration item of the first operating system is executed to run the first operating system. And combining the option for starting the first operating system generated according to the third starting configuration item with the option for starting the second operating system in the first starting manager to obtain a third starting manager so as to start the first operating system according to the third starting manager.
When the first operating system is started in the virtual environment, the third boot file is read from the virtual disk, the storage partition of the second boot manager in the virtual disk is determined according to the third boot item of the third boot file, then the second boot manager is operated according to the storage partition of the second boot manager, and then the third boot configuration item of the third boot configuration file is executed according to the second boot manager to start the first operating system. When the second boot manager executes the third boot configuration item of the third boot configuration file, the first operating system is to be booted, so that the option of selecting and booting the first operating system is selected by default, and the user does not need to select the option.
Subsequently, step S360 is executed to generate a third boot manager and a fourth boot manager according to the second boot manager, so as to boot the second operating system according to the fourth boot manager, and boot the first operating system in the virtual operating environment according to the third boot manager.
And when a third startup manager and a fourth startup manager are generated, deleting the option used for selecting to start the second operating system in the second startup manager to obtain the third startup manager, and deleting the option used for selecting to start the first operating system in the second startup manager to obtain the fourth startup manager. The third boot manager only comprises an option for selecting to boot the first operating system, and the fourth boot manager only comprises an option for selecting to boot the second operating system, so that the boot managers of the first operating system and the second operating system are separated, the second operating system is booted according to the fourth boot manager, and the first operating system is booted in the virtual running environment according to the third boot manager.
And when the second operating system is started according to the fourth starting manager, starting the second operating system according to the second boot file, the fourth starting manager and the second starting configuration file, and specifically executing a second starting configuration item of the second starting configuration file according to the fourth starting manager to start the second operating system.
When the first operating system is started in the virtual running environment according to the third boot file, the third boot manager and the third boot configuration file, the first operating system is started in the virtual running environment according to the third boot file, and specifically, the first boot configuration item of the third boot configuration file is executed according to the third boot manager to start the first operating system
According to an embodiment of the invention, further comprising the steps of: and generating a fourth boot file according to the second boot file, wherein the fourth boot file comprises a boot item of the second operating system. And when the fourth guide file is generated, deleting the first guide item in the second guide file to obtain the fourth guide file. At this time, the fourth boot file includes only the boot item of the second operating system, and the boot items of the first operating system and the second operating system are separated.
And generating a fourth starting configuration file according to the second starting configuration file, wherein the fourth starting configuration file comprises a starting configuration item of the second operating system, so that a third starting manager and a fourth starting manager are generated according to the second starting manager, so that the second operating system is started according to the fourth boot file, the fourth starting configuration file and the fourth starting manager, and the first operating system is started in the virtual running environment according to the third boot file, the third starting manager and the third starting configuration file. And when a fourth starting configuration file is generated, deleting the first starting configuration item in the second starting configuration file to obtain the fourth starting configuration file. At this time, the fourth boot configuration file only includes boot configuration items of the second operating system, so that the boot configuration items of the first operating system and the second operating system are separated.
Fig. 5 illustrates a schematic diagram of a first operating system and a second operating system separately booting process according to an exemplary embodiment of the present invention. As shown in FIG. 5, the first operating system may be implemented as a windows7 operating system and the second operating system may be implemented as a uos operating system. When the first operating system is started, after a bios self-check program, reading a fourth boot file, and determining a storage location of a fourth boot manager (grub) and a fourth boot configuration file in the external memory according to a second boot item of the fourth boot file; the fourth boot manager is then booted according to the storage location, and a second boot configuration item of a fourth boot configuration file (not shown) is executed according to the fourth boot manager to boot the second operating system.
When the first operating system is started, the first operating system is started in the virtual running environment. Reading a third boot file, and determining the storage positions of a third boot manager (grub.vdi) and a third boot configuration file (bcd file) in the virtual disk according to a third boot item of the third boot file; and then starting a third starting manager according to the storage position, and executing a third starting configuration item of a third starting configuration file according to the third starting manager to start the first operating system.
According to one embodiment of the invention, the first boot file is saved while the second boot file is generated so that the first operating system is directly launched from the computing device according to the first boot file recovery. After the boot processes of the first operating system and the second operating system are separated, the first operating system can only be started in the virtual machine and cannot be directly started by the physical machine, so that the first boot file needs to be saved so as to load the first boot file into the external memory and directly start the first operating system according to the first boot file.
According to an embodiment of the invention, the invention can add and start a plurality of other operating systems in the virtual machine, such as a third operating system, a fourth operating system and the like. The present invention does not limit the kinds of the third operating system and the fourth operating system. When other operating systems are built in the virtual machine, a boot file of a newly added operating system is built in the virtual disk, and a configuration item and a boot manager are started, so that the configuration item and the boot manager can be started to start the new operating system according to the boot file of the newly added operating system.
The multi-system running method is suitable for being executed in computing equipment, the computing equipment runs with a first operating system and stores a first starting configuration file and a first boot file which are suitable for starting the first operating system, and the method comprises the following steps: installing a second operating system, and adding a second boot item of the second operating system in the first boot file to generate a second boot file; adding a second starting configuration item of a second operating system in the first starting configuration file to generate a second starting configuration file; generating a first starting manager according to the second starting configuration file; and starting the second operating system according to the second boot file, the first boot manager and the second boot configuration file, wherein the second boot file, the first boot manager and the second boot configuration file can start the first operating system and the second operating system, the boot paths of the first operating system and the first operating system are the same, and the boot paths share one set of boot modes. Then, a virtual operating environment is built in the second operating system, a third boot file and a third boot configuration file are built in the virtual operating environment, a second boot manager is built according to the first boot manager and the third boot configuration file, so that the first operating system is started in the virtual operating environment according to the third boot file, the second boot manager and the third boot configuration file, and the first operating system can be operated in the virtual machine according to the deployment. And generating a third boot manager and a fourth boot manager according to the second boot manager so as to boot the second operating system according to the fourth boot manager, and booting the first operating system in a virtual operating environment according to the third boot manager. The invention can isolate the guide path between each operating system when a plurality of operating systems are operated in the computer, avoids mutual interference by using respective starting managers, and improves the stability of the common starting and operation of the operating systems.
In the description provided herein, numerous specific details are set forth. It is understood, however, that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
Similarly, it should be appreciated that in the foregoing description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the disclosure and aiding in the understanding of one or more of the various inventive aspects. However, the disclosed method should not be interpreted as reflecting an intention that: that the invention as claimed requires more features than are expressly recited in each claim.
Those skilled in the art will appreciate that the modules or units or groups of devices in the examples disclosed herein may be arranged in a device as described in this embodiment, or alternatively may be located in one or more devices different from the devices in this example. The modules in the foregoing examples may be combined into one module or may be further divided into multiple sub-modules.
Those skilled in the art will appreciate that the modules in the device in an embodiment may be adaptively changed and disposed in one or more devices different from the embodiment. Modules or units or groups in embodiments may be combined into one module or unit or group and may furthermore be divided into sub-modules or sub-units or sub-groups. All of the features disclosed in this specification (including any accompanying claims, abstract and drawings), and all of the processes or elements of any method or apparatus so disclosed, may be combined in any combination, except combinations where at least some of such features and/or processes or elements are mutually exclusive. Each feature disclosed in this specification (including any accompanying claims, abstract and drawings) may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise.
Furthermore, those skilled in the art will appreciate that while some embodiments described herein include some features included in other embodiments, rather than other features, combinations of features of different embodiments are meant to be within the scope of the invention and form different embodiments.
Furthermore, some of the described embodiments are described herein as a method or combination of method elements that can be performed by a processor of a computer system or by other means of performing the described functions. A processor having the necessary instructions for carrying out the method or method elements thus forms a means for carrying out the method or method elements. Further, the elements of the apparatus embodiments described herein are examples of the following apparatus: the apparatus is used to implement the functions performed by the elements for the purpose of carrying out the invention.
The various techniques described herein may be implemented in connection with hardware or software or, alternatively, with a combination of both. Thus, the methods and apparatus of the present invention, or certain aspects or portions thereof, may take the form of program code (i.e., instructions) embodied in tangible media, such as floppy diskettes, CD-ROMs, hard drives, or any other machine-readable storage medium, wherein, when the program is loaded into and executed by a machine, such as a computer, the machine becomes an apparatus for practicing the invention.
In the case of program code execution on programmable computers, the computing device will generally include a processor, a storage medium readable by the processor (including volatile and non-volatile memory and/or storage elements), at least one input device, and at least one output device. Wherein the memory is configured to store program code; the processor is configured to execute the inventive multi-system operation method according to instructions in said program code stored in the memory.
By way of example, and not limitation, computer readable media may comprise computer storage media and communication media. Computer-readable media includes both computer storage media and communication media. Computer storage media store information such as computer readable instructions, data structures, program modules or other data. Communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media. Combinations of any of the above are also included within the scope of computer readable media.
As used herein, unless otherwise specified the use of the ordinal adjectives "first", "second", "third", etc., to describe a common object, merely indicate that different instances of like objects are being referred to, and are not intended to imply that the objects so described must be in a given sequence, either temporally, spatially, in ranking, or in any other manner.
While the invention has been described with respect to a limited number of embodiments, those skilled in the art, having benefit of this description, will appreciate that other embodiments can be devised which do not depart from the scope of the invention as described herein. Furthermore, it should be noted that the language used in the specification has been principally selected for readability and instructional purposes, and may not have been selected to delineate or circumscribe the inventive subject matter. Accordingly, many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the appended claims. The present invention has been disclosed in an illustrative rather than a restrictive sense, and the scope of the present invention is defined by the appended claims.

Claims (16)

1. A multi-system execution method adapted to be executed in a computing device running a first operating system and storing a first boot profile and a first boot file adapted to boot the first operating system, the method comprising the steps of:
installing a second operating system, and adding a second boot item of the second operating system in the first boot file to generate a second boot file;
adding a second starting configuration item of the second operating system in the first starting configuration file to generate a second starting configuration file;
generating a first starting manager according to the second starting configuration file;
starting the second operating system according to the second boot file, the first starting manager and the second starting configuration file;
constructing a virtual operating environment in the second operating system, constructing a third boot file and a third boot configuration file in the virtual operating environment, and constructing a second boot manager according to the first boot manager and the third boot configuration file, so as to boot the first operating system in the virtual operating environment according to the third boot file, the second boot manager and the third boot configuration file;
and generating a third boot manager and a fourth boot manager according to the second boot manager so as to boot the second operating system according to the fourth boot manager, and booting the first operating system in a virtual operating environment according to the third boot manager.
2. The method of claim 1, wherein the method further comprises the steps of:
generating a fourth boot file according to the second boot file, wherein the fourth boot file comprises a boot item of the second operating system;
and generating a fourth boot configuration file according to the second boot configuration file, wherein the fourth boot configuration file comprises a boot configuration item of the second operating system, so that the second operating system is started according to the fourth boot file, the fourth boot configuration file and a fourth boot manager, and the first operating system is started in a virtual operating environment according to the third boot file, the third boot manager and the third boot configuration file.
3. The method of claim 2, wherein the first boot file includes a first boot item for booting the first operating system, and the second boot file includes a first boot item and a second boot item for booting a second operating system.
4. The method of claim 3, wherein the first boot configuration file comprises a first boot configuration item for loading the first operating system kernel, and the second boot configuration file comprises a first boot configuration item and a second boot configuration item for loading the second operating system kernel.
5. The method of claim 4, wherein said generating a first boot manager from said second boot profile comprises the steps of:
generating an option for selecting to start the first operating system according to the first starting configuration item, so that when a user selects, the first starting configuration item of the first operating system is executed to run the first operating system;
generating an option for selecting to start a second operating system according to the second starting configuration item, so that when a user selects, executing a first starting configuration item of the second operating system to run the second operating system;
and generating a first starting manager according to the option of selecting to start the first operating system and the option of selecting to start the second operating system.
6. The method of claim 5, wherein the computing device includes an external memory, and wherein said booting the second operating system according to the second boot file, the first boot manager, and the second boot configuration file comprises the steps of:
reading the second boot file, and determining a storage partition of the first boot manager in the external memory according to a second boot item of the second boot file;
running a first boot manager according to a storage partition of the first boot manager;
and executing a second starting configuration item of the second starting configuration file according to the first starting manager to start a second operating system.
7. The method of claim 6, wherein said building a virtual execution environment in said second operating system, building a third boot file and a third boot configuration file in said virtual execution environment comprises the steps of:
obtaining a virtual disk address stored in a virtual disk by the first operating system according to the physical disk address stored in the external memory by the first operating system;
and generating a third boot file and a third start configuration file according to the virtual disk address, and storing the third boot file and the third start configuration file in the virtual disk.
8. The method of claim 7, wherein the third boot file includes a third boot item for booting the first operating system, the third boot configuration file including a third boot configuration item for loading the first operating system.
9. The method of claim 7 or 8, wherein said building a second boot manager from said first boot manager and a third boot profile comprises the steps of:
generating an option for selecting to start the first operating system according to a third start configuration item of the third start configuration file, so that when a user selects the option, the third start configuration item of the first operating system is executed to run the first operating system;
and combining the option for starting the first operating system generated according to the third starting configuration item with the option for starting the second operating system in the first starting manager to obtain a third starting manager.
10. The method of claim 9, wherein said booting the first operating system in the virtual execution environment according to the third boot file, the second boot manager, and the third boot configuration file comprises the steps of:
reading the third boot file, and determining a storage partition of the second boot manager in the virtual disk according to a third boot item of the third boot file;
operating a second boot manager according to a storage partition of the second boot manager;
and executing a third boot configuration item of the third boot configuration file according to the second boot manager to boot the first operating system.
11. The method of claim 10, wherein said generating a fourth boot file from said second boot file comprises the steps of:
and deleting the first guide item in the second guide file to obtain a fourth guide file.
12. The method of claim 11, wherein said generating a fourth boot profile from said second boot profile comprises the steps of:
and deleting the first starting configuration item in the second starting configuration file to obtain a fourth starting configuration file.
13. The method of claim 12, wherein said generating a third boot manager and a fourth boot manager from said second boot manager comprises the steps of:
deleting options for selecting to start a second operating system in the second starting manager to obtain a third starting manager;
and deleting the option used for selecting to start the first operating system in the second starting manager to obtain the fourth starting manager.
14. The method of claim 13, wherein the first operating system comprises a Windows operating system and the second operating system comprises a linux operating system.
15. A computing device, comprising:
one or more processors;
a memory; and
one or more apparatuses comprising instructions for performing the method of any of claims 1-14.
16. A computer readable storage medium storing one or more programs, the one or more programs comprising instructions, which when executed by a computing device, cause the computing device to perform the method of any of claims 1-14.
CN202111448513.5A 2021-12-01 2021-12-01 Multi-system operation method, computing equipment and storage medium Active CN113867825B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111448513.5A CN113867825B (en) 2021-12-01 2021-12-01 Multi-system operation method, computing equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111448513.5A CN113867825B (en) 2021-12-01 2021-12-01 Multi-system operation method, computing equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113867825A true CN113867825A (en) 2021-12-31
CN113867825B CN113867825B (en) 2022-03-18

Family

ID=78985538

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111448513.5A Active CN113867825B (en) 2021-12-01 2021-12-01 Multi-system operation method, computing equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113867825B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2006110829A2 (en) * 2005-04-08 2006-10-19 The Mathworks, Inc. System and method for using an rmi activation system daemon with non-java applications
CN105159694A (en) * 2015-07-07 2015-12-16 深圳市深信服电子科技有限公司 Operating system coexistence method and apparatus
CN113157290A (en) * 2021-05-06 2021-07-23 统信软件技术有限公司 Multi-system installation method, computing equipment and storage medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2006110829A2 (en) * 2005-04-08 2006-10-19 The Mathworks, Inc. System and method for using an rmi activation system daemon with non-java applications
CN105159694A (en) * 2015-07-07 2015-12-16 深圳市深信服电子科技有限公司 Operating system coexistence method and apparatus
CN113157290A (en) * 2021-05-06 2021-07-23 统信软件技术有限公司 Multi-system installation method, computing equipment and storage medium

Also Published As

Publication number Publication date
CN113867825B (en) 2022-03-18

Similar Documents

Publication Publication Date Title
CN112988252B (en) Operating system starting method and computing device
CN106445576B (en) Motherboard and its computer implemented method and the readable storage device of non-transient computer
US11169819B2 (en) Information handling system (IHS) and method to proactively restore firmware components to a computer readable storage device of an IHS
CN113127100B (en) Heterogeneous program execution method and device, computing device and readable storage medium
CN113157290B (en) Multi-system installation method, computing equipment and storage medium
CN114691226A (en) Multi-operating-system switching operation method, computing device and storage medium
CN114461404B (en) Process migration method, computing device and readable storage medium
US20120144390A1 (en) Customized computer image preparation and deployment including virtual machine mode
CN113867825B (en) Multi-system operation method, computing equipment and storage medium
CN113485712A (en) Kernel cutting method and computing device
US11907071B2 (en) Storage failover protocol for secure and seamless extended firmware load
CN113805971B (en) Application program running method, computing device and storage medium
US20120005464A1 (en) Start up processing method, information processing apparatus, and computer-readable storage medium storing program
CN113791873B (en) Virtual machine creating method, computing device and storage medium
CN114138376B (en) Method for loading plug-in application, computing equipment and storage medium
CN113849245B (en) Application program running method, computing device and storage medium
CN113821272B (en) Application program running method, computing device and storage medium
WO2022222351A1 (en) Method for installing operating system, and computing device
CN113051584B (en) System security starting method and device, computing equipment and readable storage medium
CN114168937A (en) Resource access method, computing device and readable storage medium
CN113961086A (en) Shortcut key implementation method, computing device and storage medium
CN114138285B (en) Application deployment method, computing device and readable storage medium
CN114217904A (en) Multi-version application operation method, computing device and storage medium
CN113485769B (en) Application program running method, computing device and storage medium
US20240231803A9 (en) Maintenance mode in hci environment

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
GR01 Patent grant
GR01 Patent grant