public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* automount doesn't "follow" bind mounts
@ 2002-08-20 17:10 Matt Bernstein
  2002-08-20 20:58 ` H. Peter Anvin
  0 siblings, 1 reply; 9+ messages in thread
From: Matt Bernstein @ 2002-08-20 17:10 UTC (permalink / raw)
  To: linux-kernel

I tried to subscribe to the autofs list, but majordomo isn't replying to 
me! I think this is a problem in the automount daemon rather than the 
kernel autofs code itself.

I'm trying to automount our home dirs as
	/homes/$USERNAME
which should bind mount to
	:/home/$SERVER/$HOMENAME/$USERNAME
which should bind mount to
	:/home/$SERVER/$VOLUME/$PATH/$USERNAME
which (phew!) will be an NFS mount to
	$SERVER:/$VOLUME/$PATH/$USERNAME

The idea is that:
	(1) `/bin/pwd` = "/homes/$USERNAME"
	(2) when you run "quota" it'll only report for $SERVER:/$VOLUME

Now.. this all works perfectly if before looking at /homes/$USERNAME you
look at firstly /home/$SERVER/$VOLUME/$PATH/$USERNAME and then secondly
/home/$SERVER/$HOMENAME/$USERNAME, because the bind mounts have something
to bind to. Of course you shouldn't need to know the middle bits, but you
could look them up. Currently the binds mount fail and automount drops in
symlinks; this satisfies (2)  above, but unfortunately not (1).

I hope someone can make sense of this. Is it different in autofs4?

Matt


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: automount doesn't "follow" bind mounts
  2002-08-20 17:10 automount doesn't "follow" bind mounts Matt Bernstein
@ 2002-08-20 20:58 ` H. Peter Anvin
  2002-08-20 21:35   ` H. Peter Anvin
  0 siblings, 1 reply; 9+ messages in thread
From: H. Peter Anvin @ 2002-08-20 20:58 UTC (permalink / raw)
  To: linux-kernel

Followup to:  <Pine.LNX.4.44.0208201752430.23681-100000@r2-pc.dcs.qmul.ac.uk>
By author:    Matt Bernstein <mb/lkml@dcs.qmul.ac.uk>
In newsgroup: linux.dev.kernel
>
> I tried to subscribe to the autofs list, but majordomo isn't replying to 
> me! I think this is a problem in the automount daemon rather than the 
> kernel autofs code itself.
> 
> I'm trying to automount our home dirs as
> 	/homes/$USERNAME
> which should bind mount to
> 	:/home/$SERVER/$HOMENAME/$USERNAME
> which should bind mount to
> 	:/home/$SERVER/$VOLUME/$PATH/$USERNAME
> which (phew!) will be an NFS mount to
> 	$SERVER:/$VOLUME/$PATH/$USERNAME
> 
> The idea is that:
> 	(1) `/bin/pwd` = "/homes/$USERNAME"
> 	(2) when you run "quota" it'll only report for $SERVER:/$VOLUME
> 
> Now.. this all works perfectly if before looking at /homes/$USERNAME you
> look at firstly /home/$SERVER/$VOLUME/$PATH/$USERNAME and then secondly
> /home/$SERVER/$HOMENAME/$USERNAME, because the bind mounts have something
> to bind to. Of course you shouldn't need to know the middle bits, but you
> could look them up. Currently the binds mount fail and automount drops in
> symlinks; this satisfies (2)  above, but unfortunately not (1).
> 
> I hope someone can make sense of this. Is it different in autofs4?
> 

This is unfortunately nearly impossible to solve.  It's a known bug,
but it's questionable if anything can be done about it.

For right now, autofs cannot bind-mount to a mount from the same
automount point (the problem is with the double-use of /home/$SERVER
in your case.)

   	-hpa
-- 
<hpa@transmeta.com> at work, <hpa@zytor.com> in private!
"Unix gives you enough rope to shoot yourself in the foot."
http://www.zytor.com/~hpa/puzzle.txt	<amsp@zytor.com>

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: automount doesn't "follow" bind mounts
  2002-08-20 20:58 ` H. Peter Anvin
@ 2002-08-20 21:35   ` H. Peter Anvin
  2002-08-20 22:09     ` Benjamin LaHaise
  0 siblings, 1 reply; 9+ messages in thread
From: H. Peter Anvin @ 2002-08-20 21:35 UTC (permalink / raw)
  To: linux-kernel

Followup to:  <ajuahu$hf$1@cesium.transmeta.com>
By author:    "H. Peter Anvin" <hpa@zytor.com>
In newsgroup: linux.dev.kernel
>
> Followup to:  <Pine.LNX.4.44.0208201752430.23681-100000@r2-pc.dcs.qmul.ac.uk>
> By author:    Matt Bernstein <mb/lkml@dcs.qmul.ac.uk>
> In newsgroup: linux.dev.kernel
> >
> > I tried to subscribe to the autofs list, but majordomo isn't replying to 
> > me! I think this is a problem in the automount daemon rather than the 
> > kernel autofs code itself.
> > 
> > I'm trying to automount our home dirs as
> > 	/homes/$USERNAME
> > which should bind mount to
> > 	:/home/$SERVER/$HOMENAME/$USERNAME
> > which should bind mount to
> > 	:/home/$SERVER/$VOLUME/$PATH/$USERNAME
> > which (phew!) will be an NFS mount to
> > 	$SERVER:/$VOLUME/$PATH/$USERNAME
> > 
> > The idea is that:
> > 	(1) `/bin/pwd` = "/homes/$USERNAME"
> > 	(2) when you run "quota" it'll only report for $SERVER:/$VOLUME
> > 
> > Now.. this all works perfectly if before looking at /homes/$USERNAME you
> > look at firstly /home/$SERVER/$VOLUME/$PATH/$USERNAME and then secondly
> > /home/$SERVER/$HOMENAME/$USERNAME, because the bind mounts have something
> > to bind to. Of course you shouldn't need to know the middle bits, but you
> > could look them up. Currently the binds mount fail and automount drops in
> > symlinks; this satisfies (2)  above, but unfortunately not (1).
> > 
> > I hope someone can make sense of this. Is it different in autofs4?
> > 
> 
> This is unfortunately nearly impossible to solve.  It's a known bug,
> but it's questionable if anything can be done about it.
> 
> For right now, autofs cannot bind-mount to a mount from the same
> automount point (the problem is with the double-use of /home/$SERVER
> in your case.)
> 

Actually, if you're using autofs v3, which it sounds like you're
doing, it's even more broken, since autofs v3 doesn't support
multilevel mounts.

	-hpa
-- 
<hpa@transmeta.com> at work, <hpa@zytor.com> in private!
"Unix gives you enough rope to shoot yourself in the foot."
http://www.zytor.com/~hpa/puzzle.txt	<amsp@zytor.com>

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: automount doesn't "follow" bind mounts
  2002-08-20 21:35   ` H. Peter Anvin
@ 2002-08-20 22:09     ` Benjamin LaHaise
  2002-08-20 22:18       ` H. Peter Anvin
  2002-08-21  0:33       ` stoffel
  0 siblings, 2 replies; 9+ messages in thread
From: Benjamin LaHaise @ 2002-08-20 22:09 UTC (permalink / raw)
  To: H. Peter Anvin; +Cc: linux-kernel

On Tue, Aug 20, 2002 at 02:35:26PM -0700, H. Peter Anvin wrote:
> Actually, if you're using autofs v3, which it sounds like you're
> doing, it's even more broken, since autofs v3 doesn't support
> multilevel mounts.

Is there an autofs v4 daemon that's actually released?  The only thing I 
see is code that's over a year old in /pub/linux/daemons/autofs/testing-v4/ 
on kernel.org.  If pre10 is okay, it should be released (at least that 
would explain why we're still shipping v3).

		-ben
-- 
"You will be reincarnated as a toad; and you will be much happier."

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: automount doesn't "follow" bind mounts
  2002-08-20 22:09     ` Benjamin LaHaise
@ 2002-08-20 22:18       ` H. Peter Anvin
  2002-08-20 22:20         ` Benjamin LaHaise
  2002-08-21  0:33       ` stoffel
  1 sibling, 1 reply; 9+ messages in thread
From: H. Peter Anvin @ 2002-08-20 22:18 UTC (permalink / raw)
  To: Benjamin LaHaise; +Cc: linux-kernel

Benjamin LaHaise wrote:
> On Tue, Aug 20, 2002 at 02:35:26PM -0700, H. Peter Anvin wrote:
> 
>>Actually, if you're using autofs v3, which it sounds like you're
>>doing, it's even more broken, since autofs v3 doesn't support
>>multilevel mounts.
> 
> 
> Is there an autofs v4 daemon that's actually released?  The only thing I 
> see is code that's over a year old in /pub/linux/daemons/autofs/testing-v4/ 
> on kernel.org.  If pre10 is okay, it should be released (at least that 
> would explain why we're still shipping v3).
> 

The problem is that autofs v4 is completely unmaintained at the moment.

	-hpa



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: automount doesn't "follow" bind mounts
  2002-08-20 22:18       ` H. Peter Anvin
@ 2002-08-20 22:20         ` Benjamin LaHaise
  2002-08-20 22:21           ` H. Peter Anvin
  0 siblings, 1 reply; 9+ messages in thread
From: Benjamin LaHaise @ 2002-08-20 22:20 UTC (permalink / raw)
  To: H. Peter Anvin; +Cc: linux-kernel

On Tue, Aug 20, 2002 at 03:18:33PM -0700, H. Peter Anvin wrote:
> The problem is that autofs v4 is completely unmaintained at the moment.

Is there a todo list or known set of outstanding problems with it?

		-ben
-- 
"You will be reincarnated as a toad; and you will be much happier."

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: automount doesn't "follow" bind mounts
  2002-08-20 22:20         ` Benjamin LaHaise
@ 2002-08-20 22:21           ` H. Peter Anvin
  0 siblings, 0 replies; 9+ messages in thread
From: H. Peter Anvin @ 2002-08-20 22:21 UTC (permalink / raw)
  To: Benjamin LaHaise; +Cc: linux-kernel

Benjamin LaHaise wrote:
> On Tue, Aug 20, 2002 at 03:18:33PM -0700, H. Peter Anvin wrote:
> 
>>The problem is that autofs v4 is completely unmaintained at the moment.
> 
> 
> Is there a todo list or known set of outstanding problems with it?
> 

Not that I know of.  I don't believe the code has been analyzed for
races; in fact, it seems to me that there are inherent races in mount
point deconstruction.

	-hpa



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: automount doesn't "follow" bind mounts
  2002-08-20 22:09     ` Benjamin LaHaise
  2002-08-20 22:18       ` H. Peter Anvin
@ 2002-08-21  0:33       ` stoffel
  2002-08-21  0:35         ` H. Peter Anvin
  1 sibling, 1 reply; 9+ messages in thread
From: stoffel @ 2002-08-21  0:33 UTC (permalink / raw)
  To: Benjamin LaHaise; +Cc: H. Peter Anvin, linux-kernel

>>>>> "Benjamin" == Benjamin LaHaise <bcrl@redhat.com> writes:

Benjamin> Is there an autofs v4 daemon that's actually released?  The
Benjamin> only thing I see is code that's over a year old in
Benjamin> /pub/linux/daemons/autofs/testing-v4/ on kernel.org.  If
Benjamin> pre10 is okay, it should be released (at least that would
Benjamin> explain why we're still shipping v3).

Well, HPA says that pre10 has some serious problems, but it was the
only version I could get to work with our Solaris NIS environment and
out NetApps reliably.  I'd release the darn thing and let people send
in patches as needed.

John
   John Stoffel - Senior Unix Systems Administrator - Lucent Technologies
	 stoffel@lucent.com - http://www.lucent.com - 978-399-0479


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: automount doesn't "follow" bind mounts
  2002-08-21  0:33       ` stoffel
@ 2002-08-21  0:35         ` H. Peter Anvin
  0 siblings, 0 replies; 9+ messages in thread
From: H. Peter Anvin @ 2002-08-21  0:35 UTC (permalink / raw)
  To: stoffel; +Cc: Benjamin LaHaise, linux-kernel

stoffel@lucent.com wrote:
>>>>>>"Benjamin" == Benjamin LaHaise <bcrl@redhat.com> writes:
>>>>>
> 
> Benjamin> Is there an autofs v4 daemon that's actually released?  The
> Benjamin> only thing I see is code that's over a year old in
> Benjamin> /pub/linux/daemons/autofs/testing-v4/ on kernel.org.  If
> Benjamin> pre10 is okay, it should be released (at least that would
> Benjamin> explain why we're still shipping v3).
> 
> Well, HPA says that pre10 has some serious problems, but it was the
> only version I could get to work with our Solaris NIS environment and
> out NetApps reliably.  I'd release the darn thing and let people send
> in patches as needed.
> 

I said I *think* it is racy, mostly because noone has ever bothered
showing it to the contrary, and because I have failed to see how it
*couldn't* be.

	-hpa



^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2002-08-21  0:32 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-08-20 17:10 automount doesn't "follow" bind mounts Matt Bernstein
2002-08-20 20:58 ` H. Peter Anvin
2002-08-20 21:35   ` H. Peter Anvin
2002-08-20 22:09     ` Benjamin LaHaise
2002-08-20 22:18       ` H. Peter Anvin
2002-08-20 22:20         ` Benjamin LaHaise
2002-08-20 22:21           ` H. Peter Anvin
2002-08-21  0:33       ` stoffel
2002-08-21  0:35         ` H. Peter Anvin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox