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
Copy file name to clipboardExpand all lines: docs/management/ha.md
+13-29Lines changed: 13 additions & 29 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -175,8 +175,6 @@ The **default timeout is 60 seconds**, but you can adjust this value using the f
175
175
xe pool-param-set uuid=<pool UUID> other-config:default_ha_timeout=<timeout in seconds>
176
176
```
177
177
178
-
179
-
180
178
## 🔧 Updates/maintenance
181
179
182
180
Before any update or host maintenance, planned reboot and so on, **ALWAYS** put your host in maintenance mode. If you don't do that, XAPI will think it's an unplanned failure, and will act accordingly.
@@ -195,9 +193,13 @@ If you shut the VM down with `Xen Orchestra` or `xe`, the VM will be stopped nor
195
193
196
194
However, if you halt the VM directly in the guest OS (via the console or in SSH), XCP-ng is NOT aware of what's going on. The system will think the VM is down and will consider that an anomaly. As a result, the VM will be **started automatically!**. This behavior prevents an operator from shutting down the system and leaving the VM unavailable for a long time.
197
195
196
+
#### Configure VM shutdown behavior
197
+
198
+
##### For an entire pool
199
+
198
200
:::tip
199
201
200
-
Starting with XAPI 25.16.0, VM restart behavior can be changed. To do this, run this command:
202
+
Starting with XAPI 25.16.0, VM restart behavior can be changed on a pool-wide basis. To do this, run this command:
@@ -206,39 +208,21 @@ As a result, VMs that are shut down internally or through the API will restart t
206
208
207
209
:::
208
210
209
-
#### Configure VM shutdown behavior
210
-
211
-
If you don't want a VM to reboot automatically when it has been shut down from the guest OS: disable its HA protection, then adjust the VM reboot behavior with the parameter called `Pool.ha_reboot_vm_on_internal_shutdown` (see below).
212
-
213
-
##### Disabling HA on specific VMs
214
-
215
-
You can adjust the reboot behavior for a specific HA-protected VM:
211
+
##### For specific VMs
216
212
217
-
-**Using the `xe` cli:** :
218
-
- To disable HA features, run `xe vm-param-set uuid=<vm_uuid> ha-restart-priority=`.
219
-
- To (re-)enable HA features, run `xe vm-param-set uuid=<vm_uuid> ha-restart-priority=restart` or `xe vm-param-set uuid=<vm_uuid> ha-restart-priority=best-effort`.
220
-
-**Using Xen Orchestra**:
221
-
To change the VM reboot behavior from Xen Orchestra, check out the instructions in the [Xen Orchestra documentation](https://docs.xen-orchestra.com/manage_infrastructure#vm-high-availability-ha).
213
+
If you don't want a VM to reboot automatically when it has been shut down from the guest OS, adjust the VM reboot behavior with the parameter called `Pool.ha_reboot_vm_on_internal_shutdown`.
222
214
223
215
:::warning
224
216
Applying these changes means that your VMs will stay off after they have been shut down, until you restart them yourself.
225
217
:::
226
218
227
-
:::tip
228
-
Once HA features have been disabled on your VM, shut the VM down. Once you have started the VM again, feel free to enable HA again.
229
-
:::
230
-
231
-
##### Disabling HA on the whole pool
232
-
233
-
You can prevent automatic reboots on your entire pool. To do this, use the `xe` CLI to run this command:
To enable automatic reboots again, set the parameter to `true` instead of `false`.
219
+
-**Using the `xe` cli:** :
220
+
- To disable automatic reboots, run `xe vm-param-set uuid=<vm_uuid> ha-restart-priority=`.
221
+
- To (re-)enable automatic reboots, run `xe vm-param-set uuid=<vm_uuid> ha-restart-priority=restart` or `xe vm-param-set uuid=<vm_uuid> ha-restart-priority=best-effort`.
222
+
-**Using Xen Orchestra**:
223
+
To change the VM reboot behavior from Xen Orchestra, check out the instructions in the [Xen Orchestra documentation](https://docs.xen-orchestra.com/manage_infrastructure#vm-high-availability-ha).
238
224
239
-
:::warning
240
-
By applying these changes to your entire pool, you disable the protection that prevents VMs from being shut down by their own guest OS.
241
-
:::
225
+
Once you've changed the reboot parameter, shut the VM down. After you have started the VM again, feel free to re-enable automatic reboots.
0 commit comments