You are not logged in.

#1 2014-08-10 20:59:44

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

udevil (SpaceFM) now gives error after unmounting removable devices

After updating my (64-bit Arch) system a couple of days ago, I find that udevil always throws up an error now after unmounting any removable device, no matter whether it's used from within SpaceFM or by itself from the command line:

umount: /run/media/me/<devicelabel>: filesystem was unmounted, but mount(8) failed: Invalid argument

Doesn't seem to cause a problem, more of a nuisance, but something has changed, somewhere ...

Offline

#2 2014-08-11 02:12:45

emeres
Member
Registered: 2013-10-08
Posts: 1,570

Re: udevil (SpaceFM) now gives error after unmounting removable devices

What exact [un]mount commands are you using? Are you using udevil from community repository or from AUR?

Offline

#3 2014-08-11 09:02:37

swordfeng
Member
Registered: 2014-07-24
Posts: 19

Re: udevil (SpaceFM) now gives error after unmounting removable devices

I have the same problem, using udevil umount with all default settings. Community version.
Now I'm using udisks2. But I still want to know how it is solved.

Offline

#4 2014-08-11 09:15:05

swordfeng
Member
Registered: 2014-07-24
Posts: 19

Re: udevil (SpaceFM) now gives error after unmounting removable devices

It is clear now.
When I umounted a device through udevil, it executes umount twice:

umount /dev/sdb1
umount -d /media/sdb1-usb-Teclast_CoolFlas

I guess the devide is umounted successfully at the first time, but udevil continues to run umount the second time and makes an error.

Offline

#5 2014-08-11 09:30:01

Kotrfa
Member
Registered: 2012-10-25
Posts: 213

Re: udevil (SpaceFM) now gives error after unmounting removable devices

I get the same error when I use devmon. Is it a bug? Have you submitted it?

Offline

#6 2014-08-11 09:39:55

emeres
Member
Registered: 2013-10-08
Posts: 1,570

Re: udevil (SpaceFM) now gives error after unmounting removable devices

I have the community 0.4.3-1 x86_64 package and do not have such errors. What is the content of your udevil configuration?

Offline

#7 2014-08-11 17:40:01

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

Re: udevil (SpaceFM) now gives error after unmounting removable devices

emeres wrote:

I have the community 0.4.3-1 x86_64 package and do not have such errors. What is the content of your udevil configuration?

I'm using the same version, and here's the diff between my config file and the default supplied:

$ diff  /etc/udevil/udevil.conf{,.pacnew}
44,45c44,45
< allowed_types = $KNOWN_FILESYSTEMS, file, cifs, smbfs, nfs, curlftpfs, ftpfs, sshfs, davfs, tmpfs, ramfs
< #allowed_types = $KNOWN_FILESYSTEMS, file
---
> # allowed_types = $KNOWN_FILESYSTEMS, file, cifs, smbfs, nfs, curlftpfs, ftpfs, sshfs, davfs, tmpfs, ramfs
> allowed_types = $KNOWN_FILESYSTEMS, file
104,105c104
< #allowed_media_dirs = /media, /run/media/$USER
< allowed_media_dirs = /run/media/$USER, /media
---
> allowed_media_dirs = /media, /run/media/$USER
138d136
< allowed_internal_devices_ntfs = /dev/sda*, /dev/sdb*, /dev/sdc*
246,247c244
< #allowed_options           = nosuid, noexec, nodev, noatime, fmask=0133, dmask=0022, uid=$UID, gid=$GID, ro, rw, sync, flush, iocharset=*, utf8, remount
< allowed_options           = nosuid, noexec, nodev, noatime, fmask=0133, dmask=0022, uid=$UID, gid=$GID, ro, rw, sync, flush, iocharset=*, utf8, remount, exec
---
> allowed_options           = nosuid, noexec, nodev, noatime, fmask=0133, dmask=0022, uid=$UID, gid=$GID, ro, rw, sync, flush, iocharset=*, utf8, remount

Wouldn't think that there was much in the config to cause trouble - it never has before.
@swordfeng: That's an interesting observation about executing umount twice - how did you detect that?
@Kotrfa: Problem only emerged very recently; something apart from udevil has been updated and affected its operation. My pacman log shows that it has been a long time since udevil was updated:

[2013-12-09 16:35] [ALPM] warning: /etc/udevil/udevil.conf installed as /etc/udevil/udevil.conf.pacnew
[2013-12-09 16:35] [PACMAN] upgraded udevil (0.4.2-1 -> 0.4.3-1)

Am not sure where the "bug" lies, if indeed it is ...

Offline

#8 2014-08-11 19:10:53

oliver
Member
Registered: 2007-12-12
Posts: 448

Re: udevil (SpaceFM) now gives error after unmounting removable devices

just want to add that I have the same issue with Community udevil.  /etc/udevil/udevil.conf is untouched as is /etc/conf.d/devmon

When I umount (using 'udevil umount /media/<USB>') I get the following in /var/log/udevil.log

@11 Aug 2014 17:15:20::oliver$ /usr/sbin/udevil --show-info /dev/sdb1

@11 Aug 2014 17:15:20::oliver$ udevil umount /media/SANDISK16_EXT4_6
udevil: trying umount as current user
USER: /bin/umount /media/SANDISK16_EXT4_6
      umount exit status = 1
ROOT: /bin/umount -d /media/SANDISK16_EXT4_6
      umount exit status = 1

@11 Aug 2014 17:15:20::oliver$ /usr/sbin/udevil clean
udevil: cleaned '/media/SANDISK16_EXT4_6'

So it looks like udevil tries to umount as me and thinks it's failing so tries again as root (but I'm assuming the original umount does work)

Last edited by oliver (2014-08-11 21:21:02)

Offline

#9 2014-08-11 22:04:30

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

Re: udevil (SpaceFM) now gives error after unmounting removable devices

I wonder if the problem has been caused by changes to umount via the last upgrade to the util-linux package:

 $ pacman -Qo umount
/usr/bin/umount is owned by util-linux 2.25-3
[2014-08-08 15:57] [PACMAN] upgraded util-linux (2.24.2-1 -> 2.25-3)

Offline

#10 2014-08-12 00:51:32

swordfeng
Member
Registered: 2014-07-24
Posts: 19

Re: udevil (SpaceFM) now gives error after unmounting removable devices

@oliver
You may be right.`sudo udevil umount /dev/sdb1` has no error.
The devices mounted using udevil cannot be umounted by normal user. However, devices mounted with udisks/udisks2 can.
I wonder how `umount` decides which devices are allowed to be umounted.

Offline

#11 2014-08-12 13:58:41

oliver
Member
Registered: 2007-12-12
Posts: 448

Re: udevil (SpaceFM) now gives error after unmounting removable devices

:-)
I think I was backwards.  I was assuming the umount as $USER works and udevil was trying as root erroneously but it sounds like it fails as $USER.  What confuses me is they both report as failed in the logs (exit status = 1)

Offline

#12 2014-08-13 22:55:16

stevenhoneyman
Member
From: England
Registered: 2014-05-25
Posts: 241

Re: udevil (SpaceFM) now gives error after unmounting removable devices

I've been getting this same error as well. util-linux has had a recent update, but spacefm also got downgraded to gtk2 recently in the Arch binary package

Offline

#13 2014-08-15 19:38:50

Knusperkeks
Member
From: Germany
Registered: 2012-07-14
Posts: 26

Re: udevil (SpaceFM) now gives error after unmounting removable devices

I just use udevil alone and also suffering from unmount problems with usb devices since the last util-linux update sad
Are there any workarounds to solve this problem? Or any lightweight alternative working as well as udevil?

Offline

#14 2014-08-15 20:52:55

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

Re: udevil (SpaceFM) now gives error after unmounting removable devices

Knusperkeks wrote:

Or any lightweight alternative working as well as udevil?

zuluCrypt is good, and you can use zuluMount (provided by the package) to automount normal devices too, as well as encrypted containers.
Maybe not quite as configurable as udevil though, but still a lot of options available for most folks.

Edit: Increased affirmation of zuluMount's flexibility.

Last edited by ninian (2014-08-16 14:59:00)

Offline

#15 2014-08-15 20:54:49

mhogomchungu
Member
Registered: 2013-03-29
Posts: 87

Re: udevil (SpaceFM) now gives error after unmounting removable devices

Knusperkeks wrote:

I just use udevil alone and also suffering from unmount problems with usb devices since the last util-linux update sad
Are there any workarounds to solve this problem? Or any lightweight alternative working as well as udevil?

zuluMount-cli is an alternative that works just as well if you use udevil to mount/unmount block devices.It ships as part of zuluCrypt[1]

edit:
how do i delete this post as the one above it speaks of the same thing?(it got posted before mine)

[1] https://bbs.archlinux.org/viewtopic.php?id=160477

Last edited by mhogomchungu (2014-08-15 20:57:59)

Offline

#16 2014-08-16 13:17:42

emeres
Member
Registered: 2013-10-08
Posts: 1,570

Re: udevil (SpaceFM) now gives error after unmounting removable devices

@mhogomchungu I do not think your post should be deleted, since you are 'the source' of this workaround, but a moderator or the administrator should be able to help out, if you insist.

I would go deeper into the dependencies, try to isolate the problem.

Offline

#17 2014-08-16 14:27:30

stevenhoneyman
Member
From: England
Registered: 2014-05-25
Posts: 241

Re: udevil (SpaceFM) now gives error after unmounting removable devices

I just switched back to PCManFM instead... my reason(s) I left it originally were gvfs requirement, and it wasn't being developed. Now it's flipped again! SpaceFM is not developed, and udevil is a problem.

PCManFM works fine with udisks (v1, not the bloated v2) so no longer needs gvfs

Offline

#18 2014-08-17 08:48:27

emeres
Member
Registered: 2013-10-08
Posts: 1,570

Re: udevil (SpaceFM) now gives error after unmounting removable devices

@stevenhoneyman You can specify which commands to use in SpaceFM for [un]mounting, so this should not be a problem. It should work fine with udisks1 and 2, pmount, udevil and maybe others as well (untested).

Offline

#19 2014-08-17 15:42:07

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

Re: udevil (SpaceFM) now gives error after unmounting removable devices

emeres wrote:

@stevenhoneyman You can specify which commands to use in SpaceFM for [un]mounting, so this should not be a problem. It should work fine with udisks1 and 2, pmount, udevil and maybe others as well (untested).

Yes indeed, setting SpaceFM's Mount and Unmount command settings to:

/usr/bin/zuluMount-cli -m -d %v
/usr/bin/zuluMount-cli -u -d %v

respectively work fine.

Offline

#20 2014-08-23 16:32:56

LCJr
Member
Registered: 2012-11-12
Posts: 7

Re: udevil (SpaceFM) now gives error after unmounting removable devices

Adding the -l "lazy" flag to udevil's unmount command suppresses the error messages.

 /usr/bin/udevil unmount -l %v 

udevil.log still shows an error for the User unmount but the Root unmount shows clean/no error.

 udevil: trying umount as current user
USER: /bin/umount -l /dev/sda2
      umount exit status = 1
ROOT: /bin/umount -l -d /run/media/user/sda2-blah-blah
udevil: cleaned '/run/media/user/sda2-blah-blah' 

I haven't been able to find much documentation on the lazy option so anyone aware of any potential problems by going this route?

Thanks for the reminder emeres, haven't posted here in quite some time.

Last edited by LCJr (2014-08-23 19:11:53)

Offline

#21 2014-08-23 18:39:38

emeres
Member
Registered: 2013-10-08
Posts: 1,570

Re: udevil (SpaceFM) now gives error after unmounting removable devices

@LCJr Use [⁣code][⁣/code] tags to mark output of a command.

Offline

#22 2014-08-24 00:47:17

oliver
Member
Registered: 2007-12-12
Posts: 448

Re: udevil (SpaceFM) now gives error after unmounting removable devices

LCJr wrote:

I haven't been able to find much documentation on the lazy option so anyone aware of any potential problems by going this route?

Interesting find LCJr

From 'man umount'

       Note that a file system cannot be unmounted when it is 'busy' - for example, when there are open files on it, or
       when  some  process has its working directory there, or when a swap file on it is in use.  The offending process
       could even be umount itself - it opens libc, and libc in its turn may open for example  locale  files.  A  lazy
       unmount avoids this problem.


       -l, --lazy
              Lazy  unmount.   Detach  the  filesystem from the file hierarchy now, and clean up all references to this
              filesystem as soon as it is not busy anymore.  (Requires kernel 2.4.11 or later.)

Offline

#23 2014-10-22 20:19:37

Kotrfa
Member
Registered: 2012-10-25
Posts: 213

Re: udevil (SpaceFM) now gives error after unmounting removable devices

Hello,

I'm still getting this error with devmon. It works fine (the device is unmounted), but it's annoying. Has anyone submit it? Thank you

Offline

#24 2014-10-23 17:57:08

mentat
Member
From: France
Registered: 2009-01-13
Posts: 138
Website

Re: udevil (SpaceFM) now gives error after unmounting removable devices

udevil dev is stopped for the moment:

ANNOUNCEMENT 2014-04-28: Most development and maintenance on the SpaceFM and udevil projects is indefinitely suspended. See IgnorantGuru's Hiatus

http://igurublog.wordpress.com/2014/04/ … us-hiatus/

We'll miss Ignorant Guru Überskill since that day.
Until a real good fix for this problem, I use the lazy option:

udevil umount -l

and

udevil clean

sometimes.

For devmon, maybe you can execute it with cron, inotify ...

Edit: devmon smile

Last edited by mentat (2014-10-23 18:03:17)

Offline

#25 2014-11-03 16:35:35

oliver
Member
Registered: 2007-12-12
Posts: 448

Re: udevil (SpaceFM) now gives error after unmounting removable devices

I'm not sure how helpful this will be but over the weekend I did a fresh install and now udevil is working again with 'udevil umount'.  I'm not sure what I did differently but removable devices are now mounted to /run/media/<username>/<device> instead of /media/<device>

Maybe it's a udisks versus udisks2 thing?  I don't remember which one I had before.

Like I said, not that helpful since I don't know *what* I did differently but it does appear to be resolvable.

Offline

Board footer

Powered by FluxBB