Update-Entity
This cmdlet remediates an inventory object against the specified baselines. If RunAsync is set, returns a task that can be used to monitor the remediation progress. You can remediate Template, VirtualMachine, VMHost, Cluster, Datacenter, Folder, and VApp objects.
Syntax
-Entity <InventoryItem>
[-ClusterDisableDistributedPowerManagement <Boolean>]
[-ClusterDisableFaultTolerance <Boolean>]
[-ClusterDisableHighAvailability <Boolean>]
[-ClusterEnableParallelRemediation <Boolean>]
[-ExcludePatch <Patch[]>]
[-GuestCreateSnapshot <Boolean>]
[-GuestKeepSnapshotHours <Int32>]
[-GuestSnapshotDescription <String>]
[-GuestSnapshotName <String>]
[-GuestTakeMemoryDump <Boolean>]
[-HostDisableMediaDevices <Boolean>]
[-HostEnablePXEbootHostPatching <Boolean>]
[-HostFailureAction <HostRemediationFailureAction>]
[-HostIgnoreThirdPartyDrivers <Boolean>]
[-HostNumberOfRetries <Int32>]
[-HostPreRemediationPowerAction <HostPreRemediationPowerAction>]
[-HostRetryDelaySeconds <Int32>]
[-RunAsync]
[-Server <VIServer[]>]
[CommonParameters]
Parameters
Required | Parameter Name | Type | Position | Features | Description |
---|---|---|---|---|---|
required |
|
Baseline[] | named |
|
Specifies the baseline you want to use for the remediation. | required |
|
InventoryItem | named |
|
Specifies a Template, VirtualMachine, VMHost, Cluster, Datacenter, Folder, or VApp object to remediate. | optional |
|
Boolean | named |
|
Indicates that you want to temporarily disable Distributed Power Management (DPM) for the specified clusters. After the remediation, DPM is automatically re-enabled. | optional |
|
Boolean | named |
|
Indicates that you want to temporarily disable Fault Tolerance (FT) for the specified clusters. After the remediation, FT is automatically re-enabled. | optional |
|
Boolean | named |
|
Indicates that you want to temporarily disable High Availability (HA) for the specified clusters. After the remediation, HA is automatically re-enabled. | optional |
|
Boolean | named |
|
Indicates that you want to enable parallel remediation for the specified clusters. | optional |
|
Patch[] | named |
|
Specifies the patches you want to exclude from the remediation process. | optional |
|
Boolean | named |
|
Indicates that you want to create a snapshot before initializing remediation. | optional |
|
Int32 | named |
|
Specifies how long (in hours) you want to keep the snapshot. If not set, the snapshots are never deleted. | optional |
|
String | named |
|
Specifies a description for the snapshot you want to create before initializing remediation. This parameter is valid only if the GuestCreateSnapshot parameter is set. | optional |
|
String | named |
|
Specifies a name for the snapshot you want to create before initializing remediation. This parameter is valid only if the GuestCreateSnapshot parameter is set. | optional |
|
Boolean | named |
|
Indicates that you want the guest to take a memory dump while creating a snapshot. | optional |
|
Boolean | named |
|
Indicates that you want to temporarily disable any media devices that might prevent the specified hosts from entering maintenance mode. | optional |
|
Boolean | named |
|
Indicates that you want to enable PXE booted ESXi hosts patching. | optional |
|
HostRemediationFailureAction | named |
|
Specifies an action in case the host cannot be placed in a maintenance mode. This might happen due to running virtual machines that cannot be automatically migrated to another host. The valid values are FailTask, Retry, PowerOffVMsAndRetry, and SuspendVMsAndRetry. | optional |
|
Boolean | named |
|
Indicates that you want to ignore installed third-party software that is incompatible with the upgrade. | optional |
|
Int32 | named |
|
Specifies how many times to retry to set the host into a maintenance mode. | optional |
|
HostPreRemediationPowerAction | named |
|
Specifies an action before trying to enter the host into a maintenance mode. The valid values are PowerOffVMs, SuspendVMs, and DoNotChangeVMsPowerState. | optional |
|
Int32 | named |
|
Specifies how long (in seconds) to wait for the host to enter a maintenance mode. | optional |
|
SwitchParameter | named |
|
Indicates that the command returns immediately without waiting for the task to complete. In this mode, the output of the cmdlet is a Task object. For more information about the -RunAsync parameter run "help About_RunAsync" in the vSphere PowerCLI console. | optional |
|
VIServer[] | named |
|
Specifies the vSphere servers on which you want to run the cmdlet. If no value is given to this parameter, the command runs on the default servers. |
Output
Examples
Example 1
Remediates a host in asynchronous mode.
Example 2
Upgrades a virtual machine with the latest virtual hardware. If the upgrade fails, the command creates a snapshot of the target virtual machine.
Example 3
Remediates a cluster with DPM, HA, and FT that are enabled and need to be disabled during the remediation process.
Example 4
Remediates a cluster in parallel mode. All hosts in the cluster are remediated simultaneously and that saves time.
Example 5
Remediates a host with preinstalled third-party drivers, which prevent host from upgrade.
Related Commands
Entity