Set-PveClusterHaRules
Update HA rule.
API: PUT /cluster/ha/rules/{rule}, Proxmox VE API viewer
Syntax
Section titled “Syntax”Set-PveClusterHaRules [-PveTicket <PveTicket>] [-Delete <string>] [-Digest <string>] -Rule <string> -Type <string> [-Affinity <string>] [-Comment <string>] [-Disable <bool>] [-Nodes <string>] [-Resources <string>] [-Strict <bool>] [<CommonParameters>]Parameters
Section titled “Parameters”| Parameter | Type | Required | Description |
|---|---|---|---|
-PveTicket |
PveTicket |
No | Ticket data connection. |
-Delete |
string |
No | A list of settings you want to delete. |
-Digest |
string |
No | Prevent changes if current configuration file has a different digest. This can be used to prevent concurrent modifications. |
-Rule |
string |
Yes | HA rule identifier. |
-Type |
string |
Yes | HA rule type. Values: node-affinity, resource-affinity. |
-Affinity |
string |
No | Describes whether the HA resources are supposed to be placed on the given nodes (‘positive’), or are supposed to be placed on any but the given nodes (‘negative’). Values: positive, negative. |
-Comment |
string |
No | HA rule description. |
-Disable |
bool |
No | Whether the HA rule is disabled. |
-Nodes |
string |
No | List of cluster node names with optional priority. |
-Resources |
string |
No | List of HA resource IDs. This consists of a list of resource types followed by a resource specific name separated with a colon (example: vm:100,ct:101). |
-Strict |
bool |
No | Describes whether the node affinity rule is strict or non-strict. |
Every parameter also binds by property name from the pipeline, so an object with node and vmid properties (the output of Get-PveGuest, for one) fills -Node and -Vmid. Without -PveTicket the cmdlet uses the last connection, see Connection.
Output
Section titled “Output”A PveResponse: the data returned by Proxmox VE is in .Response.data, the outcome in .IsSuccessStatusCode. See Results and Errors.