Add support to flush out system dumps
Changes:
- Added keyword to delete system dumps.
- Call the new keyword at boot test and clean up path.
Change-Id: Ibdb880b7e0ad07b9097b3c97701fea72c2d4f28a
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
diff --git a/extended/standby_bmc.robot b/extended/standby_bmc.robot
index f5129f6..d7ecc5c 100644
--- a/extended/standby_bmc.robot
+++ b/extended/standby_bmc.robot
@@ -96,6 +96,7 @@
Run Keyword And Ignore Error Redfish Set Power Restore Policy AlwaysOff
Run Keyword And Ignore Error Redfish Purge Event Log
Run Keyword And Ignore Error Redfish Delete All BMC Dumps
+ Run Keyword And Ignore Error Redfish Delete All System Dumps
Run Keyword And Ignore Error Delete All Redfish Sessions
diff --git a/lib/dump_utils.robot b/lib/dump_utils.robot
index b8acd21..eadae80 100644
--- a/lib/dump_utils.robot
+++ b/lib/dump_utils.robot
@@ -176,6 +176,12 @@
Redfish.Post /redfish/v1/Managers/bmc/LogServices/Dump/Actions/LogService.ClearLog
+Redfish Delete All System Dumps
+ [Documentation] Delete all system dumps via Redfish.
+
+ Redfish.Post /redfish/v1/Systems/system/LogServices/Dump/Actions/LogService.ClearLog
+
+
Delete All BMC Dump
[Documentation] Delete all BMC dump entries using "DeleteAll" interface.
diff --git a/lib/obmc_boot_test.py b/lib/obmc_boot_test.py
index 41cfd4e..1729ed1 100755
--- a/lib/obmc_boot_test.py
+++ b/lib/obmc_boot_test.py
@@ -82,6 +82,7 @@
else:
delete_errlogs_cmd = "Redfish Purge Event Log"
delete_bmcdump_cmd = "Redfish Delete All BMC Dumps"
+ delete_sysdump_cmd = "Redfish Delete All System Dumps"
default_set_power_policy = "Redfish Set Power Restore Policy AlwaysOff"
else:
default_power_on = "REST Power On"
@@ -983,6 +984,8 @@
# We need to purge error logs between boots or they build up.
grk.run_key(delete_errlogs_cmd, ignore=1)
grk.run_key(delete_bmcdump_cmd, ignore=1)
+ if redfish_support_trans_state:
+ grk.run_key(delete_sysdump_cmd, ignore=1)
boot_results.print_report()
gp.qprint_timen("Finished boot " + str(boot_count) + ".")
@@ -1171,6 +1174,8 @@
# Delete errlogs prior to doing any boot tests.
grk.run_key(delete_errlogs_cmd, ignore=1)
grk.run_key(delete_bmcdump_cmd, ignore=1)
+ if redfish_support_trans_state:
+ grk.run_key(delete_sysdump_cmd, ignore=1)
# Process caller's boot_stack.
while (len(boot_stack) > 0):