From: Anand Jain <Anand.Jain@oracle.com>
To: linux-btrfs@vger.kernel.org
Cc: Duncan <1i5t5.duncan@cox.net>
Subject: Re: btrfs multiple mounts stacked on the same mount point
Date: Wed, 12 Feb 2014 11:37:35 +0800 [thread overview]
Message-ID: <52FAEC7F.4050707@oracle.com> (raw)
In-Reply-To: <pan$9211b$42bef7b0$dd1350ae$978558c5@cox.net>
Thanks.
In the context of btrfs,
what is the critical need of this feature ?
OR
what is that it can't do without this feature ?
Thanks, Anand
On 02/12/14 04:57 AM, Duncan wrote:
> Anand Jain posted on Tue, 11 Feb 2014 16:18:02 +0800 as excerpted:
>
>> per mount(2)
>>
>> ---
>> multiple mounts can be stacked on the same mount point.
>> ---
>>
>> In this situation how could ioctl communicate (using mount point) with
>> each FS stacked on the same mount point ?
>>
>> BTW I don't understand the need for multiple mounts on the same mount
>> point ?
>
> The most common case of multiple over-mounts is almost certainly the
> kernel's built-in rootfs in RAM, usually as an initramfs or initrd, with
> real-root often directly over-mounted the same mountpoint, tho it can
> also be mounted elsewhere on the initramfs.
>
> The various union-filesystem solutions also directly use over-mounting,
> with the read-only mount often directly over-mounted with the writable
> but semi-transparent overlay, such that if a file hasn't changed from the
> read-only version on the under-mount, that's the version that gets used.
>
> Otherwise, over-mounts generally obscure what's underneath them, making
> direct access to it impossible, unless that underneath filesystem is bind-
> mounted elsewhere.
>
> (Which is actually how I backup my root filesystem, using a bind-mount to
> mount it elsewhere for the backup, so for instance the /dev/console and
> /dev/null device nodes located directly on root get copied over to my
> backup root as well, instead of the devtmpfs content otherwise over-
> mounted on /dev.)
>
> That principle of over-mount obscuring what's beneath it should apply to
> the ioctls as well. They will always communicate with the top mounted
> layers. To communicate with anything underneath, the over-mounting
> layers will either need umounted, or (if it's not the exact same
> mountpoint, which might have been your point) a bind-mount of the under-
> mount can be used.
>
> But an over-mount obscuring under-mounts is how Linux (and I believe POSIX
> in general) normally works. (The semi-transparent union-filesystem
> solutions mentioned above thus being exceptions with those exceptions
> being the hairy bits, that explaining the several implementations with
> their various limitations and bugs.) So not being able to access under-
> mounts is the normal state of affairs. =:^)
>
next prev parent reply other threads:[~2014-02-12 3:37 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-11 8:18 btrfs multiple mounts stacked on the same mount point Anand Jain
2014-02-11 20:57 ` Duncan
2014-02-12 3:37 ` Anand Jain [this message]
2014-02-12 5:15 ` Duncan
2014-02-12 7:36 ` Anand Jain
2014-02-12 13:17 ` Duncan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=52FAEC7F.4050707@oracle.com \
--to=anand.jain@oracle.com \
--cc=1i5t5.duncan@cox.net \
--cc=linux-btrfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.