Methods and systems for tracking a virtual memory of a virtual machine
US-10592271-B1 · Mar 17, 2020 · US
US2022121473A1 · US · A1
| Field | Value |
|---|---|
| Publication number | US-2022121473-A1 |
| Application number | US-202117564994-A |
| Country | US |
| Kind code | A1 |
| Filing date | Dec 29, 2021 |
| Priority date | Jun 29, 2019 |
| Publication date | Apr 21, 2022 |
| Grant date | — |
A practical reading order for non-experts. Skip the full description unless you need deep technical detail.
What the patent document calls the invention.
A short plain-language summary of the technical disclosure.
Who owns or filed the patent and who is credited as inventor.
Filing, priority, publication, and grant dates set the timeline.
The legal scope of protection — read this for what is actually claimed.
Technology tags used to group this patent with similar filings.
Prior art links and similar publications in this corpus.
Official abstract text for this publication.
This application provides a method for migrating a virtual machine and an apparatus. The method is applied to a source-end physical host, the source-end physical host includes a host machine operating system and a source-end virtual machine running in the host machine operating system, and the host machine operating system includes a PF driver. According to the technical solutions of this application, memory consistency, before and after a migration process, of a virtual machine configured with a pass-through device can be ensured.
Opening claim text (preview).
What is claimed is: 1 . A physical host, comprising a source-end virtual machine module and a physical function PF driver module, wherein the source-end virtual machine is configured to send a first instruction to the source-end pass-through device by using the PF driver module, wherein the first instruction is used to instruct the source-end pass-through device to record a storage address of dirty page data, and the dirty page data is data written by the source-end pass-through device to the source-end virtual machine module in a direct memory access DMA manner; and the source-end virtual machine module is further configured to obtain the storage address that is of the dirty page data and that is recorded by the source-end pass-through device, and send to-be-migrated data to a destination-end virtual machine, wherein the to-be-migrated data comprises the dirty page data of the source-end virtual machine module. 2 . The physical host according to claim 1 , wherein the source-end virtual machine module is specifically configured to: send the first instruction to the PF driver module; and the PF driver module is specifically configured to send the first instruction to the source-end pass-through device. 3 . The physical host according to claim 1 , wherein the PF driver module is specifically configured to: write the first instruction into reserved storage space, wherein the reserved storage space is used by the source-end pass-through device to obtain the first instruction. 4 . The physical host according to claim 3 , wherein the PF driver module is further configured to: send an address of the reserved storage space to the source-end pass-through device by using a register of the source-end pass-through device. 5 . The physical host according to any one of claim 1 , wherein the PF driver module is specifically configured to: write the first instruction into a reserved bit of peripheral component interconnect express PCIe configuration space of the source-end pass-through device, wherein the PCIe configuration space is used by the source-end pass-through device to obtain the instruction. 6 . The physical host according to any one of claim 1 , wherein the PF driver module is specifically configured to write the first instruction into preconfigured PCIe configuration space of the source-end pass-through device, and the preconfigured PCIe configuration space is used by the source-end pass-through device to obtain the first instruction. 7 . The physical host according to any one of claim 1 , wherein a plurality of virtual pass-through devices run in the source-end pass-through device, and the physical host further comprises: a control module, and the control module is configured to allocate first storage space to the PF driver module, wherein the first storage space is used to store a storage address that is of dirty page data and that is recorded by each of the plurality of virtual pass-through devices. 8 . The physical host according to claim 7 , wherein the source-end virtual machine module is further configured to: send a dirty page synchronization instruction to the source-end pass-through device by using the PF driver module, wherein the dirty page instruction comprises a first address in the first storage space, and the dirty page synchronization instruction is used to instruct the source-end pass-through device to synchronize the storage address of the dirty page data to a storage location that is in the first storage space and that is indicated by the first address; and read the storage address of the dirty page data from the first storage space based on the first address. 9 . The physical host according to claim 7 , wherein the control module is further configured to: allocate second storage space to the PF driver module, wherein the second storage space is used to store status information of each of the plurality of virtual pass-through devices, the status information is status information of each virtual pass-through device at a moment at which running stops, and the status information comprises information about a register of each virtual pass-through device and information about a memory descriptor. 10 . The physical host according to claim 9 , wherein the source-end virtual machine module is further configured to: send a save instruction to the source-end pass-through device by using the PF driver module, wherein the save instruction comprises a second address in the second storage space, and the save instruction is used to instruct the source-end pass-through device to save the status information to a storage location that is in the second storage space and that is indicated by the second address; and obtain the status information from the storage location that is in the second storage space and that corresponds to the second address. 11 . The physical host according to any one of claim 7 , wherein the plurality of virtual pass-through devices comprise a first virtual pass-through device and a second virtual pass-through device, and the source-end virtual machine module is further configured to: after receiving a feedback instruction that is of a second instruction and that is sent by the PF driver module, send a third instruction to the second virtual pass-through device by using the PF driver module, wherein the feedback instruction indicates that the PF driver module has sent the second instruction to the first virtual pass-through device. 12 . A pass-through device, comprising a communications module and a processing module, wherein the communications module is configured to receive a first instruction sent by a source-end virtual machine by using a physical function PF driver, wherein the first instruction is used to instruct the pass-through device to record a storage address of dirty page data, the dirty page data is data written by the pass-through device to the source-end virtual machine in a direct memory access DMA manner, the PF driver runs in a host operating system of a source-end physical host, and the source-end physical host further comprises the source-end virtual machine running in the host operating system; the processing module is configured to record the storage address of the dirty page data according to the first instruction; and the communications module is further configured to send the storage address of the dirty page data to the source-end virtual machine. 13 . The pass-through device according to claim 12 , wherein the communications module is specifically configured to: receive the first instruction sent by the PF driver, wherein the first instruction is an instruction that is transparently transmitted by the source-end virtual machine to the pass-through device by using the PF driver. 14 . The pass-through device according to claim 12 , wherein the communications module is further configured to: obtain, by the pass-through device, an address of reserved storage space; and the processing module is further configured to obtain, based on the address of the reserved storage space, the first instruction carried in the reserved storage space, wherein the first instruction is an instruction written by the PF driver to the reserved storage space. 15 . The pass-through device according to claim 12 , wherein the communications module is specifically configured to: obtain the first instruction carried in a reserved bit of peripheral component interconnect express PCIe configuration space of the pass-through device, wherein the first instruction is an instruction written by the PF driver to the reserved bit. 16
I/O management, e.g. providing access to device drivers or storage · CPC title
Hypervisor-specific management and integration aspects · CPC title
Distribution of virtual machine instances; Migration and load balancing · CPC title
Related publications grouped by family.
Answers are generated from the same data shown on this page.