Proposal: Allow mounting and bind mounting over symlinks – flag to not expand symlinks

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Morning all!

I would like to propose adding a flag to the syscall underlying mount(2) that disables symlink expansion.

The motivating use case for this is as follows: I am trying to set up a netns namespace that requires a specific DNS setup,
to this end, I am creating a mount namespace and replacing /etc/resolve.conf. Unfortunately, resolv.conf is a symlink provided
by systemd-resolved. Bind mounting over said file with my replacement is impossible: With `-c` option, the `mount` command
actually targets `/etc/resolv.conf` instead of the file it's pointing to, but the kernel expands it internally and seems to
mount over the file being pointed to.

I highly similar use cases exist.

I have tried the nosymfollow option, which did not work. I think it affects only how symlinks are handled once the fs
is mounted.

Best,
Karolin Varner



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux