If this is your first visit, be sure to
check out the FAQ. You will have to register
before you can post. To start viewing messages,
select the forum that you want to visit from the selection below.
Please do not use the CODE tag when pasting content that contains formatting (colored, bold, underline, italic, etc).
The CODE tag displays all content as plain text, including the formatting tags, making it difficult to read.
Somewhere, Kubuntu is starting up Bluetooth support automatically. Where does this take place? It is probably not the only thing running which I do not need.
Thanks in advance.
'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain
Windows no longer obstructs my view.
Using Kubuntu Linux since March 23, 2007.
"It is a capital mistake to theorize before one has data." - Sherlock Holmes
However, having looked at those files and the README, it is not obvious what to do to stop bluetooth from starting, since, e.g., rc0.d/K74bluetooth says
#currently this init script exists only because of what appears to be
#an egg and chicken problem
# bluetoothd normally starts up by udev rules. it needs dbus to function,
# but dbus doesn't start up until after udev finishes triggering
Also, the README says
Generally it is not necessary to alter the scripts in this directory.
Their purpose is to stop all services and to make the system ready
for shutdown.
In spite of the fact that K74bluetooth says "# Short-Description: Start bluetoothd" and the README also says
The scripts in this directory are executed once when entering runlevel 0.
meaning at boot time.
I admit to being confused here. Are these scripts for startup or shutdown? And without them would bluetooth be started by udev, whatever that may be?
'I must have a prodigious quantity of mind; it takes me as much as a week sometimes to make it up.' Mark Twain
Can't help you with that. I'm not sure which of those files is actually 'starting' KBluetooth, if any of them are. But one (or more) are almost certainly involved.
Windows no longer obstructs my view.
Using Kubuntu Linux since March 23, 2007.
"It is a capital mistake to theorize before one has data." - Sherlock Holmes
You shouldn't have to worry about udev/init scripts with bluetooth.
udev should start bluetooth service when a bluetooth device is added or enabled, when there is no bluetooth device on the system, the service shouldn't be running.
Ok, I have renamed /usr/share/autostart/kbluetooth.desktop to something else and will see if that does the trick.
That should work, but upgrades to kbluetooth will add the file back, so you'll need to redo it when you upgrade kbluetooth (or kde). A more permanent solution would be to uninstall kbluetooth if you don't need it.
Unfortunately, kbluetooth.desktop doesn't include an "autostart-condition" tag (like many of the other autostart .desktop files) which would allow you to disable autostarting in kbluetoothrc file (that way the setting would persist over upgrades)
Interesting question and Snowhog was spot on - disable the daemon.
Do the Xbuntus use upstart or still init? If the latter, then it should only be a matter of some research on the Ubuntu wiki to be able to manipulate which daemons get started during boot and which get backgrounded for a faster boot experience.
That is the kind of control I like to have over a system - for example, who needs cups if you haven't got a printer on the laptop or bluetooth if you have no device or avahi if you don't fancy talking to your local network. The list goes on...
One could of course put a couple of lines into rc.local to that effect (am just cranking up ye olde virtualbox to see whether kubuntu has that file and yes it does) but that would be starting and stopping, i.e. merely as a power saving measure for laptops..
Once your problem is solved please mark the topic of the first post as SOLVED so others know and can benefit from your experience! / FAQ
Like I said before, bluetoothd (the daemon) should be started by udev only when there is a bluetooth device on the system (or when one is enabled).
And if you have one, it's probably a good thing to have it running (the daemon is very light on resources).
if you really want to stop it, you can use 'sudo service bluetooth stop', but that doesn't really affect power consumption. If you want to save power you need to disable the device either by hardware (most laptops have a keyboard shortcut for this) or by software (with rfkill, for example).
If one uses bluetooth infrequently (or does not have a bluetooth device), one can stop kbluetooth (the KDE bluetooth front-end) from autostarting by removing/renaming the kbluetooth.desktop file (or uninstalling kbluetooth if you do not have a device) to save a few MBs of memory or just hide the icon fron notification tray settings if you only want to clean up the tray.
Comment