-   Slackware (
-   -   Xfce's Thunar automount issue (

dunric 11-20-2012 01:27 PM

Xfce's Thunar automount issue

in /etc/fstab I have the following entry:

/dev/sdb1      /mnt/memory auto noauto,rw,user,comment=x-gvfs-show  0 0
The x-gvfs-show option recommends Pat in his Changes & Hints document.

Volume gets automounted in Xfce but unexpectedly with root:root ownership. If there is no entry for the device in /etc/fstab it is properly automounted with current user ownership. How can I achieve user automount for devices listed in fstab ?

Btw. mount /mnt/memory from shell does mount with current user privileges. It just does not work for Gvfs-based Thunar's Volman.

ljb643 11-20-2012 06:01 PM

Interesting find - confirmed. I assume this has a VFAT-type filesystem on the volume (e.g. one with no inherent file ownership concept).

The default for vfat filesystems (uid,gid options) is the IDs of the current process. When you issue the mount command line, that's you, so you own the files on the volume.

But when Xfce/Thunar mounts the volume (whether because you enabled auto-mount, or because you right-clicked it on the desktop and picked Mount), then the udisks2 process does the mount. If there is no entry for the volume in /etc/fstab, then udisks makes you the owner of files on the volume. It also mounts it at the location we all complain about /run/media/USER/volume.

However, if there is an entry in /etc/fstab, then udisks seems to use exactly the options there, and does not arrange to "fix" the ownership. udisks runs as root, hence root owns files on the volume.

  1. Remove the entry from /etc/fstab, and live with the default options and awkward mount point that udisks likes.
  2. If this is a single user situation, you could probably add the uid=... option to the /etc/fstab line for the volume.
  3. Use only command-line mounts.
(I didn't say they were good options)

All times are GMT -5. The time now is 07:00 AM.