Re: "Too many levels of symbolic links"

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

 



On Wed, 2016-03-09 at 18:44 +0100, Donald Buczek wrote:
> 
> As a reminder, here is the script we used to demonstrate the problem (
> assuming /project/mariux32 is served by autofs) :
> 
> ===
> #! /bin/sh
> 
> ls -ld /project/mariux32/.
> unshare -m -- bash -c "sleep 6;ls -ld /project/mariux32/.;echo
> exit..." &
> kill -USR1  `cat /var/run/autofs-running`
> sleep 3
> ls -ld /project/mariux32/.
> wait
> ===
> 
> In your mail quoted below you wrote, the error would be avoided if "/"
> was set to shared before automount is started, but I can't confirm
> this.
> 
> ===
> root:nsa:/scratch/local/# systemctl stop automount.service
> root:nsa:/scratch/local/# mount --make-rshared /
> root:nsa:/scratch/local/# systemctl start automount.service
> root:nsa:/scratch/local/# ./test.sh
> drwxrwsr-x 6 mx32prj mx32grp 56 Feb 24  2011 /project/mariux32/.
> ls: cannot access /project/mariux32/.: Too many levels of symbolic
> links
> drwxrwsr-x 6 mx32prj mx32grp 56 Feb 24  2011 /project/mariux32/.
> exit...
> root:nsa:/scratch/local/#

And, sadly, it's not that simple as I tried to describe with the cases
of the previous mail.

One thing that occurred to me long ago was setting the autofs mounts
propagation private at mount so they wouldn't be cloned to namespaces.

So you'd think, problem solved for some selected cases, but other cases,
such as container implementations that need mounts to be propagation
slave, broken.

But setting the autofs mounts themselves propagation private doesn't
stop them being cloned, it only prevents the child mount from
propagating which would just force the ELOOP behaviour regardless of the
namespace mount propagation status.

And, as I found out, it isn't possible to set a mount so it doesn't
propagate, it can only be done by setting the parent to not propagate
(all of) it's children. So there's no way to selectively set individual
mounts to not propagate at mount time, so they don't show up in a
created namespace.

So it is quite a difficult problem.

Ian
--
To unsubscribe from this list: send the line "unsubscribe autofs" in



[Index of Archives]     [Linux Filesystem Development]     [Linux Ext4]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux