You are not logged in.

#1 2008-10-05 13:23:57

Hohoho
Member
Registered: 2007-06-23
Posts: 222

Removing the USB stick during suspend

I'm using Gnome and Nautilus as my volume manager, have the latest stable packages, on a Dell Inspiron 1520 laptop.
Suspend is set up to work through uswsusp.

Now if I insert a USB stick it is mounted automagically and works great, then I suspend, and while the laptop is suspended I remove the USB stick (happens sometimes, eg. forgot to remove it before), then after I resume Nautilus still shows that the stick is mounted hmm. A user can't unmount it, only root can. Is there a way to fix this? Force HAL(?) to rescan what hardware is connected and adjust mountpoints accordingly or something?
Any hints would be appreciated.

Thanks

Last edited by Hohoho (2008-10-05 13:28:34)

Offline

#2 2008-10-05 15:22:40

lilsirecho
Veteran
Registered: 2003-10-24
Posts: 5,000

Re: Removing the USB stick during suspend

Perhaps reinsert the USB device and then unmount..................


Prediction...This year will be a very odd year!
Hard work does not kill people but why risk it: Charlie Mccarthy
A man is not complete until he is married..then..he is finished.
When ALL is lost, what can be found? Even bytes get lonely for a little bit!     X-ray confirms Iam spineless!

Offline

#3 2008-10-05 16:03:08

Hohoho
Member
Registered: 2007-06-23
Posts: 222

Re: Removing the USB stick during suspend

After further investigation turns out this has nothing to do with suspending, gnome-volume-manager doesnt handle forcefully removed usb storage properly.
After removing it, the mount point stays, you cant unmount it unless you are root.
If you reinsert the USB storage device it makes a duplicate mount point, so now there are 2 same mountpoints only one has an extra "_" at the end.

Offline

#4 2008-10-05 16:33:44

lilsirecho
Veteran
Registered: 2003-10-24
Posts: 5,000

Re: Removing the USB stick during suspend

I would assume that the listing of the USB device after removing it is a non-issue and produces no impact on performance.

This is born out by the re-install which enables the USB device while displaying both , one active and the other a remnant with no active consequence.


Prediction...This year will be a very odd year!
Hard work does not kill people but why risk it: Charlie Mccarthy
A man is not complete until he is married..then..he is finished.
When ALL is lost, what can be found? Even bytes get lonely for a little bit!     X-ray confirms Iam spineless!

Offline

#5 2008-10-05 17:04:28

pelle.k
Member
From: Åre, Sweden (EU)
Registered: 2006-04-30
Posts: 667

Re: Removing the USB stick during suspend

and while the laptop is suspended I remove the USB stick (happens sometimes, eg. forgot to remove it before)

You would do yourself a huge favor by waking it up and removing it, instead of removing it while in suspend, because eventually you *will* ruin the filesystem on it.
It is not a solution, but, very good advice. I hope you don't mind.

I guess you could create a pm script to unmount devices that match a pattern, say the UUID or LABEL of the stick? That would be executed upon suspending your machine.


"Your beliefs can be like fences that surround you.
You must first see them or you will not even realize that you are not free, simply because you will not see beyond the fences.
They will represent the boundaries of your experience."

SETH / Jane Roberts

Offline

Board footer

Powered by FluxBB