Red Hat Bugzilla – Bug 1468875
Synchronize hosted-engine maintenance state after power management operation
Last modified: 2018-07-04 06:56:08 EDT
Description of problem:
We need to synchronize the HE and the engine maintenance state after power management operation
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Configure HE environment with at least two hosts
2. Configure power management on the host with HE VM
3. Put host with HE VM to maintenance
4. Restart host via power management
After host restart, host go straight forward to UP state, when the HE maintenance state still has "LocalMaintenance" state
Both the engine and the HE maintenance state must be synchronized after power management operation(or both will have state maintenance or both will have state up)
It affects our automation tests
This is actually by design.
There's a difference between having a host in maintenance to having a hosted-engine node in maintenance. The main reason is to allow maintenance of the HE parts without interrupting vdsm and other running VMs.
So just to summarize;
A hosted engine node can be in local maintenance while the hypervisor in not in maintenance and working properly.
I can agree with it when the user himself manually set local maintenance on the host via HE CLI, but in this case, one that brake sync the engine, so the engine also must be responsible for restoring sync between maintenance states after power management operation, for example, we have power_saving with power management policy:
1) Set the policy
2) In case if the engine has more hosts in reserve than power_saving policy needed, the engine put one of the free hosts to maintenance(automatically the engine put host to local maintenance), the engine poweroff the host via power management
3) Now if the engine will need to power on the host, host will not enter into the maintenance state but will jump straight forward to the state UP, but it will stay in the local maintenance from the HE perspective
Using power management on a host in local maintenance set from the hosted engine cli is a corner case and the hosted engine flags will stay as they are.
Is the webadmin based flow works like this?
1) Put a host to local maintenance
2) Reboot the host using the UI power management options
3) The host is rebooted and automatically activated
If it is then I think the activation should be done properly on the engine side or the host should return to local maintenance and leave the job of activating the host to the admin.
This is a corner case as far as SLA is concerned, but it might be a bug in the Infra area.