bhouse-nexthop commented on PR #14777:
URL: https://github.com/apache/cloudstack/pull/14777#issuecomment-7108294294
Tested the 4.22 backport of this change on a nested KVM lab running
**4.22.1.1-nexthop** (a 4.22.1.1-based build). The lab has 3 KVM hosts, and the
hooks dir is set to `/etc/cloudstack/agent/hooks`.
`kvm.host.maintenance.run.hooks=true` is set at cluster scope. One stub script
per stage logs the time and its exit code.
| # | Scenario | Result | Evidence |
|---|---|---|---|
| 1 | prepareHostForMaintenance on a host with a user VM and the SSVM/CPVM,
then cancelHostMaintenance | Pass | PreFlight, then PreMaintenance (10s later),
then the host went to PrepareForMaintenance and its 3 VMs migrated off.
Maintenance was reached after 27s, and PostMigrate ran right after with the
host empty. On cancel, PostMaintenance ran first and the host was Enabled about
11s later. Each hook ran once |
| 2 | PreMaintenance exits 70 | Pass | Prepare was refused ("Maintenance
hook PreMaintenance on Host ..."). The host stayed Up/Enabled and no VM moved.
Only PreFlight and PreMaintenance ran |
| 3 | startRollingMaintenance on the empty host (one cluster, so it can't
migrate VMs away) | Pass | `hostsupdated: [host]`. The stages ran PreFlight,
PreMaintenance, PostMigrate, Maintenance, PostMaintenance, each exactly once,
with PostMigrate after entering maintenance and before Maintenance |
| 4 | startRollingMaintenance without a Maintenance script | Pass | Skipped
with "There is no maintenance script on the host", as before |
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]