Pcornel
Virtualization · PCI & Device Passthrough

NIC Passthrough

Cheat sheet · https://pcornel.dk/topic.php?topic=3549

Back to the Topic

Answer

NIC passthrough gives a VM a physical network card or port for line-rate, low-latency networking, typically for firewalls or NFV. It bypasses the virtual switch and limits migration; SR-IOV virtual functions are often a better compromise.

Remember

  • Bypasses virtual switch and its features.
  • Blocks migration.
  • Consider SR-IOV instead.

First checks

  • lspci -nnk | grep -A3 Ethernet — NIC bound to vfio
  • ethtool -i <if> — guest driver
  • ip -s link — guest counters

Verify in this order

physical NIC → vfio → guest driver

Where it usually breaks

First mismatch in host capability/IOMMU/NUMA → hypervisor allocation/mapping → virtual hardware model → guest driver/enumeration → workload use; preserve identity/native error/pre-state before mutation.

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=3549

Confirmation

Confirm action

Continue?