Bug 262395

Summary: windows partition not removed after unplugging external iomega hard disk
Product: [Unmaintained] plasma4 Reporter: Hans-Rudi Denzler <hr.denzler>
Component: notificationsAssignee: Marco Martin <notmart>
Status: RESOLVED FIXED    
Severity: normal CC: plasma-bugs-null
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Unlisted Binaries   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: IOMEGA_HDD should be removed after unplugging
dolphin:Places and device notifier in buggy action

Description Hans-Rudi Denzler 2011-01-07 12:03:45 UTC
Version:           unspecified (using Devel) 
OS:                Linux

since KDE 4.6 RC 2

Reproducible: Didn't try
Comment 1 Hans-Rudi Denzler 2011-01-07 12:10:09 UTC
Created attachment 55679 [details]
IOMEGA_HDD should be removed after unplugging

1. plug in external harddisk with windows and Linux partition
2. plug it out -> windows partition IOMEGA_HDD is not removed
3. try to display content of removed device
Comment 2 Lukáš Tinkl 2011-01-07 14:04:16 UTC
Did you just physically unplug it from the USB port, without pressing the unmount button? Or perhaps it was automounted?
Comment 3 Hans-Rudi Denzler 2011-01-07 14:45:38 UTC
The external hard disk is an ieee1394 iomega fire wire device. The device is not mounted anymore before pulling the electrical plug (no automount):
> cat /proc/mounts
...

The command
> udisks --dump | gvim -
doesn't show any ieee1394 devices anymore, but the device notifier still shows the invalid IOMEGA_HDD device (windows partition): picture 2.

Picture 3 gives the correct error message: cannot be mounted.

To correct the device notifier I have to restart plasma-desktop:
> kbuildsycoca4 && kquitapp plasma-desktop && kstart plasma-desktop
Comment 4 Lukáš Tinkl 2011-01-07 15:27:13 UTC
Ok, can you check please if it still appears also in "solid-hardware --list" at that moment?
Comment 5 Hans-Rudi Denzler 2011-01-07 15:44:54 UTC
Comment #1, picture 1 (device plugged in, not mounted):
> solid-hardware list 2>&1 | grep sdd
udi = '/org/freedesktop/UDisks/devices/sdd1'
udi = '/org/freedesktop/UDisks/devices/sdd2'
udi = '/org/freedesktop/UDisks/devices/sdd'

picture2 (device plugged out), windows partition still present in device notifier:
> solid-hardware list 2>&1 | grep sdd
(no output)
Comment 6 Lukáš Tinkl 2011-01-08 20:01:45 UTC
Then it's a bug in the device notifier itself, reassigning
Comment 7 Hans-Rudi Denzler 2011-01-21 15:51:47 UTC
Created attachment 56294 [details]
dolphin:Places and device notifier in buggy action
Comment 8 Hans-Rudi Denzler 2011-01-26 12:19:29 UTC
KDE 4.6.0:
After renaming kded_device_automounterrc to kded_device_automounterrc~ and restarting:

[Devices][/org/freedesktop/UDisks/devices/sdd1]
EverMounted=true
Icon=drive-harddisk
LastNameSeen=IOMEGA_HDD
LastSeenMounted=false

[Devices][/org/freedesktop/UDisks/devices/sdd2]
EverMounted=true
Icon=drive-harddisk
LastNameSeen=18,6 GiB Wechselmedium
LastSeenMounted=false

Plugin drive sdd:
IOMEGA_HDD shown in dolphin:Places (OK)
       not shown in device notifier (not OK)
18,6 GiB Wechselmedium: OK

remove sdd:
IOMEGA_HDD shown in dolphin:Places (not OK)
           not shown in device notifier as above
18,6 GiB Wechselmedium: OK

restart dolphin: recognizes removal of sdd (OK)

Conclusion:
A restarted dolphin does something right what device notifier should do also.
An open dolphin is not correctly informed of the removal of IOMEGA_HDD.