Bluetooth not working on VM but working on host

MasterG87

New Member
Dec 29, 2018
10
1
1
37
Hi,

I have installed Proxmox 5.3 on my Gigabyte Brixx GB-BLCE-4105. It also has an Intel Bluetooth Wifi Chip called Intel AC 3168 onboard. On the Proxmox host I am able to use the bluetooth device properly and I can find several bluetooth devices with

bluetoothctl - scan on

But If I do the same on my VM with Debian 9 Stretch, "sudo bluetoothctl" and "power on" gives me the output:
"No default controller available".

The same command on the host works properly. Do you have any idea? In my opinion I have the same drivers installed on both.

Regards,
Thomas
 
the guests do not get access to the hardware of the host

either you use that hardware on the host or you try to pass it through to the vm see https://pve.proxmox.com/pve-docs/chapter-qm.html#qm_pci_passthrough

Ok I tried the settings you proposed and I wasn't able to succeed. I might have picked the wrong ID for the passthrough.


When I do "lspci -nn" on the host, I get:


00:00.0 Host bridge [0600]: Intel Corporation Device [8086:31f0] (rev 03)

00:00.3 System peripheral [0880]: Intel Corporation Device [8086:3190] (rev 03)

00:02.0 VGA compatible controller [0300]: Intel Corporation Device [8086:3185] (rev 03)

00:0e.0 Audio device [0403]: Intel Corporation Device [8086:3198] (rev 03)

00:0f.0 Communication controller [0780]: Intel Corporation Device [8086:319a] (rev 03)

00:12.0 SATA controller [0106]: Intel Corporation Device [8086:31e3] (rev 03)

00:13.0 PCI bridge [0604]: Intel Corporation Device [8086:31da] (rev f3)

00:13.3 PCI bridge [0604]: Intel Corporation Device [8086:31db] (rev f3)

00:15.0 USB controller [0c03]: Intel Corporation Device [8086:31a8] (rev 03)

00:1c.0 SD Host controller [0805]: Intel Corporation Device [8086:31cc] (rev 03)

00:1e.0 SD Host controller [0805]: Intel Corporation Device [8086:31d0] (rev 03)

00:1f.0 ISA bridge [0601]: Intel Corporation Device [8086:31e8] (rev 03)

00:1f.1 SMBus [0c05]: Intel Corporation Device [8086:31d4] (rev 03)

01:00.0 Network controller [0280]: Intel Corporation Device [8086:24fb] (rev 10)

02:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller [10ec:8168] (rev 15)


Which one is the Wifi+Bluetooth card, I want to passthrough? I thought it is 01:00.0, but it is apparently not. I also thought it might be 00.13, but I can add it to the VM Hardware because it doesn't occur in the list of available PCI cards. I know that the Wifi+Bluetooth module is on the PCI card slot.
 
Here some further details. I activated IOMMU on the host:

dmesg | grep IOMMU

[ 0.000000] DMAR: IOMMU enabled

[ 0.004000] DMAR-IR: IOAPIC id 1 under DRHD base 0xfed65000 IOMMU 1


and this is the output of:

find /sys/kernel/iommu_groups/ -type l

/sys/kernel/iommu_groups/7/devices/0000:00:15.0

/sys/kernel/iommu_groups/5/devices/0000:00:13.0

/sys/kernel/iommu_groups/3/devices/0000:00:0f.0

/sys/kernel/iommu_groups/11/devices/0000:01:00.0

/sys/kernel/iommu_groups/1/devices/0000:00:02.0

/sys/kernel/iommu_groups/8/devices/0000:00:1c.0

/sys/kernel/iommu_groups/6/devices/0000:00:13.3

/sys/kernel/iommu_groups/4/devices/0000:00:12.0

/sys/kernel/iommu_groups/12/devices/0000:02:00.0

/sys/kernel/iommu_groups/2/devices/0000:00:0e.0

/sys/kernel/iommu_groups/10/devices/0000:00:1f.0

