CN106557444A - The method and apparatus for realizing SR-IOV network interface cards is, the method and apparatus for realizing dynamic migration - Google Patents
The method and apparatus for realizing SR-IOV network interface cards is, the method and apparatus for realizing dynamic migration Download PDFInfo
- Publication number
- CN106557444A CN106557444A CN201510646047.XA CN201510646047A CN106557444A CN 106557444 A CN106557444 A CN 106557444A CN 201510646047 A CN201510646047 A CN 201510646047A CN 106557444 A CN106557444 A CN 106557444A
- Authority
- CN
- China
- Prior art keywords
- user space
- virtnic
- data
- sent
- virtual client
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F13/00—Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F13/38—Information transfer, e.g. on bus
- G06F13/42—Bus transfer protocol, e.g. handshake; Synchronisation
- G06F13/4282—Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/08—Protocols specially adapted for terminal emulation, e.g. Telnet
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Stored Programmes (AREA)
- Computer And Data Communications (AREA)
Abstract
The invention discloses one kind realizes the method and apparatus of single input/output virtualization (SR-IOV) network interface card, the method and apparatus for realizing dynamic migration, including:Data is activation to be sent in User space internal memory is given User space virtNIC-BE when virtual client needs to send data by User space virtNIC-FE;Data is activation to be sent is driven Driver to User space virtual functions VF by User space virtNIC-BE;Data is activation to be sent is given corresponding VF by User space VF Driver.By the solution of the present invention, the transmission of data is realized by User space virtNIC-FE, User space virtNIC-BE, User space VF Driver, without by data from User space memory copying in kernel state internal memory, also without switching between user space and kernel space, the network performance of virtual client is improve.
Description
Technical field
The present invention relates to single input/output virtualizes (SR-IOV, Single Root I/O
Virtualization) technology, espespecially a kind of method and apparatus for realizing SR-IOV network interface cards, realizes that dynamic is moved
The method and apparatus of shifting.
Background technology
Cloud computing is current very popular cutting edge technology, and one of cloud computing very important to be characterized in that void
Planization.After Intel Virtualization Technology, user can be at an arbitrary position, using various terminals acquisition using clothes
Business.The resource that these applications are used is from " cloud ", rather than fixed tangible entity.Apply at " cloud "
Middle somewhere, but actually particular location of the user without the need for understanding, without application operation is worried.User is only
Need a notebook or a mobile phone, it is possible to all for realizing by network service that we need,
Even include task as supercomputing.In order to meet this characteristic of user, cloud computing system is necessary
Cloud service virtual machine (i.e. virtual client) dynamic migration can be performed, and (Live Migration, are called
Thermophoresis, real-time migration) on different physical computers (i.e. host).Dynamic migration refers to cloud
The running status of whole virtual client is completely preserved by computing system, while quickly can recover
To on original hardware platform even different hardware platforms.After recovery, virtual client application is still just flat
Sliding operation, user will not perceive any difference.
Virtualization includes the virtualization of CPU, the virtualization of internal memory, the void of input and output (I/O) equipment
Planization.Wherein, the Intel Virtualization Technology comparative maturity of the virtualization of CPU and internal memory, I/O equipment it is virtual
Change more delayed.
There is a kind of technology in I/O device virtualizations SR-IOV technologies.SR-IOV technologies are that one kind is based on
The virtualization solution of hardware, can improve performance and scalability.SR-IOV standards are allowed virtual
Quick peripheral component is efficiently shared between client computer and interconnects (PCIe, Peripheral Component
Interconnect Express) equipment, directly allow client computer to use the equipment of host, as it is hard
Realize in part, it is possible to obtain very high I/O performances.
The SR-IOV network equipments generally define a physical function (PF, Physical Function) and
Several virtual functions (VF, Virtual Function), PF and VF can be used as single network interface card,
VF is typically transparent to hardware in virtual client by PCIe Signal Transparent Transmission Technologies, so in virtual client
In can directly access the hardware register of VF.But the hardware of the SR-IOV due to different hosts machine
The equipment of difference, such as network interface card for different manufacturers, hardware are entirely different, and for example in virtual client
PCIe buses are different, and the base address of the PCIe configuration space of the VF hardware of distribution is different, this scheme
Under, the failure such as the virtual client of carrying transparent transmission VF occurs exception after migrating, machine of delaying, thus be difficult
Dynamic migration is realized between different hosts.
In order to solve this problem, a kind of method is dynamically to virtual client using PCIe hot plug technologys
The machine transplanting of rice enters SR-IOV VF network interface cards or removes SR-IOV VF network interface cards from virtual client.Fig. 1 be into
The structure composition schematic diagram of two hosts of Mobile state migration.As shown in figure 1, host HOST1
When virtual client VM is created, it is that virtual client VM distributes two network interface cards, respectively software mould
The Microsoft Loopback Adapter virtNIC and SR-IOV VF network interface cards of plan, virtNIC and SR-IOV VF network interface cards are necessary
It is the PF and VF of Same Physical network interface card.Inside virtual client, virtNIC and SR-IOV VF nets
Card makes aggregation port bonding, and bonding can be operated in the mode or active/standby mode of load sharing.It is negative
Lotus is shared under mode, and Business Stream shares virtNIC and SR-IOV VF network interface cards place according to certain rule
Both links on, when wherein one link breaks down, all flow switchs are to an other link
On.Under active/standby mode, a Business Stream chain only by being located in virtNIC and SR-IOV VF network interface cards
Road is communicated with other virtual clients, and under normal circumstances, Business Stream passes through SR-IOV VF network interface cards institute
Link communicated with other virtual clients, when SR-IOV VF network interface cards be located link occur therefore
During barrier, Business Stream is all switched to the link at virtNIC places.
Equally, the virtual client for creating in host HOST2, it is also desirable to distribute two network interface cards, he
Between relation must also keep and HOST1 identical annexations.The physics of host HOST1
Network interface card link must be linked together by switch with the physical network card link of host HOST2, this
Virtual client on sample host HOST1 can be with dynamic migration to host HOST2.
As SR-IOV VF network interface cards are the physical network card functions of PCIe, if the SR-IOV VF network interface cards
Always situated in virtual client, virtual client will be unable to carry out dynamic migration.By host HOST1
Virtual client dynamic migration to host HOST2 when, it is necessary first to by host HOST1's
SR-IOV VF network interface cards are extracted from virtual client, now the convergence mouth bonding in virtual client
Member port there was only virtNIC a ports, the migration of virtual client can be carried out.Cloud computing system
System moves to virtual client on host HOST2, the virtual client on host HOST2
Converge mouth bonding and there was only mono- member port of virtNIC, SR-IOV is inserted into into host again at this moment
In the virtual client of HOST2.
In said method, in virtual client, each business network port has to configure two virtual terminals
Mouthful, the two ports must connect the VF and PF of unified logistics network interface card, and inside virtual client
Two ports are configured to converge mouth, increased the tedious work of cloud computing user.In this case virtNIC
With vSwitch be located at main frame kernel state, and client computer be located at User space, the poor-performing of virtNIC,
Virtual client is migrated when the service traffics of virtual client are heavier, service traffics are all switched to virtNIC,
Substantial amounts of network data can be caused to lose, can traffic affecting processing procedure.General user is not very willing to be connect
Receive this mode.
To another kind of processing method of SR-IOV VF network interface cards be in the virtualized environment of dynamic migration,
SR-IOV VF network interface cards are not transparent in client computer, but always situated in host kernel.Fig. 2 is realization
The schematic diagram of SR-IOV network interface cards.As shown in Fig. 2 VF drives (Driver) to operate in host HOST1
Kernel in, by the rear module of a macvtap and kernel state virtNIC on the VF Driver
(virtNIC-BE).Wherein, macvtap is a network-driven equipment of linux kernel, and it simplifies
The complexity of virtual network device, under the conditions of virtualization, data first reach simulator I/O layers
VirtNIC, then be forwarded on hardware by macvtap.
The existing method for realizing SR-IOV network interface cards is generally comprised:
When virtual client needs to send data, the front-end module (virtNIC-FE) of User space virtNIC
Cut to kernel state virtNIC-BE, and host from user's space the data is activation in User space internal memory
Kernel spacing is changed to, kernel state virtNIC-BE copies data to kernel state internal memory from User space internal memory
In, the data in kernel state internal memory are sent to kernel state by macvtap by kernel state virtNIC-BE
VF Driver, kernel state VF Driver send the data to corresponding VF, and VF sends the data to embedding
Enter formula bridge Embedded Bridge, Embedded Bridge are according to the destination address of data (such as media
Access control (MAC, Media Access Control) address, Internet protocol (IP, Internet
Protocol) address etc.) forwarded.
When VF receives data, kernel state VF Driver, kernel state are given by the data is activation for receiving
VF Driver send the data to kernel state virtNIC-BE, kernel state virtNIC-BE by macvtap
By data from kernel state memory copying in User space internal memory, and host is switched to use from kernel spacing
Data is activation in User space internal memory is given corresponding application by family space, User space virtNIC-FE.
In the existing method for realizing SR-IOV network interface cards, due in transceiving data, kernel state
VirtNIC-BE need by data from User space memory copying in kernel state internal memory, or from kernel state
Deposit and copy in User space internal memory, and host needs to be cut between user space and kernel space
Change, cause the network performance of virtual client poor.According to test data display, in this case,
The performance of one VF can only achieve the performance of host bare machine 50% or so, in virtualized data center
Or performance indications in telecommunications application, cannot be met.
The content of the invention
In order to solve the above problems, the present invention propose a kind of method and apparatus for realizing SR-IOV network interface cards,
The method and apparatus for realizing dynamic migration, it is possible to increase the network performance of virtual client.
In order to achieve the above object, the present invention proposes a kind of method for realizing SR-IOV network interface cards, including:
The front-end module virtNIC-FE of User space Microsoft Loopback Adapter virtual client need send data when,
By the data is activation to be sent in User space internal memory to User space Microsoft Loopback Adapter rear module
virtNIC-BE;
Data is activation to be sent is driven Driver to User space virtual functions VF by User space virtNIC-BE;
Data is activation to be sent is given corresponding VF by User space VF Driver.
Preferably, when the VF is received from the data of embedded net-bridge Embedded Bridge,
The method also includes:
The data is activation for receiving is given corresponding User space VF Driver by the VF;
The data is activation for receiving is given the User space by the User space VF Driver
virtNIC-BE;
The data is activation for receiving is given the User space by the User space virtNIC-BE
virtNIC-FE。
Preferably, the data is activation to be sent in the internal memory by User space gives User space virtNIC-BE bags
Include:
Data to be sent in the User space internal memory are sent to into the User space using message pointer
virtNIC-BE;
Data is activation to be sent is included by the User space virtNIC-BE to User space VF Driver:
The data to be sent are sent to described by the User space virtNIC-BE using the message pointer
User space VF Driver.
Preferably, also include before the method:
The kernel-driven of unloading SR-IOV network interface cards;
Apply for the User space memory address of the SR-IOV network interface cards, and by the VF corresponding depositor
The User space of the User space memory address mappings of address and application to the process of the SR-IOV network interface cards is empty
Between;
User is loaded according to the User space memory address of the corresponding register address of the VF and the application
State VF Driver.
The invention allows for a kind of method for realizing dynamic migration, including:
The dynamic migration instruction from user is received, according to the resource requirement of virtual client to be migrated
Search purpose host;
The sourcesink main frame that control virtual client to be migrated is located is by the configuration of virtual client to be migrated
File is sent to purpose host;
It is virtual client distribution virtual functions VF to be migrated to control purpose host, and updates configuration
File;
Control purpose host creates new virtual client placed in a suspend state according to the configuration file for updating
Machine, and network configuration information is configured on the VF of distribution;
The internal memory of virtual client to be migrated is sent to purpose host by voltage input host;
Voltage input host stops VF pair of virtual client to be migrated and virtual client to be migrated
The thread answered, and discharge the corresponding VF resources of virtual client to be migrated;
The state of new virtual client is changed into running status by control purpose host.
The invention allows for a kind of device for realizing SR-IOV network interface cards, at least includes:
The front-end module virtNIC-FE of User space Microsoft Loopback Adapter, for needing to send number in virtual client
According to when, by the data is activation to be sent in User space internal memory to User space Microsoft Loopback Adapter rear module
virtNIC-BE;
User space virtNIC-BE, for data is activation to be sent is driven to User space virtual functions VF
Driver;
User space VF Driver, for giving corresponding VF by data is activation to be sent.
Preferably, the User space VF Driver are additionally operable to:
The User space virtNIC-BE is given by the data is activation for receiving;
The User space virtNIC-BE is additionally operable to:
The User space virtNIC-FE is given by the data is activation for receiving.
Preferably, also include:
Unload module, for unloading the kernel-driven of SR-IOV network interface cards;
Application module, for applying for the User space memory address of the SR-IOV network interface cards, and by the VF
Process of the User space memory address mappings of corresponding register address and application to the SR-IOV network interface cards
User's state space;
Load-on module, in the User space according to the corresponding register address of the VF and the application
Deposit address loading User space VF Driver.
The invention allows for a kind of device for realizing dynamic migration, at least includes:
Receiver module, the dynamic migration for receiving from user are instructed;
Searching modul, for searching purpose host according to the resource requirement of virtual client to be migrated;
Control module, for controlling the sourcesink main frame at virtual client place to be migrated by void to be migrated
The configuration file for intending client computer is sent to purpose host;It is virtual visitor to be migrated to control purpose host
Family machine distribution virtual functions VF, and more new configuration file;Control purpose host is according to the configuration for updating
Document creation new virtual client placed in a suspend state, and network configuration information is configured to into distribution
On VF;The internal memory of virtual client to be migrated is sent to purpose host by voltage input host;Control
Sourcesink main frame processed stops the corresponding lines of the VF of virtual client and virtual client to be migrated to be migrated
Journey, and discharge the corresponding VF resources of virtual client to be migrated;Purpose host is controlled by new void
The state for intending client computer is changed into running status.
Compared with prior art, technical scheme includes:User space virtNIC-FE is in virtual visitor
When family machine needs to send data, by the data is activation to be sent in User space internal memory to User space
virtNIC-BE;Data is activation to be sent is driven by User space virtNIC-BE to User space virtual functions VF
Dynamic Driver;Data is activation to be sent is given corresponding VF by User space VF Driver.By the present invention's
Scheme, realizes number by User space virtNIC-FE, User space virtNIC-BE, User space VF Driver
According to transmission, without by data from User space memory copying in kernel state internal memory, it is not required that
Switch between user's space and kernel spacing, improve the network performance of virtual client.
Description of the drawings
Below the accompanying drawing in the embodiment of the present invention is illustrated, the accompanying drawing in embodiment is for this
Bright further understands, and is used for explaining the present invention together with description, does not constitute to present invention protection model
The restriction enclosed.
Fig. 1 is the structure composition schematic diagram of existing two hosts for carrying out dynamic migration;
Fig. 2 is the existing schematic diagram for realizing SR-IOV network interface cards;
Fig. 3 is the flow chart of the method that the present invention realizes SR-IOV network interface cards;
Fig. 4 is the structure composition schematic diagram of the device that the present invention realizes SR-IOV network interface cards;
Fig. 5 is the structure composition schematic diagram of the device that the present invention realizes dynamic migration.
Specific embodiment
For the ease of the understanding of those skilled in the art, below in conjunction with the accompanying drawings the present invention is further retouched
State, can not be used for limiting the scope of the invention.It should be noted that in the case where not conflicting,
The various modes in embodiment and embodiment in the application can be mutually combined.
Referring to Fig. 3, the present invention proposes a kind of method for realizing SR-IOV network interface cards, including:
Step 300, User space virtNIC-FE virtual client need send data when, by User space
Data is activation to be sent in internal memory gives User space virtNIC-BE.
In this step, the data is activation to be sent in User space internal memory is included to User space virtNIC-BE:
Data to be sent in User space internal memory are sent to into User space virtNIC-BE using message pointer.
Specifically, message pointer points to physical address of the data to be sent in User space internal memory, so,
User space virtNIC-FE only needs to for message pointer to be sent to User space virtNIC-BE, User space
VirtNIC-BE is just obtained in that data to be sent.That is User space virtNIC-FE and User space
Same User space internal memory is shared between virtNIC-BE.
Data is activation to be sent is given User space virtual functions VF by step 301, User space virtNIC-BE
Drive Driver.Specifically include:
Data to be sent are sent to User space VF Driver using message pointer by User space virtNIC-BE.
Specifically, message pointer points to physical address of the data to be sent in User space internal memory, so,
User space virtNIC-BE only needs to for message pointer to be sent to User space VF Driver, User space VF
Driver is just obtained in that data to be sent.That is User space virtNIC-BE and User space VF
Same User space internal memory is shared between Driver.
Data is activation to be sent is given corresponding VF by step 302, User space VF Driver.
In this step, data is activation to be sent is given embedded net-bridge Embedded Bridge by VF,
Embedded Bridge are sent to other hosts according to the destination address of data to be sent or are sent to PF
Or other VF.
Further, when VF is received from the data of Embedded Bridge, the method is also wrapped
Include:
The data is activation for receiving is given corresponding User space VF Driver by VF;User space VF Driver
User space virtNIC-BE is given by the data is activation for receiving;User space virtNIC-BE is by the number for receiving
According to being sent to User space virtNIC-FE.
Wherein, when Embedded Bridge receive data, PF is sent to according to the destination address of data
Or VF.Preserve between PF or VF and IP address or MAC Address in Embedded Bridge
Corresponding relation.
Wherein, the data is activation for receiving is included by User space VF Driver to User space virtNIC-BE:
The data for receiving are sent to User space using message pointer by User space VF Driver
virtNIC-BE。
Wherein, the data is activation for receiving is included by User space virtNIC-BE to User space virtNIC-FE:
The data for receiving are sent to User space using message pointer by User space virtNIC-BE
virtNIC-FE。
Further, also include before the method:
The kernel-driven of unloading SR-IOV network interface cards;The User space memory address of application SR-IOV network interface cards,
And by the User space memory address mappings of VF corresponding register address and application to SR-IOV network interface cards
User's state space of process (i.e. vNIC processes in Fig. 4);According to the corresponding register address of VF and
The User space memory address loading User space VF Driver of application.
Wherein, the process of SR-IOV network interface cards is applied in one piece of continuous or discrete physics in initialization
The User space internal memory as SR-IOV network interface cards is deposited, and by the physical memory addresses of application (i.e. in User space
Deposit address) and the corresponding register address of VF be mapped to user's state space of the process of SR-IOV network interface cards.
Wherein it is possible to pass through the mmap interfaces of Linux by the physical memory addresses applied (i.e. User space
Memory address) and the corresponding register address of VF be mapped to the process of SR-IOV network interface cards User space it is empty
Between.
Wherein, the kernel-driven for how unloading SR-IOV network interface cards belongs to the known skill of those skilled in the art
Art, the protection domain being not intended to limit the present invention, is repeated no more here.
Wherein, start the transmitting-receiving that the corresponding threads of VF can just realize data.
The invention allows for a kind of method for realizing dynamic migration, including:
The dynamic migration instruction from user is received, according to the resource requirement of virtual client to be migrated
Search purpose host;The sourcesink main frame that control virtual client to be migrated is located will be to be migrated virtual
The configuration file of client computer is sent to purpose host;It is virtual client to be migrated to control purpose host
Machine distributes virtual functions VF, and more new configuration file;According to the configuration for updating on control purpose host
Document creation new virtual client placed in a suspend state, and network configuration information is configured to into distribution
On VF;The internal memory of virtual client to be migrated is sent to purpose host by voltage input host;Control
Sourcesink main frame processed stops the corresponding lines of the VF of virtual client and virtual client to be migrated to be migrated
Journey, and discharge the corresponding VF resources of virtual client to be migrated;Purpose host is controlled by new void
The state for intending client computer is changed into running status.
Wherein, the resource requirement of virtual client to be migrated may refer to virtual client to be migrated
CPU computing capabilitys, the memory size for needing, hard drive space size and network interface card demand etc..
Wherein, how purpose host is searched according to the resource requirement of virtual client to be migrated and belongs to this
The known technology of art personnel, the protection domain being not intended to limit the present invention.
Wherein, the configuration file of virtual client to be migrated includes:It is network configuration information, required
Cpu resource, memory source and hard drive space etc..
Wherein, when purpose host is virtual client distribution VF to be migrated, it is only necessary to for be migrated
Virtual client distribute an idle VF.
Wherein, control purpose host new void according to the configuration file establishment for updating placed in a suspend state
When intending client computer, it is new virtual client distribution cpu resource, memory source, hard drive space and network interface card
Resource.Wherein, the SR-IOV network interface card types that network interface card type is provided for the present invention, virtual client
VirtNIC-FE is using the standard front network interface card type in virtual client, such as virtio-net or e1000
Network interface card.
Wherein, network configuration information refer to the MAC Address of virtual client, MTU (MTU,
Maximum Transmission Unit), VLAN (VLAN, Virtual Local Area
Network) etc..
Wherein, how network configuration information is configured on the VF of distribution and belongs to those skilled in the art's
Known technology, the protection domain being not intended to limit the present invention, is repeated no more here.
Wherein, after the completion of dynamic migration, virtual client moves to host from host HOST1
On HOST2, after migration, the MAC Address and IP address of new virtual client are identical with before migration.
User space virtNIC-FE, User space virtNIC-BE, User space VF Driver, VF, Embedded
The function of Bridge is identical with before migration, and new virtual client passes through User space virtNIC-FE, user
State virtNIC-BE, User space VF Driver, VF, Embedded Bridge and other hosts or its
He is communicated virtual client.
Referring to Fig. 4, the invention allows for a kind of device for realizing SR-IOV network interface cards, at least includes:
The front-end module virtNIC-FE of User space Microsoft Loopback Adapter, for needing to send number in virtual client
According to when, by the data is activation to be sent in User space internal memory to User space Microsoft Loopback Adapter rear module
virtNIC-BE;
User space virtNIC-BE, for data is activation to be sent is driven to User space virtual functions VF
Driver;
User space VF Driver, for giving corresponding VF by data is activation to be sent.
In the device of the present invention, the User space VF Driver are additionally operable to:
The User space virtNIC-BE is given by the data is activation for receiving;
The User space virtNIC-BE is additionally operable to:
The User space virtNIC-FE is given by the data is activation for receiving.
In the device of the present invention, also include:
Unload module, for unloading the kernel-driven of SR-IOV network interface cards;
Application module, it is for applying for the User space memory address of SR-IOV network interface cards and VF is corresponding
The User space of the User space memory address mappings of register address and application to the process of SR-IOV network interface cards is empty
Between;
Load-on module, for being added according to the User space memory address of the corresponding register address of VF and application
Carry User space VF Driver.
Referring to Fig. 5, the invention allows for a kind of device for realizing dynamic migration, at least includes:
Receiver module, the dynamic migration for receiving from user are instructed;
Searching modul, for searching purpose host according to the resource requirement of virtual client to be migrated;
Control module, for controlling the sourcesink main frame at virtual client place to be migrated by void to be migrated
The configuration file for intending client computer is sent to purpose host;It is virtual visitor to be migrated to control purpose host
Family machine distribution virtual functions VF, and more new configuration file;Control purpose host is according to the configuration for updating
Document creation new virtual client placed in a suspend state, and network configuration information is configured to into distribution
On VF;The internal memory of virtual client to be migrated is sent to purpose host by voltage input host;Control
Sourcesink main frame processed stops the corresponding lines of the VF of virtual client and virtual client to be migrated to be migrated
Journey, and discharge the corresponding VF resources of virtual client to be migrated;Purpose host is controlled by new void
The state for intending client computer is changed into running status.
The function of above-mentioned all modules may each be by computing device store program in memory/
Instruction is realized, can also be realized by firmware/logic circuit/integrated circuit.
It should be noted that embodiment described above is for only for ease of those skilled in the art's understanding
, protection scope of the present invention is not limited to, in the premise of the inventive concept without departing from the present invention
Under, those skilled in the art are to any obvious replacement made of the invention and improvement etc. at this
Within the protection domain of invention.
Claims (9)
1. a kind of method for realizing that single input/output virtualizes SR-IOV network interface cards, it is characterised in that
Including:
The front-end module virtNIC-FE of User space Microsoft Loopback Adapter virtual client need send data when,
By the data is activation to be sent in User space internal memory to User space Microsoft Loopback Adapter rear module
virtNIC-BE;
Data is activation to be sent is driven Driver to User space virtual functions VF by User space virtNIC-BE;
Data is activation to be sent is given corresponding VF by User space VF Driver.
2. method according to claim 1, it is characterised in that when the VF is received from embedding
When entering the data of formula bridge Embedded Bridge, the method also includes:
The data is activation for receiving is given corresponding User space VF Driver by the VF;
The data is activation for receiving is given the User space by the User space VF Driver
virtNIC-BE;
The data is activation for receiving is given the User space by the User space virtNIC-BE
virtNIC-FE。
3. method according to claim 1 and 2, it is characterised in that in the internal memory by User space
Data is activation to be sent include to User space virtNIC-BE:
Data to be sent in the User space internal memory are sent to into the User space using message pointer
virtNIC-BE;
Data is activation to be sent is included by the User space virtNIC-BE to User space VF Driver:
The data to be sent are sent to described by the User space virtNIC-BE using the message pointer
User space VF Driver.
4. method according to claim 1 and 2, it is characterised in that also include before the method:
The kernel-driven of unloading SR-IOV network interface cards;
Apply for the User space memory address of the SR-IOV network interface cards, and by the VF corresponding depositor
The User space of the User space memory address mappings of address and application to the process of the SR-IOV network interface cards is empty
Between;
User is loaded according to the User space memory address of the corresponding register address of the VF and the application
State VF Driver.
5. a kind of method for realizing dynamic migration, it is characterised in that include:
The dynamic migration instruction from user is received, according to the resource requirement of virtual client to be migrated
Search purpose host;
The sourcesink main frame that control virtual client to be migrated is located is by the configuration of virtual client to be migrated
File is sent to purpose host;
It is virtual client distribution virtual functions VF to be migrated to control purpose host, and updates configuration
File;
Control purpose host creates new virtual client placed in a suspend state according to the configuration file for updating
Machine, and network configuration information is configured on the VF of distribution;
The internal memory of virtual client to be migrated is sent to purpose host by voltage input host;
Voltage input host stops VF pair of virtual client to be migrated and virtual client to be migrated
The thread answered, and discharge the corresponding VF resources of virtual client to be migrated;
The state of new virtual client is changed into running status by control purpose host.
6. a kind of device for realizing that single input/output virtualizes SR-IOV network interface cards, it is characterised in that
At least include:
The front-end module virtNIC-FE of User space Microsoft Loopback Adapter, for needing to send number in virtual client
According to when, by the data is activation to be sent in User space internal memory to User space Microsoft Loopback Adapter rear module
virtNIC-BE;
User space virtNIC-BE, for data is activation to be sent is driven to User space virtual functions VF
Driver;
User space VF Driver, for giving corresponding VF by data is activation to be sent.
7. device according to claim 6, it is characterised in that the User space VF Driver are also
For:
The User space virtNIC-BE is given by the data is activation for receiving;
The User space virtNIC-BE is additionally operable to:
The User space virtNIC-FE is given by the data is activation for receiving.
8. the device according to claim 6 or 7, also includes:
Unload module, for unloading the kernel-driven of SR-IOV network interface cards;
Application module, for applying for the User space memory address of the SR-IOV network interface cards, and by the VF
Process of the User space memory address mappings of corresponding register address and application to the SR-IOV network interface cards
User's state space;
Load-on module, in the User space according to the corresponding register address of the VF and the application
Deposit address loading User space VF Driver.
9. a kind of device for realizing dynamic migration, it is characterised in that at least include:
Receiver module, the dynamic migration for receiving from user are instructed;
Searching modul, for searching purpose host according to the resource requirement of virtual client to be migrated;
Control module, for controlling the sourcesink main frame at virtual client place to be migrated by void to be migrated
The configuration file for intending client computer is sent to purpose host;It is virtual visitor to be migrated to control purpose host
Family machine distribution virtual functions VF, and more new configuration file;Control purpose host is according to the configuration for updating
Document creation new virtual client placed in a suspend state, and network configuration information is configured to into distribution
On VF;The internal memory of virtual client to be migrated is sent to purpose host by voltage input host;Control
Sourcesink main frame processed stops the corresponding lines of the VF of virtual client and virtual client to be migrated to be migrated
Journey, and discharge the corresponding VF resources of virtual client to be migrated;Purpose host is controlled by new void
The state for intending client computer is changed into running status.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510646047.XA CN106557444B (en) | 2015-09-30 | 2015-09-30 | Method and device for realizing SR-IOV network card and method and device for realizing dynamic migration |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510646047.XA CN106557444B (en) | 2015-09-30 | 2015-09-30 | Method and device for realizing SR-IOV network card and method and device for realizing dynamic migration |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106557444A true CN106557444A (en) | 2017-04-05 |
CN106557444B CN106557444B (en) | 2022-01-25 |
Family
ID=58417708
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510646047.XA Active CN106557444B (en) | 2015-09-30 | 2015-09-30 | Method and device for realizing SR-IOV network card and method and device for realizing dynamic migration |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106557444B (en) |
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107332791A (en) * | 2017-07-25 | 2017-11-07 | 郑州云海信息技术有限公司 | A kind of method and apparatus that network is created with virtual switch |
CN109474475A (en) * | 2018-12-07 | 2019-03-15 | 天津津航计算技术研究所 | The switching system of dual redundant network interface card under windows XPE |
CN109614229A (en) * | 2018-11-30 | 2019-04-12 | 深圳先进技术研究院 | A kind of virtual network resource distribution system based on software definition |
CN109728915A (en) * | 2018-12-07 | 2019-05-07 | 天津津航计算技术研究所 | The switching method of dual redundant network interface card under windows XPE |
CN109739618A (en) * | 2018-12-10 | 2019-05-10 | 新华三云计算技术有限公司 | Virtual machine migration method and device |
CN109753346A (en) * | 2018-12-25 | 2019-05-14 | 新华三云计算技术有限公司 | A kind of live migration of virtual machine method and device |
CN110602155A (en) * | 2018-06-13 | 2019-12-20 | 网宿科技股份有限公司 | Proxy server and method for processing data message thereof |
CN111866209A (en) * | 2020-07-07 | 2020-10-30 | 上海云轴信息科技有限公司 | Method and equipment for distributing network card for cloud host |
CN114546604A (en) * | 2022-04-26 | 2022-05-27 | 赛芯半导体技术(北京)有限公司 | Thermal migration method and device for virtual machine |
CN114662162A (en) * | 2022-05-25 | 2022-06-24 | 广州万协通信息技术有限公司 | Multi-algorithm-core high-performance SR-IOV encryption and decryption system and method for realizing dynamic VF distribution |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101459618A (en) * | 2009-01-06 | 2009-06-17 | 北京航空航天大学 | Data packet forwarding method and device for virtual machine network |
CN103621026A (en) * | 2013-04-01 | 2014-03-05 | 华为技术有限公司 | Virtual machine data exchange method, apparatus and system |
-
2015
- 2015-09-30 CN CN201510646047.XA patent/CN106557444B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101459618A (en) * | 2009-01-06 | 2009-06-17 | 北京航空航天大学 | Data packet forwarding method and device for virtual machine network |
CN103621026A (en) * | 2013-04-01 | 2014-03-05 | 华为技术有限公司 | Virtual machine data exchange method, apparatus and system |
Non-Patent Citations (1)
Title |
---|
张华: "DPDK support for vhost-user学习笔记", 《HTTP://BLOG.CSDN.NET/QUQI99》 * |
Cited By (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107332791A (en) * | 2017-07-25 | 2017-11-07 | 郑州云海信息技术有限公司 | A kind of method and apparatus that network is created with virtual switch |
CN110602155A (en) * | 2018-06-13 | 2019-12-20 | 网宿科技股份有限公司 | Proxy server and method for processing data message thereof |
CN109614229A (en) * | 2018-11-30 | 2019-04-12 | 深圳先进技术研究院 | A kind of virtual network resource distribution system based on software definition |
CN109728915A (en) * | 2018-12-07 | 2019-05-07 | 天津津航计算技术研究所 | The switching method of dual redundant network interface card under windows XPE |
CN109474475A (en) * | 2018-12-07 | 2019-03-15 | 天津津航计算技术研究所 | The switching system of dual redundant network interface card under windows XPE |
CN109474475B (en) * | 2018-12-07 | 2020-12-01 | 天津津航计算技术研究所 | Switching system of dual-redundancy network card under windows XPE |
CN109728915B (en) * | 2018-12-07 | 2020-12-01 | 天津津航计算技术研究所 | Switching method of dual-redundancy network card under windows XPE |
CN109739618A (en) * | 2018-12-10 | 2019-05-10 | 新华三云计算技术有限公司 | Virtual machine migration method and device |
CN109753346A (en) * | 2018-12-25 | 2019-05-14 | 新华三云计算技术有限公司 | A kind of live migration of virtual machine method and device |
CN109753346B (en) * | 2018-12-25 | 2021-01-01 | 新华三云计算技术有限公司 | Virtual machine live migration method and device |
CN111866209A (en) * | 2020-07-07 | 2020-10-30 | 上海云轴信息科技有限公司 | Method and equipment for distributing network card for cloud host |
CN114546604A (en) * | 2022-04-26 | 2022-05-27 | 赛芯半导体技术(北京)有限公司 | Thermal migration method and device for virtual machine |
CN114546604B (en) * | 2022-04-26 | 2022-08-05 | 赛芯半导体技术(北京)有限公司 | Thermal migration method and device for virtual machine |
CN114662162A (en) * | 2022-05-25 | 2022-06-24 | 广州万协通信息技术有限公司 | Multi-algorithm-core high-performance SR-IOV encryption and decryption system and method for realizing dynamic VF distribution |
Also Published As
Publication number | Publication date |
---|---|
CN106557444B (en) | 2022-01-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106557444A (en) | The method and apparatus for realizing SR-IOV network interface cards is, the method and apparatus for realizing dynamic migration | |
US11005755B2 (en) | Packet processing method in cloud computing system, host, and system | |
CN113556275B (en) | Calculation method, calculation apparatus, and computer-readable storage medium | |
US10135726B2 (en) | Virtualization port layer including physical switch port and logical switch port | |
CA2991208C (en) | Packet processing method in cloud computing system, host, and system | |
US20180109471A1 (en) | Generalized packet processing offload in a datacenter | |
US8806025B2 (en) | Systems and methods for input/output virtualization | |
EP2880828B1 (en) | System and method for virtual ethernet interface binding | |
US8335237B1 (en) | Streamlined guest networking in a virtualized environment | |
US9692706B2 (en) | Virtual enhanced transmission selection (VETS) for lossless ethernet | |
US9910687B2 (en) | Data flow affinity for heterogenous virtual machines | |
WO2013049991A1 (en) | Network adapter hardware state migration discovery in a stateful environment | |
US11048535B2 (en) | Method and apparatus for transmitting data packet based on virtual machine | |
US10901725B2 (en) | Upgrade of port firmware and driver software for a target device | |
US10942729B2 (en) | Upgrade of firmware in an interface hardware of a device in association with the upgrade of driver software for the device | |
US10581730B2 (en) | Packet processing using service chains | |
US10877822B1 (en) | Zero-copy packet transmission between virtualized computing instances | |
US11327789B2 (en) | Merged input/output operations from a plurality of virtual machines | |
US11838206B2 (en) | Edge node with datapath split between pods | |
US20230028837A1 (en) | Scaling for split-networking datapath | |
US20220283866A1 (en) | Job target aliasing in disaggregated computing systems | |
US20230043461A1 (en) | Packet processing configurations |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |