[OpenBMC][Test Automation] Test Bmc Dump test failed
CS20 CHLi30
CHLI30 at nuvoton.com
Thu Jun 17 12:02:27 AEST 2021
Hi Rahul,
After using redfish create dump, we got all test items failed from redfish/managers/test_bmc_dumps.robot.
And we found that problem in bmcweb and test_bmc_dumps.robot. Thus, we have provided patches to fix this problem then test is PASS.
I also add you as reviewer, could you please help to check this issue and our patches? Thanks you.
Patch for test_bmc_dumps.robot:
https://gerrit.openbmc-project.xyz/c/openbmc/openbmc-test-automation/+/44161
redfish: managers: Fix extract dump id from correct dump location URI
Symptom:
Create User Initiated BMC Dump keyword return incorrect field
Root cause:
"Create User Initiated BMC Dump" HttpHeaders of Payload didn't return correct location
then cause dump id cannot get properly
Solution:
Extract dump id from correct dump location URI
Tested:
robot test PASS for "Test Bmc Dumps" from redfish/managers/test_bmc_dumps.robot
Patch for bmcweb:
https://gerrit.openbmc-project.xyz/c/openbmc/bmcweb/+/44006
redfish: log_services: fix createDump functionality of redfish
Symptom:
CreateDump resp_handler got error in bmcweb then report internal error.
Root cause:
1. createDump() function in bmcweb didn't support parameters as CreateDump() function
in phosphor-debug-collector then cause create dump through redfish all test items are failed.
2. createTask() function called by createDumpTaskCallback() in bmcweb didn't handle well with
member InterfacesAdded then cause match rule didn't match and return dbus error.
Solution:
1. Modify sync_method_call with object_path return type for CreateDump method call.
2. Modify match rule with member PropertiesChanged for bmc dump entry path.
Tested:
curl -k -H "X-Auth-Token: $token" -X POST https://${bmc}/redfish/v1/Managers/bmc/LogServices/Dump/Actions/LogService.CollectDiagnosticData
-d '{"DiagnosticDataType": "Manager"}'
Sincerely,
Tim
From: openbmc [mailto:openbmc-bounces+chli30=nuvoton.com at lists.ozlabs.org] On Behalf Of Rahul Maheshwari
Sent: Tuesday, May 25, 2021 3:25 PM
To: CS20 CHLi30 <CHLI30 at nuvoton.com>
Cc: CS20 KWLiu <KWLIU at nuvoton.com>; openbmc at lists.ozlabs.org
Subject: Re: [OpenBMC][Test Automation] Test Bmc Dump test failed
Hi Tim
`/redfish/extended/test_bmc_dump.robot` suite has usage of older xyz dump path. Can you make use of `redfish/managers/test_bmc_dumps.robot` suite to run the dump automation test? This suite has usage of recent Redfish dump uri implementation i.e. /redfish/v1/Managers/bmc/LogServices/Dump.
Thanks
Rahul
On Thu, May 20, 2021 at 10:00 AM CS20 CHLi30 <CHLI30 at nuvoton.com<mailto:CHLI30 at nuvoton.com>> wrote:
Hi All,
We found that some of "Test Bmc Dump" items are failed when we run test automation.
After checking log and source code that seems relate to return type of CreateDump() in phosphor-debug-collector
is not consistent with OpenBMC-Test-Automation/redfish/extended/test_bmc_dump.robot.
Seems we need to modify test_bmc_dump.robot about return type from "Create User Initiated Dump" keyword
from ${dump_id} to object_path according current CreateDump() implementation in phosphor-debug-collector, am I right?
Summary:
CreateDump() change return type from uint32_t to object_path from this commit:
https://github.com/openbmc/phosphor-debug-collector/commit/6ccb50e133342d20d2758c3efc3f8b429abcbf90#diff-6053a5177ee8dcedec88c55df4de554b5a54497f92b041e1585c6770236773a1<https://apc01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fopenbmc%2Fphosphor-debug-collector%2Fcommit%2F6ccb50e133342d20d2758c3efc3f8b429abcbf90%23diff-6053a5177ee8dcedec88c55df4de554b5a54497f92b041e1585c6770236773a1&data=04%7C01%7Cchli30%40nuvoton.com%7C00069a126c024c78854208d91f4e4631%7Ca3f24931d4034b4a94f17d83ac638e07%7C0%7C0%7C637575943652844341%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=ToC4ABFr7NkmzgFIJWC0HXoO6FGKe15gqZW345jvIec%3D&reserved=0>
However, in OpenBMC-Test-Automation/redfish/extended/test_bmc_dump.robot
Verify User Initiated BMC Dump When Powered Off
[Documentation] Create user initiated BMC dump at host off state and
... verify dump entry for it.
[Tags] Verify_User_Initiated_BMC_Dump_When_Powered_Off
Redfish Power Off stack_mode=skip
${dump_id}= Create User Initiated Dump
Check Existence Of BMC Dump File ${dump_id}
Run keyword "Create User Initiated Dump" still using dump id (uint32_t) to check create bmc dump functionality.
Thus, we got error message from "Check Existence Of BMC Dump File ${dump_id}" as below:
Evaluating expression '/xyz/openbmc_project/dump/bmc/entry/1 == None' failed: SyntaxError: invalid syntax.
Repo steps:
Run test automation: robot -t Verify_User_Initiated_BMC_Dump_When_Powered_Off redfish/extended/test_bmc_dump.robot
Symptom:
screenshot from test automation report for you refer it.
[cid:image001.jpg at 01D7635D.7AA549C0]
Sincerely,
Tim
________________________________
The privileged confidential information contained in this email is intended for use only by the addressees as indicated by the original sender of this email. If you are not the addressee indicated in this email or are not responsible for delivery of the email to such a person, please kindly reply to the sender indicating this fact and delete all copies of it from your computer and network server immediately. Your cooperation is highly appreciated. It is advised that any unauthorized use of confidential information of Nuvoton is strictly prohibited; and any information in this email irrelevant to the official business of Nuvoton shall be deemed as neither given nor endorsed by Nuvoton.
________________________________
The privileged confidential information contained in this email is intended for use only by the addressees as indicated by the original sender of this email. If you are not the addressee indicated in this email or are not responsible for delivery of the email to such a person, please kindly reply to the sender indicating this fact and delete all copies of it from your computer and network server immediately. Your cooperation is highly appreciated. It is advised that any unauthorized use of confidential information of Nuvoton is strictly prohibited; and any information in this email irrelevant to the official business of Nuvoton shall be deemed as neither given nor endorsed by Nuvoton.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ozlabs.org/pipermail/openbmc/attachments/20210617/f2244977/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.jpg
Type: image/jpeg
Size: 45886 bytes
Desc: image001.jpg
URL: <http://lists.ozlabs.org/pipermail/openbmc/attachments/20210617/f2244977/attachment-0001.jpg>
More information about the openbmc
mailing list