Bug 438610 - eject should not only check for removable but also for hotpluggable
Summary: eject should not only check for removable but also for hotpluggable
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: eject
Version: 8
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Zdenek Prikryl
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-03-22 20:52 UTC by Leo Bergolth
Modified: 2008-04-09 05:15 UTC (History)
1 user (show)

Fixed In Version: 2.1.5-8.fc8
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-04-09 05:13:00 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Output of lshal -lu `hal-find-by-property --key "block.device" --string "/dev/sdb"` (1.75 KB, text/plain)
2008-03-22 20:52 UTC, Leo Bergolth
no flags Details

Description Leo Bergolth 2008-03-22 20:52:11 UTC
Description of problem:
eject-2.1.5-6 and 2.1.5-7 added a check for the removable flag of a device.
Unfortunately, USB disks are marked as not removable but "only" hotpluggable.
Hence, the new version of eject refuses to operate on USB disks.

Version-Release number of selected component (if applicable):
2.1.5-7.fc8

How reproducible:
Try to eject a USB-disk.

Actual results:
# eject /dev/sdb
eject: device "/dev/sdb" doesn't have a removable flag

Expected results:
Should eject the device.

Additional info:
See
http://lists.freedesktop.org/archives/hal/2005-October/003441.html
for an explanation of removable and hotpluggable.

Cheers,
--leo

Comment 1 Leo Bergolth 2008-03-22 20:52:11 UTC
Created attachment 298855 [details]
Output of lshal -lu `hal-find-by-property --key "block.device" --string "/dev/sdb"`

Comment 2 Mike C 2008-03-24 16:57:01 UTC
I presume that this is the origin of the problem I have with a usb drive that is
mounted fine, and has the drive icon on the desktop, in kde in a fully updated
f8 system. If the drive icon is right-clicked and "safely remove" is selected
then you get the nasty crash sound, and although the drive is unmounted it is
not "ejected". This is with eject-2.1.5-7.fc8. Pulling out the usb plug does
then remove the drive icon from the desktop.

Comment 3 Zdenek Prikryl 2008-03-26 16:33:29 UTC
A hotpluggable flag, which you can see in your lshal, is set by hal (not the
kernel). Its value is determined only on a type of a bus. It means that if a
device is on usb, pcmcia, ..., then it is automatically hotpluggable.

A question is, if eject should be allowed to eject this kind of devices. Only
what eject does is, that unmount a device. So one can use instead eject umount.

Comment 4 Leo Bergolth 2008-03-26 17:22:59 UTC
(In reply to comment #3)
> A hotpluggable flag, which you can see in your lshal, is set by hal (not the
> kernel). Its value is determined only on a type of a bus. It means that if a
> device is on usb, pcmcia, ..., then it is automatically hotpluggable.
> A question is, if eject should be allowed to eject this kind of devices. Only
> what eject does is, that unmount a device. So one can use instead eject umount.

Since KDEs kio_media_mounthelper calls eject when removing USB devices and
probably many other existing applications will do similar things, I believe
Redhats version of eject should retain it's upstream behavior. It should
continue to work for hotpluggable devices, even if it effectively only umounts
them, otherwise it will break many applications.

Cheers,
--leo


Comment 5 Fedora Update System 2008-04-02 09:02:50 UTC
eject-2.1.5-8.fc8 has been submitted as an update for Fedora 8

Comment 6 Fedora Update System 2008-04-02 09:12:34 UTC
eject-2.1.5-8.fc7 has been submitted as an update for Fedora 7

Comment 7 Fedora Update System 2008-04-09 05:12:57 UTC
eject-2.1.5-8.fc8 has been pushed to the Fedora 8 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2008-04-09 05:15:42 UTC
eject-2.1.5-8.fc7 has been pushed to the Fedora 7 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.