Open in the explorer

Configure Corrupted File Recovery behavior

Configurer le comportement de récupération de fichier endommagé

Type
Computer
GPO path
Computer Configuration › Policies › Administrative Templates › System › Troubleshooting and Diagnostics › Corrupted File Recovery FR: Configuration ordinateur › Stratégies › Modèles d'administration › Système › Dépannage et diagnostics › Récupération de fichier endommagé
Supported on
At least Windows Vista FR: Au minimum Windows Vista
ADMX file
FileRecovery.admx
Internal name
FileRecovery/WdiScenarioExecutionPolicy

Explanation

This policy setting allows you to configure the recovery behavior for corrupted files to one of three states:

Regular: Detection, troubleshooting, and recovery of corrupted files will automatically start with a minimal UI display. Windows will attempt to present you with a dialog box when a system restart is required. This is the default recovery behavior for corrupted files.

Silent: Detection, troubleshooting, and recovery of corrupted files will automatically start with no UI. Windows will log an administrator event when a system restart is required. This behavior is recommended for headless operation.

Troubleshooting Only: Detection and troubleshooting of corrupted files will automatically start with no UI. Recovery is not attempted automatically. Windows will log an administrator event with instructions if manual recovery is possible.

If you enable this setting, the recovery behavior for corrupted files will be set to either the regular (default), silent, or troubleshooting only state.

If you disable this setting, the recovery behavior for corrupted files will be disabled. No troubleshooting or resolution will be attempted.

If you do not configure this setting, the recovery behavior for corrupted files will be set to the regular recovery behavior.

No system or service restarts are required for changes to this policy to take immediate effect after a Group Policy refresh.

Note: This policy setting will take effect only when the Diagnostic Policy Service (DPS) is in the running state. When the service is stopped or disabled, system file recovery will not be attempted. The DPS can be configured with the Services snap-in to the Microsoft Management Console.

French text from Windows 11 26H2

Ce paramètre de stratégie permet de configurer le comportement de récupération de fichier endommagé à l’un des trois états suivants :

Normal : la détection, le dépannage et la récupération des fichiers endommagés commencent automatiquement avec un affichage d’interface utilisateur minimal. Windows tente d’afficher une boîte de dialogue lorsqu’un redémarrage du système est nécessaire. Il s’agit du comportement de récupération de fichier endommagé par défaut.

Silencieux : la détection, le dépannage et la récupération des fichiers endommagés commencent automatiquement sans interface utilisateur. Windows enregistre un événement d’administrateur lorsqu’un redémarrage du système est nécessaire. Ce comportement est recommandé pour un fonctionnement sans périphérique de contrôle.

Dépannage seulement : la détection et le dépannage des fichiers endommagés commencent automatiquement sans interface utilisateur. La récupération n’est pas tentée automatiquement. Windows enregistre un événement d’administrateur avec des instructions si une récupération manuelle est possible.

Si vous activez ce paramètre, le comportement de récupération de fichier endommagé prend au choix l’état normal (par défaut), silencieux ou dépannage seulement.

Si vous désactivez ce paramètre, le comportement de récupération de fichier endommagé est désactivé. Aucun dépannage ou aucune résolution n’est tenté.

Si vous ne configurez pas ce paramètre, le comportement de récupération de fichier endommagé prend le comportement normal.

Aucun redémarrage du système ou de services n’est nécessaire pour l’application immédiate des modifications apportées à cette stratégie après une actualisation de la stratégie de groupe.

Remarque : ce paramètre de stratégie ne s’applique que si le service de stratégie de diagnostic est en cours d’exécution. Lorsque ce service est arrêté ou désactivé, la récupération de fichier système n’est pas tentée. Le service de stratégie de diagnostic peut être configuré avec le composant logiciel enfichable Services dans Microsoft Management Console.

Registry

HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WDI\{8519d925-541e-4a2b-8b1e-8059d16082f2}
Value name
ScenarioExecutionEnabled
StateValue written
EnabledREG_DWORD = 1
DisabledREG_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: FileRecovery/WdiScenarioExecutionPolicy
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\WDI\{8519d925-541e-4a2b-8b1e-8059d16082f2}'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'ScenarioExecutionEnabled' -Value 1 -Type DWord
# Scenario Execution Level
# Possible options:
#   Troubleshooting Only = 1
#   Regular = 2
#   Silent = 3
Set-ItemProperty -Path $k -Name 'EnabledScenarioExecutionLevel' -Value 2 -Type DWord

Disable

# Disable: FileRecovery/WdiScenarioExecutionPolicy
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\WDI\{8519d925-541e-4a2b-8b1e-8059d16082f2}'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
Set-ItemProperty -Path $k -Name 'ScenarioExecutionEnabled' -Value 0 -Type DWord

Revert to "Not configured"

# Revert to "Not configured": FileRecovery/WdiScenarioExecutionPolicy
$k = 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\WDI\{8519d925-541e-4a2b-8b1e-8059d16082f2}'
Remove-ItemProperty -Path $k -Name 'ScenarioExecutionEnabled' -ErrorAction SilentlyContinue
Remove-ItemProperty -Path $k -Name 'EnabledScenarioExecutionLevel' -ErrorAction SilentlyContinue

Options (1)

LabelControlRegistry valueREG typeConstraints / details
Scenario Execution LevelNiveau d’exécution de scénarioWdiScenarioExecutionPolicyLevelDrop-down listenumEnabledScenarioExecutionLevelREG_DWORD
Required · Default choice (UI): #1
LabelValue
Troubleshooting OnlyREG_DWORD = 1
RegularREG_DWORD = 2
SilentREG_DWORD = 3

Availability