From: Heiner Litz <hlitz@ucsc.edu>
To: Igor Konopko <igor.j.konopko@intel.com>
Cc: "Javier González" <javier@javigon.com>,
"Heiner Litz" <hlitz@ucsc.edu>,
"Matias Bjørling" <mb@lightnvm.io>,
"Hans Holmberg" <hans.holmberg@cnexlabs.com>,
linux-block@vger.kernel.org,
"Linux Kernel Mailing List" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] lightnvm: pblk: Introduce hot-cold data separation
Date: Fri, 26 Apr 2019 09:23:55 -0700 [thread overview]
Message-ID: <CAJbgVnWsHQRpEPkd77E6u0hoW5jKQaOGR-3dW9+drGNq_JYpfA@mail.gmail.com> (raw)
In-Reply-To: <a1df8967-2169-1c43-c55a-e2144fa53b9a@intel.com>
Nice catch Igor, I hadn't thought of that.
Nevertheless, here is what I think: In the absence of a flush we don't
need to enforce ordering so we don't care about recovering the older
gc'ed write. If we completed a flush after the user write, we should
have already invalidated the gc mapping and hence will not recover it.
Let me know if I am missing something.
On Fri, Apr 26, 2019 at 6:46 AM Igor Konopko <igor.j.konopko@intel.com> wrote:
>
>
>
> On 26.04.2019 12:04, Javier González wrote:
> >
> >> On 26 Apr 2019, at 11.11, Igor Konopko <igor.j.konopko@intel.com> wrote:
> >>
> >> On 25.04.2019 07:21, Heiner Litz wrote:
> >>> Introduce the capability to manage multiple open lines. Maintain one line
> >>> for user writes (hot) and a second line for gc writes (cold). As user and
> >>> gc writes still utilize a shared ring buffer, in rare cases a multi-sector
> >>> write will contain both gc and user data. This is acceptable, as on a
> >>> tested SSD with minimum write size of 64KB, less than 1% of all writes
> >>> contain both hot and cold sectors.
> >>
> >> Hi Heiner
> >>
> >> Generally I really like this changes, I was thinking about sth similar since a while, so it is very good to see that patch.
> >>
> >> I have a one question related to this patch, since it is not very clear for me - how you ensure the data integrity in following scenarios:
> >> -we have open line X for user data and line Y for GC
> >> -GC writes LBA=N to line Y
> >> -user writes LBA=N to line X
> >> -we have power failure when both line X and Y were not written completely
> >> -during pblk creation we are executing OOB metadata recovery
> >> And here is the question, how we distinguish whether LBA=N from line Y or LBA=N from line X is the valid one?
> >> Line X and Y might have seq_id either descending or ascending - this would create two possible scenarios too.
> >>
> >> Thanks
> >> Igor
> >>
> >
> > You are right, I think this is possible in the current implementation.
> >
> > We need an extra constrain so that we only GC lines above the GC line
> > ID. This way, when we order lines on recovery, we can guarantee
> > consistency. This means potentially that we would need several open
> > lines for GC to avoid padding in case this constrain forces to choose a
> > line with an ID higher than the GC line ID.
> >
> > What do you think?
>
> I'm not sure yet about your approach, I need to think and analyze this a
> little more.
>
> I also believe that probably we need to ensure that current user data
> line seq_id is always above the current GC line seq_id or sth like that.
> We cannot also then GC any data from the lines which are still open, but
> I believe that this is a case even right now.
>
> >
> > Thanks,
> > Javier
> >
next prev parent reply other threads:[~2019-04-26 16:24 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-25 5:21 [PATCH] lightnvm: pblk: Introduce hot-cold data separation Heiner Litz
2019-04-25 5:49 ` Javier González
2019-04-26 9:11 ` Igor Konopko
2019-04-26 10:04 ` Javier González
2019-04-26 13:46 ` Igor Konopko
2019-04-26 16:23 ` Heiner Litz [this message]
2019-05-01 6:19 ` Javier González
2019-05-01 20:20 ` Heiner Litz
2019-05-02 8:27 ` Javier González
2019-05-02 9:08 ` Igor Konopko
2019-05-06 5:16 ` Heiner Litz
2019-05-07 5:27 ` Javier González
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=CAJbgVnWsHQRpEPkd77E6u0hoW5jKQaOGR-3dW9+drGNq_JYpfA@mail.gmail.com \
--to=hlitz@ucsc.edu \
--cc=hans.holmberg@cnexlabs.com \
--cc=igor.j.konopko@intel.com \
--cc=javier@javigon.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mb@lightnvm.io \
/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).