Hi Hatayama,
On Thu, Feb 15, 2024 at 6:08 PM HATAYAMA Daisuke <d.hatayama(a)fujitsu.com> wrote:
I've made a RFC patch set to make sanity check of page descriptor
table in kdump compressed format strict.
This work has arose from the past issue that a produced crash dump
file was broken not only in data segment but also in headers including
page descriptor table. I've ever explained a bit this on crash-devel
in the following thread:
https://listman.redhat.com/archives/crash-utility/2023-September/010957.html
In this past issue, I couldn't find out its root cause after all
because when I began investigating the issue, problematic system where
the issue was reproduced was already unavailable.
This patch set is aimed at allowing us to figure out this kind of
issue more quickly and in more detail using crash utility. The code is
based on the tool I made to analyze the broken crash dump in the past
issue.
This is still incomplete, for example, the sanity check has not yet
supported split dump files in the kdump-compressed format and old
header version up to 5. It would be appreciated if I can get comments
for this RFC version.
I think this is a nice patchset, so we can have a verification if some
kdump data is corrupt. Just for curiosity, shouldn't makedumpfile
implement a similar function? I thought of 2 solutions: 1)
makedumpfile compress and write one block, then verify the validity of
it, then continue for the next one, until all blocks are written and
verified. 2) or makedumpfile create and write the kdump file, then
verify the whole file like what the code do here in crash, then exit
with the status of verification. What do you think?
Thanks,
Tao Liu
HATAYAMA Daisuke (9):
diskdump: Add stat object in diskdump_data
diskdump: Add function sanity_check_page_desc() that sanity checks an
entry of page descriptor table
diskdump: Add function check_kdump_headers() that validates page
descriptor table
defs.h: Introduce flag VALIDATE_KDUMP_HEADERS
diskdump, main: Add --validate_kdump_headers command-line option
diskdump: Make sanity check in cache_page() strict
help: Add description of --validate_kdump_headers command-line option
man: Add description of --validate_kdump_headers command-line option
diskdump, debug: Print elapsed time consumed in validation of page
descriptor table
crash.8 | 4 +++
defs.h | 1 +
diskdump.c | 74 +++++++++++++++++++++++++++++++++++++++++++++++++++++-
help.c | 4 +++
main.c | 5 ++++
5 files changed, 87 insertions(+), 1 deletion(-)
--
2.43.1
--
Crash-utility mailing list -- devel(a)lists.crash-utility.osci.io
To unsubscribe send an email to devel-leave(a)lists.crash-utility.osci.io
https://${domain_name}/admin/lists/devel.lists.crash-utility.osci.io/
Contribution Guidelines:
https://github.com/crash-utility/crash/wiki