LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 04-16-2024, 04:29 PM   #1
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 859

Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
bluetoothd crashes after attempt to reconnect in -current


I got a Bluetooth keyboard that disconnects itself after a period of inactivity.

Someone rang the doorbell at home, I went to see who it was, and when I came back the screen was locked (after the timeout) as usual, but there was no way that my keyboard would reconnect.

After I unlocked Plasma, it became apparent that the Bluetooth daemon was no longer running. After passing
Code:
/etc/rc.d/rc.bluetooth restart
to the root console, I was able to use my keyboard again.

The only clue I got were these two lines at /var/log/messages:

Code:
apple 0005:05AC:024F.0009: input,hidraw5: BLUETOOTH HID v1.06 Keyboard [Keychron K10] on 30:24:32:bb:23:ac

bluetoothd[1218]: segfault at 38 ip 00000000004a3ade sp 00007ffffdb33790 error 4 in bluetoothd (deleted)[407000+cb000] likely on CPU 2 (core 2, socket 0)
So it seems that the computer goes idle, the Bluetooth keyboard gets disconnected, and when it attempts to reconnect, bluetoothd segfaults.

Did anyone else noticed this issue? Any hints on a workaround?

I began to see this just after the updates of last week.

EDIT: Even after today's update to bluez, the issue persists.
 
Old 04-17-2024, 08:58 AM   #2
litelinux
Member
 
Registered: Sep 2018
Location: Taipei/Taichung, TW
Distribution: Slackware
Posts: 101

Rep: Reputation: 58
Hi,

Maybe adding the file mentioned in this comment would help:

https://www.linuxquestions.org/quest...9/#post6495638

If not try adding

Code:
/etc/rc.d/rc.bluetooth restart
in the "post" section, under "done".

-- ltlnx
 
1 members found this post helpful.
Old 04-17-2024, 10:24 AM   #3
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 859

Original Poster
Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
Quote:
Originally Posted by litelinux View Post
Hi,

Maybe adding the file mentioned in this comment would help:

https://www.linuxquestions.org/quest...9/#post6495638

If not try adding

Code:
/etc/rc.d/rc.bluetooth restart
in the "post" section, under "done".

-- ltlnx
Thanks for the suggestion.

However, my system did not go to sleep/hybernate. The screen was just locked out, but otherwise the system was fully active. The laptop was on AC power and the inactivity was of just a few minutes.

Will keep looking for options.
 
Old 04-20-2024, 04:52 PM   #4
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 859

Original Poster
Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
Unfortunately, even after the latest updates and the reversal of elogind to 252, I'm still experiencing this issue. I now have to keep open a root terminal just for restarting bluetoothd after crashing.

UPDATE: After some thinking it seems that the culprit is bluez. I'm downgrading to 5.73 to see if this fixes the issue. I didn't want to use 5.74 since it lasted only two days and then it was replaced by 5.75. Let's see what happens.

Last edited by sombragris; 04-20-2024 at 05:17 PM.
 
Old 04-24-2024, 06:20 AM   #5
mickski56
Member
 
Registered: Mar 2018
Distribution: Slackware
Posts: 74

Rep: Reputation: Disabled
Probably this https://github.com/bluez/bluez/issues/815. The good news is the fix is in, so 5.76 should fix it.
 
Old 04-25-2024, 06:24 AM   #6
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 859

Original Poster
Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
Quote:
Originally Posted by mickski56 View Post
Probably this https://github.com/bluez/bluez/issues/815. The good news is the fix is in, so 5.76 should fix it.
Thanks for the info. This is consistent with my experience. I will wait for the fix, since my patching abilities are not that good.

Meanwhile, I can confirm that:
  • The issue still persists here after the latest -current changes; and
  • reverting to bluez-5.73 makes the issue disappear.

Therefore, barring an upcoming update, I respectfully request for bluez to be reverted to 5.73 until a suitable fix appears. Thanks!!
 
Old 04-25-2024, 09:44 AM   #7
titopoquito
Senior Member
 
Registered: Jul 2004
Location: Lower Rhine region, Germany
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,646

Rep: Reputation: 146Reputation: 146
Quote:
Originally Posted by sombragris View Post
Thanks for the info. This is consistent with my experience. I will wait for the fix, since my patching abilities are not that good.

Meanwhile, I can confirm that:
  • The issue still persists here after the latest -current changes; and
  • reverting to bluez-5.73 makes the issue disappear.

Therefore, barring an upcoming update, I respectfully request for bluez to be reverted to 5.73 until a suitable fix appears. Thanks!!
In case you want to try the patch follow the following steps:
  • Go to the github page concerning the bug. In the second last message you see the commit hash with the fix. Click it, then in the URL bar of your browser add ".patch" and you will get the patch in unified diff format. The URL should read https://github.com/bluez/bluez/commi...234c6dea.patch
  • Download the source for bluez. 'lftp -c "open https://mirrors.slackware.com/slackw...ent/source/n/; mirror bluez"' (remove the single quotes)
  • cd to the downloaded bluez folder, copy or move the downloaded patch in this folder
  • Edit the bluez.SlackBuild. I would suggest you add a line right after the line "cd $PKGNAM-$VERSION || exit 1". Make the line look like "patch -p1 < b94f1be656f34ea1363f5566ef63b847234c6dea.patch"
  • Execute the SlackBuild, the package will be put in /tmp.
  • upgradepkg --reinstall /tmp/bluez-5.75-x86_64-2.txz
  • Yes, it's that easy :-)
  • Voilą!
 
1 members found this post helpful.
Old 04-25-2024, 05:05 PM   #8
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 859

Original Poster
Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
In today's ChangeLog:

Code:
n/bluez-5.75-x86_64-3.txz: Rebuilt.
       [PATCH] shared/uhid: Fix crash if bt_uhid_destroy free replay structure.
       Thanks to sombragris.
Thanks! I will check it out and hopefully this issue will go away. If it does, I'll mark the thread as solved.
 
Old 04-26-2024, 04:11 PM   #9
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 859

Original Poster
Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
So far Bluetooth reconnect works again and no segfaults were apparent so far after upgrading to the patched bluez. So I'm marking this tentatively as solved.

Thank you Pat. Also thank you a lot @titopoquito for your instrctions regarding patching. I had no opportunity to apply them but they are very easy to follow and approachable.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
bluetoothd segfault on -current BenCollver Slackware 4 01-22-2022 11:32 AM
[SOLVED] After upgrading to Pop!_OS 20.10, bluetoothd no longer starts ALazyDope Linux - Newbie 4 11-26-2020 04:39 PM
[SOLVED] -current (April 7th): bluetoothd segfault? andrew.46 Slackware 7 04-10-2018 02:19 AM
BlueZ-4.58 is installed, but bluetoothd is not running, says "Unable to get on D-Bus" deepthits Linux - Wireless Networking 3 12-10-2009 01:18 AM
Bluetoothd using 100% cpu on Slackware 12 natefoss Slackware 0 07-16-2007 02:46 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 02:09 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration