Bug 233415 - Hal does not update label information when changed [Was: Device manager shows wrong (cached) label of a device (the label was removed)]
Summary: Hal does not update label information when changed [Was: Device manager shows...
Status: RESOLVED UPSTREAM
Alias: None
Product: solid
Classification: Frameworks and Libraries
Component: libsolid-hal (show other bugs)
Version: unspecified
Platform: Debian testing Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-05 20:29 UTC by Hans-J. Ullrich
Modified: 2010-12-22 11:58 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hans-J. Ullrich 2010-04-05 20:29:04 UTC
Version:            (using KDE 4.3.5)
OS:                Linux
Installed from:    Debian testing/unstable Packages

Dear maintainers, 

I have the following problem:

I used a sd card which I labelled "Debian Inst". When I put it in the slot, the devicemanager (in German: Gerätemanager") did see it as a new device with label/name "Debian Inst". So far all worked fine. 

But now I deleted the label of my sd-card, but the devicemanager is still seeing it labelled as "Debian Inst". I confirmed, the device has no label any more. 

So, where is the label been stored? I suppose, I can solve it, by deleting some cached file. 

Maybe it is a bug?

Best regards

Hans-J. Ullrich
Comment 1 Kevin Ottens 2010-04-06 23:35:27 UTC
You mean that by unplugging it and plugging it again it keeps the same label information?

If yes I'm indeed unsure from where the caching would come from, lower in the stack there's nothing saving such information AFAIK.
Comment 2 Hans-J. Ullrich 2010-04-07 00:16:29 UTC
Am Dienstag, 6. April 2010 schrieb Kevin Ottens:
> https://bugs.kde.org/show_bug.cgi?id=233415
> 
> 
> 
> 
> 
> --- Comment #1 from Kevin Ottens <ervin kde org>  2010-04-06 23:35:27 ---
> You mean that by unplugging it and plugging it again it keeps the same
>  label information?
> 
Yes, it just keeps a once given label. If you put in the same device with 
another label or without any label, it keeps the first time seen label of the 
device. So I guess, this information might be somewhere cached, but I am not 
so exprienced with it, to know where. Checked my whole ~/user directory, but 
could not find it.

> If yes I'm indeed unsure from where the caching would come from, lower in
>  the stack there's nothing saving such information AFAIK.
> 

Yes, me too, so I hope, the maintainers might know.


Cheers 

Hans
Comment 3 Kevin Ottens 2010-04-07 07:29:42 UTC
Ah forgot another question: Is Dolphin doing the same thing? Or only the device manager is impacted?
Comment 4 Kevin Ottens 2010-10-02 15:00:18 UTC
No reply, the question was essential to proper triaging.
Comment 5 Hans-J. Ullrich 2010-10-02 18:12:03 UTC
(In reply to comment #4)
> No reply, the question was essential to proper triaging.

Sorry, I did not see your latest question. Please let me still answer though:

Is Dolphin doing the same thing?
Hmm, I do not quite know, what you mean. But I suppose, you mean, if Dolphin is showing the old label, too? No, it is not showing, just the hardwaremanager in the task bar.

 Or only the device manager is impacted?
Yes, IMO it is only the device manager involved.

Hope this helps, although my answer came back a little late. Should this bug be reopened?

Best regards

Hans
Comment 6 Hans-J. Ullrich 2010-10-02 18:12:18 UTC
(In reply to comment #4)
> No reply, the question was essential to proper triaging.

Sorry, I did not see your latest question. Please let me still answer though:

Is Dolphin doing the same thing?
Hmm, I do not quite know, what you mean. But I suppose, you mean, if Dolphin is showing the old label, too? No, it is not showing, just the hardwaremanager in the task bar.

 Or only the device manager is impacted?
Yes, IMO it is only the device manager involved.

Hope this helps, although my answer came back a little late. Should this bug be reopened?

Best regards

Hans
Comment 7 Kevin Ottens 2010-10-04 07:58:29 UTC
Reassigning to the right component then.
Comment 8 Jacopo De Simoi 2010-12-19 12:00:44 UTC
I'll have a look to see if I can reproduce. Stay tuned
Comment 9 Jacopo De Simoi 2010-12-21 22:13:21 UTC
Here is what I can reproduce with the HAL backend:

Insert an USB key labeled "foo"
Plasma device notifier and dolphin both show "foo"; solid-hardware gives:

udi = '/org/freedesktop/Hal/devices/volume_uuid_9202bc8f_3ab1_4cfd_afa9_03b088f27067'
  parent = '/org/freedesktop/Hal/devices/storage_serial_Lexar_ExpressCard_3563BF05221737200407_0_0'  (string)
  vendor = ''  (string)
  product = 'foo'  (string)
  Block.major = 8  (0x8)  (int)
  Block.minor = 18  (0x12)  (int)
  Block.device = '/dev/sdb2'  (string)
  StorageAccess.accessible = false  (bool)
  StorageAccess.filePath = ''  (string)
  StorageVolume.ignored = false  (bool)
  StorageVolume.usage = 'FileSystem'  (0x2)  (enum)
  StorageVolume.fsType = 'ext3'  (string)
  StorageVolume.label = 'foo'  (string)
  StorageVolume.uuid = '9202bc8f-3ab1-4cfd-afa9-03b088f27067'  (string)
  StorageVolume.size = 4512972800  (0x10cfe8000)  (qulonglong)

Relabel it "bar" with e2label; 
both dolphin and the Device Notifier keep showing "foo"; solid-hardware gives:

udi = '/org/freedesktop/Hal/devices/volume_uuid_9202bc8f_3ab1_4cfd_afa9_03b088f27067'
  parent = '/org/freedesktop/Hal/devices/storage_serial_Lexar_ExpressCard_3563BF05221737200407_0_0'  (string)
  vendor = ''  (string)
  product = 'foo'  (string)
  Block.major = 8  (0x8)  (int)
  Block.minor = 18  (0x12)  (int)
  Block.device = '/dev/sdb2'  (string)
  StorageAccess.accessible = false  (bool)
  StorageAccess.filePath = ''  (string)
  StorageVolume.ignored = false  (bool)
  StorageVolume.usage = 'FileSystem'  (0x2)  (enum)
  StorageVolume.fsType = 'ext3'  (string)
  StorageVolume.label = 'foo'  (string)
  StorageVolume.uuid = '9202bc8f-3ab1-4cfd-afa9-03b088f27067'  (string)
  StorageVolume.size = 4512972800  (0x10cfe8000)  (qulonglong)

extract and reinsert the usb key
dolphin and Device Notifier show "bar"; solid-hardware shows:

udi = '/org/freedesktop/Hal/devices/volume_uuid_9202bc8f_3ab1_4cfd_afa9_03b088f27067'
  parent = '/org/freedesktop/Hal/devices/storage_serial_Lexar_ExpressCard_3563BF05221737200407_0_0'  (string)
  vendor = ''  (string)
  product = 'bar'  (string)
  Block.major = 8  (0x8)  (int)
  Block.minor = 18  (0x12)  (int)
  Block.device = '/dev/sdb2'  (string)
  StorageAccess.accessible = false  (bool)
  StorageAccess.filePath = ''  (string)
  StorageVolume.ignored = false  (bool)
  StorageVolume.usage = 'FileSystem'  (0x2)  (enum)
  StorageVolume.fsType = 'ext3'  (string)
  StorageVolume.label = 'bar'  (string)
  StorageVolume.uuid = '9202bc8f-3ab1-4cfd-afa9-03b088f27067'  (string)
  StorageVolume.size = 4512972800  (0x10cfe8000)  (qulonglong)

I believe this is a solid-hal issue; will try with solid-udev asaic
Comment 10 Jacopo De Simoi 2010-12-22 10:26:01 UTC
Turns out lshal doesn't notice the label change as well;

so as for the report this should be definitely marked as UPSTREAM.
@ervin: thoughts?
Comment 11 Jacopo De Simoi 2010-12-22 11:58:05 UTC
This is a HAL bug

Marked as UPSTREAM as suggested by ervin on irc.