Allow kdump/crash-sysrq-c to run the 2nd part of the test when executed by tmt

After a system reboot from a kernel panic, kdump/crash-sysrq-c is supposed to continue the 2nd part of the test. However, currently when executed by tmt, the 2nd part of the test doesn't run because of the TMT_TEST_RESTART_COUNT == 1 check.

Actually kdump/crash-sysrq-c will create K_REBOOT file to tell if a system just reboots from a kernel panic. So there is no need to use TMT_TEST_RESTART_COUNT to make sure a kernel panic is only triggered once. But when tmt restarts the test, K_REBOOT file will be deleted when tmt synchronize the test data with the test machine. So instead of creating K_REBOOT file as TMT_TEST_PLAN/discover/NFS-kdump-tests/tests/kdump/crash-sysrq/KDUMP-REBOOT, save it to /var/local/kdump_tmt_test.

Note

  1. With commit 0d617b21 ("kdump/restraint: fix test failures caused by sync issue"), /tmp/rstrntsync.sock will be deleted automatically. So there is no need to delete this file in kdump/crash-sysrq-c.

  2. The 2nd part of kdump/crash-sysrq-c test will check for existence of vmcore. But it only works for local dumping. For NFS/SSH dumping, set PANIC_VMCORE_CHECK=false to skip it. And check vmcore using the analyse-crash-cmd/simple_check test after the copy-nfs test

Reported-by: Xiaoying Yan yiyan@redhat.com Signed-off-by: Coiby Xu coiby.xu@gmail.com

Testing farm job that runs the 2nd part of crash-sysrq test: https://artifacts.osci.redhat.com/testing-farm/37341a6d-e500-4b8f-8d66-de95173a3d1a/

Merge request reports

Loading