Sharing Same Bluetooth device on Windows/Linux dual-boot
This is a guide written on how to share the same Bluetooth device(s) across Windows and Linux without having to uniquely pair each.
Steps
-
Pair your Bluetooth device(s) with Linux first
-
Reboot into Windows, then re-pair the devices with Windows
-
Run
regedit
as Administrator -
Navigate to:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\BTHPORT\Parameters\Keys
If you do not see any Keys under the tree then you need to open
regedit
as a system-account user. One way to do this is using the PsExec by downloading it from Microsoft Sysinternals. Once it is downloaded, you will need to run a command-prompt as Administrator and navigate to the locationPsExec
is unzipped and runPsExec.exe -s -i regedit
. The Bluetooth keys should now be visible. -
Right-click on
Keys
in the left-hand pane and selectExport
. During the dialog changeSave as type
toText files
and that theExport range
is set toSelected branch
. Store this somewhere accessible by both Windows and Linux – if a shared drive is unavailable, use a USB drive or cloud-storage. -
Reboot to Linux
-
In a root (e.g.
sudo su
) terminal navigate to/var/lib/bluetooth
then to the MAC address of your host-system (there should only be a single sub-directory under/var/lib/bluetooth
) -
Find the relevant Bluetooth device(s) by MAC address to share and enter the equally named MAC address directory of the client device.
-
Open the
info
file, with root privileges, in the text editor of your choice. -
In another tab/window, using either a text viewer or editor, open the previously exported Windows registry text file for the device
-
From the Windows file, copy the Bluetooth Key. Example:
00000000 31 c0 08 fa 4f 7b d2 4c - 6f e1 7d ba 32 29 a9 a7 1À.ïO{ÒLoá}ºQ)©§
From the above copy
31 c0 .... a9 a7
-
Paste the key from the previous step into the
Key=
portion of the Linux Bluetoothinfo
file. Make sure to remove all spaces, hyphens, and change all characters to upper-case (all-caps). -
Save the
info
file with the changes to complete device sharing. Repeat for any other Bluetooth devices to share.