"Steve M. Robbins" <[EMAIL PROTECTED]> writes:

> The bug report requested to use --rbind rather than --bind
> for session-managed plain chroots.
>
> However; the patch to setup/10mount that you posted, Roger, 
> includes an extra bit:
>
> -     do_mount "-t proc"    "proc"     "${CHROOT_PATH}/proc"
> -     do_mount "-o rw,bind" "/dev/pts" "${CHROOT_PATH}/dev/pts"
> -     do_mount "-t tmpfs"   "tmpfs"    "${CHROOT_PATH}/dev/shm"
> -     do_mount "-o rw,bind" "/home"    "${CHROOT_PATH}/home"
> -     do_mount "-o rw,bind" "/tmp"     "${CHROOT_PATH}/tmp"
> +     if [ "$CHROOT_TYPE" != "plain" ]; then
> +         do_mount "-t proc"    "proc"     "${CHROOT_PATH}/proc"
> +         do_mount "-o rw,bind" "/dev/pts" "${CHROOT_PATH}/dev/pts"
> +         do_mount "-t tmpfs"   "tmpfs"    "${CHROOT_PATH}/dev/shm"
> +         do_mount "-o rw,bind" "/home"    "${CHROOT_PATH}/home"
> +         do_mount "-o rw,bind" "/tmp"     "${CHROOT_PATH}/tmp"
> +     fi
>
> In short, you disabled mounting /home when using a plain type
> of chroot.  Clearly this is deliberate.  How may I obtain the
> original behaviour?

The "plain" type was never intended to do all the automatic mounts;
that was a workaround for the missing --rbind support.  Now --rbind is
supported, you can just mount them under the chroot location (e.g. in
/etc/fstab) and --rbind will rebind them all under the session mount
location when you start a session.

Because the automatic mounting is being used by a few people, and it
is a convenient way to do things, I'm going to introduce a new chroot
type which will be "plain+mounts".  This won't be the default, but
will provide the functionality you want.

I hope to add this before the next release (0.99.2).  It's not a great
deal of work; the most difficult bit is finding a suitable name for
the chroot type!  Any ideas are welcome!


Regards,
Roger

-- 
Roger Leigh
                Printing on GNU/Linux?  http://gutenprint.sourceforge.net/
                Debian GNU/Linux        http://www.debian.org/
                GPG Public Key: 0x25BFB848.  Please sign and encrypt your mail.

Attachment: pgpVizZWYEFEX.pgp
Description: PGP signature

Reply via email to