On Ma, 09 feb 21, 13:00:23, David Christensen wrote: > > We were all confused by a feature of mount(1) -- mounting a remote > filesystem changes the owner and group of the mount point on the local > machine while the remote filesystem is mounted: Maybe it's easier to understand that a file system is mounted "on top" of a mount point (which is typically, but not necessarily, an empty directory). There is no change of permissions involved, one is just looking at two different directories, that just happen to be attached at the same point in the file system hierarchy. > 2021-02-09 12:13:43 dpchrist@tinkywinky ~ > $ mount | grep '/po' > > 2021-02-09 12:23:26 dpchrist@tinkywinky ~ > $ ls -ld /po > drwxr-xr-x 2 dpchrist dpchrist 4096 Jan 21 13:32 /po > > 2021-02-09 12:23:29 dpchrist@tinkywinky ~ > $ mount /po > > 2021-02-09 12:24:14 dpchrist@tinkywinky ~ > $ mount | grep '/po' > po:/ on /po type fuse.sshfs > (ro,nosuid,nodev,noexec,relatime,user_id=13250,group_id=13250,user=dpchrist) > > 2021-02-09 12:24:17 dpchrist@tinkywinky ~ > $ ls -ld /po > drwxr-xr-x 1 root root 4096 Aug 30 18:09 /po These are the permissions of the root directory of the mounted file system. > The owner and group are restored when the filesystem is unmounted: > > 2021-02-09 12:24:21 dpchrist@tinkywinky ~ > $ fusermount -u /po > > 2021-02-09 12:25:45 dpchrist@tinkywinky ~ > $ ls -ld /po > drwxr-xr-x 2 dpchrist dpchrist 4096 Jan 21 13:32 /po Here you are looking again at the mount point. Kind regards, Andrei -- http://wiki.debian.org/FAQsFromDebianUser
Attachment:
signature.asc
Description: PGP signature