Menu

#21 aufs doesn't copy up changed directory permissions

v1.0_(example)
open
nobody
None
5
2015-06-07
2015-06-07
No

I have two writeable branches each containing a directory test with permissions set to 700:

# ls -l branch*
branch1:
total 4
drwx------ 2 root root 4096 Jun  7 15:07 test

branch2:
total 4
drwx------ 2 root root 4096 Jun  7 15:07 test

These are tied together at the mount point /mnt/union:

# mount -t aufs -o br=branch1=rw:branch2=rw none /mnt/union

I set the permissions of /mnt/union/test to 755:

# chmod 755 /mnt/union/test

Now /mnt/union/test should be accessible by anyone. But it isn't because aufs only altered the permissions of branch1/test and left branch2/test untouched:

# ls -l branch*
branch1:
total 4
drwxr-xr-x 2 root root 4096 Jun  7 15:07 test

branch2:
total 4
drwx------ 2 root root 4096 Jun  7 15:07 test

Is this behavior by design or a bug? I know about the mount option dirperm1 and it helps in this situation, but it seems like working around the real problem of not propagating the changed permissions to all appropriate directories.

Tests were done on Debian 8, kernel 3.19.8, aufs-standalone 3.19, aufs-util 3.14, ext4.

Discussion

  • J. R. Okajima

    J. R. Okajima - 2015-06-07

    Hello Kontroll Freak,

    "Kontroll Freak":

    Is this behavior by design or a bug? I know about the mount option dirperm1 and it helps in this situation, but it seems like working around the real problem of not propagating the changed permissions to all appropriate directories.

    By design.
    Essentially, in a single operation, aufs writes to the selected writable
    branch only.

    J. R. Okajima

     
    • Anne Nonymous

      Anne Nonymous - 2015-06-07

      Thanks for clarifying.

       

Log in to post a comment.

Auth0 Logo