CN107193491B - Virtual environment disk operation method and device - Google Patents

Virtual environment disk operation method and device Download PDF

Info

Publication number
CN107193491B
CN107193491B CN201710349671.2A CN201710349671A CN107193491B CN 107193491 B CN107193491 B CN 107193491B CN 201710349671 A CN201710349671 A CN 201710349671A CN 107193491 B CN107193491 B CN 107193491B
Authority
CN
China
Prior art keywords
disk
virtual machine
information
operation command
command information
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
CN201710349671.2A
Other languages
Chinese (zh)
Other versions
CN107193491A (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.)
Inspur Cloud Information Technology Co Ltd
Original Assignee
Inspur Cloud Information 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 Inspur Cloud Information Technology Co Ltd filed Critical Inspur Cloud Information Technology Co Ltd
Priority to CN201710349671.2A priority Critical patent/CN107193491B/en
Publication of CN107193491A publication Critical patent/CN107193491A/en
Application granted granted Critical
Publication of CN107193491B publication Critical patent/CN107193491B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0662Virtualisation aspects
    • G06F3/0664Virtualisation aspects at device level, e.g. emulation of a storage device or system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0629Configuration or reconfiguration of storage systems
    • G06F3/0631Configuration or reconfiguration of storage systems by allocating resources to storage systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0673Single storage device
    • G06F3/0674Disk device
    • 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/45579I/O management, e.g. providing access to device drivers or storage

Abstract

The application provides a virtual environment disk operation method and device, wherein the method comprises the following steps: acquiring or receiving virtual machine disk operation command information, wherein the virtual machine disk operation command information is used for configuring a disk to be operated; executing the operation corresponding to the instruction content of the operation command information on the disk to be operated; and feeding back the instruction content execution result of the virtual machine operation command information to the disk processor. And the disk operation of the virtual machine is realized by managing the disk information of the virtual machine.

Description

Virtual environment disk operation method and device
Technical Field
The invention relates to a computer software application technology, in particular to a virtual environment disk operation method and device.
Background
With the further development of the internet technology and the popularization of cloud computing application, functions such as creation and mounting of a virtual machine disk are realized in various existing cloud computing platforms. After the disk or the extended disk is mounted, because processing such as formatting and/or partitioning is required before the mounted or extended disk is used, a user still needs to log in the virtual machine manually to perform operation of a disk command, and the virtual environment disk management is complex.
Disclosure of Invention
The invention provides a virtual environment disk operation method and device, which realize disk operation on a virtual machine through management of disk information of the virtual machine.
In order to achieve the purpose of the invention, the technical scheme adopted by the invention is as follows:
a virtual environment disk operation method is applied to a virtual machine agent instruction receiver and comprises the following steps:
acquiring or receiving virtual machine disk operation command information, wherein the virtual machine disk operation command information is used for configuring a disk to be operated;
executing the operation corresponding to the instruction content of the operation command information on the disk to be operated;
and feeding back the instruction content execution result of the virtual machine operation command information to the disk processor.
Preferably, the obtaining or receiving the virtual machine disk operation command information includes:
monitoring command messages of the message queue;
detecting whether the monitored command message comprises the unique identifier of the virtual machine, detecting whether the command message conforms to the message format of the disk operation command message when the monitored command message comprises the unique identifier of the virtual machine, and determining to acquire or receive the disk operation command message of the virtual machine when the monitored command message conforms to the message format of the disk operation command message.
Preferably, the operation corresponding to the instruction content of the operation command information executed by the disk to be operated includes at least one of:
selecting a disk to be operated according to the disk number information in the disk operation command;
creating a corresponding partition according to the disk partition information in the disk operation command, and marking the activity state of the partition;
distributing a drive number or a mounting point according to mounting information in the disk operation command;
according to the disk capacity expansion information in the disk operation command, executing expansion operation on the specified disk;
and executing formatting operation on the specified disk according to the disk formatting information in the disk operation command.
In order to solve the above technical problem, the present invention further provides a virtual environment disk operating method, applied to a disk processor, including:
determining the disk operation command information of the virtual machine according to a disk information table of the virtual machine, wherein the disk information table of the virtual machine comprises a mirror image and disk use information of the virtual machine, and is used for initializing the disk information of the virtual machine by the mirror image; the virtual machine disk operation command information is used for configuring a disk to be operated;
sending the virtual machine disk operation command information to a virtual machine agent instruction receiver;
and receiving the instruction content execution result of the virtual machine operation command information fed back by the virtual machine agent instruction receiver.
Preferably, determining the virtual machine disk operation command information according to the virtual machine disk information table includes:
and matching the disk command library to generate virtual machine disk operation command information according to the virtual machine disk information table.
Preferably, the sending the virtual machine disk operation command information to the virtual machine agent instruction acceptor comprises:
and formatting the disk operation command information, assembling the unique identifier of the virtual machine and the formatted disk operation command information, and sending the assembled unique identifier and the formatted disk operation command information to a message queue.
Preferably, after receiving the instruction content execution result of the virtual machine operation command information fed back by the virtual machine agent instruction acceptor, the method further includes:
if the execution result is successful, storing the result information of the partition and/or mounting and/or formatting and/or expanding of the disk in the execution result into an operation record log of the virtual machine;
and if the execution result is failure, manually analyzing the fed-back error code and the error information.
In order to solve the above technical problem, the present invention further provides a virtual environment disk operating apparatus, disposed at a virtual machine proxy instruction receiver, including:
the communication module is used for acquiring or receiving virtual machine disk operation command information, and the virtual machine disk operation command information is used for configuring a disk to be operated;
the execution module is configured to execute the operation corresponding to the instruction content of the operation command information on the disk to be operated;
the communication module is further configured to feed back an instruction content execution result of the virtual machine operation command information to the disk processor.
Preferably, the communication module includes:
the monitoring unit is arranged for monitoring the command message of the message queue;
and the detection unit is used for detecting whether the monitored command message comprises the unique identifier of the virtual machine, detecting whether the command message conforms to the message format of the disk operation command message when the monitored command message comprises the unique identifier of the virtual machine, and determining to acquire or receive the disk operation command message of the virtual machine when the monitored command message conforms to the message format of the disk operation command message.
Preferably, the operation corresponding to the instruction content of the operation command information executed by the execution module on the disk to be operated includes at least one of the following:
selecting a disk to be operated according to the disk number information in the disk operation command;
creating a corresponding partition according to the disk partition information in the disk operation command, and marking the activity state of the partition;
distributing a drive number or a mounting point according to mounting information in the disk operation command;
according to the disk capacity expansion information in the disk operation command, executing expansion operation on the specified disk;
and executing formatting operation on the specified disk according to the disk formatting information in the disk operation command.
In order to solve the above technical problem, the present invention further provides a virtual environment disk operating apparatus, disposed in a disk processor, including:
the command library module is arranged for determining the disk operation command information of the virtual machine according to a disk information table of the virtual machine, wherein the disk information table of the virtual machine comprises a mirror image and disk use information of the virtual machine and is used for initializing the disk information of the virtual machine by the mirror image; the virtual machine disk operation command information is used for configuring a disk to be operated;
the instruction output module is used for sending the virtual machine disk operation command information to a virtual machine agent instruction receiver;
and the disk management module is used for receiving the instruction content execution result of the virtual machine operation command information fed back by the virtual machine agent instruction receiver.
Preferably, the determining, by the command library module, the virtual machine disk operation command information according to the virtual machine disk information table includes:
and matching the disk command library to generate virtual machine disk operation command information according to the virtual machine disk information table.
Preferably, the sending the virtual machine disk operation command information to the virtual machine agent command acceptor by the command output module comprises:
and formatting the disk operation command information, assembling the unique identifier of the virtual machine and the formatted disk operation command information, and sending the assembled unique identifier and the formatted disk operation command information to a message queue.
Preferably, the disk management module is further configured to:
if the execution result is successful, storing the result information of the partition and/or mounting and/or formatting and/or expanding of the disk in the execution result into an operation record log of the virtual machine;
and if the execution result is failure, manually analyzing the fed-back error code and the error information.
Compared with the prior art, the invention has the following beneficial effects:
according to the technical scheme, when the virtual machine is created through mirroring, a plurality of disks are created and mounted on the virtual machine, and partitioning, formatting and mounting are carried out to the designated disk identifier or directory according to requirements. Or when the disk of the existing virtual machine is not satisfied, mounting a new disk or expanding an old disk, and partitioning, formatting and mounting to a specified disk character or directory according to requirements.
Drawings
FIG. 1 is a flowchart of a method for operating a virtual environment disk according to an embodiment of the present invention;
FIG. 2 is a flowchart of another virtual environment disk operating method according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of a virtual environment disk operating apparatus according to an embodiment of the present invention;
FIG. 4 is a schematic structural diagram of another virtual environment disk operating apparatus according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of disk processing in a virtual environment according to embodiment 1 of the present invention;
fig. 6 is a flowchart of virtual environment disk processing according to embodiment 1 of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the following description of the embodiments of the present invention with reference to the accompanying drawings is provided, and it should be noted that, in the case of conflict, features in the embodiments and the embodiments in the present application may be arbitrarily combined with each other.
As shown in fig. 1, an embodiment of the present invention provides a virtual environment disk operating method, applied to a virtual machine proxy instruction acceptor, including:
s101, acquiring or receiving virtual machine disk operation command information, wherein the virtual machine disk operation command information is used for configuring a disk to be operated;
s102, executing operation corresponding to the instruction content of the operation command information on the disk to be operated;
s103, feeding back the instruction content execution result of the virtual machine operation command information to the disk processor.
The virtual machine proxy instruction acceptor may be a client installed on the virtual machine, or may be a device provided on the virtual machine. The method is used for appointing to accept the disk operation command, execute the command and return the command result aiming at the virtual machine.
The obtaining or receiving of the virtual machine disk operation command information in step S101 may be performed in the following manner:
monitoring command messages of the message queue;
detecting whether the monitored command message comprises the unique identifier of the virtual machine, detecting whether the command message conforms to the message format of the disk operation command message when the monitored command message comprises the unique identifier of the virtual machine, and determining to acquire or receive the disk operation command message of the virtual machine when the monitored command message conforms to the message format of the disk operation command message.
In the embodiment of the invention, the unique identification is carried out on the virtual machine, the unique message queue of the virtual machine is established through the unique identification, the virtual machine agent instruction receiver only monitors the unique message queue of the virtual machine where the virtual machine agent instruction receiver is located, the type distinction is added aiming at the condition that the disk operation instruction information sent to the virtual machine agent instruction receiver is formatted, and the virtual machine agent instruction receiver only executes the command type which can be identified.
In step S102, the operation corresponding to the instruction content of the operation command information executed by the disk to be operated includes at least one of:
selecting a disk to be operated according to the disk number information in the disk operation command;
creating a corresponding partition according to the disk partition information in the disk operation command, and marking the activity state of the partition;
distributing a drive number or a mounting point according to mounting information in the disk operation command;
according to the disk capacity expansion information in the disk operation command, executing expansion operation on the specified disk;
and executing formatting operation on the specified disk according to the disk formatting information in the disk operation command.
The virtual machine disk operation command information of the embodiment of the invention comprises partition information of a newly added disk, mounting information (disk identifier is distributed or mounted to a folder) and formatting information; mounting information (disk signature is allocated or mounted to a folder) after the disk is mounted to the virtual machine again; and expanding the capacity expansion information of the mounted disk.
As shown in fig. 2, an embodiment of the present invention further provides a virtual environment disk operation method, applied to a disk processor, including:
s201, determining virtual machine disk operation command information according to a virtual machine disk information table, wherein the virtual machine disk information table comprises a mirror image and disk use information of a virtual machine, and is used for initializing disk information of the virtual machine by the mirror image; the virtual machine disk operation command information is used for configuring a disk to be operated;
s202, sending the virtual machine disk operation command information to a virtual machine agent instruction receiver;
s203, receiving the instruction content execution result of the virtual machine operation instruction information fed back by the virtual machine agent instruction acceptor.
The disk processor can be a client installed on the upper computer or a device arranged on the upper computer.
When the virtual machine is created by using the mirror image, the disk information of the virtual machine is initialized through the virtual machine disk information table of the mirror image.
The contents contained in the disk information table of the virtual machine may be as shown in table 1:
TABLE 1
Serial number Field information Description of the invention
1 Inner code Unique ID 32-bit uuid of magnetic disk
2 Disk name Name information of magnetic disk
3 Using object designations Virtual machine mark or mirror mark for mounting disk
4 Size and breadth Size of magnetic disk (GB)
5 Hanging point Mounting point of magnetic disk (the second disk under windows)
The contents contained in the virtual machine disk operation command information may be as shown in table 2:
TABLE 2
Serial number Field information Description of the invention
1 Inner code Unique 32-bit uuid for disk partition information
2 Disk label The unique designation of a disk, representing the partition of that disk
3 The first table partition The partition is the second partition of the disk
4 Partition size Size of the partition (GB)
5 Mounting path Partition mounting path (disc symbol or folder)
Step S201 determines, according to the virtual machine disk information table, that the virtual machine disk operation command information includes:
and matching the disk command library to generate virtual machine disk operation command information according to the virtual machine disk information table.
The step S202 of sending the virtual machine disk operation command information to a virtual machine agent instruction acceptor includes:
and formatting the disk operation command information, assembling the unique identifier of the virtual machine and the formatted disk operation command information, and sending the assembled unique identifier and the formatted disk operation command information to a message queue.
Step S203 is followed by:
if the execution result is successful, storing the result information of the partition and/or mounting and/or formatting and/or expanding of the disk in the execution result into an operation record log of the virtual machine;
and if the execution result is failure, manually analyzing the fed-back error code and the error information.
The log display page of the embodiment of the invention is as follows:
and (3) executing the result:
microsoft DiskPart version 6.1.7601 copyright (C) 1999-: ZLABU2VF-MASTER disk 1 is now the selected disk. DiskPart successfully cleared the disk. Diskpart successfully created the specified partition. Partition 1 is now the selected partition. DiskPart marks the current partition as active. DiskPart successfully assigns a drive number or load point. 0 percent completed 100 percent completed distPart successfully formats the volume. Exit diskpart.start install pyodbc.step 1: chec
And (3) executing the result:
microsoft DiskPart version 6.1.7601 copyright (C) 1999-: ZLABU2VF-MASTER volume 3 is the selected volume. DiskPart successfully expands volumes. Exit diskpart.
As shown in fig. 3, an embodiment of the present invention provides a virtual environment disk operating apparatus, disposed in a virtual machine proxy instruction acceptor, including:
the communication module is used for acquiring or receiving virtual machine disk operation command information, and the virtual machine disk operation command information is used for configuring a disk to be operated;
the execution module is configured to execute the operation corresponding to the instruction content of the operation command information on the disk to be operated;
the communication module is further configured to feed back an instruction content execution result of the virtual machine operation command information to the disk processor.
The communication module includes:
the monitoring unit is arranged for monitoring the command message of the message queue;
and the detection unit is used for detecting whether the monitored command message comprises the unique identifier of the virtual machine, detecting whether the command message conforms to the message format of the disk operation command message when the monitored command message comprises the unique identifier of the virtual machine, and determining to acquire or receive the disk operation command message of the virtual machine when the monitored command message conforms to the message format of the disk operation command message.
The execution module executes the operation corresponding to the instruction content of the operation command information on the disk to be operated, and the operation comprises at least one of the following operations:
selecting a disk to be operated according to the disk number information in the disk operation command;
creating a corresponding partition according to the disk partition information in the disk operation command, and marking the activity state of the partition;
distributing a drive number or a mounting point according to mounting information in the disk operation command;
according to the disk capacity expansion information in the disk operation command, executing expansion operation on the specified disk;
and executing formatting operation on the specified disk according to the disk formatting information in the disk operation command.
As shown in fig. 4, an embodiment of the present invention further provides a virtual environment disk operating apparatus, disposed in a disk processor, including:
the command library module is arranged for determining the disk operation command information of the virtual machine according to a disk information table of the virtual machine, wherein the disk information table of the virtual machine comprises a mirror image and disk use information of the virtual machine and is used for initializing the disk information of the virtual machine by the mirror image; the virtual machine disk operation command information is used for configuring a disk to be operated;
the instruction output module is used for sending the virtual machine disk operation command information to a virtual machine agent instruction receiver;
and the disk management module is used for receiving the instruction content execution result of the virtual machine operation command information fed back by the virtual machine agent instruction receiver.
The command library module determines the virtual machine disk operation command information according to the virtual machine disk information table, and comprises the following steps:
and matching the disk command library to generate virtual machine disk operation command information according to the virtual machine disk information table.
The step that the instruction output module sends the virtual machine disk operation command information to the virtual machine proxy instruction receiver comprises the following steps:
and formatting the disk operation command information, assembling the unique identifier of the virtual machine and the formatted disk operation command information, and sending the assembled unique identifier and the formatted disk operation command information to a message queue.
The disk management module is further configured to:
if the execution result is successful, storing the result information of the partition and/or mounting and/or formatting and/or expanding of the disk in the execution result into an operation record log of the virtual machine;
and if the execution result is failure, manually analyzing the fed-back error code and the error information.
Example 1
As shown in fig. 5 and fig. 6, in this embodiment, a window operating system is combined to implement a disk processing function, and a virtual disk management page may be used to transmit a command by using a message queue (rabbitmq), so as to implement a remote disk operation, which specifically includes:
the disk processor determines virtual machine disk operation command information according to a virtual machine disk information table, wherein the virtual machine disk information table comprises a mirror image and disk use information of a virtual machine and is used for initializing disk information of the virtual machine by the mirror image; the virtual machine disk operation command information comprises mounting position information and partition information of the disk;
the virtual machine agent instruction receiver acquires or receives virtual machine disk operation command information, wherein the virtual machine disk operation command information comprises mounting position information and partition information of the disk;
the virtual machine agent instruction receiver partitions the virtual machine disk according to the virtual machine operation command information and mounts the partitioned disk to the mounting position;
and the virtual machine agent instruction receiver feeds back the instruction content execution result of the virtual machine operation command information to the disk processor.
The virtual disk management page can be used for receiving disk management settings of a user and displaying disk information and partition information under the virtual machine to the user.
Although the embodiments of the present invention have been described above, the contents thereof are merely embodiments adopted to facilitate understanding of the technical aspects of the present invention, and are not intended to limit the present invention. It will be apparent to persons skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention as defined in the appended claims.

Claims (10)

1. A virtual environment disk operation method is applied to a virtual machine agent instruction acceptor, and comprises the following steps:
acquiring or receiving virtual machine disk operation command information, wherein the virtual machine disk operation command information is used for configuring a disk to be operated;
executing the operation corresponding to the instruction content of the operation command information on the disk to be operated;
feeding back an instruction content execution result of the virtual machine operation command information to a disk processor;
the acquiring or receiving the virtual machine disk operation command information includes:
monitoring command messages of the message queue;
detecting whether the monitored command message comprises the unique identifier of the virtual machine, detecting whether the command message conforms to the message format of the disk operation command message when the monitored command message comprises the unique identifier of the virtual machine, and determining to acquire or receive the disk operation command message of the virtual machine when the monitored command message conforms to the message format of the disk operation command message.
2. The method of claim 1, wherein: the operation corresponding to the instruction content of the operation command information executed by the disk to be operated comprises at least one of the following operations:
selecting a disk to be operated according to the disk number information in the disk operation command;
creating a corresponding partition according to the disk partition information in the disk operation command, and marking the activity state of the partition;
distributing a drive number or a mounting point according to mounting information in the disk operation command;
according to the disk capacity expansion information in the disk operation command, executing expansion operation on the specified disk;
and executing formatting operation on the specified disk according to the disk formatting information in the disk operation command.
3. A virtual environment disk operation method is applied to a disk processor and comprises the following steps:
determining the disk operation command information of the virtual machine according to a disk information table of the virtual machine, wherein the disk information table of the virtual machine comprises a mirror image and disk use information of the virtual machine, and is used for initializing the disk information of the virtual machine by the mirror image; the virtual machine disk operation command information is used for configuring a disk to be operated;
sending the virtual machine disk operation command information to a virtual machine agent instruction receiver;
receiving an instruction content execution result of the virtual machine operation command information fed back by the virtual machine agent instruction receiver;
wherein the sending the virtual machine disk operation command information to a virtual machine agent instruction receiver comprises:
and formatting the disk operation command information, assembling the unique identifier of the virtual machine and the formatted disk operation command information, and sending the assembled unique identifier and the formatted disk operation command information to a message queue.
4. The method of claim 3, wherein: according to the virtual machine disk information table, determining virtual machine disk operation command information comprises:
and matching the disk command library to generate virtual machine disk operation command information according to the virtual machine disk information table.
5. The method of claim 3, wherein: after receiving the instruction content execution result of the virtual machine operation command information fed back by the virtual machine agent instruction acceptor, the method further comprises the following steps:
if the execution result is successful, storing the result information of the partition and/or mounting and/or formatting and/or expanding of the disk in the execution result into an operation record log of the virtual machine;
and if the execution result is failure, manually analyzing the fed-back error code and the error information.
6. A virtual environment disk operating device is characterized in that: the virtual machine agent instruction acceptor is arranged, and comprises:
the communication module is used for acquiring or receiving virtual machine disk operation command information, and the virtual machine disk operation command information is used for configuring a disk to be operated;
the execution module is configured to execute the operation corresponding to the instruction content of the operation command information on the disk to be operated;
the communication module is further configured to feed back an instruction content execution result of the virtual machine operation command information to the disk processor;
wherein the communication module comprises:
the monitoring unit is arranged for monitoring the command message of the message queue;
and the detection unit is used for detecting whether the monitored command message comprises the unique identifier of the virtual machine, detecting whether the command message conforms to the message format of the disk operation command message when the monitored command message comprises the unique identifier of the virtual machine, and determining to acquire or receive the disk operation command message of the virtual machine when the monitored command message conforms to the message format of the disk operation command message.
7. The apparatus of claim 6, wherein: the execution module executes the operation corresponding to the instruction content of the operation command information on the disk to be operated, and the operation comprises at least one of the following operations:
selecting a disk to be operated according to the disk number information in the disk operation command;
creating a corresponding partition according to the disk partition information in the disk operation command, and marking the activity state of the partition;
distributing a drive number or a mounting point according to mounting information in the disk operation command;
according to the disk capacity expansion information in the disk operation command, executing expansion operation on the specified disk;
and executing formatting operation on the specified disk according to the disk formatting information in the disk operation command.
8. A virtual environment disk operating device is characterized in that the virtual environment disk operating device is arranged on a disk processor and comprises:
the command library module is arranged for determining the disk operation command information of the virtual machine according to a disk information table of the virtual machine, wherein the disk information table of the virtual machine comprises a mirror image and disk use information of the virtual machine and is used for initializing the disk information of the virtual machine by the mirror image; the virtual machine disk operation command information is used for configuring a disk to be operated;
the instruction output module is used for sending the virtual machine disk operation command information to a virtual machine agent instruction receiver;
the disk management module is used for receiving the instruction content execution result of the virtual machine operation command information fed back by the virtual machine agent instruction receiver;
the step of sending the virtual machine disk operation command information to a virtual machine agent command receiver by the command output module comprises the following steps:
and formatting the disk operation command information, assembling the unique identifier of the virtual machine and the formatted disk operation command information, and sending the assembled unique identifier and the formatted disk operation command information to a message queue.
9. The apparatus of claim 8, wherein: the command library module determines the virtual machine disk operation command information according to the virtual machine disk information table, and comprises the following steps:
and matching the disk command library to generate virtual machine disk operation command information according to the virtual machine disk information table.
10. The apparatus of claim 8, wherein: the disk management module is further configured to:
if the execution result is successful, storing the result information of the partition and/or mounting and/or formatting and/or expanding of the disk in the execution result into an operation record log of the virtual machine;
and if the execution result is failure, manually analyzing the fed-back error code and the error information.
CN201710349671.2A 2017-05-17 2017-05-17 Virtual environment disk operation method and device Active CN107193491B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710349671.2A CN107193491B (en) 2017-05-17 2017-05-17 Virtual environment disk operation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710349671.2A CN107193491B (en) 2017-05-17 2017-05-17 Virtual environment disk operation method and device

Publications (2)

Publication Number Publication Date
CN107193491A CN107193491A (en) 2017-09-22
CN107193491B true CN107193491B (en) 2020-11-03

Family

ID=59872825

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710349671.2A Active CN107193491B (en) 2017-05-17 2017-05-17 Virtual environment disk operation method and device

Country Status (1)

Country Link
CN (1) CN107193491B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108733323B (en) * 2018-05-24 2021-12-21 云宏信息科技股份有限公司 Self-service formatting method and device for data disc
CN111381929A (en) * 2018-12-29 2020-07-07 广州小沐信息科技有限公司 Realization method for xen virtualization to automatically identify newly-added disk of windows virtual machine
CN110908609B (en) * 2019-11-22 2021-09-17 苏州浪潮智能科技有限公司 Method, system and equipment for processing disk and readable storage medium
CN113504872B (en) * 2021-05-14 2023-11-03 济南浪潮数据技术有限公司 Method, system, equipment and medium for mounting virtual disk on cloud physical machine

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110010710A1 (en) * 2009-07-10 2011-01-13 Microsoft Corporation Image Transfer Between Processing Devices
CN105573819A (en) * 2015-12-11 2016-05-11 国云科技股份有限公司 Method for obtaining disk capacity information of virtual machine directly through host machine
CN106528263A (en) * 2016-10-21 2017-03-22 郑州云海信息技术有限公司 A method for injecting metainformation into virtual machines and performing initialization in a virtualization environment
CN107483247A (en) * 2017-08-17 2017-12-15 郑州云海信息技术有限公司 A kind of multi-level service configuration management method based on cloud platform

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110010710A1 (en) * 2009-07-10 2011-01-13 Microsoft Corporation Image Transfer Between Processing Devices
CN105573819A (en) * 2015-12-11 2016-05-11 国云科技股份有限公司 Method for obtaining disk capacity information of virtual machine directly through host machine
CN106528263A (en) * 2016-10-21 2017-03-22 郑州云海信息技术有限公司 A method for injecting metainformation into virtual machines and performing initialization in a virtualization environment
CN107483247A (en) * 2017-08-17 2017-12-15 郑州云海信息技术有限公司 A kind of multi-level service configuration management method based on cloud platform

Also Published As

Publication number Publication date
CN107193491A (en) 2017-09-22

Similar Documents

Publication Publication Date Title
CN107193491B (en) Virtual environment disk operation method and device
US10067692B2 (en) Method and apparatus for backing up and restoring cross-virtual machine application
US8495625B1 (en) Method and system for creation of streamed files on-demand
EP2731013A1 (en) Backing up method, device, and system for virtual machine
US10282120B2 (en) Method, apparatus and system for inserting disk
KR101913346B1 (en) Method and apparatus for managing cloud server in cloud environment
US10404568B2 (en) Agent manager for distributed transaction monitoring system
US20120210114A1 (en) Log file processing system and method
CN109474467B (en) Network automation management method and device, storage medium and electronic equipment
WO2013182051A1 (en) Software installation method, terminal, system and computer storage medium
CN107665141B (en) Database configuration method and equipment thereof
CN111880967A (en) File backup method, device, medium and electronic equipment in cloud scene
US20200183789A1 (en) Installation file processing method and device, and server
CN113590365A (en) Cross-process communication method and Binder driver
CN112612417A (en) Data migration method, device, equipment and storage medium
EP4030296A1 (en) I/o request processing method, storage array, and host
US8549545B2 (en) Abstraction of computer disk image cloning capabilities from bootable media
US11792278B2 (en) Resolving conflicts of application runtime dependencies
CN109710377A (en) A method of restoring kvm virtual machine in the distributed storage of failure
US11226775B2 (en) Extracting drive letters for partitions in an offline virtual disk
CN109634721B (en) Method and related device for starting communication between virtual machine and host
KR101597246B1 (en) Method for Connecting Virtual Disk for Changing Between Virtual Machines
CN106131237A (en) Communication control method and device between container
CN113900765A (en) Cloud application starting method, equipment, terminal and computer readable storage medium
CN112671561B (en) Network card configuration method and equipment of cloud host

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
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20200522

Address after: 250101 floor 27, S01, Inspur Science Park, No. 1036, Inspur Road, Jinan City, Shandong Province

Applicant after: Tidal Cloud Information Technology Co.,Ltd.

Address before: 450018 Henan province Zheng Dong New District of Zhengzhou City Xinyi Road No. 278 16 floor room 1601

Applicant before: ZHENGZHOU YUNHAI INFORMATION TECHNOLOGY Co.,Ltd.

CB02 Change of applicant information
CB02 Change of applicant information

Address after: 250101 floor 27, S01, Inspur Science Park, No. 1036, Inspur Road, Jinan City, Shandong Province

Applicant after: Inspur cloud Information Technology Co., Ltd

Address before: 250101 floor 27, S01, Inspur Science Park, No. 1036, Inspur Road, Jinan City, Shandong Province

Applicant before: Tidal Cloud Information Technology Co.,Ltd.

GR01 Patent grant
GR01 Patent grant