You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 78470fa
Browse filesBrowse the repository at this point in the historyBrowse files
2.**fast path**: skips Ready nodes that do not carry the taint, so a healthy
52
62
cluster makes no Xen Orchestra API call;
53
-
3. queries Xen Orchestra with `InstancesV2.InstanceExists` and
54
-
`InstanceShutdown`;
55
-
4. applies the taint when the VM is down **and** the node is `NotReady`:
63
+
3. queries Xen Orchestra with `GetInstance`, which returns the VM's power state
64
+
and in-flight operations;
65
+
4. applies the taint when the VM is down or shutting down **and** the node is
66
+
`NotReady`:
56
67
* the VM was deleted from Xen Orchestra → immediate, it can never come back;
57
-
* the VM is only powered off → only after
58
-
`--node-out-of-service-grace-period` (default `30s`), because a clean reboot
59
-
must not trigger a force detach;
68
+
* the VM is not running (halted, paused or suspended), or a `suspend`,
69
+
`clean-shutdown` or `hard-shutdown` operation is in progress → only after
70
+
`--node-out-of-service-grace-period` (default `30s`), because a clean
71
+
reboot (no operation in flight) must not trigger a force detach;
60
72
5. removes the taint once the VM runs again and the node is `Ready`.
61
73
62
74
Applying the taint to a node that is not actually shut down can corrupt a
63
-
filesystem, so the two conditions (VM down *and* node `NotReady`) and the grace
64
-
period are required. See the upstream warning in the Node Shutdowns
65
-
documentation.
75
+
filesystem, so the two conditions (VM down or shutting down *and* node
76
+
`NotReady`) and the grace period are required. The grace period also covers a
77
+
shutdown operation that is cancelled before it completes. See the upstream
78
+
warning in the Node Shutdowns documentation.
66
79
67
80
## Enabling the controller
68
81
@@ -75,7 +88,7 @@ the `docs/deploy` manifests enable it by default.
75
88
| flag | default | description |
76
89
|---|---|---|
77
90
|`--node-out-of-service-sync-period`|`10s`| reconciliation period |
78
-
|`--node-out-of-service-grace-period`|`30s`| how long a powered-off VM must stay down (with a NotReady node) before tainting |
91
+
|`--node-out-of-service-grace-period`|`30s`| how long a VM must stay down or have a shutdown operation in progress (with a NotReady node) before tainting |
79
92
80
93
With the Helm chart these are set with the `nodeOutOfServiceSyncPeriod` and
81
94
`nodeOutOfServiceGracePeriod` values (empty by default, which keeps the built-in
0 commit comments