linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Vojtech Pavlik <vojtech@ucw.cz>
To: Pavel Machek <pavel@ucw.cz>
Cc: Theodore Ts'o <tytso@mit.edu>,
	Reindl Harald <h.reindl@thelounge.net>,
	linux-ext4@vger.kernel.org,
	kernel list <linux-kernel@vger.kernel.org>,
	kent.overstreet@gmail.com, linux-bcache@vger.kernel.org
Subject: Re: bcache with existing ext4 filesystem
Date: Tue, 25 Jul 2017 12:32:48 +0200	[thread overview]
Message-ID: <20170725103248.GA12869@suse.com> (raw)
In-Reply-To: <20170725064304.GA11723@amd>

On Tue, Jul 25, 2017 at 08:43:04AM +0200, Pavel Machek wrote:
> On Tue 2017-07-25 00:51:56, Theodore Ts'o wrote:
> > On Mon, Jul 24, 2017 at 10:04:51PM +0200, Pavel Machek wrote:
> > > Question for you was... Is the first 1KiB of each ext4 filesystem still
> > > free and "reserved for a bootloader"?
> > 
> > Yes.
> 
> Thanks.
> 
> > > If I needed more for bcache superblock (8KiB, IIRC), would that be
> > > easy to accomplish on existing filesystem?
> > 
> > Huh?  Why would the bcache superblock matter when you're talking about
> > the ext4 layout?  The bcache superblock will be on the bcache
> > device/partition, and the ext4 superblock will be on the ext4
> > device/partition.
> 
> I'd like to enable bcache on already existing ext4 partition. AFAICT
> normal situation, even on the backing device, is:
> 
> | 8KiB bcache superblock | 1KiB reserved | ext4 superblock | 400GB data |
> 
> Unfortunately, that would mean shifting 400GB data 8KB forward, and
> compatibility problems. So I'd prefer adding bcache superblock into
> the reserved space, so I can have caching _and_ compatibility with
> grub2 etc (and avoid 400GB move):

The common way to do that is to move the beginning of the partition,
assuming your ext4 lives in a partition.

I don't see how overlapping the ext4 and the bcache backing device
starts would give you what you want, because bcache assumes the
backing device data starts with an offset.

-- 
Vojtech Pavlik

  reply	other threads:[~2017-07-25 10:32 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-24 18:57 bcache with existing ext4 filesystem Pavel Machek
2017-07-24 19:08 ` Reindl Harald
2017-07-24 19:15   ` Pavel Machek
2017-07-24 19:27     ` Theodore Ts'o
2017-07-24 20:04       ` Pavel Machek
2017-07-25  4:51         ` Theodore Ts'o
2017-07-25  6:43           ` Pavel Machek
2017-07-25 10:32             ` Vojtech Pavlik [this message]
2017-07-25 11:12               ` Pavel Machek
2017-07-25 16:10                 ` Theodore Ts'o
2017-07-25 18:13                 ` Eric Wheeler
2017-07-25 22:02                   ` Pavel Machek
2017-07-26 17:41                     ` Eric Wheeler
2017-07-26 18:59                       ` Austin S. Hemmelgarn
2017-07-26 19:16                         ` Eric Wheeler
2017-07-26 20:01                       ` Pavel Machek
2017-07-25 13:46           ` Pavel Machek
2017-07-25 18:02             ` Theodore Ts'o
2017-07-25 20:55               ` Pavel Machek

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=20170725103248.GA12869@suse.com \
    --to=vojtech@ucw.cz \
    --cc=h.reindl@thelounge.net \
    --cc=kent.overstreet@gmail.com \
    --cc=linux-bcache@vger.kernel.org \
    --cc=linux-ext4@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pavel@ucw.cz \
    --cc=tytso@mit.edu \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).