Wrong /var/lib/bluetooth/<BD address>/config prevents setting correct hci class
| Affects | Status | Importance | Assigned to | Milestone | |
|---|---|---|---|---|---|
| bluez-utils (Ubuntu) |
Invalid
|
Undecided
|
Unassigned | ||
Bug Description
Binary package hint: bluez-utils
When entry 'class' exists in /var/lib/
I discovered it when trying to install the newest version of bluez-utils (3.19). It has "class 0x000100;" set in the default hcid.conf. After installation hciconfig -a showed:
Class: 0x000100
Service Classes: Unspecified
Device Class: Computer, Uncategorized
I adjusted the "class" entry in etc/bluetooth/
I found out that removing the file /var/lib/
Steps to recreate the condition:
-------
root@jl-desktop:~# cat /var/lib/
mode discoverable
(this is the only line in my properly working file)
root@jl-desktop:~# hciconfig -a
hci0: Type: USB
BD Address: 00:08:1B:02:3B:67 ACL MTU: 192:8 SCO MTU: 64:8
UP RUNNING PSCAN ISCAN
RX bytes:2750 acl:0 sco:0 events:57 errors:0
TX bytes:1210 acl:0 sco:0 commands:56 errors:0
Features: 0xff 0xff 0x0f 0x00 0x00 0x00 0x00 0x00
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
Link policy: HOLD SNIFF PARK
Link mode: ACCEPT MASTER
Name: 'JL-DESKTOP_(0)'
Class: 0x3e0104
Service Classes: Networking, Rendering, Capturing, Object Transfer, Audio
Device Class: Computer, Desktop workstation
HCI Ver: 1.1 (0x1) HCI Rev: 0x33d LMP Ver: 1.1 (0x1) LMP Subver: 0x33d
root@jl-desktop:~# echo class 0x000100 >> /var/lib/
root@jl-desktop:~# /etc/init.
* Restarting Bluetooth services [ OK ]
root@jl-desktop:~# hciconfig -a
hci0: Type: USB
BD Address: 00:08:1B:02:3B:67 ACL MTU: 192:8 SCO MTU: 64:8
UP RUNNING PSCAN ISCAN
RX bytes:3344 acl:0 sco:0 events:68 errors:0
TX bytes:1502 acl:0 sco:0 commands:67 errors:0
Features: 0xff 0xff 0x0f 0x00 0x00 0x00 0x00 0x00
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
Link policy: HOLD SNIFF PARK
Link mode: ACCEPT MASTER
Name: 'JL-DESKTOP_(0)'
Class: 0x000100
Service Classes: Unspecified
Device Class: Computer, Uncategorized
HCI Ver: 1.1 (0x1) HCI Rev: 0x33d LMP Ver: 1.1 (0x1) LMP Subver: 0x33d
root@jl-desktop:~# gedit /var/lib/
(I manually deleted the previously inserted line with class 0x000100)
root@jl-desktop:~# /etc/init.
* Restarting Bluetooth services [ OK ]
root@jl-desktop:~# hciconfig -a
hci0: Type: USB
BD Address: 00:08:1B:02:3B:67 ACL MTU: 192:8 SCO MTU: 64:8
UP RUNNING PSCAN ISCAN
RX bytes:3938 acl:0 sco:0 events:79 errors:0
TX bytes:1794 acl:0 sco:0 commands:78 errors:0
Features: 0xff 0xff 0x0f 0x00 0x00 0x00 0x00 0x00
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
Link policy: HOLD SNIFF PARK
Link mode: ACCEPT MASTER
Name: 'JL-DESKTOP_(0)'
Class: 0x3e0104
Service Classes: Networking, Rendering, Capturing, Object Transfer, Audio
Device Class: Computer, Desktop workstation
HCI Ver: 1.1 (0x1) HCI Rev: 0x33d LMP Ver: 1.1 (0x1) LMP Subver: 0x33d
-------
I could not find any references to /var/lib/

Don't touch hcid.conf at all. The values from the /var/lib/bluetooth wll overwrite any settings done in hcid.conf and this is on purpose. If you wanna change your class of device, use the D-Bus methods or bluetooth- properties.