-
Notifications
You must be signed in to change notification settings - Fork 226
Fixes #38498 - Add support for Reset (powerreset) via Redfish provider #916
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes #38498 - Add support for Reset (powerreset) via Redfish provider #916
Conversation
82ff063 to
a025c08
Compare
ekohl
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@stejskalleos do we have the capacity to verify this somewhere using actual Redfish hardware?
| poweraction('ForceRestart') | ||
| end | ||
|
|
||
| def powerreset |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks the same as the powercycle implementation. Is there a reason you can't use `cycle?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ekohl san
Thank you for your comment.
Because powercycle and power reset is different power action.
According to the Redfish specification (DSP2046_2025.1, p.513), these actions are different one and should use different reset type:
- powercycle should use the PowerCycle
- powerreset should use ForceRestart
The current implementation uses ForceRestart against powercycle and this is wrong implementation.
This is described in ticket #38498.
I plan to submit a separate PR to correct the powercycle behavior.
|
@ekohl san Thank you for your comment. According to the Redfish specification (DSP2046_2025.1, p.513), these actions are different one and should use different reset type:
The current implementation uses ForceRestart against powercycle and this is wrong implementation. |
a025c08 to
3a74cff
Compare
3a74cff to
3a45495
Compare
3a45495 to
46210ab
Compare
Yes and no. I have the capacity, but don't have the hardware. I think it could be tested with the @spesnova717 I will do the review. I added it to my backlog, but I can't promise a quick response as I'm quite new to it. |
|
@stejskalleos |
46210ab to
8900f46
Compare
|
@spesnova717, To resolve the merge conflicts, can you please rebase the branch over the latest |
8900f46 to
f1df1ec
Compare
|
@stejskalleos |
Bug #3073 is caused by 3 things:
1. Foreman core doesn't call BMC proxy's API correctly
- Changing power state to 'Reboot' via Web GUI calls BMC proxy's 'soft'
power action
- Changing power state to 'Reset' via Web GUI calls BMC proxy's 'cycle'
power action
2. Foreman BMC proxy doesn't support reboot at all BMC provider
3. Foreman BMC proxy doesn't support reset(powerreset) at Redfish provider
2nd & 3rd item are mentioned in #38498. And this PR fixes 3rd item.
For backward compatibility, power_action_v2 capability is introduced
to smart proxy at PRs related to #38498. PR related to #3073 adds logic
to determine if smart proxy supports this capability into Foreman core.
Co-Authored-By: Vanou Ishii <[email protected]>
f1df1ec to
e25e3fa
Compare
stejskalleos
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug #3073 is caused by 3 things:
power action
power action
2nd & 3rd item are mentioned in #38498. And this PR fixes 3rd item.
Modifications in this PR
Enable proper handling of "Reset" power action via Redfish
This PR enables the powerreset operation to be processed correctly by the Smart Proxy when using the Redfish provider.
Internally, this maps the "Reset" request from Foreman core to the appropriate Redfish ForceRestart operation, aligning the behavior with user expectations in the Web UI.
To support this, a new powerreset API endpoint is introduced, and the Redfish BMC class is extended to implement the corresponding logic.