Feature Request: Virtual Function NIC pass-through?

brad_mssw

Well-Known Member
Jun 13, 2014
133
9
58
Some NICs like Mellanox allow you to create "virtual functions" (basically a hardware-assisted virtual NIC). These are meant to be passed directly through to VMs instead of generating "tap" interfaces tied to a bridge.

Supposedly this sort of thing completely hardware-offloads all communication from VM to VM freeing up resources on the host and reducing latency.

You can assign a VLAN per virtual function, or use vlan 4095 to pass through *all* vlans available:
https://community.mellanox.com/docs/DOC-1123

It looks like if you create an LACP LAG/bond on the host, it will auto route traffic to the "up" port even though the VF is tied to one port, which is a nice feature so you don't have to do some bonding hack in the guest:
https://community.mellanox.com/docs/DOC-2612

It would seem like Proxmox could add management interfaces to assign and configure VFs dynamically like it does with tap interfaces. I'm not really seeing any limitations to this vs bonding, but I do see a huge potential upside, especially if using high performance (10/25/40G) nics.

Are there any plans for doing something like this?

Thanks!
-Brad
 
since the virtual functions appear on the host as additional pci devices, you can manually pass through the virtual functions via the 'hostpci'
doing this automatically is hard, because i believe the configuration of this is not the same for all hardware vendors (AFAIK), and we really do not want to do
this for every vendor out there (especially if we do not have the hardware)
 
Looking at the commands used, they are all core iproute2 commands to bring up the virtual function ... so it would work with any vendor implementing the right hooks since you're never calling a vendor-supplied command directly. I think it would be worthwhile if it is intended to be vendor-neutral, even if only 1 vendor is doing it right now ... I'm sure it wouldn't stay that way for long.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!