/sys/kernel/iommu_groups/10/devices/0000:00:1f.1

/sys/kernel/iommu_groups/0/devices/0000:00:00.0

/sys/kernel/iommu_groups/0/devices/0000:00:00.3

/sys/kernel/iommu_groups/9/devices/0000:00:1e.0

The command
lspci -n | tail -20

gives me:

00:00.0 0600: 8086:31f0 (rev 03)

00:00.3 0880: 8086:3190 (rev 03)

00:02.0 0300: 8086:3185 (rev 03)

00:0e.0 0403: 8086:3198 (rev 03)

00:0f.0 0780: 8086:319a (rev 03)

00:12.0 0106: 8086:31e3 (rev 03)

00:13.0 0604: 8086:31da (rev f3)

00:13.3 0604: 8086:31db (rev f3)

00:15.0 0c03: 8086:31a8 (rev 03)

00:1c.0 0805: 8086:31cc (rev 03)

00:1e.0 0805: 8086:31d0 (rev 03)

00:1f.0 0601: 8086:31e8 (rev 03)

00:1f.1 0c05: 8086:31d4 (rev 03)

01:00.0 0280: 8086:24fb (rev 10)

02:00.0 0200: 10ec:8168 (rev 15)




Therefore created the file vfio.conf in /etc/modprobe.d and added the line and rebooted the host:
options vfio-pci ids=8086:24fb






The command "qm set VMID -hostpci0 01:00.0" did not work on the VM console, so I thought I do the passthrough over the web interface by adding the Hardware there. What am I doing wrong?
 
Can you post output of the command "hciconfig -a" on Proxmox host? It will show where Bluetooth HW is really attached. If it is attached to USB (it might be), you need to passthrough USB device, not PCI. (hciconfig can be installed via bluez package).

If output in the 1st line will be “Type: Primary Bus: USB”, then post also output of the command “lsusb”.
 
  • Like
Reactions: MasterG87
Can you post output of the command "hciconfig -a" on Proxmox host? It will show where Bluetooth HW is really attached. If it is attached to USB (it might be), you need to passthrough USB device, not PCI. (hciconfig can be installed via bluez package).

If output in the 1st line will be “Type: Primary Bus: USB”, then post also output of the command “lsusb”.
The output of hciconfig -a is:

hci0: Type: Primary Bus: USB

BD Address: C0:B6:F9:C6:04:39 ACL MTU: 1021:4 SCO MTU: 96:6

UP RUNNING

RX bytes:781 acl:0 sco:0 events:57 errors:0

TX bytes:2735 acl:0 sco:0 commands:57 errors:0

Features: 0xbf 0xfe 0x0f 0xfe 0xdb 0xff 0x7b 0x87

Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3

Link policy: RSWITCH SNIFF

Link mode: SLAVE ACCEPT

Name: 'pve'

Class: 0x000104

Service Classes: Unspecified

Device Class: Computer, Desktop workstation

HCI Version: 4.2 (0x8) Revision: 0x1100

LMP Version: 4.2 (0x8) Subversion: 0x1100

Manufacturer: Intel Corp. (2)


But I don't really get how this is related to bluetooth. Can you help?


The output of lsusb is:
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

Bus 001 Device 002: ID 8087:0aa7 Intel Corp.

Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
 
  • Like
Reactions: msre
Ok it was the USB Port. I did the passthrough and Bluetooth works properly. I was looking for a solution for such a long time. Thank you.
 
Last edited:
>But I don't really get how this is related to bluetooth. Can you help?

hciconfig is used to configure Bluetooth devices and prints name and basic information about all the Bluetooth devices installed in the system.


8087:0aa7 is seems to be your Bluetooth device, you need to passthrough this USB device to your VM via Proxmox GUI in hardware section and choose option "Use USB Vendor/Device ID", choose device - 8087:0aa7. Then check bluetooth device from VM.


This approach worked for me (however I use different motherboard with built-in Wifi+Bluetooth)
 
  • Like
Reactions: msre

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!