You are not logged in.

#1 2011-02-20 14:49:30

KoS
Member
Registered: 2006-02-02
Posts: 35

USB drive reappears after 'Safely Remove Drive'

Hi!

I have the following problem in GNOME on a Lenovo S12 Ion netbook.
When I select "Safely Remove Drive" upon right-clicking on the USB device, it is successfully removed BUT it reappears again after a few seconds. This happens for both external USB HDDs (tried with 2.5 HDD only) and pendrives. If an "Eject" menu item is also present in the menu (mostly for pendrives) than it works as should (just like calling umount from command line), but this menu item is not present for my external USB HDD.
It is pretty inconvenient to select "Safely Remove Drive" and then try to unplug the device at the right time (after it is unmounted but just before it is being remounted) or to start a terminal and do umount by hand before unplugging.

I searched the forums and I didn't find anyone else facing the same problem which is pretty strange for me... can this problem be a hardware specific problem?

I just updated all my packages not to report an already fixed problem.

I'm not sure what HW specific informations should I provide so I rather not spam the forum with irrelevant informations but feel free to ask for any infos.

Any suggestions are welcome.

Offline

#2 2011-05-25 20:21:11

mrechte
Member
Registered: 2011-05-04
Posts: 41

Re: USB drive reappears after 'Safely Remove Drive'

Hello,

KoS, you are not alone !

I have the  same problem. The drive reappears after a few seconds. If I "safely remove the drive" a second time then it disappears for good. This is not a hardware related problem (in my case) because this machine was OK with Fedora (it is a desktop computer). What I am not sure is whether the problem appeared since  the Arch install or after the Gnome 3 update.

Have you found any clue ?

Thanks

Offline

#3 2011-05-26 08:13:23

KoS
Member
Registered: 2006-02-02
Posts: 35

Re: USB drive reappears after 'Safely Remove Drive'

Hi mrechte!

Thanks for your feedback! I was already confident that the problem is because of some unique environment issue in my system.

I did not upgrade yet to Gnome 3 so I suppose it is not related to it.
This is bad news for me as I thought that upgrading to Gnome 3 would finally solve this problem however it seems that it wouldn't :-/

I'll try to debug this deeper when I have some spare time. My guess would be a hotplug issue or something related.

Offline

#4 2011-05-26 09:15:07

ninian
Member
From: United Kingdom
Registered: 2008-02-24
Posts: 726
Website

Re: USB drive reappears after 'Safely Remove Drive'

I don't use Gnome, just window managers such as Openbox and IceWm.
When using Udiskie (if I recall right, and maybe devmon too) to automount devices via udisks, this happened with an external hard drive. It remounted again so quickly - within about a second.
Anyway, that was one of the reasons I gave up on automounting and have a simple script to handle this under my own control.
So, probably a udisks or similar problem, rather than Gnome itself.

Offline

#5 2011-05-27 01:14:30

Gumper
Member
From: U.S.A.
Registered: 2009-10-26
Posts: 132

Re: USB drive reappears after 'Safely Remove Drive'

I had a similar problem when trying to eject my WD Passport USB drive. It would spin down but then immediately start back up again before I had time to remove it. I ended up creating the following script to properly eject it that I launch with a custom action in Thunar.

It works for me. You'll most likely have to modify it to search for the volume name of your drive.

#!/bin/sh

#script to properly shutdown external usb hd 
#check where drive is mounted by using grep of mtab
#this needs to have sdparm installed to work correctly

#find location of hd by searching for volume name
Drive=`grep "Passport" /etc/mtab | cut -c 1-8`

#sync data to drive
sdparm --command=sync $Drive
sleep 5    
#spindown drive
sdparm --command=stop $Drive 

Ready yourselves, ready yourselves
Let us shine the light of Jesus in the darkest night
Ready yourselves, ready yourselves
May the powers of darkness tremble as our praises rise .... Casting Crowns-Until The Whole World Hears.

Offline

#6 2011-08-03 03:25:58

shayan
Member
From: Edmonton
Registered: 2011-07-26
Posts: 9

Re: USB drive reappears after 'Safely Remove Drive'

I have the same problem with western digital hard disks ( I have two hard disks and both of them suffer from this problem)
@Gumper, I think this is not a good idea. This script stops the disk from spinning but does not do it gracefully. There should be a better solution. I read it here: http://www.linuxquestions.org/questions … dd-616410/
I have disabled gnome auto-mount so the disks are not mounted again, but they still spin after being safely removed.
I am still trying to find a solution for this. Any suggestions?

P.S.1:
This thread is a duplicate of https://bbs.archlinux.org/viewtopic.php?id=67309

P.S.2: Not related to this problem, but it's informative
https://bbs.archlinux.org/viewtopic.php?id=99626

Last edited by shayan (2011-08-03 03:26:44)

Offline

Board footer

Powered by FluxBB