The Send-LinkedCloneRecompose command is used to recompose either a specific Horizon linked clone desktop or the entire desktop pool.
In the following example, we will be recomposing to a new snapshot of the same parent VM. The snapshot is named UpdatesApplied. Since this VM now has two snapshots, the ParentSnapshotPath will now be in the /Base/UpdatesApplied format, where Base is the name of the original snapshot used to create the pool. The remainder of the command follows a format that is similar to the Send-LinkedCloneRefresh command:
Get-Pool -Pool_id “EngineeringLC1” | Get-DesktopVM | Send-LinkedCloneRecompose -ParentVMPath “/RTP/vm/Master/Win10x32-LC” -ParentSnapshotPath “/Base/UpdatesApplied” -schedule “2018-12-31 22:00”
The command will recompose all desktops in the pool to the snapshot named UpdatesApplied at the indicated time. You can also select a different parent VM when performing a recompose, but remember that the VM must be running the same OS as the existing desktops.
You can also recompose a single desktop using the -machine_id option and the Get-DesktopVM command, as shown in the following code:
Send-LinkedCloneRecompose (Get-DesktopVM -Name “HorLC0001”).machine_id -ParentVMPath “/RTP/vm/Master/Win10x32-LC” -ParentSnapshotPath “/Base/UpdatesApplied” -schedule “2018-12-31 22:00”
The Send-LinkedCloneRecompose command requires you to specify multiple options, including Schedule, ParentVMPath, and ParentSnapshotPath. The command also supports the StopOnError and ForceLogoff options.