Re: ec overwrite issue

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Sep 29, 2017 at 3:02 AM, Xinze Chi (信泽) <xmdxcxz@xxxxxxxxx> wrote:
> hi, all
>
>     I confuse the roll_forward logic in the PG::append_log. The
> pg_log.roll_forward func may roll forward the all inflight
> transactions which maybe not be completed by all shards.
>
>     The comment also makes me wonder. so could anyone explain it in
> detail. thanks.
>
>
>   if (!transaction_applied) {
>      /* We must be a backfill peer, so it's ok if we apply
>       * out-of-turn since we won't be considered when
>       * determining a min possible last_update.
>       */
>     pg_log.roll_forward(&handler);
>   }
>
>     /* We don't want to leave the rollforward artifacts around
>      * here past last_backfill.  It's ok for the same reason as
>      * above */
>     if (transaction_applied &&
>        p->soid > info.last_backfill) {
>       pg_log.roll_forward(&handler);
>     }

transaction_applied can only be false if we are being backfilled. If
we are being backfilled, we may not *have* the older data that we
would rollback to, and our peers don't rely on us having that data. So
there's no point in our trying to keep rollback data around, and
keeping it around would mean finding a way to clean it up later. Thus,
delete it now.
-Greg
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [CEPH Users]     [Ceph Large]     [Information on CEPH]     [Linux BTRFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux