SevanH
Contributor
Contributor

Difference between SR-IOV and DirectPath I/O

Hello,

I am testing some pass-through features in order to better the network latency of a virtual machine, those features being DirectPath I/O and SR-IOV (As per the whitepapper http://www.vmware.com/files/pdf/techpaper/latency-sensitive-perf-vsphere55.pdf)

The difference between both of them is quite unclear for me, when reading at VMware vSphere 5.1 it says :

SR-IOV offers performance benefits and tradeoffs similar to those of DirectPath I/O. DirectPath I/O and SR-IOV have similar functionalty but you use them to accomplish different things.

SR-IOV is beneficial in workloads with very high packet rates or very low latency requirements. Like DirectPath I/O, SR-IOV is not compatible with certain core virtualization features, such as vMotion. SR-IOV does, however, allow for a single physical device to be shared amongst multiple guests.

With DirectPath I/O you can map only one physical funtion to one virtual machine. SR-IOV lets you share a single physical device, allowing multiple virtual machines to connect directly to the physical funtion.

I have the impression that both allows you to achieve the same goal (i.e. having the devices mounted directly inside the guest OS by bypassing the kernel layer), however that SR-IOV allows multiple VMs to share the same physical device where DirectPath I/O allows only one VM to use the PCI device.

Am I correct?

Is there a difference in terms of performance between both features?

When should I use DP IO rather than SR-IOV?

Thanks,

Sevan

0 Kudos
7 Replies
kabanossi
Enthusiast
Enthusiast

Hi!

You are correct in your assumption. In general both SR-IOV and DirectPath I/O have similar functionality.

Personally I would go with SR-IOV as it's just more flexible.

But first ensure that your hardware fully supports it and corresponding BIOS settings are enabled.

Sorry, I didn't find a text so here's an image:

1212323.png

0 Kudos
valteesjunior
Enthusiast
Enthusiast

Hi Guys!

So, if I understood well, both features are very similar, but DirectPath I/O is a vSphere feature, and SR-IOV is a PCI interface feature. Am I correct?

And it's not clear for me yet in which cases may I use one or another. SR-IOV is recommended when low latency is required. How about DirectPath I/O?

Best Regards.

Valter Junior

0 Kudos
baber
Expert
Expert

i understand these :

1 - if use SR/IOV we can use one physical network adapter to multi vms but in direct path we just assign one physical adapter to one vm

is that correct ?

2- in which mode vmotion will be work ? SR/IOV or direct path

BR

Please mark helpful or correct if my answer resolved your issue.
0 Kudos
valteesjunior
Enthusiast
Enthusiast

I think vMotion is now supported only with DirectPath I/O:

Enable DirectPath I/O with vMotion on a Virtual Machine

Regards

Valter Junior

0 Kudos
NathanosBlightc
Commander
Commander

Yes absolutely you are correct ... in continous of your explaination VMware mentioned "vSphere SR-IOV support relies on the interaction between the virtual functions (VFs) and the physical function (PF) of the NIC port for better performance, and interaction between the driver of the PF and the host switch for traffic control"

Please mark my comment as the Correct Answer if this solution resolved your problem
0 Kudos
valteesjunior
Enthusiast
Enthusiast

Great! Thank you!

0 Kudos
valteresjunior1
Contributor
Contributor

Hi All. 

Some years later, backing to this question. In vSphere 7, he've this limitation:  "You can add up to 16 PCI vSphere DirectPath I/O devices to a VM. The devices must be reserved for PCI passthrough on the host on which the VM runs. Snapshots are not supported with vSphere DirectPath I/O pass-through devices."

  1. What this is about? If I mix all supported interfaces (NIC and HBA), the maxim supported by VM is 16?
  2. DirectPath is enable by default when I add a new NIC in VM. How this works, since only one physical NIC could be mapped to one VM? Could I enable this in multiple VMs at the same time, using different physical interfaces?
  3. Can I configure a VM using a vNIC and a PCI device with DirectPath I/O at the same time?

Regards.

Valter Junior

0 Kudos