Bug 158316 - KDE fails to unmount an auto-mounted USB flash drive
Summary: KDE fails to unmount an auto-mounted USB flash drive
Status: RESOLVED WORKSFORME
Alias: None
Product: SUSE Linux 10.1
Classification: openSUSE
Component: KDE (show other bugs)
Version: Beta 7
Hardware: i686 Other
: P5 - None : Normal (vote)
Target Milestone: ---
Assignee: E-mail List
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on: 158579
Blocks:
  Show dependency treegraph
 
Reported: 2006-03-15 17:06 UTC by Jiri Dluhos
Modified: 2006-04-24 09:47 UTC (History)
1 user (show)

See Also:
Found By: Other
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments
Strace output for hald when attempting to unmount the drive from KDE. (44.37 KB, text/plain)
2006-03-15 17:40 UTC, Jiri Dluhos
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Dluhos 2006-03-15 17:06:30 UTC
When trying to connect an USB flash drive to my workstation (SL10.1 beta7, KDE), it got automatically mounted with the standard KDE dialog appearing, and worked, but I was not able to unmount it from KDE.

When right-clicking the icon of the disk in the 'My Computer' folder, a 'Safely Remove' entry is in the menu, but when I click on it, an error window appears, titled "Error - kio_media_mounthelper", with message "An unknown error occurred".

The disk can be unmounted by classical 'umount' command but only if run as root. I am afraid a common user would be lost.

It is well possible that this behavior is only specific to some types of USB flash disks or computer hardware. I have used Corsair FlashVoyager.
Comment 1 Jiri Dluhos 2006-03-15 17:10:12 UTC
After unmounting it by hand, and then disconnecting and reinserting it again, the situation is slightly different: the 'Safely Remove' option now did not report any error, and the device icon changed to unmounted state, but the drive is still mounted; when clicking on the icon, an error message 'Device is already mounted' appears. Further attempts to 'Safely Remove' still appear to work, but have no effect.
Comment 2 Jiri Dluhos 2006-03-15 17:12:43 UTC
I have tried another USB flash disk, an old Apacer Handy Drive (USB1.0 only), it behaves in the same way.
Comment 3 Stephan Kulow 2006-03-15 17:22:51 UTC
I can't reproduce that at all ;(

Please strace -f $(pidof hald) and then safely remove and attach it here.
Comment 4 Dirk Mueller 2006-03-15 17:29:48 UTC
I have the very same issue on my laptop (10.1b7)
Comment 5 Jiri Dluhos 2006-03-15 17:40:49 UTC
Created attachment 73076 [details]
Strace output for hald when attempting to unmount the drive from KDE.
Comment 6 Jiri Dluhos 2006-03-15 17:44:53 UTC
Please find the attached strace output.

Interestingly, the computer behaved differently this time, or possibly I have mistaken the previous behavior.

The 'Safely Remove' option seemed to really unmount the drive successfully and *then* issued an error message. When I typed 'mount' in the console, the drive was not mounted. When I clicked on the icon (now in unmounted state), I have got the 'Device is already mounted' message, but when I typed 'mount' in the console again, the drive was mounted successfully (but Konqueror was unable to show its contents).

In short, now it seemed both functions worked correctly but they *think* they failed. Unfortunately I don't know how to check if the behavior changed or if it was this way from the start.

Comment 7 Jiri Dluhos 2006-03-15 17:48:00 UTC
Nope, I was wrong - when the drive is mounted, the 'Safely Remove' option does not unmount it, it just does not report any error.
Comment 8 Jiri Dluhos 2006-03-15 17:49:27 UTC
Ouch, now I have confused it completely; please better look at the strace output and don't take my babbling too seriously :-)
Comment 9 Stephan Kulow 2006-03-15 18:53:30 UTC
read(48, "/usr/lib/hal/scripts/hal-system-"..., 510) = 73
write(2, "2204: arguments to dbus_message_"..., 225) = 225
writev(14, [{"l\3\1\1\35\0\0\0%\v\0\0O\0\0\0\6\1s\0\5\0\0\0:1.30\0\0"..., 96}, {"\30\0\0\0An unknown error occured\0", 29}], 2) = 125

HAL is not behaving as it should be (and I have no idea what would be different on my machine). If Dirk can reproduce this, I might reproduce this on friday.
Comment 10 Ludwig Nussel 2006-03-16 10:58:29 UTC
parts of this could be caused by #158579
Comment 11 Christoph Thiel 2006-04-23 11:13:27 UTC
There hasn't been any progress on this bug for more than a month now -> what's the status?
Comment 12 Stephan Kulow 2006-04-24 09:47:10 UTC
I claim it's fixed