[Xfce-bugs] [Bug 14718] New: symlink on read-only NFS share to redirect homedirectory prevents thunar from copy/paste to homedirectory

bugzilla-daemon at xfce.org bugzilla-daemon at xfce.org
Tue Sep 25 20:53:53 CEST 2018


https://bugzilla.xfce.org/show_bug.cgi?id=14718

            Bug ID: 14718
           Summary: symlink on read-only NFS share to redirect
                    homedirectory prevents thunar from copy/paste to
                    homedirectory
    Classification: Xfce Core
           Product: Thunar
           Version: 1.6.15
          Hardware: PC (x86_64)
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: Medium
         Component: Core
          Assignee: xfce-bugs at xfce.org
          Reporter: liebundartig at freenet.de
                CC: benny at xfce.org, hjudt at xfce.org
  Target Milestone: 1.8.2

I am not sure if this is the correct component to file the bug for.

* my environment *
Fedora 28 x86_64 computer joined to Microsoft Active Directory (AD) with realmd
and SSSD. POSIX attributes are stored in and coming from AD.
SELinux is disabled.
USER's home directory is served over NFS.
In order to use different servers we symlink the home directory. So different
servers can be used.
USER's home directory path is a symlink. The symlink is located on a share of
one server. This share is mounted read-only. The symlink points to a different
local path. That path can point to a different server.

It looks like this:
$ getent passwd USER 
USER:*:12345:6789:NAME OF USER:/usr/home/USER:/bin/bash

$ ls -ld /usr/home/USER
lrwxrwxrwx 1 root root 21 May  8  2009 /usr/home/USER -> /usr/people/home/USER

$ ls -ld /usr/people/home/USER
drwx------ 54 USER GROUP 16384 Sep 25 18:47 /usr/people/home/USER

$ ls -ld /usr/home /usr/people/home
drwxr-xr-x   2 root root 28672 Sep 21 11:47 /usr/home
drwxr-xr-x 331 root root 28672 Sep 21 11:47 /usr/people/home


The mount point options are (additional spaces and truncation by me):
$ mount | grep home
nas1:/home on /usr/people/home type nfs (rw,...same...)
nas1:/meta on /usr/home        type nfs (ro,...same...)



* finding the cause of the problem *
It seems only the first mount point options are obeyed (read-only folder).
The symlink does not seem to be resolved (realpath?) to the read-write folder.

I edited /etc/fstab (changed ro to rw for /usr/home) and rebooted the computer.
Afterwards Thunar has no problems anymore to copy/cut-paste files with content
to home directory.

I want to keep mounting the share with the symlinks read-only because it is
small.
/usr/home - maximum size is 16 MB
/usr/people/home - maximum size is much larger than 16 MB


I try to create a guide to create a similar environment for local testing. When
done I will post it as comment.



* the problem behavior *
These actions fail with an error message from Thunar ("The destination is
read-only." see below for more information):
- drag-and-drop an email attachment from Evolution to the homedirectory
- in thunar right mouse button click on file, select copy; go to USERS's
homedirectoy (house icon on the left side in PLACES); Edit -- Paste
- in thunar copy/cut a file with content (a single letter is sufficient);
pasting into /usr/home/USER


These actions work without problem:
- in thunar copy/cut a file with content (a single letter is sufficient);
pasting into /usr/people/home/USER
- in thunar copy/cut an *empty* file and paste it in either homedirectory path 
- in Evolution right mouse button click on the same email attachment and using
"Save as" to save the file in the homedirectory
- in terminal: echo "test" > /tmp/test ; cp /tmp/test.txt /usr/home/USER
- in terminal: echo "test" > /tmp/test ; cp /tmp/test.txt /usr/people/home/USER
- using `nautilus` or `dolphin` to copy/cut-paste files (with and without
content) to either home directory



* the error message from thunar *
After I paste the file 2 pop-up windows appear. Window 1 with title and content
is:
---8<---
File Operation Progress
--
Copying files to "USER"...
Colleting files...
[[]]
---8<---


Window 2 with title and content is:
---8<---

--
Error while copying to "USER".
The destination is read-only.
[Close]
---8<---



* more information*
With testing I confirmed:
- not a problem of tcsh vs bash as loginshell.
- not reproducible with local account and symlinked local folders:
root at box:~ # useradd -m test
root at box:~ # passwd test
...
root at box:~ # ls -ld /home
drwxr-xr-x. 3 root root 4096 Jun 20 18:05 /home
root at box:~ # mkdir /home2
root at box:~ # mv /home/test /home2
root at box:~ # ls -ld /home /home2 /home2/test
drwxr-xr-x.  2 root root 4096 Sep 25 19:23 /home
drwxr-xr-x   3 root root 4096 Sep 25 19:23 /home2
drwx------  17 test test 4096 Sep 25 19:20 /home2/test
root at box:~ # ln -s /home2/test /home
root at box:~ # ls -l /home
total 0
lrwxrwxrwx 1 root root 11 Sep 25 19:23 test -> /home2/test

same result with / as new home basedir

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the Xfce-bugs mailing list