One long term "non-easy" issue that keeps coming up a few times a year, is attempting to dismount an external drive/usb stick and this failing due to a file being opened.
lsof is a good start, and sometimes advised in the error message with some other command. However, what ends up the case is gvfs has it's greedy fingers stuck right up the drive and refuses to let go! There _ought_ be a simple force dismount option. There ought be one command (I know, let's say "umount") that achieves this, optionally with a --quiet option so it doesn't stop to ask the user in case some file is actually open for editing. Does such a thing exist? But more importantly, how do I cause gvfs to "detach", e.g.: $ sudo umount -vd /media/tmp # same result with -i option umount: /media/tmp: device is busy. (In some cases useful info about processes that use the device is found by lsof(8) or fuser(1)) $ lsof /media/tmp/ COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME gvfsd-met 10600 justa mem REG 254,5 32768 49238 /media/tmp/352/.local/share/gvfs-metadata/uuid-e4dffbb8-6a22-4ae5-99a7-11d3734976c3-b71ca6c5.log gvfsd-met 10600 justa mem REG 254,5 696 49235 /media/tmp/352/.local/share/gvfs-metadata/uuid-e4dffbb8-6a22-4ae5-99a7-11d3734976c3 gvfsd-met 10600 justa 9r REG 254,5 696 49235 /media/tmp/352/.local/share/gvfs-metadata/uuid-e4dffbb8-6a22-4ae5-99a7-11d3734976c3 gvfsd-met 10600 justa 10u REG 254,5 32768 49238 /media/tmp/352/.local/share/gvfs-metadata/uuid-e4dffbb8-6a22-4ae5-99a7-11d3734976c3-b71ca6c5.log $ gvfs-mount -l # extract follows: Volume(3): 1.1 GB Volume Type: GProxyVolume (GProxyVolumeMonitorUDisks2) Mount(0): 1.1 GB Volume -> file:///media/tmp Type: GProxyMount (GProxyVolumeMonitorUDisks2) $ gvfs-mount -ui /media/tmp/ Error unmounting mount: One or more programs are preventing the unmount operation. WTFiretruck? Of course a reboot would work, but that' just not the GNU way! :) Craziness ending suggestions REALLY appreciated, Zenaan -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/caosgnstucrnrl5yggkw3pu4lnvp4no7vaaknbvrbfj3wugo...@mail.gmail.com