Turn off logging via package settings
Désactiver l’enregistrement à l’aide des paramètres de package
Explanation
This policy setting controls Windows Installer's processing of the MsiLogging property. The MsiLogging property in an installation package can be used to enable automatic logging of all install operations for the package.
If you enable this policy setting, you can use the options in the Disable logging via package settings box to control automatic logging via package settings behavior.
-- The "Logging via package settings on" option instructs Windows Installer to automatically generate log files for packages that include the MsiLogging property.
-- The "Logging via package settings off" option turns off the automatic logging behavior when specified via the MsiLogging policy. Log files can still be generated using the logging command line switch or the Logging policy.
If you disable or do not configure this policy setting, Windows Installer will automatically generate log files for those packages that include the MsiLogging property.
Ce paramètre de stratégie contrôle le traitement de la propriété MsiLogging par Windows Installer. La propriété MsiLogging d’un package d’installation peut être utilisée pour activer l’enregistrement automatique de toutes les opérations d’installation du package.
Si vous activez ce paramètre de stratégie, vous pouvez utiliser les options de la zone Désactiver l’enregistrement à l’aide des paramètres de package pour contrôler l’enregistrement automatique à l’aide du comportement des paramètres de package.
-- L’option « Enregistrement à l’aide des paramètres de package activés » demande à Windows Installer de générer automatiquement les fichiers journaux des packages qui contiennent la propriété MsiLogging.
-- L’option « Enregistrement à l’aide des paramètres de package désactivés » désactive le comportement d’enregistrement automatique lorsqu’il est spécifié par la stratégie MsiLogging. Les fichiers journaux peuvent toujours être générés à l’aide du commutateur de ligne de commande d’enregistrement ou de la stratégie Enregistrement.
Si vous désactivez ce paramètre de stratégie ou si vous ne le configurez pas, Windows Installer génère automatiquement les fichiers journaux des packages qui contiennent la propriété MsiLogging.
Registry
HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Installer- Value name
- not defined in the ADMX
Enable / disable values: not defined in the ADMX (see the options below).
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: MSI/DisableLoggingFromPackage
$k = 'HKLM:\Software\Policies\Microsoft\Windows\Installer'
if (-not (Test-Path -Path $k)) { New-Item -Path $k -Force | Out-Null }
# Disable logging via package settings
# Possible options:
# Disable logging via package settings off = 1
# Disable logging via package settings on = 0
Set-ItemProperty -Path $k -Name 'DisableLoggingFromPackage' -Value 0 -Type DWordDisable
# Disable: MSI/DisableLoggingFromPackage
# No value is written in the "Disabled" state (nothing defined in the ADMX)Revert to "Not configured"
# Revert to "Not configured": MSI/DisableLoggingFromPackage
$k = 'HKLM:\Software\Policies\Microsoft\Windows\Installer'
Remove-ItemProperty -Path $k -Name 'DisableLoggingFromPackage' -ErrorAction SilentlyContinueOptions (1)
| Label | Control | Registry value | REG type | Constraints / details | ||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Disable logging via package settingsDésactiver l’enregistrement à l’aide des paramètres de packageDisableLoggingFromPackage | Drop-down listenum | DisableLoggingFromPackage | REG_DWORD | Required · Default choice (UI): #1
|