Testing crash consistency

38 views
Skip to first unread message

steve

unread,
Jun 19, 2020, 1:01:49 PM6/19/20
to pmem
Hi all,

I'm starting to work on crash consistency and it appears that it's going to be very difficult to test.

Flushes can be done by the O/S and/or hardware at any time, and are likely to happen before a programmed or otherwise artificially created power
outage. This means that it's likely that a test would show my data to be consistent even if I missed a situation in the code where a power failure
would make it inconsistent.

So how can I test that I can handle a power outage happening at any point during my transaction commit phase? Are there tools to simulate such events
at a predictable point in the flushing operation?

Thanks!
------------
Steve Heller

steve

unread,
Jun 19, 2020, 1:33:48 PM6/19/20
to st...@steveheller.org, pmem
Hi all again,

It looks as though "Intel® Inspector - Persistence Inspector" (apparently named by the Department of Redundancy Department) should do what I need,
assuming it is still available. Is it part of Intel System Studio?
------------
Steve Heller

Anton Gavriliuk

unread,
Jun 19, 2020, 2:12:24 PM6/19/20
to Steve, pmem
Hi Steve

> So how can I test that I can handle a power outage happening at any point during my transaction commit phase? Are there tools to simulate such events at a predictable point in the flushing operation?

Probably you may use sys_rq on Linux


Anton 

пт, 19 июн. 2020 г. в 20:33, steve <st...@steveheller.org>:
--
You received this message because you are subscribed to the Google Groups "pmem" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pmem+uns...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pmem/78tpef962nks07696281r5hvpqnr35vgoe%404ax.com.

ppbb...@gmail.com

unread,
Jun 19, 2020, 2:23:19 PM6/19/20
to pmem
Persistence Inspector is very much available here, you can read more about it here:

With PMDK, we use our own valgrind tool, pmemcheck, to detect various issues:

For comprehensive crash consistency checking, we record all stores made by an application using the aforementioned pmemcheck, and then run it through pmreorder:

You can learn more about those tools and how they can be used in Chapter 12 of the Programming Persistent Memory book:

Piotr

steve

unread,
Jun 19, 2020, 4:36:37 PM6/19/20
to ppbb...@gmail.com, pmem
Thanks, I'll use Persistence Inspector once I have written the code that I want it to inspect.

On Fri, 19 Jun 2020 11:23:19 -0700 (PDT), <ppbb...@gmail.com> wrote:

>Persistence Inspector is very much available here, you can read more about
>it here:
>https://software.intel.com/content/www/us/en/develop/articles/detect-persistent-memory-programming-errors-with-intel-inspector-persistence-inspector.html
>
>With PMDK, we use our own valgrind tool, pmemcheck, to detect various
>issues:
>https://github.com/pmem/valgrind
>
>For comprehensive crash consistency checking, we record all stores made by
>an application using the aforementioned pmemcheck, and then run it through
>pmreorder:
>https://github.com/pmem/pmdk/tree/master/src/tools/pmreorder
>https://pmem.io/pmdk/manpages/linux/master/pmreorder/pmreorder.1.html
>
>You can learn more about those tools and how they can be used in Chapter 12
>of the Programming Persistent Memory book:
>https://link.springer.com/chapter/10.1007/978-1-4842-4932-1_12
>
>Piotr
>
>pi?tek, 19 czerwca 2020 o 20:12:24 UTC+2 antos...@gmail.com napisa?(a):
>
>> Hi Steve
>>
>> > So how can I test that I can handle a power outage happening at any
>> point during my transaction commit phase? Are there tools to simulate such
>> events at a predictable point in the flushing operation?
>>
>> Probably you may use sys_rq on Linux
>>
>> https://www.kernel.org/doc/html/v4.10/admin-guide/sysrq.html
>>
>> Anton
>>
>> ??, 19 ???. 2020 ?. ? 20:33, steve <st...@steveheller.org>:
------------
Steve Heller
Reply all
Reply to author
Forward
0 new messages