OPNsense
  • Home
  • Help
  • Search
  • Login
  • Register

  • OPNsense Forum »
  • Profile of Nearly9892 »
  • Show Posts »
  • Topics
  • Profile Info
    • Summary
    • Show Stats
    • Show Posts...
      • Messages
      • Topics
      • Attachments

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

  • Messages
  • Topics
  • Attachments

Topics - Nearly9892

Pages: [1]
1
General Discussion / Bhyve PCI Passthrough NIC Issue
« on: September 23, 2024, 04:39:04 pm »
I recently set up a new hypervisor using vm-bhyve. I ran into an issue passing through an Intel dual port 82576 NIC and a Mellanox ConnectX-4 Lx MCX4121A-XCAT. I searched the web but did not find anyone discussing this issue.

Following the vm-bhyve man page, I reserved the devices by adding the device ID as shown with 
Code: [Select]
pciconf -lv to the pptdevs variable in /boot/loader.conf.

Mellanox: 1/0/0 and 1/0/1
Intel NIC: 5/0/0 and 5/0/1

Then I rebooted and added the devices to the vm config file.

Code: [Select]
passthru0="5/0/0=8:0"
passthru1="5/0/1=8:1"
passthru2="1/0/0=9:0"
passthru3="1/0/1=9:1"

The VM would boot, but the nics would show in the VM intermittently and did not work most of the time.

To fix this I went back to /boot/loader.conf and reserved all possible functions (0-7) in the pptdevs variable, not just the ones displayed in pciconf -lv. This fixed the problem.

Code: [Select]
pptdevs="5/0/0 5/0/1 5/0/2 5/0/3 5/0/4 5/0/5 5/0/6 5/0/7 1/0/0 1/0/1 1/0/2 1/0/3 1/0/4 1/0/5 1/0/6 1/0/7"
I hope this helps someone trying to virtualize opnsense using bhyve.

Pages: [1]
OPNsense is an OSS project © Deciso B.V. 2015 - 2024 All rights reserved
  • SMF 2.0.19 | SMF © 2021, Simple Machines
    Privacy Policy
    | XHTML | RSS | WAP2