DEV Community

Cover image for Fixing Bluetooth instability on Ubuntu (26.04) caused by Realtek RTL8821CU Wi-Fi/Bluetooth combo chipset
Sakis bal
Sakis bal

Posted on

Fixing Bluetooth instability on Ubuntu (26.04) caused by Realtek RTL8821CU Wi-Fi/Bluetooth combo chipset

I got a pair of some nice sony 1000xm6 headphones which i wanted to connect to my computer running ubuntu. To connect my headphones with my computer i purchased a Realtek RTL8821CU which has a chipset that is integrated with wifi and bluetooth.

To my bad luck the headphones did not connect gracefully to my bluetooth device. The headphones connected without any issue to other devices so i was sure that they were fine and the issue was lying somewhere between ubuntu and the realtek device. And so my journey to fix the issue had started.

I tried google, chatgpt, gemini and any LLM you can think of. Sadly none of these seemed to have a solution so i had to dig deeper to the depths of stackoverflow and old reddit posts dating years back. After a lot of searching i felt obligated to post the solution i found here for anyone stumbling on the same issue.

It seems that ubuntu doesn't play well with bluetooth headphones that connect to a dual integrated chip for wifi and bluetooth so all i had to do what disable the wifi from the realtek device and just use bluetooth this way:

Search for your wireless network interfaces

iw dev
Enter fullscreen mode Exit fullscreen mode

Close the wifi connection from the device

sudo ip link set wlx90de80ee7e03 down
Enter fullscreen mode Exit fullscreen mode

To keep the device wifi offline you can start a service to keep it off on startup

sudo nano /etc/systemd/system/disable-realtek-wifi.service
Enter fullscreen mode Exit fullscreen mode

Write inside this file

[Unit]
Description=Disable Realtek WiFi interface
After=network-pre.target
Before=network.target

[Service]
Type=oneshot
ExecStart=/usr/sbin/ip link set wlx90de80ee7e03 down
RemainAfterExit=yes

[Install]
WantedBy=multi-user.target
Enter fullscreen mode Exit fullscreen mode

And enable the service

sudo systemctl enable disable-realtek-wifi.service
Enter fullscreen mode Exit fullscreen mode

Top comments (0)