Question about PowerShell
Hello, I need to adjust the retention period for virus notifications. I would like to temporarily store virus notifications for a maximum of 1 day for various reasons.
I attempted to modify this setting using PowerShell with administrative privileges by running the following command:
> Set-MpPreference -QuarantinePurgeItemsAfterDelay 1
However, I encountered an error:
Set-MpPreference : The operation failed with the following error: 0x%1!x!
At line:1 char:2
+ Set-MpPreference -QuarantinePurgeItemsAfterDelay 1
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (MSFT_MpPreference:rootMicrosoft…FT_MpPreference) [Set-MpPreference],
CimException
+ FullyQualifiedErrorId : HRESULT 0xc0000142,Set-MpPreference
Can someone assist me in making this adjustment?
Operating System Version: 23H2 (OS Build 22631.2792)
Hello, I need to adjust the retention period for virus notifications. I would like to temporarily store virus notifications for a maximum of 1 day for various reasons. I attempted to modify this setting using PowerShell with administrative privileges by running the following command: > Set-MpPreference -QuarantinePurgeItemsAfterDelay 1 However, I encountered an error: Set-MpPreference : The operation failed with the following error: 0x%1!x!At line:1 char:2+ Set-MpPreference -QuarantinePurgeItemsAfterDelay 1+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~+ CategoryInfo : NotSpecified: (MSFT_MpPreference:rootMicrosoft…FT_MpPreference) [Set-MpPreference],CimException+ FullyQualifiedErrorId : HRESULT 0xc0000142,Set-MpPreference Can someone assist me in making this adjustment? Operating System Version: 23H2 (OS Build 22631.2792) Read More