Skip to content
Commit bb9366d0 authored by Tim Lee's avatar Tim Lee
Browse files

Adjust current size of total dump files in dump directory



Symptom:
"Verify Maximum BMC Dump Creation" test item got failed sometimes.
This test item expect that dump space is enough to create a new BMC dump file.
But, dump manager doesn't think dump space is enough to create
according to current size of dump directory.

Root cause:
dump manager is using std::filesystem::file_size to calculate total size of
dump log files in dump directory. Then total size is divided by 1024
convert to KB. However, test item is using linux command "du -s" to calculate
total size of dump log files in dump directory.
The calculation result is different between dump manager and test item
then cause test got failed sometimes.

Solution:
calculate each dump file with std::ceil() and convert size to KB then
calculate total dump files size in dump directory. That's can reduce size
difference of total dump files between dump manager
and test item then avoid this test got failed.

Tested:
Run 3~4 times robot
Verify_Maximum_BMC_Dump_Creation redfish/managers/test_bmc_dumps.robot
Verify Maximum BMC Dump Creation :: Create maximum BMC dump and ve... | PASS |
1 critical test, 1 passed, 0 failed
1 test total, 1 passed, 0 failed

Signed-off-by: default avatarTim Lee <timlee660101@gmail.com>
Change-Id: Ic1a6d941d12516678ff21789355941653d319858
parent 6341919f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment