LCM Category
Cmdlets are usually implemented around resource operations. The four basic operations are CREATE, READ, UPDATE and DELETE. This set of operations is known as CRUD. Most of the cmdlets support CRUD which are respectively cmdlets that start with the New/Get/Set/Remove cmdlet verbs but they also may have additional operations
Step 1: Retrieve a object by running a Get command
# Creates a desired state recommendation based on the latest ESXi base image version.
Get-LcmClusterDesiredStateRecommendation 'lcm-cluster'
Step 2 : Run commands from the CRUD group
# Creates a new offline depot from the depot update file located at http://link/to/offline/depot. OwnerData can be any string that you want to associate with the new depot.
PS C:\> New-LcmOfflineDepot -Location 'http://link/to/offline/depot' -Description 'Company offline depot' -OwnerData '{depot:security_updates}'
# Exports metadata for the desired state of the 'lcm-cluster' cluster in the 'desired-state' subdirectory.
Export-LcmClusterDesiredState -Cluster 'lcm-cluster' -Destination './desired-state'
Step 3: Explore More Related Commands:
New-LCMClusterRuleWithTransform | New-LCMClusterRuleWithTransform [-Name] <string> -Pattern <string[]> -LcmCluster <VIObjectCore> -NoSignatureCheck [-Item <VIObjectCore[]>] [<CommonParameters>] New-LCMClusterRuleWithTransform [-Name] <string> -AllHosts -LcmCluster <VIObjectCore> -NoSignatureCheck [-Item <VIObjectCore[]>] [<CommonParameters>] |
Reset-LCMClusterRuleWithTransform | Reset-LCMClusterRuleWithTransform [-DeployRule] <DeployRuleWrapper> [-Force] [-NoSignatureCheck] [<CommonParameters>] |
Set-LCMClusterRuleWithTransform | Set-LCMClusterRuleWithTransform [-DeployRule] <DeployRuleWrapper> -LcmCluster <VIObjectCore> [-Pattern <string[]>] [-AllHosts] [-Item <VIObjectCore[]>] [-Force] [-NoSignatureCheck] [<CommonParameters>] |
Export-LcmVMHostDesiredState | This cmdlet exports the desired state of an ESXi host that is managed by vSphere Lifecycle Manager. The desired state consists of the host's base image and the installed software packages. |
Get-LcmHardwareCompatibility | This cmdlet verifies that the components in the base image are compatible with all storage controllers on the hosts in the cluster in accordance with the VMware Compatibility Guide. |
Get-LcmImage | This cmdlet retrieves the vSphere Lifecycle Manager images available on a vCenter Server system. |
Get-LcmSoftwareSpecification | This cmdlet retrieves the vSphere Lifecycle Manager software specifications available on a vCenter Server system. |
Import-LcmClusterDesiredState | This cmdlet imports a specification file to set a desired state of a vSphere Lifecycle Manager cluster. |
Test-LcmClusterCompliance | This cmdlet tests cluster's hosts compliance respective to its target state. |
Test-LcmClusterHealth | This cmdlet tests cluster's hosts health respective to its target state. |