Home Store Blog Development

Bluetooth connected at startup


#1

Hello!

I disabled bluetooth. When I reboot the machine it goes back on to stay activated.

How do I fix it? I want it to be disabled when I turn on the computer.


Budgie 18.04 minimal version missing some important programs
#2

v17.10 of UB ?

If so this is a known issue with the bluetooth stack - I understand it has been fixed in 18.04


#3

17.10. Do you recommend installing the 18?


#4

18.04 goes stable in a couple of weeks


#5

I installed it on 18.04. Bluetooth problem continues :confused:


#6

please report a bug to make the ubuntu-devs aware of the issue on 18.04

ubuntu-bug bluez

#7

I have the same issue. I thought that was intentional? If I turn off Bluetooth, it’s on with reboot.


#8

Hmm seems it’s has been a very common issue for a long time.

There doesn’t seem to be one answer though


#9

I was able to workaround this in ubuntu budgie 18.04 by adding rfkill block bluetooth to my /etc/rc.local file.

This gave me the behavior I wanted where when I boot my laptop bluetooth is in airplane mode, but I can enable it from the bluetooth indicator if needed

Note: in my case the rc.local file wasn’t there by default, so I added it with these contents:

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

rfkill block bluetooth

exit 0

And then made it executable:

sudo chmod 755 /etc/rc.local


#10

I experienced the same problem in Ubuntu 17.10 and in 18.04. The solution I came up with was to mask Bluetooth. It worked for me in both distros.
Try doing this:

sudo systemctl mask bluetooth

That should stop Bluetooth from auto starting.


#11

Presumably the same command substituting “unmask” should restore it?


#12

Unmasking it will allow you to start/stop the service again.


#13

Exactly what I was searching for, thanks !

Strange Bluetooth state is not remembered through session - what’s different regarding bluetooth compared to default ubuntu 18.04 ( where BT state is remembered ) ?

If put in /etc/rc.local does it mean it will set this behavior for all users ?
May that command rfkill block bluetooth be put in « application at startup » for a per user preference ?

I think that way is more convenient than
sudo systemctl mask bluetooth
which demands another sudo command to enable again BT when needed.


#14

I’ve had the same problem and I’ve solved it as follows:
On Desktop Budgie Parameters create a Command Type Autostart App with these commands:
rfkill block bluetooth

Give it name and description you like (doesn’t matter) and save. Every time you restart your computer your Bluetooth will be disabled.


#15

This is actually even easier than I originally thought… you just need to disable bluetooth within the gnome settings | power section instead of via the bluetooth indicator icon in the system tray.

When I disable it via the gnome settings panel, it stays disabled without any further tweaks needed