Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 149187 - gamin keeps files locked preventing unmounting of mass storage device
gamin keeps files locked preventing unmounting of mass storage device
Product: Fedora
Classification: Fedora
Component: gamin (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Daniel Veillard
Depends On:
  Show dependency treegraph
Reported: 2005-02-20 10:06 EST by Armijn Hemel
Modified: 2007-11-30 17:11 EST (History)
8 users (show)

See Also:
Fixed In Version: 0.0.25
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-03-02 13:11:25 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Armijn Hemel 2005-02-20 10:06:10 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5) Gecko/20041111 Firefox/1.0

Description of problem:
After an upgrade to gamin 0.0.24 I can't unmount my Olympus C-50 camera anymore after normal use with gthumb. umount complains the device is busy and lsof shows
that only the gam_server process has /media/usbdisk open.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. attach Olympus C-50
2. use it normally
3. close applications
4. unmount

Actual Results:  Device is not unmounted.

Additional info:
Comment 1 Armijn Hemel 2005-02-20 10:13:03 EST
I downgraded to 0.0.17 and I'm not seeing this problem anymore.
Comment 2 Michal Jaegermann 2005-02-22 15:21:44 EST
The same problem makes removable medial like a USB memory stick
or a USB floppy practically unusable. gam_server grabs references,
apparently multiple ones, to mount points and makes unmounting
without killing gam_server process impossible.  Even the later
seem to depend heavily on timing and if one is late with umount
then the whole game has to be restarted again.

If one will manage to kill gam_server and unmount a floppy then
putting a new floppy in a drive does not seem to have any effect
even if another gam_server process was restarted.  One has to
replug a USB floppy enclosure before it is recognized again.

Interestingly enough the above does not happen for CDs.  Are they
special-cased in the code?

Backing off to gamin-0.0.17-1.FC3 makes floppies unmountable
again but an icon for a USB floppy drive does not show up even
after hitting "Reload" in a "Computer" window.  Interestingly
enough what brings it is clicking on "Floppy Drive" icon in
"Computer" while no media are present.  This is causing an error
but also makes an icon for a "Removable Media" to show up both
in "Computer" window and on a desktop.  With 0.0.17 this still
can be unmounted.

All the above is not particular to i386.
Comment 3 Justin 2005-02-26 06:28:49 EST
i am experiencing the exact same problem this is one annoying bug and
has already cause the corruption of one usb key
Comment 4 Justin 2005-02-26 07:13:43 EST
i dont know what the deal is this is a lesser version number than the
one that is available on the site but this gamin appears to work

all of a sudden my usb key can unmount.
Comment 5 Michal Jaegermann 2005-02-26 12:42:14 EST
A report I got from a friend with a USB memory stick is that if
you will let it "hotplug mount", and will _not_ open any file
manager windows to a corresponding directory but use a command
line operations to move files in and out, then gam_server is not
sticking to directory handles and unmounting is possible without
doing 'pkill -f gam_' or equivalent.
Comment 6 Travis Suel 2005-02-26 17:28:14 EST
Someone mentioned that this does not happen with CD's.  But I have
this problem with both my CD-ROMs.  Although it doesn't happen unless
I browse the CD with Konqueror.  After that I am forced to umount like
      ]$ fuser -k /mnt/cdrw
      ]$ umount /dev/cdrw
Comment 7 Russell East 2005-02-28 20:05:16 EST
I have this problem with a memory stick.  After attempting to umount
the stick via the KDE icon, `ps -ef` shows me there are 2 (two)
gam_server processes like this:
russell   6295     1  0 10:37 ?        00:00:00 /usr/libexec/gam_server
root     11709     1  0 15:55 ?        00:00:00 /usr/libexec/gam_server

I can force the umount by using the following (as root):
kill -HUP 6295;umount /media/usbdisk/

In other words, I only have to hang-up the process that is owned by
me.  Subsequently, KDE, or whatever, is reestablishing a new user
process as seen here:
root     11709     1  0 15:55 ?        00:00:00 /usr/libexec/gam_server
russell  14433     1  0 16:58 ?        00:00:00 /usr/libexec/gam_server

Comment 8 Daniel Veillard 2005-03-01 06:49:26 EST
I know about the issue, just didn't found the cause yet.

Comment 9 Håvard Wigtil 2005-03-01 16:37:20 EST
I halso have this problem with the 0.24 update and USB sticks.
However, the 0.25 SRPM from http://www.gnome.org/~veillard/gamin/SRPMS/ fixes
the problem for me.
Comment 10 Daniel Veillard 2005-03-01 16:40:49 EST
yes 0.0.25 should fix this problem, well I made the release specifically
after finding the bugs related to this, so I hope this is fixed, it works
for me with FC3 and 0.0.25,

Comment 11 Michal Jaegermann 2005-03-01 17:30:46 EST
A quick check on x86_64 indeed seem to confirm that 0.25 works as
intended.  This was not a very extensive testing.
Comment 12 Tim Waugh 2005-03-02 05:50:03 EST
Reopening -- Daniel, this clearly needs an FC3 update, since it is a regression
since FC3 release.
Comment 13 Daniel Veillard 2005-03-02 05:55:23 EST
It is being pushed to FC-3 and if the build system didn't took 7 hours to
compile it, and 12 more hours to get someone to approve it, it would be
pushed out already !

Comment 14 Justin 2005-03-02 09:45:21 EST
after installing gamin-0.0.25-1 files only appear in nautilus after hitting refresh
Comment 15 Daniel Veillard 2005-03-02 09:48:58 EST
w.r.t. comment #14, this works for me. I tested it specifically. So you will
have to provide a reproductible test case including paths used etc ... in a new
bug report after being sure to have restarted all running gam_server 
I will close that bug once 0.0.25 is finished pushing to FC-3

Comment 16 Justin 2005-03-02 09:55:37 EST
sorry daniel,  i though that when installing the rpm ot would have restarted
gam_server right after installation.  after restart it worked perfectly.  thanks
Comment 17 Daniel Veillard 2005-03-02 10:23:51 EST
better :-)

Comment 18 Daniel Veillard 2005-03-02 13:11:25 EST
Pushed to FC-3 updates,

Comment 19 Russell East 2005-03-02 20:32:49 EST
it works fine for me.  After installing the update, I can now mount
and unmount the thumb drive using the KDE icon.  Thanks!

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