Migrazione delle impostazioni di Horizon Client da VMware a Omnissa con Omnissa DEM

Con il rebranding di VMware Horizon Client in Omnissa Horizon Client, uno degli aspetti spesso sottovalutati è la migrazione delle impostazioni utente.

Nel contesto in cui ho dovuto operare la necessità principale era replicare le impostazioni dell’Horizon Client (dalla versione VMware a quella Omnissa) in un contesto di VDI. Le impostazioni fondamentale da copiare erano quelle del “Drive & Folder Sharing”

In ambienti enterprise – specialmente VDI non persistenti gestiti con Omnissa Dynamic Environment Manager (DEM) – è fondamentale garantire che:

• le impostazioni dell’utente vengano mantenute
• la migrazione avvenga una sola volta
• non ci siano impatti sui logon successivi

In questo articolo vediamo come migrare automaticamente le impostazioni del client Horizon:

• da:

%AppData%\VMware\VMware Horizon View Client

• a:

%AppData%\Omnissa\Omnissa Horizon Client

utilizzando uno script PowerShell integrato correttamente in Omnissa DEM.

 

Prerequisiti

Configurazione di DEM per esportare le personalizzazioni di:

  • VMware Horizon Client
  • Omnissa Horizon Client
  • Chiave di registro di controllo

Precisamente:

.

.

Approccio

La soluzione si basa su tre concetti chiave:

1.Script PowerShell in contesto utente
2.Logon Task in Flex Configuration (DEM)
3.Condition basata su chiave di registro HKCU per garantire l’esecuzione una sola volta

La chiave di registro viene salvata nel profilo utente e gestita da DEM, rendendo la soluzione compatibile con:

• VDI floating
• desktop non persistenti
• profili DEM

.

Script PowerShell

Lo script seguente:

• verifica se la migrazione è già avvenuta
• copia le impostazioni se presenti
•scrive una chiave di registro per bloccare le esecuzioni successive
# ==============================
# Omnissa Horizon Client Migration
# ==============================

$SourcePath = Join-Path $env:APPDATA "VMware\VMware Horizon View Client"
$DestinationPath = Join-Path $env:APPDATA "Omnissa\Omnissa Horizon Client"

# Registry key (per-utente)
$RegPath = "HKCU:\Software\Omnissa\Migrations"
$RegName = "HorizonClientSettingsMigrated"

# ---- Controllo se già eseguito ----
if (Test-Path $RegPath) {
    $Migrated = Get-ItemProperty -Path $RegPath -Name $RegName -ErrorAction SilentlyContinue
    if ($Migrated.$RegName -eq 1) {
        exit 0
    }
}

# ---- Verifica sorgente ----
if (-not (Test-Path $SourcePath)) {
    # Scriviamo comunque la chiave per evitare retry inutili
    New-Item -Path $RegPath -Force | Out-Null
    New-ItemProperty -Path $RegPath -Name $RegName -Value 1 -PropertyType DWORD -Force | Out-Null
    exit 0
}

# ---- Creazione destinazione ----
New-Item -Path $DestinationPath -ItemType Directory -Force | Out-Null

# ---- Copia contenuto ----
Copy-Item -Path "$SourcePath\*" `
          -Destination $DestinationPath `
          -Recurse `
          -Force `
          -ErrorAction SilentlyContinue

# ---- Scrittura chiave di completamento ----
New-Item -Path $RegPath -Force | Out-Null
New-ItemProperty -Path $RegPath -Name $RegName -Value 1 -PropertyType DWORD -Force | Out-Null

exit 0

Lo script lo posizioniamo nella share Config di DEM creando una cartella chiamandola script. Nel mio caso

C:\DEMConfig\Script 

.

Configurazione in Omnissa DEM

Lo script deve essere configurato come Logon Task per cui dalla console di DEM:

• User Environment→ Logon Tasks
• Name:

Migrate Horizon Client Settings (VMware → Omnissa)

• Command:

powershell.exe  -ExecutionPolicy Bypass -NoProfile -File \\fs02.pollaio.lan\DEMConfig\Scripts\Migrate-HorizonClientSettings.ps1

Condition (fondamentale)

• Hive: HKEY_CURRENT_USER
• Key: Software\Omnissa\Migrations
• Value: HorizonClientSettingsMigrated 
non è uguale a 1 

 

Qui il video dove replico tutti i passaggi e provo il tutto:

.

Migrazione delle impostazioni di Horizon Client da VMware a Omnissa con Omnissa DEM

Omnissa Dynamic Environment Manager 2406 and User-Managed Auto-Start Shortcuts

 

The Dynamic Environment Manager 2406 has many new functions, we can read all the info about this version in the following link:

Omnissa Dynamic Environment Manager Release Notes

 

I want to write about the “User-Managed Auto-Start Shortcuts”.

To use this new function it is necessary to:

  1. upgrade FlexEngine Agent to 2406 on VDI (Master Image or VDI Full Clone):
  • For AD agent install -> update the ADMX template (On Active Directory Central Store)

                   We need to modify or create a GPO (assigned to the OU where the VDI are allocated) and                           enable the “User-Managed Auto-Start Shortcuts”

                   User Configuration -> Policies -> Administrative Templates: Policy Definitions -> VMware                       DEM -> FlexEngine -> Self-Support -> Allow managing auto-start shortcuts and set it to                         Enable

  • For NOAD agent Install -> Use this parameter ManageAutoStartShortcuts, on the upgrade step, and set it to 1 to configure properly the self-support tools
  1. upgrade DEM console to 2406

Now in DEM Console (under User Environment), we need to create ShortCuts like this

A screenshot of a computer

Description automatically generated

We need to enable “User-managed auto-start”

Now when the users log in to their VDI and launch the DEM Self-support program, they can select which shortcut applications automatically start when they log on:

A screenshot of a computer

Description automatically generated

Click SAVE and Close

Now at the next login……

A screenshot of a computer

Description automatically generated

Omnissa Dynamic Environment Manager 2406 and User-Managed Auto-Start Shortcuts