Block clean-up of unused language packs
Bloquer le nettoyage des modules linguistiques inutilisés
Explanation
This policy setting controls whether the LPRemove task will run to clean up language packs installed on a machine but are not used by any users on that machine.
If you enable this policy setting, language packs that are installed as part of the system image will remain installed even if they are not used by any user on that system.
If you disable or do not configure this policy setting, language packs that are installed as part of the system image but are not used by any user on that system will be removed as part of a scheduled clean up task.
Ce paramètre de stratégie contrôle si la tâche LPRemove s’exécute pour nettoyer les modules linguistiques installés mais inutilisés sur un ordinateur.
Si vous activez ce paramètre de stratégie, les modules linguistiques installés en tant que partie intégrante de l’image système demeureront installés et ce, même si aucun utilisateur ne les utilise sur ce système.
Si vous désactivez ce paramètre de stratégie ou si vous ne le configurez pas, les modules linguistiques installés en tant que partie intégrante de l’image système, mais inutilisés sur ce système, seront désinstallés dans le cadre d’une tâche de nettoyage planifiée.
Registry
HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Control Panel\International- Value name
BlockCleanupOfUnusedPreinstalledLangPacks
| 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: Globalization/BlockCleanupOfUnusedPreinstalledLangPacks
$k = 'HKLM:\Software\Policies\Microsoft\Control Panel\International'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'BlockCleanupOfUnusedPreinstalledLangPacks' -Value 1 -Type DWordDisable
# Disable: Globalization/BlockCleanupOfUnusedPreinstalledLangPacks
$k = 'HKLM:\Software\Policies\Microsoft\Control Panel\International'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'BlockCleanupOfUnusedPreinstalledLangPacks' -Value 0 -Type DWordRevert to "Not configured"
# Revert to "Not configured": Globalization/BlockCleanupOfUnusedPreinstalledLangPacks
$k = 'HKLM:\Software\Policies\Microsoft\Control Panel\International'
Remove-ItemProperty -Path $k -Name 'BlockCleanupOfUnusedPreinstalledLangPacks' -ErrorAction SilentlyContinue