CN109960517B - Method, device and system for manufacturing mirror image file and storage medium - Google Patents

Method, device and system for manufacturing mirror image file and storage medium Download PDF

Info

Publication number
CN109960517B
CN109960517B CN201910193354.5A CN201910193354A CN109960517B CN 109960517 B CN109960517 B CN 109960517B CN 201910193354 A CN201910193354 A CN 201910193354A CN 109960517 B CN109960517 B CN 109960517B
Authority
CN
China
Prior art keywords
image file
file
target image
target
mirror image
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.)
Active
Application number
CN201910193354.5A
Other languages
Chinese (zh)
Other versions
CN109960517A (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.)
Loongson Technology Corp Ltd
Original Assignee
Loongson Technology Corp 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 Loongson Technology Corp Ltd filed Critical Loongson Technology Corp Ltd
Priority to CN201910193354.5A priority Critical patent/CN109960517B/en
Publication of CN109960517A publication Critical patent/CN109960517A/en
Application granted granted Critical
Publication of CN109960517B publication Critical patent/CN109960517B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation
    • G06F8/63Image based installation; Cloning; Build to order
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/73Program documentation

Abstract

The invention provides a method, a device, a system and a storage medium for manufacturing a mirror image file, wherein the method comprises the following steps: creating an image file according to preset default parameters; partitioning the mirror image file to obtain a target mirror image file; virtualizing the target image file into loop back equipment, and loading the target image file; mounting the target mirror image file to a specified directory; decompressing the optical disk file system of the Linux operating system to the specified directory; copying the file decompressed by the optical disk file system of the Linux operating system to the directory of the target mirror image file in a preset mode; and converting the target image file into an image file with a preset format. The invention can simplify the manufacturing process of the mirror image file and reduce the interactive operation of users in the manufacturing process.

Description

Method, device and system for manufacturing mirror image file and storage medium
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method, an apparatus, a system, and a storage medium for creating an image file.
Background
The sparse file is an advanced characteristic of a Linux file system and can realize overload use of a disk; such as creating a virtual hard disk and database snapshot for a virtual machine. In Linux, a file system image file without partitions may be loaded through a losetup program, or a file system image file with partitions may be loaded through cooperation of a wrapx (mount virtual file system command). Because the sparse file is easy to manufacture, when the image file in the qcow2 format needs to be manufactured, the sparse file is manufactured firstly, and then the sparse file is converted into the image file in the qcow2 format.
At present, in a manufacturing process of an image file, an image file (one of sparse files) with a specified size is generally created first, then a partition table is established for the image file, the image file is associated with a bare device, the image file is mounted after a file system partition table is read, a file system with a system iso format is copied into the image file, and finally the image file is converted into an image file with a qcow2 format.
However, the method for making the image file has a complicated flow, requires a user to manually confirm the image file for many times, and has low making efficiency of the image file.
Disclosure of Invention
The invention provides a method, a device and a system for manufacturing a mirror image file and a storage medium, which can simplify the manufacturing process of the mirror image file and reduce the interactive operation of a user in the manufacturing process.
In a first aspect, an embodiment of the present invention provides a method for manufacturing an image file, including:
creating a mirror image file according to preset default parameters;
partitioning the image file to obtain a target image file;
virtualizing the target image file into loop back equipment, and loading the target image file;
mounting the target mirror image file to a specified directory;
decompressing the optical disk file system of the Linux operating system to the specified directory;
copying the file decompressed by the optical disk file system of the Linux operating system to the directory of the target mirror image file in a preset mode;
and converting the target image file into an image file with a preset format.
In one possible design, creating the image file according to preset default parameters includes:
and calling preset default parameters through a command of creating a disk file to generate an image file in an img format.
In a possible design, partitioning the image file to obtain a target image file, includes:
and partitioning the image file by automatically calling a partition function to obtain a target image file containing at least one main partition.
In one possible design, before converting the target image file into an image file in a preset format, the method further includes:
and creating a common account, a common account password and an administrator account password in the file system of the target image file.
In one possible design, before loading the target image file, the method further includes:
and judging whether the target image file is successfully virtualized into loop back equipment or not, and if the target image file fails, performing system error reporting to prompt system troubleshooting.
In a possible design, before creating a general account, a general account password, and an administrator account password in the file system of the target image file, the method further includes:
and entering the file system of the target mirror image file through a file system switching instruction, and ending the process if the entry fails.
In a second aspect, an embodiment of the present invention provides an apparatus for manufacturing an image file, including:
the creating module is used for creating the mirror image file according to preset default parameters;
the partition module is used for partitioning the image file to obtain a target image file;
the virtual module is used for virtualizing the target image file into loop back equipment and loading the target image file;
the mounting module is used for mounting the target mirror image file to a specified directory;
the decompression module is used for decompressing the optical disk file system of the Linux operating system to the specified directory;
the copying module is used for copying the file decompressed by the optical disk file system of the Linux operating system to the directory of the target mirror image file in a preset mode;
and the conversion module is used for converting the target image file into an image file in a preset format.
In one possible design, the creating module is specifically configured to:
and calling preset default parameters through a command of creating a disk file, and generating an image file in a raw format with img as an extension (which can be of other types).
In one possible design, the partition module is specifically configured to:
and partitioning the image file by automatically calling a partition function to obtain a target image file containing at least one main partition.
In one possible design, further comprising:
and the encryption module is used for creating a common account, a common account password and an administrator account password in the file system of the target image file.
In one possible design, further comprising:
and the judging module is used for judging whether the target image file is successfully virtualized into loop back equipment or not before loading the target image file, and if the target image file fails, performing system error reporting to prompt system troubleshooting.
In one possible design, further comprising:
and the changing module is used for entering the file system of the target mirror image file through a file system switching instruction before creating a common account, a common account password and an administrator account password in the file system of the target mirror image file, and ending the process if the entering fails.
In a third aspect, an embodiment of the present invention provides a system for manufacturing an image file, including: the device comprises a memory and a processor, wherein the memory stores executable instructions of the processor; wherein the processor is configured to execute the method for making the image file according to any one of the first aspect by executing the executable instructions.
In a fourth aspect, an embodiment of the present invention is a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the computer program implements the method for making an image file according to any one of the first aspect.
According to the method, the device and the system for manufacturing the image file and the storage medium, the image file is created according to the preset default parameters; partitioning the image file to obtain a target image file; virtualizing the target image file into loop back equipment, and loading the target image file; mounting the target mirror image file to a specified directory; decompressing the optical disk file system of the Linux operating system to the specified directory; copying the file decompressed by the optical disk file system of the Linux operating system to the directory of the target mirror image file in a preset mode; and converting the target image file into an image file with a preset format. The invention can realize the production of the mirror image file automatically by operating the preset control instruction, thereby reducing the interactive operation of users in the production process and simplifying the production process of the mirror image file.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
FIG. 1 is a schematic diagram of an application scenario of the present invention;
fig. 2 is a flowchart of a method for making an image file according to an embodiment of the present invention;
fig. 3 is a flowchart of a method for manufacturing an image file according to a second embodiment of the present invention;
fig. 4 is a schematic structural diagram of a device for manufacturing an image file according to a third embodiment of the present invention;
fig. 5 is a schematic structural diagram of a system for manufacturing an image file according to a fourth embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The terms "first," "second," "third," "fourth," and the like in the description and in the claims, as well as in the drawings, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are, for example, capable of operation in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The technical solution of the present invention will be described in detail below with specific examples. The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments.
In the following, some terms in the present application are explained to facilitate understanding by those skilled in the art:
1) The mirror image file is similar to the rar ZIP compressed package in nature, and a specific series of files are made into a single file according to a certain format so as to be convenient for a user to download and use, such as an operating system, games and the like. The most important characteristic of the method is that the method can be identified by specific software and can be directly recorded on an optical disc. In fact, the image file in the general sense can be expanded again, and more information can be contained in the image file. Such as system files, boot files, partition table information, etc., so that the image file may contain all the information for a partition or even a hard disk.
2) A Loopback Device (Loopback Device) refers to a block Device that allows a user to virtualize a normal disk file. The loopback device is used the same as any other block device, and a user can create a file system on the loopback device and mount it in the system like a normal disk.
3) Sparse files are a file storage mode in a file system, when a file is created, continuous storage space required by the file is pre-allocated, and most of internal space of the file is not filled with data. At present, most file systems support sparse files.
Fig. 1 is a schematic view of an application scenario of the present invention, as shown in fig. 1, including: firstly, creating an image file according to preset default parameters; then, the mirror image file is subjected to partition processing; virtualizing the mirror image file into loopback equipment; and judging whether the loopback equipment is virtualized successfully or not, if so, loading the mirror image file, and if not, reporting the system by mistake to prompt the system to troubleshoot.
After the mirror image file is loaded, mounting the mirror image file to a specified directory; decompressing the optical disk file system of the Linux operating system to a specified directory; copying a file decompressed by an optical disk file system of a Linux operating system to a directory of a mirror image file in a preset mode; entering a target file system, and creating a common account, a common account password and an administrator account password; and judging whether the target file system is entered, if so, converting the image file into an image file with a preset format, and if not, ending the process.
By adopting the method, the manufacturing process of the mirror image file can be simplified, the interactive operation of a user in the manufacturing process is reduced, and the copying speed of the file is effectively improved on the premise of ensuring the integrity of the file copying.
The following describes the technical solution of the present invention and how to solve the above technical problems with specific embodiments. The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments. Embodiments of the present invention will be described below with reference to the accompanying drawings.
Fig. 2 is a flowchart of a method for making an image file according to an embodiment of the present invention, and as shown in fig. 2, the method in this embodiment may include:
s101, creating an image file according to preset default parameters.
In this embodiment, a preset default parameter may be called by a command to create a disk file, so as to generate an image file in an img format. Specifically, a basic sparse file may be created by a truncate command (create disk file command), and then the sparse file may be converted into an img format image file.
It should be noted that, in order to reduce the interaction of the user, all the input parameters involved in the creation process of the image file select default parameters. In the process of creating, a preset default parameter is called through a command of creating a disk file to directly produce a basic sparse file, and then the basic sparse file is converted into an image file. The sparse file does not contain user data, and is not allocated to a disk space for storing the user data. As data is written to the sparse file, the system gradually allocates disk space for it.
And S102, partitioning the mirror image file to obtain a target mirror image file.
In this embodiment, the partition processing may be performed on the image file by automatically invoking a partition function, so as to obtain a target image file including at least one main partition. Alternatively, in practical applications, only one main partition may be made for the sake of simplicity of partitioning.
S103, virtualizing the target image file into loop back equipment, and loading the target image file.
In this embodiment, before loading the target image file, it may be further determined whether the target image file is successfully virtualized into a loopback device, and if the target image file fails, the process is ended.
In this embodiment, the target image file is loaded only after the loopback device is successfully virtualized, so that unnecessary operations caused by the loopback device being failed are avoided, and the success rate of making the image file is improved.
And S104, mounting the target image file to a specified directory.
In this embodiment, the specified directory refers to a directory that is preset by a user and used for placing a manufactured image file.
S105, decompressing the optical disc file system of the Linux operating system to a specified directory.
In this embodiment, a decompression program is called to decompress the optical disc file system of the Linux operating system to the specified directory in step S104.
And S106, copying the file decompressed by the optical disk file system of the Linux operating system to the directory of the target image file in a preset mode.
In this embodiment, the optimized copy tool may be used to copy the file decompressed by the optical disc file system of the Linux operating system to the directory of the target image file.
Specifically, the file decompressed by the optical disc file system of the Linux operating system can be copied to the directory of the target image file in an optimized rsync mode (a data image backup tool in the Linux system). By the method, the problem of incomplete copying can be avoided, and the finished mirror image file is guaranteed to be a complete file.
And S107, converting the target image file into an image file in a preset format.
In this embodiment, the image file in the img format may be converted into an image file in the qcow2 format.
It should be noted that the embodiment can be applied to a Linux operating system platform to rapidly create an image file. Besides the Linux operating system, the method in this embodiment may also be implemented in other similar operating systems, and the specific implementation process and implementation principle thereof are similar, and are not described herein again.
In the embodiment, an image file is created according to preset default parameters; partitioning the mirror image file to obtain a target mirror image file; virtualizing a target image file into loop equipment, and loading the target image file; mounting a target mirror image file to a specified directory; decompressing an optical disk file system of a Linux operating system to a specified directory; copying a file decompressed by an optical disk file system of a Linux operating system to a directory of a target image file in a preset mode; and converting the target image file into an image file with a preset format. In the embodiment, the system automatically calls the preset default parameters to create the mirror image file, partitions the mirror image file according to the partition command, autonomously runs the mount and copy program of the mirror image file, and completes the manufacture of the mirror image file.
Fig. 3 is a flowchart of a method for manufacturing an image file according to a second embodiment of the present invention, and as shown in fig. 3, the method in this embodiment may include:
s201, creating an image file according to preset default parameters.
S202, partitioning the mirror image file to obtain a target mirror image file.
S203, virtualizing the target image file into loop back equipment, and loading the target image file.
And S204, mounting the target image file to a specified directory.
S205, decompressing the optical disk file system of the Linux operating system to a specified directory.
And S206, copying the decompressed file of the optical disk file system of the Linux operating system to a directory of the target image file in a preset mode.
For the detailed implementation process and principle of steps S201 to S206 in this embodiment, please refer to the related description of steps S101 to S106 in fig. 2, which is not described herein again.
And S207, creating a common account, a common account password and an administrator account password in the file system of the target image file.
In an optional implementation manner, before step S207 is executed, a file system of the target image file may be entered through a file system switching instruction, and if the entry fails, the process is ended.
Specifically, a chroma command (file system switching instruction) is executed, a file system of a target image file is entered, and then a normal account, a normal account password, and an administrator account password are created in a chroma running environment. By creating the common account, the common account password and the administrator account password, malicious modification of the mirror image file can be prevented, and normal operation of the manufactured mirror image file can be guaranteed.
And S208, converting the target image file into an image file in a preset format.
For a specific implementation process and principle of step S208 in this embodiment, please refer to the related description of step S107 in fig. 2, which is not described herein again.
In the embodiment, an image file is created according to preset default parameters; partitioning the mirror image file to obtain a target mirror image file; virtualizing a target image file into loop equipment, and loading the target image file; mounting a target mirror image file to a specified directory; decompressing an optical disk file system of a Linux operating system to a specified directory; copying a file decompressed by an optical disk file system of a Linux operating system to a directory of a target mirror image file in a preset mode; and converting the target image file into an image file with a preset format. In the embodiment, the system automatically calls the preset default parameters to create the mirror image file, partitions the mirror image file according to the partition command, autonomously runs the mount and copy program of the mirror image file, and completes the manufacture of the mirror image file. And when entering into the file system of the target image file, a common account password and an administrator account password are created, so that the operation authority of a common user and an administrator can be set, the malicious modification of the image file by other personnel is prevented, and the normal operation of the manufactured image file is ensured.
Fig. 4 is a schematic structural diagram of a device for manufacturing an image file according to a third embodiment of the present invention, and as shown in fig. 4, the device in this embodiment may include:
a creating module 301, configured to create an image file according to preset default parameters;
the partitioning module 302 is configured to perform partitioning processing on the image file to obtain a target image file;
the virtualization module 303 is configured to virtualize the target image file into loopback equipment, and load the target image file;
a mounting module 304, configured to mount the target image file to a specified directory;
a decompression module 305, configured to decompress the optical disc file system of the Linux operating system to a specified directory;
the copying module 306 is configured to copy the file decompressed by the optical disc file system of the Linux operating system to the directory of the target image file in a preset manner;
a conversion module 307, configured to convert the target image file into an image file in a preset format.
In one possible design, the creating module 301 is specifically configured to:
and calling preset default parameters through a command of creating a disk file to generate an image file in an img format.
In one possible design, the partition module 302 is specifically configured to:
and partitioning the image file by automatically calling a partition function to obtain a target image file containing at least one main partition.
In one possible design, further comprising:
and the encryption module 308 is used for creating a common account, a common account password and an administrator account password in the file system of the target image file.
The determining module 309 is configured to determine whether the target image file is successfully virtualized into a loopback device before the target image file is loaded, and if the target image file fails, perform a system error report to prompt system troubleshooting.
In one possible design, further comprising:
the changing module 310 is configured to enter the file system of the target image file through a file system switching instruction before creating a common account, a common account password, and an administrator account password in the file system of the target image file, and if the entry fails, end the process.
The allocation apparatus for display memory of this embodiment may execute the technical solutions in the methods shown in fig. 2 and fig. 3, and the specific implementation process and technical principle of the allocation apparatus refer to the related descriptions in the methods shown in fig. 2 and fig. 3, which are not described herein again.
In the embodiment, an image file is created according to preset default parameters; partitioning the mirror image file to obtain a target mirror image file; virtualizing a target image file into loop equipment, and loading the target image file; mounting a target mirror image file to a specified directory; decompressing an optical disk file system of a Linux operating system to a specified directory; copying a file decompressed by an optical disk file system of a Linux operating system to a directory of a target image file in a preset mode; creating a common account, a common account password and an administrator account password in a file system of the target image file; and converting the target image file into an image file with a preset format. In the embodiment, the system automatically calls the preset default parameters to create the mirror image file, partitions the mirror image file according to the partitioning command, and autonomously runs the mounting and copying program of the mirror image file to complete the manufacture of the mirror image file, so that the manual confirmation of a user is not needed in the whole process, the interactive operation of the user in the manufacturing process is reduced, and the manufacturing process of the mirror image file is simplified. And when entering the file system of the target image file, creating a common account, a common account password and an administrator account password, so that the operation permission of a common user and the administrator can be set, the malicious modification of the image file by other personnel is prevented, and the normal operation of the manufactured image file is ensured.
Fig. 5 is a schematic structural diagram of a system for manufacturing an image file according to a fourth embodiment of the present invention, and as shown in fig. 5, the system 40 for manufacturing an image file according to this embodiment may include: a processor 41 and a memory 42.
A memory 42 for storing a computer program (such as an application program, a functional module, and the like that implement the method for creating the image file), a computer instruction, and the like;
the computer programs, computer instructions, etc. described above may be stored in one or more memories 42 in partitions. And the above-described computer programs, computer instructions, data, etc. may be called by the processor 41.
A processor 41 for executing the computer program stored in the memory 42 to implement the steps of the method according to the above embodiments.
Reference may be made in particular to the description relating to the previous method embodiments.
The processor 41 and the memory 42 may be separate structures or may be integrated structures integrated together. When the processor 41 and the memory 42 are separate structures, the memory 42 and the processor 41 may be coupled by a bus 43.
The server in this embodiment may execute the technical solutions in the methods shown in fig. 2 and fig. 3, and the specific implementation process and technical principle of the server refer to the relevant descriptions in the methods shown in fig. 2 and fig. 3, which are not described herein again.
In the embodiment, an image file is created according to preset default parameters; partitioning the mirror image file to obtain a target mirror image file; virtualizing a target image file into loop equipment, and loading the target image file; mounting a target mirror image file to a specified directory; decompressing the optical disk file system of the Linux operating system to a specified directory; copying a file decompressed by an optical disk file system of a Linux operating system to a directory of a target image file in a preset mode; creating a common account, a common account password and an administrator account password in a file system of the target image file; and converting the target image file into an image file with a preset format.
In addition, embodiments of the present application further provide a computer-readable storage medium, in which computer-executable instructions are stored, and when at least one processor of the user equipment executes the computer-executable instructions, the user equipment executes the above-mentioned various possible methods.
Wherein computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer. An exemplary storage medium is coupled to the processor such the processor can read information from, and write information to, the storage medium. Of course, the storage medium may also be integral to the processor. The processor and the storage medium may reside in an ASIC. Additionally, the ASIC may reside in user equipment. Of course, the processor and the storage medium may reside as discrete components in a communication device.
Those of ordinary skill in the art will understand that: all or a portion of the steps of implementing the above-described method embodiments may be performed by hardware associated with program instructions. The program may be stored in a computer-readable storage medium. When executed, the program performs steps comprising the method embodiments described above; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. A method for making a mirror image file is characterized by comprising the following steps:
calling preset default parameters through a command of creating a disk file to generate an image file in an img format;
partitioning the image file by automatically calling a partition function to obtain a target image file containing at least one main partition;
virtualizing the target image file into loop back equipment, and loading the target image file;
mounting the target mirror image file to a specified directory;
decompressing the optical disk file system of the Linux operating system to the specified directory;
copying a file decompressed by the optical disk file system of the Linux operating system to a directory of the target image file in an rsync mode;
and converting the target image file into an image file with a preset format.
2. The method of claim 1, further comprising, prior to converting the target image file to an image file of a predetermined format:
and creating a common account, a common account password and an administrator account password in the file system of the target image file.
3. The method of claim 1 or 2, further comprising, prior to loading the target image file:
and judging whether the target image file is successfully virtualized into loop back equipment or not, and if the target image file fails, performing system error reporting to prompt system troubleshooting.
4. The method of claim 2, wherein before creating the common account, the common account password, and the administrator account password in the file system of the target image file, the method further comprises:
and entering the file system of the target mirror image file through a file system switching instruction, and ending the process if the entry fails.
5. An apparatus for producing an image file, comprising:
the creating module is used for calling preset default parameters through a disk file creating command and generating an image file in an img format; the partition module is used for partitioning the image file by automatically calling a partition function to obtain a target image file containing at least one main partition;
the virtual module is used for virtualizing the target image file into loop back equipment and loading the target image file;
the mounting module is used for mounting the target mirror image file to a specified directory;
the decompression module is used for decompressing the optical disk file system of the Linux operating system to the specified directory;
the copying module is used for copying the file decompressed by the optical disk file system of the Linux operating system to the directory of the target mirror image file in an rsync mode;
and the conversion module is used for converting the target image file into an image file in a preset format.
6. The apparatus of claim 5, further comprising:
and the encryption module is used for creating a common account, a common account password and an administrator account password in the file system of the target image file.
7. The apparatus of claim 5 or 6, further comprising:
and the judging module is used for judging whether the target image file is successfully virtualized into loop back equipment or not before loading the target image file, and if the target image file fails, performing system error reporting to prompt system troubleshooting.
8. The apparatus of claim 6, further comprising:
and the changing module is used for entering the file system of the target mirror image file through a file system switching instruction before creating a common account, a common account password and an administrator account password in the file system of the target mirror image file, and ending the process if the entering fails.
9. A system for producing an image file, comprising: the device comprises a memory and a processor, wherein the memory stores executable instructions of the processor; wherein the processor is configured to perform the method of making an image file of any of claims 1-4 via execution of the executable instructions.
10. A computer-readable storage medium on which a computer program is stored, the program being characterized by a processor for implementing the method for making an image file according to any one of claims 1 to 4.
CN201910193354.5A 2019-03-14 2019-03-14 Method, device and system for manufacturing mirror image file and storage medium Active CN109960517B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910193354.5A CN109960517B (en) 2019-03-14 2019-03-14 Method, device and system for manufacturing mirror image file and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910193354.5A CN109960517B (en) 2019-03-14 2019-03-14 Method, device and system for manufacturing mirror image file and storage medium

Publications (2)

Publication Number Publication Date
CN109960517A CN109960517A (en) 2019-07-02
CN109960517B true CN109960517B (en) 2022-11-22

Family

ID=67024260

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910193354.5A Active CN109960517B (en) 2019-03-14 2019-03-14 Method, device and system for manufacturing mirror image file and storage medium

Country Status (1)

Country Link
CN (1) CN109960517B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111090439B (en) * 2019-12-13 2021-10-22 苏州浪潮智能科技有限公司 Mirror image generation method, device and equipment for Linux system of bare metal server
CN111338652B (en) * 2020-02-20 2022-12-23 苏州浪潮智能科技有限公司 Operating system mirror image manufacturing method, device, equipment and medium
CN111813422A (en) * 2020-07-16 2020-10-23 济南浪潮数据技术有限公司 Installation method, device, equipment and storage medium of operating system
CN112698834A (en) * 2020-12-31 2021-04-23 深圳创维-Rgb电子有限公司 Burning file generation method and device, burning equipment and computer storage medium
CN115344313B (en) * 2022-08-22 2023-08-11 亿咖通(湖北)技术有限公司 Android system partition mounting method, electronic equipment and machine-readable storage medium
CN115509563B (en) * 2022-11-15 2023-02-28 济南浪潮数据技术有限公司 Mirror image file manufacturing method, device, equipment and medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101743546A (en) * 2007-08-06 2010-06-16 国际商业机器公司 Hierarchical storage management for a file system providing snapshots
CN103530148A (en) * 2013-09-18 2014-01-22 国云科技股份有限公司 Distribution method for large-scale Linux software package
CN108536729A (en) * 2018-02-24 2018-09-14 国家计算机网络与信息安全管理中心 Across the subregion image file synchronous method of one kind and device
CN108563454A (en) * 2018-03-30 2018-09-21 天津麒麟信息技术有限公司 A kind of operating system hard disk quick deployment method towards machine of soaring

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103970585B (en) * 2013-01-31 2017-10-27 新华三技术有限公司 Create the method and device of virtual machine
US9965307B2 (en) * 2014-10-06 2018-05-08 Vmware, Inc. Building virtual appliances
US10037334B1 (en) * 2016-12-26 2018-07-31 Parallels International Gmbh Memory management and sharing host OS files for Virtual Machines using execution-in-place
CN107438102B (en) * 2017-07-31 2020-04-03 国云科技股份有限公司 Cloud platform mirror image manufacturing system and implementation method thereof

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101743546A (en) * 2007-08-06 2010-06-16 国际商业机器公司 Hierarchical storage management for a file system providing snapshots
CN103530148A (en) * 2013-09-18 2014-01-22 国云科技股份有限公司 Distribution method for large-scale Linux software package
CN108536729A (en) * 2018-02-24 2018-09-14 国家计算机网络与信息安全管理中心 Across the subregion image file synchronous method of one kind and device
CN108563454A (en) * 2018-03-30 2018-09-21 天津麒麟信息技术有限公司 A kind of operating system hard disk quick deployment method towards machine of soaring

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
"Redundancy Aware Virtual Disk Mobility for Cloud Computing";Alexei Karve等;《2013 IEEE Sixth International Conference on Cloud Computing》;20131202;第35-42页 *
"Rethink the storage of virtual machine images in clouds";Xiaolin Xu等;《Future Generation Computer Systems》;20150604;第50卷;第75-86页 *
"一种基于聚类分组的虚拟机镜像去冗余方法";徐继伟 等;《软件学报》;20151116;第27卷(第02期);第466-480页 *
"基于内核函数监控的Linux系统防护方法的研究与实现";刘晨;《中国优秀博硕士学位论文全文数据库(硕士) 信息科技辑》;20180615(第06期);I138-82 *

Also Published As

Publication number Publication date
CN109960517A (en) 2019-07-02

Similar Documents

Publication Publication Date Title
CN109960517B (en) Method, device and system for manufacturing mirror image file and storage medium
CN102402446B (en) Method and device for installing application software
US8924954B2 (en) Application software installation method and application software installation apparatus
US20120102455A1 (en) System and apparatus for hosting applications on a storage array via an application integration framework
US9501296B2 (en) Hypervisor automation manager for starting an operation system with customization data from a disk image
CN104182257B (en) The installation method of application software and the erecting device of application software
US9817592B1 (en) Using an intermediate virtual disk format for virtual disk conversion
JP7012074B2 (en) Virtual disk expansion method and equipment
CN107239309B (en) Patch generation method and device, updating method, electronic device and storage medium
US20150120674A1 (en) Virtual program installation and state restoration
US20160062757A1 (en) Virtual appliance deployment
CN111831396A (en) Docker software and hardware integration-based delivery method and device
CN110716845A (en) Method for reading log information of Android system
CN111240807B (en) Volume-started virtual machine reconstruction method, terminal and readable storage medium
CN116450287A (en) Method, device, equipment and readable medium for managing storage capacity of service container
CN110780889A (en) Cloud mobile phone data cloning method and cloud mobile phone data restoring method
CN106933604B (en) System upgrading method and device
US9201699B2 (en) Decommissioning virtual appliances
CN110968852B (en) Virtual machine password management method, system, equipment and computer storage medium
CN115562590A (en) Method, system, equipment and storage medium for using cloud hard disk by cloud host
CN109271179B (en) Virtual machine application program management method, device, equipment and readable storage medium
CN112052439A (en) Access right control method and device of embedded system and storage medium
CN108304200B (en) Method and device for upgrading driving program and electronic equipment
CN113010195A (en) System upgrading method, storage medium and terminal equipment
CN113296891B (en) Platform-based multi-scene knowledge graph processing method and device

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
CB02 Change of applicant information

Address after: 100095 Building 2, Longxin Industrial Park, Zhongguancun environmental protection technology demonstration park, Haidian District, Beijing

Applicant after: Loongson Zhongke Technology Co.,Ltd.

Address before: 100095 Building 2, Longxin Industrial Park, Zhongguancun environmental protection technology demonstration park, Haidian District, Beijing

Applicant before: LOONGSON TECHNOLOGY Corp.,Ltd.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant