Windows Defender Exclusions SQL Server

These are the Powershell commands for exclusions on a Microsoft SQL Server on Windows 2016.  This only includes the Database role, if you have Reporting, Analysis, Full Text Indexing or other roles there will be more.

The -ExclusionPath will need to be changed to what you configured in SQL on install.

Powershell must be run as administrator.

Add-MpPreference -ExclusionExtension “.mdf”
Add-MpPreference -ExclusionExtension “.ldf”
Add-MpPreference -ExclusionExtension “.ndf”
Add-MpPreference -ExclusionExtension “.bak”
Add-MpPreference -ExclusionExtension “.trn”
Add-MpPreference -ExclusionExtension “.trc”
Add-MpPreference -ExclusionExtension “.sqlaudit”
Add-MpPreference -ExclusionExtension “.sql”
Add-MpPreference -ExclusionProcess “SQLServr.exe”
Add-MpPreference -ExclusionPath “E:\Temp”
Add-MpPreference -ExclusionPath F:\Logs
Add-MpPreference -ExclusionPath G:\Data
Add-MpPreference -ExclusionPath H:\Backup

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Powered by WordPress.com.

Up ↑

%d bloggers like this: