Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 08-24-2014, 02:30 AM   #1
Registered: Feb 2005
Location: Germany
Distribution: Aptosid
Posts: 148

Rep: Reputation: 19
Bluetooth pairing fails _with_ PIN (org.bluez.Error.AuthenticationFailed)

EDIT: Alright, so it looks like I'm missing an agent. I finally found out about bluetoothctl, and when I registered agent KeyboardOnly; default-agent there, it worked! Now what do I have to do to make it usable via GUI? Plus it seems like blueman has some major bugs, anyway... attempting to connect results in an empty error message, and I can't receive files, because it's using an outdated DBUS interface for OpenObex, and obexfs fails silently... yay for userfriendliness! Imagine what a newbie would do in that situation...

EDIT2: OK, giving up. _Not even_ the stable or testing versions work together after purging and reinstalling everything about Bluetooth, they're _all_ incompatible. Even though I now managed to connect (have bluetoothctl running with keyboard agent, enter yes on connection attempt), and even though it registers like 10 services from the BlackBerry, _only_ the remote control service is allowed. When I try it the other way around, with obexftp, I have to specify the precise channel to connect on so that it doesn't just report "Connecting...failed: connect", and _then_ it times out with "Connecting..\failed: send UUID". (Plus the usual _real helpful_ messages like "error: connect(): success".) And even getting _that_ far would have been completely impossible without extensive console work. I've never seen something that thoroughly riddled with holes, because you can't call those bugs any more. 15 years of using Linux, and I can't get a simple Bluetooth transfer set up in several hours? Right, right, we're past the 90s, it's the year of the Linux Desktop...



I'm trying to pair my old BlackBerry 8310 to my Linux desktop (up-to-date Debian Sid, 3.15-10.dmz.1-liquorix-amd64) by using blueman and its associated tools. Scanning for the device works equally well for both sides; however, I am unable to pair the two once it comes to entering the PIN.

If I scan from my PC, I have two options in blueman-manager regarding my phone: Directly selecting "pair", or selecting "setup".

- If I select "pair", nothing happens on my desktop, but the phone asks me to enter a PIN; if I do so, it reports that pairing has failed. During that, nothing is logged to the console.

- Selecting "setup" opens a configuration dialog that allows for entering or generating a PIN. Regardless, I get to a screen that tells me to enter the PIN on the phone, and at the same time, the phone pops up the equivalent dialog. This would be what one would expect to work; but whatever I enter (naturally, the same on both), both devices report that pairing has failed, and blueman-manager logs

init_services (/usr/lib/python2.7/dist-packages/blueman/main/  
    Loading services   
    org.bluez.Error.AuthenticationFailed: Authentication Failed
- If I instead try to pair from the phone, I cannot see any kind of reaction from my desktop - all I get is the equivalent "pairing failed" message from the BlackBerry after I entered a PIN in the dialog that pops up there.

hcitool scan and hciconfig -a work without complaints, but I cannot find a way to try the pairing as a whole on the console since bluez-simple-agent seems to have been discontinued and this recommendation is everywhere on Google. (Plus everyone only worries about pairing _without_ PIN...) hcitool cc as root opens the PIN dialog on the phone, then fails with "Input/Output error" once I enter it. The user is not permitted to execute this command. I also tried creating /usr/lib/bluetooth/<MAC>/pincodes to manually define a persistent PIN, which seems to have had no effect. The same goes for running the different commands as root, though I'm really confused about the internal structure of the Bluetooth subsystem now: They usually and inconsistently failed with Python or DBUS errors or just showed the same results.

The only other Bluetooth device I have around are a pair of Creative speakers. Trying "setup" asks me to enter a key on them, which is impossible. If I try "pair", I'm asked for a PIN as I should, but no pairing takes place, and no errors appear on the console. (It just repeats their name a few times.) Interestingly, I tried that before writing my question, and nothing happened in terms of PIN questions, just like with the BlackBerry, which still shows no change. I don't think I actively changed anything since then. The BlackBerry can pair with and connect to the speakers, and everything goes as one would expect, so the problem is definitely with my desktop.

So thus my questions:

- What is that PIN window generated by, and why does it seem to appear randomly?

- How can I find out what, exactly, fails after trying to add the speakers, as this may give me a clue?

- Is there any kind of complete log that concerns itself with Bluetooth?

- What data can I provide to make this more solvable?


Last edited by Vinter; 08-24-2014 at 05:21 AM.
Old 08-25-2014, 09:48 AM   #2
LQ Guru
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,251

Rep: Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321
Bluetooth is a major PITA aleways. Even linux & android is dodgy. Linux or Android & MacOS is next tio impossible. You have heard of libmobiledevice? It might help(or not)
Old 08-27-2014, 04:04 AM   #3
LQ Guru
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,251

Rep: Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321Reputation: 2321
have you hcitools?


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
bluetooth: obexd running and files visible on mobile after pairing but "GET" fails er.mahavir Linux - Wireless Networking 1 10-04-2013 06:15 PM
System Settings: No way in 12.12 to enter PIN Number when pairing w/Bluetooth hlw Linux Deepin 2 07-11-2013 01:26 AM
pairing problem with bluez(version 4.91) dbus wshn13 Linux - Wireless Networking 1 12-05-2011 11:38 PM
Bluetooth Pairing Fails ThePowerTool Red Hat 1 09-29-2011 01:35 PM
Bluetooth Pairing - hci cc fails, but rfcomm connect works gpecke Linux - Newbie 5 07-20-2009 03:55 PM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:56 AM.

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