Do not reinitialize a pre-existing roamed user profile when it is loaded on a machine for the first time
Ne réinitialisez pas un profil utilisateur itinérant préexistant lorsqu'il est chargé sur un ordinateur pour la première fois
Explanation
This policy setting allows administrators who have configured roaming profile in conjunction with Delete Cached Roaming Profile Group Policy setting to ensure that Explorer will not reinitialize default program associations and other settings to default values.
If you enable this policy setting on a machine that does not contain all programs installed in the same manner as it was on the machine on which the user had last logged on, unexpected behavior could occur.
Ce paramètre de stratégie permet aux administrateurs ayant configuré un profil itinérant conjointement avec le paramètre de stratégie de groupe Supprimer le profil itinérant en cache de s'assurer que l'Explorateur ne va pas réinitialiser les associations de programmes par défaut et d'autres paramètres à leurs valeurs par défaut.
Si vous activez ce paramètre de stratégie sur un ordinateur dont les programmes ne sont pas configurés de la même manière que sur l'ordinateur à partir duquel l'utilisateur s'est connecté pour la dernière fois, un comportement inattendu peut se produire.
Registry
HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Explorer- Value name
DisableRoamedProfileInit
| State | Value written |
|---|---|
| Enabled | REG_DWORD = 1 |
| Disabled | REG_DWORD = 0 |
PowerShell
PowerShell commands that write to the registry what the policy would write. Values in angle brackets (<…>) must be replaced.
Writing directly to the registry bypasses Group Policy: if a GPO manages this value, it will be rewritten at the next gpupdate; otherwise the value stays in place (the "tattooing" effect). Prefer a GPO or, locally, LGPO.exe. Run PowerShell as administrator for HKLM. Some policies need a restart or gpupdate /force.
Enable
# Enable: Explorer/DisableRoamedProfileInit
$k = 'HKLM:\Software\Policies\Microsoft\Windows\Explorer'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'DisableRoamedProfileInit' -Value 1 -Type DWordDisable
# Disable: Explorer/DisableRoamedProfileInit
$k = 'HKLM:\Software\Policies\Microsoft\Windows\Explorer'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'DisableRoamedProfileInit' -Value 0 -Type DWordRevert to "Not configured"
# Revert to "Not configured": Explorer/DisableRoamedProfileInit
$k = 'HKLM:\Software\Policies\Microsoft\Windows\Explorer'
Remove-ItemProperty -Path $k -Name 'DisableRoamedProfileInit' -ErrorAction SilentlyContinue