* PGLog::rewind_divergent_log use case
@ 2013-06-08 8:16 Loic Dachary
2013-06-10 23:02 ` Samuel Just
0 siblings, 1 reply; 3+ messages in thread
From: Loic Dachary @ 2013-06-08 8:16 UTC (permalink / raw)
To: Samuel Just; +Cc: Ceph Development
[-- Attachment #1.1: Type: text/plain, Size: 1188 bytes --]
[Note: ceph-devel cc'ed]
Hi Sam,
While trying to create the conditions for the following to happen in PGLog::rewind_divergent_log:
if (p == log.log.begin()) {
// yikes, the whole thing is divergent!
divergent.swap(log.log);
break;
}
https://github.com/ceph/ceph/blob/master/src/osd/PGLog.cc#L355
I created this ( matching the drawing attached ), and the test case works.
{
pg_log_entry_t e;
info.log_tail = log.tail = eversion_t(1, 1);
newhead = eversion_t(1, 3);
e.version = divergent_version = eversion_t(1, 5);
e.soid.hash = 0x9;
divergent_object = e.soid;
e.op = pg_log_entry_t::DELETE;
e.prior_version = prior_version = eversion_t(0, 2);
log.log.push_back(e);
log.head = e.version;
}
https://github.com/dachary/ceph/commit/d592d7f10968c56139cb470a4111ddfbe08a4030#L0R136
But it does not look like a situation that is actually going to happen. I feel something is missing and a hint would be much appreciated :-)
Cheers
--
Loïc Dachary, Artisan Logiciel Libre
All that is necessary for the triumph of evil is that good people do nothing.
[-- Attachment #1.2: a.png --]
[-- Type: image/png, Size: 6068 bytes --]
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 262 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: PGLog::rewind_divergent_log use case
2013-06-08 8:16 PGLog::rewind_divergent_log use case Loic Dachary
@ 2013-06-10 23:02 ` Samuel Just
2013-06-11 19:51 ` Loic Dachary
0 siblings, 1 reply; 3+ messages in thread
From: Samuel Just @ 2013-06-10 23:02 UTC (permalink / raw)
To: Loic Dachary; +Cc: Ceph Development
I think that case may be possible, and that the assert may be wrong.
We have probably never seen a problem there due to
osd_min_pg_log_entries. It's also possible that there is a subtle bug
between there and calc_acting().
-Sam
On Sat, Jun 8, 2013 at 1:16 AM, Loic Dachary <loic@dachary.org> wrote:
> [Note: ceph-devel cc'ed]
>
> Hi Sam,
>
> While trying to create the conditions for the following to happen in PGLog::rewind_divergent_log:
>
> if (p == log.log.begin()) {
> // yikes, the whole thing is divergent!
> divergent.swap(log.log);
> break;
> }
>
> https://github.com/ceph/ceph/blob/master/src/osd/PGLog.cc#L355
>
> I created this ( matching the drawing attached ), and the test case works.
>
> {
> pg_log_entry_t e;
>
> info.log_tail = log.tail = eversion_t(1, 1);
> newhead = eversion_t(1, 3);
> e.version = divergent_version = eversion_t(1, 5);
> e.soid.hash = 0x9;
> divergent_object = e.soid;
> e.op = pg_log_entry_t::DELETE;
> e.prior_version = prior_version = eversion_t(0, 2);
> log.log.push_back(e);
> log.head = e.version;
> }
>
> https://github.com/dachary/ceph/commit/d592d7f10968c56139cb470a4111ddfbe08a4030#L0R136
>
> But it does not look like a situation that is actually going to happen. I feel something is missing and a hint would be much appreciated :-)
>
> Cheers
>
> --
> Loïc Dachary, Artisan Logiciel Libre
> All that is necessary for the triumph of evil is that good people do nothing.
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: PGLog::rewind_divergent_log use case
2013-06-10 23:02 ` Samuel Just
@ 2013-06-11 19:51 ` Loic Dachary
0 siblings, 0 replies; 3+ messages in thread
From: Loic Dachary @ 2013-06-11 19:51 UTC (permalink / raw)
To: Samuel Just; +Cc: Ceph Development
[-- Attachment #1: Type: text/plain, Size: 2312 bytes --]
Hi Sam,
I took a look at calc_acting and I can't figure out enough to create a bug report. There are checks based on last_update and tail but it is difficult go infer how it relates to the rewind_divergent_log function. If you can connect the dots for me I'd be happy to write down a proper bug report ;-)
Cheers
On 06/11/2013 01:02 AM, Samuel Just wrote:
> I think that case may be possible, and that the assert may be wrong.
> We have probably never seen a problem there due to
> osd_min_pg_log_entries. It's also possible that there is a subtle bug
> between there and calc_acting().
> -Sam
>
> On Sat, Jun 8, 2013 at 1:16 AM, Loic Dachary <loic@dachary.org> wrote:
>> [Note: ceph-devel cc'ed]
>>
>> Hi Sam,
>>
>> While trying to create the conditions for the following to happen in PGLog::rewind_divergent_log:
>>
>> if (p == log.log.begin()) {
>> // yikes, the whole thing is divergent!
>> divergent.swap(log.log);
>> break;
>> }
>>
>> https://github.com/ceph/ceph/blob/master/src/osd/PGLog.cc#L355
>>
>> I created this ( matching the drawing attached ), and the test case works.
>>
>> {
>> pg_log_entry_t e;
>>
>> info.log_tail = log.tail = eversion_t(1, 1);
>> newhead = eversion_t(1, 3);
>> e.version = divergent_version = eversion_t(1, 5);
>> e.soid.hash = 0x9;
>> divergent_object = e.soid;
>> e.op = pg_log_entry_t::DELETE;
>> e.prior_version = prior_version = eversion_t(0, 2);
>> log.log.push_back(e);
>> log.head = e.version;
>> }
>>
>> https://github.com/dachary/ceph/commit/d592d7f10968c56139cb470a4111ddfbe08a4030#L0R136
>>
>> But it does not look like a situation that is actually going to happen. I feel something is missing and a hint would be much appreciated :-)
>>
>> Cheers
>>
>> --
>> Loïc Dachary, Artisan Logiciel Libre
>> All that is necessary for the triumph of evil is that good people do nothing.
> --
> To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
Loïc Dachary, Artisan Logiciel Libre
All that is necessary for the triumph of evil is that good people do nothing.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 262 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-06-11 19:51 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-08 8:16 PGLog::rewind_divergent_log use case Loic Dachary
2013-06-10 23:02 ` Samuel Just
2013-06-11 19:51 ` Loic Dachary
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.