DMTF / Redfish-Usecase-Checkers

This is a collection of python3 tools to exercise and validate common use cases for Redfish
Other
1 stars 6 forks source link

Added tracking of system URIs incase the URI cannot be built based on Ids #30

Closed mraineri closed 4 years ago

mraineri commented 4 years ago

Also added checking if the PowerState property is present before trying to use it.

Fix #29

gkeishin commented 4 years ago
$ git  clone -b Power-Control-Error-Handling https://github.com/DMTF/Redfish-Usecase-Checkers
Cloning into 'Redfish-Usecase-Checkers'...
remote: Enumerating objects: 4, done.
remote: Counting objects: 100% (4/4), done.
remote: Compressing objects: 100% (4/4), done.
remote: Total 274 (delta 0), reused 2 (delta 0), pack-reused 270
Receiving objects: 100% (274/274), 71.39 KiB | 0 bytes/s, done.
Resolving deltas: 100% (140/140), done.
gkeishin@ ~/DMTF/Redfish-Usecase-Checkers
$ git branch
* Power-Control-Error-Handling
$ python3 Redfish-Usecase-Checkers/power_control/power_control.py -r xx.xx.xx.xx -u root -p 0penBmc -S Always
Found 1 system instances
Resetting WITHERSPOON_0006 using On
Resetting WITHERSPOON_0006 using ForceOff
Resetting WITHERSPOON_0006 using ForceOn
Resetting WITHERSPOON_0006 using ForceRestart
Resetting WITHERSPOON_0006 using GracefulRestart
Resetting WITHERSPOON_0006 using GracefulShutdown
Resetting WITHERSPOON_0006 using PowerCycle
Resetting WITHERSPOON_0006 using Nmi

Thanks @mraineri for the fix. The changes works like charm. Apprciated

mraineri commented 4 years ago

Thanks for verifying! We'll likely get this in officially next week during the next group review.

gkeishin commented 4 years ago

Sure thing. Appreciated

mraineri commented 4 years ago

Approved 10/10