You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: defender-endpoint/schedule-antivirus-scans-powershell.md
+23Lines changed: 23 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -32,6 +32,21 @@ search.appverid: met150
32
32
33
33
This article describes how to configure scheduled scans using PowerShell cmdlets. To learn more about scheduling scans and about scan types, see [Configure scheduled quick or full Microsoft Defender Antivirus scans](schedule-antivirus-scans.md).
34
34
35
+
## Use PowerShell cmdlets to set the general settings for Scheduled scan and/or On-Demand scan
36
+
37
+
| Description | Setting|Powershell cmdlet|
38
+
| -------- | -------- | -------- |
39
+
|Check for Security Intelligence Updates Before Running Scan |Disabled/Not configured (Default)|Set-MpPreference -CheckForSignaturesBeforeRunningScan <Boolean><br>For example: Set-MpPreference -CheckForSignaturesBeforeRunningScan $False|
40
+
|Randomize Schedule Task Times|Disabled/Not configured (Default)|Set-MpPreference -RandomizeScheduleTaskTimes <Boolean> <br>Example for physical devices: Set-MpPreference -RandomizeScheduleTaskTimes $False <br>Example for Virtual Machines (VM's) or Virtual Desktop Infrastructure (VDI's) or Azure Virtual Desktop (AVD): Set-MpPreference -RandomizeScheduleTaskTimes $True <br>Note: The default randomization time is within an interval of 30 minutes after the specified start time, if the "Scheduler Randomization Time" is also not configured.<br>|
41
+
|Scheduler Randomization Time|0/Not Configured (Default, Scheduled tasks won't be randomized)|Set-MpPreference -SchedulerRandomizationTime <UInt32> <br>For example: Set-MpPreference -SchedulerRandomizationTime 1<br>Note: If Randomize Schedule Task Times is "Not configured" and "Randomize Schedule Task Times" is also set to "Not configured", then the system will use the default behavior within an interval of 30 minutes after the specific start time.<br>Note: If you enable this setting, you must pick a randomization window in hours between 1 and 23. <br> Note 2: Applies to scheduled scans.|
42
+
|Avg CPU Load Factor|50/Not Configured (Default)|Set-MpPreference -ScanAvgCPULoadFactor <Byte><br>For example: Set-MpPreference -ScanAvgCPULoadFactor 50 <br>Note: The default value is 50. The acceptable values are 5 through 100. <br>Note 2: The lower you set it, the longer the scan will take. <br>Note 3: If both ScanOnlyIfIdleEnabled and DisableCpuThrottleOnIdleScans are both enabled, then the value of ScanAvgCPULoadFactor is ignored. <br> Note 4: Applies to scheduled scans. |
||Enabled/Not Configured (Default)|Set-MpPreference -DisableCpuThrottleOnIdleScans <Boolean><br>For example: Set-MpPreference -DisableCpuThrottleOnIdleScans $True <br> Idle here means 90% of CPU utilization or below|
45
+
|Enable Low CPU Priority|Disabled (Default)|Set-MpPreference -EnableLowCpuPriority <Boolean><br>|
For more information about how to use PowerShell with Microsoft Defender Antivirus, see [Use PowerShell cmdlets to configure and run Microsoft Defender Antivirus](use-powershell-cmdlets-microsoft-defender-antivirus.md) and [Defender Antivirus cmdlets](/powershell/module/defender/).
82
97
98
+
#### See also
99
+
100
+
[Troubleshoot Microsoft Defender Antivirus scan issues](/defender-endpoint/troubleshoot-mdav-scan-issues)
101
+
102
+
[Use PowerShell cmdlets to configure and manage Microsoft Defender Antivirus](/defender-endpoint/use-powershell-cmdlets-microsoft-defender-antivirus)
103
+
104
+
[Defender Antivirus specific Powershell functions](/powershell/module/defender/?view=windowsserver2025-ps)
105
+
83
106
> [!TIP]
84
107
> If you're looking for Antivirus related information for other platforms, see:
85
108
> -[Set preferences for Microsoft Defender for Endpoint on macOS](mac-preferences.md)
0 commit comments