[gutsy] Bluetooth devices doesn't awake after sleeping

Bug #140668 reported by Kristoffer Lundén
4
Affects Status Importance Assigned to Milestone
bluez-utils (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Binary package hint: bluez-utils

I have a Logitech DiNovo Keyboard + Mouse combo that is set up to use bluetooth instead of USB mode.

When the computer is left alone so it goes into screensaver mode (actually, just turns the screen black), the bluetooth devices disappear and only come back after "sudo /etc/init.d/bluetooth restart". In Feisty, the devices woke up (or never slept?) immediately when touching a key or moving the mouse. This is the same install, upgraded to Gutsy.

Revision history for this message
bubbalouie (ryan-gossink) wrote :

Confirmed, two Sony laptops with Kubuntu 7.10 final (and diNovo keyboard + mouse too no less), both fully up to date exhibit the same problem. The alpha version of Gutsy did not experience this issue.

Revision history for this message
bubbalouie (ryan-gossink) wrote :

Fix Possibly Found:

Add the bluetooth module to you ACPI white list.

Open the following file in your preferred editor as root (I used nano for quickness, also, I recommend making a copy just in case there is a mistake):

/etc/default/acpi-support

You will find the following line:

# Add modules to this list to leave them in the kernel over suspend/resume
MODULES_WHITELIST=""

Change it to:

# Add modules to this list to leave them in the kernel over suspend/resume
MODULES_WHITELIST="bluetooth"

This appears to have fixed things on both the FE-25GP and FE-35GP laptops I have had the issue with. However, it may create some issues with your suspend/resume functions.

Revision history for this message
bubbalouie (ryan-gossink) wrote :

I may have celebrated too soon, still no fix....

This is actually quite an annoying problem, as the beta never experienced this issue...

Revision history for this message
Kristoffer Lundén (kristoffer-lunden) wrote :

Still happens in Hardy Alpha 5, on another computer; this one a HP 2710p laptop with built-in bluetooth together with the Logitech mouse.

It is not a suspend/hibernate issue, the computer does not go into any actual sleep state, but it seems it happens when the computer is left alone long enough to blank the screen according to default settings in power management.

Going to System-Preferences-Bluetooth-Services and quickly toggling Input Services wakes it up again.

Changed in bluez-utils:
status: New → Confirmed
Revision history for this message
Kristoffer Lundén (kristoffer-lunden) wrote :

This is not a duplicate bug of bug #123920 - that bug is about pairing keyboard/mouse at all, which works just fine for me. This bug is about the input service stopping to work after a certain unknown period of inactivity, like when reading or watching a movie without touching the mouse for an extended period of time.

Can someone please unduplicate?

For my current workaround I have a launcher in my panel that goes to a script that looks like this:

  $ cat /home/stoffe/.config/restart_bt.sh
  #!/bin/sh

  dbus-send --system --type=method_call --dest=org.bluez /org/bluez/service_input org.bluez.Service.Stop

  dbus-send --system --type=method_call --dest=org.bluez /org/bluez/service_input org.bluez.Service.Start

That works for me since I use a laptop and can click that launcher whenever input service has gone away, to wake it up again.

Revision history for this message
bubbalouie (ryan-gossink) wrote :

Agreed, this is NOT a duplicate of bug #123920, I am using the laptops built in bluetooth adapter, the DiNovo gear works fine after the system has booted (but not before the login screen, as should be expected) until it has been idle for a long time, at which point it may lose the connection.

The following thread has a few people with the same issue:

http://ubuntuforums.org/showthread.php?t=594624

I am fairly confident that they have successfully connected the devices using bluetooth, further adding to the evidence of this being a different bug.

Revision history for this message
Leon van der Ree (lvanderree) wrote :
Download full text (8.7 KiB)

I can confirm this bug, and that it is another bug than #123920

Bluetooth now works for me, from gdm on (in latest hardy) (that was bug #123920, however I don't know if it has been fixed in general, or that I changed anything)

However I now have this bug, where if I don't use my bluetooth mouse/keyboard for a while (5/10minutes or something?) the bluetooth connection gets disconnected I think, and the keyboard doesn't work anymore.

I think this line in my syslog is related to the braking of the connection:
Apr 19 11:31:33 leon-desktop NetworkManager: <debug> [1208597493.546317] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/bluetooth_acl_761755afb_0_logicaldev_input').

I can use my normal mouse and right click the still visible bluetooth icon and click on the disconnect-button in the connection-overview, and than the bluetooth icon will dissapear as well, but my bluetooth keyboard/mouse start responding again (probably because the bluetooth-functionality of the receiver gets unloaded/disabled by some bug).

I think these lines are related to the stop of the bluetooth driver, and the re-attachement of my keyboard in 'normal-modus' (after pressing the disconnect button):
Apr 19 12:01:24 leon-desktop input[9433]: /org/bluez/input: org.bluez.input.Manager.ListDevices()
Apr 19 12:01:24 leon-desktop audio[9434]: /org/bluez/audio: org.bluez.audio.Manager.ListDevices()
Apr 19 12:01:24 leon-desktop input[9433]: /org/bluez/input/keyboard0: org.bluez.input.Device.GetAdapter()
Apr 19 12:01:24 leon-desktop input[9433]: /org/bluez/input/keyboard0: org.bluez.input.Device.GetAddress()
Apr 19 12:01:24 leon-desktop input[9433]: /org/bluez/input/keyboard0: org.bluez.input.Device.GetName()
Apr 19 12:01:31 leon-desktop NetworkManager: <debug> [1208599291.549884] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/bluetooth_acl_761755afb_0').
Apr 19 12:01:36 leon-desktop kernel: [ 6832.718073] usb 2-2: USB disconnect, address 3
Apr 19 12:01:36 leon-desktop kernel: [ 6832.718080] usb 2-2.1: USB disconnect, address 6
Apr 19 12:01:36 leon-desktop hcid[9412]: HCI dev 0 down
Apr 19 12:01:36 leon-desktop hcid[9412]: Stopping security manager 0
Apr 19 12:01:36 leon-desktop hcid[9412]: Device hci0 has been disabled
Apr 19 12:01:36 leon-desktop NetworkManager: <debug> [1208599296.987656] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_46d_c709_0007617BCBF1_if0_bluetooth_hci_7617bcbf1_1').
Apr 19 12:01:37 leon-desktop hcid[9412]: HCI dev 0 unregistered
Apr 19 12:01:37 leon-desktop hcid[9412]: Unregister path: /org/bluez/hci0
Apr 19 12:01:37 leon-desktop hcid[9412]: Device hci0 has been removed
Apr 19 12:01:37 leon-desktop kernel: [ 6832.973623] usb 2-2.2: USB disconnect, address 4
Apr 19 12:01:37 leon-desktop NetworkManager: <debug> [1208599297.237027] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_device_46d_c709_0007617BCBF1_if0_bluetooth_hci_7617bcbf1').
Apr 19 12:01:37 leon-desktop NetworkManager: <debug> [1208599297.238849] nm_hal_device_removed(): Device removed (hal udi is '/org/freedesktop/Hal/devices/usb_devic...

Read more...

Revision history for this message
Kyle James (kvitale) wrote : Re: [Bug 140668] Re: [gutsy] Bluetooth devices doesn't awake after sleeping
Download full text (10.0 KiB)

I was sort of able to resolve this issue, although it is far from
perfect, and maybe not that much help here. It turns out another
device (my UPS) was conflicting somehow and was knocking my bluetooth
keyboard out, but not the embedded track mouse on the keyboard. I
unplugged the usb cable to my UPS and my keyboard has worked fine
since. (Hasn't happened in over a month)

On Apr 19, 2008, at 6:23 AM, leon van der Ree wrote:

> *** This bug is a duplicate of bug 123920 ***
> https://bugs.launchpad.net/bugs/123920
>
> I can confirm this bug, and that it is another bug than #123920
>
> Bluetooth now works for me, from gdm on (in latest hardy) (that was
> bug
> #123920, however I don't know if it has been fixed in general, or
> that I
> changed anything)
>
> However I now have this bug, where if I don't use my bluetooth
> mouse/keyboard for a while (5/10minutes or something?) the bluetooth
> connection gets disconnected I think, and the keyboard doesn't work
> anymore.
>
> I think this line in my syslog is related to the braking of the
> connection:
> Apr 19 11:31:33 leon-desktop NetworkManager: <debug>
> [1208597493.546317] nm_hal_device_removed(): Device removed (hal udi
> is '/org/freedesktop/Hal/devices/
> bluetooth_acl_761755afb_0_logicaldev_input').
>
> I can use my normal mouse and right click the still visible bluetooth
> icon and click on the disconnect-button in the connection-overview,
> and
> than the bluetooth icon will dissapear as well, but my bluetooth
> keyboard/mouse start responding again (probably because the bluetooth-
> functionality of the receiver gets unloaded/disabled by some bug).
>
> I think these lines are related to the stop of the bluetooth driver,
> and the re-attachement of my keyboard in 'normal-modus' (after
> pressing the disconnect button):
> Apr 19 12:01:24 leon-desktop input[9433]: /org/bluez/input:
> org.bluez.input.Manager.ListDevices()
> Apr 19 12:01:24 leon-desktop audio[9434]: /org/bluez/audio:
> org.bluez.audio.Manager.ListDevices()
> Apr 19 12:01:24 leon-desktop input[9433]: /org/bluez/input/
> keyboard0: org.bluez.input.Device.GetAdapter()
> Apr 19 12:01:24 leon-desktop input[9433]: /org/bluez/input/
> keyboard0: org.bluez.input.Device.GetAddress()
> Apr 19 12:01:24 leon-desktop input[9433]: /org/bluez/input/
> keyboard0: org.bluez.input.Device.GetName()
> Apr 19 12:01:31 leon-desktop NetworkManager: <debug>
> [1208599291.549884] nm_hal_device_removed(): Device removed (hal udi
> is '/org/freedesktop/Hal/devices/bluetooth_acl_761755afb_0').
> Apr 19 12:01:36 leon-desktop kernel: [ 6832.718073] usb 2-2: USB
> disconnect, address 3
> Apr 19 12:01:36 leon-desktop kernel: [ 6832.718080] usb 2-2.1: USB
> disconnect, address 6
> Apr 19 12:01:36 leon-desktop hcid[9412]: HCI dev 0 down
> Apr 19 12:01:36 leon-desktop hcid[9412]: Stopping security manager 0
> Apr 19 12:01:36 leon-desktop hcid[9412]: Device hci0 has been disabled
> Apr 19 12:01:36 leon-desktop NetworkManager: <debug>
> [1208599296.987656] nm_hal_device_removed(): Device removed (hal udi
> is '/org/freedesktop/Hal/devices/
> usb_device_46d_c709_0007617BCBF1_if0_bluetooth_hci_7617bcbf1_1').
> Apr ...

Revision history for this message
Sir Nikon (omnineko) wrote :

I recently had to swap out my Logitech provided Bluetooth USB dongle with a generic Bluetooth USB. It was difficult enough to get the thing connected but I can also confirm this bug.

It seems that after about ten minutes (which is what I have set for my monitor to shut off in the power settings), the keyboard and mouse both lose their connection. I can not recover it unless I remove the USB dongle, reconnect it on a different port, and then run the "hidd --search" command in the terminal.

Of course, after running that command everything seems to work perfectly well until I get up for a while and come back.

Revision history for this message
bubbalouie (ryan-gossink) wrote :

@Sir Nikon:

You needn't go through quite so many steps, I find the following command tends to work quite well:

sudo /etc/init.d/bluetooth restart

That should hopefully be simpler, though, until this bug s acknowledged by a developer, or a user fixes it I think everything shall just remain in limbo.

Revision history for this message
Gael Beaudoin (gaboo) wrote :

I can confirm this bug with hardy, with a logitech dinovo keyboard. I have to launch hidd --search twice to get it back.

Revision history for this message
Roger (r-wiberg) wrote : Re: [Bug 140668] Re: [gutsy] Bluetooth devices doesn't awake after sleeping

What happens if you go to /etc/default/bluetooth and change
HID2HCI_ENABLED=1 to HID2HCI_ENABLED=0?

That solved the problem for me. I haven't hade to re-pair my devices
since.

Roger

On Fri, 2008-05-30 at 08:37 +0000, Gael Beaudoin wrote:
> *** This bug is a duplicate of bug 123920 ***
> https://bugs.launchpad.net/bugs/123920
>
> I can confirm this bug with hardy, with a logitech dinovo keyboard. I
> have to launch hidd --search twice to get it back.
>

Revision history for this message
Kristoffer Lundén (kristoffer-lunden) wrote :

> Remember, this bug report is a duplicate. Comment here only if you think the duplicate status is wrong.

Again, it is wrong.

But to the real reason I post: this issue seems to be fixed for me now. I am running hardy-updates and I am updating every day or so. This weekend I noticed that I haven't had the need to restart bluetooth even when leaving the computer for a long time. I can't point to any one update, though, and I have no idea why this might be. :)

Can someone else with this problem (not the false duplicate in #123920!) try to update what hardy-updates wants to add and try if it's fixed for them as well?

Hope this is a real fix! If so, thank you developers! :D

Revision history for this message
Leon van der Ree (lvanderree) wrote :

Unfortunately I cannot confirm.

I have a fresh hardy install with my Logitech Dinovo Edge. logged in with my ps2 keyboard in order to pair my dinovo with a password, keyboard is working fine.
After a while of not using my computer, the keyboard doesn't respond for a while, until bluetooth times out and icon dissapears. Dinovo works again, but now with normal wireless connection, not via Bluetooth.

I haven't made any change to my /etc-files
I have installed all hardy-updates (not proposed or backports)

Revision history for this message
bubbalouie (ryan-gossink) wrote :

@Kristoffer Lundén

The problem still persists, further it is insisted that this is a duplicate bug. I think what people fail to see is that this problem affects people who are using their laptop's built in bluetooth adapters & people using the logitech dongles. Also, they seem to be confusing "can't connect at all" and the real issue here "connection is lost after a period of inactivity and does not recover".

In any case I have started using the logitech dongle in my dock and use this line:

HID2HCI_ENABLED=0

However, without this work around (as is the case with the other computer as I only have 1 dongle) bluetooth is frustratingly cumbersome, I suspect this problem will not be fixed in the near future, it is certainly a pitty, however, at least there are some work arounds, even if they are less than elegant.

Revision history for this message
bubbalouie (ryan-gossink) wrote :

I thought the following may be of interest:

https://bugs.launchpad.net/ubuntu/intrepid/+source/linux/+bug/175743

I can no longer test this as I recently 'upgraded' to 8.10 (only to find BT mice don't work).... In any case confirmation about this "UNIQUE" bug and fix might be nice...

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.