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: articles/defender-for-cloud/enable-defender-sql-at-scale.md
+38-5Lines changed: 38 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,7 @@ ms.topic: how-to
5
5
ms.author: dacurwin
6
6
author: dcurwin
7
7
ms.date: 07/14/2024
8
+
#customer intent: As a user, I want to learn how to enable Defender for SQL servers at scale so that I can protect my SQL servers efficiently.
8
9
---
9
10
10
11
# Enable Microsoft Defender for SQL servers on machines at scale
@@ -45,9 +46,9 @@ This page explains how you can enable the auto-provisioning process for Defender
45
46
46
47
- Permissions: requires VM contributor, contributor or owner rules.
47
48
48
-
## Run the Powershell script
49
+
## Powershell script parameters and samples
49
50
50
-
The Powershell script that enables Microsoft Defender for SQL on Machines on a given subscription.
51
+
The Powershell script that enables Microsoft Defender for SQL on Machines on a given subscription has several parameters that you can customize to fit your needs. The following table lists the parameters and their descriptions:
51
52
52
53
| Parameter name | Required | Description |
53
54
|--|--|--|
@@ -57,8 +58,40 @@ The Powershell script that enables Microsoft Defender for SQL on Machines on a g
57
58
| DataCollectionRuleResourceId | Optional | The resource ID of the data collection rule, if you want to use a custom DCR instead of the default one. |
58
59
| UserAssignedIdentityResourceId | Optional | The resource ID of the user assigned identity, if you want to use a custom user assigned identity instead of the default one. |
59
60
61
+
The following is a sample script for when you use a default Log Analytics workspace, data collection rule and managed identity.
62
+
63
+
```powershell
64
+
Write-Host "------ Enable Defender for SQL on Machines example ------"
## Enable Defender for SQL servers on machines at scale
82
+
83
+
60
84
1. Open a Powershell window.
61
-
1.
62
-
1.
63
85
64
-
```powershell
86
+
1. Copy the [EnableDefenderForSqlOnMachines.ps1](https://github.com/Azure/Microsoft-Defender-for-Cloud/blob/fd04330a79a4bcd48424bf7a4058f44216bc40e4/Powershell%20scripts/Enable%20Defender%20for%20SQL%20servers%20on%20machines/EnableDefenderForSqlOnMachines.ps1) script.
87
+
88
+
1. Paste the script into Powershell.
89
+
90
+
1. Enter parameter information as needed.
91
+
92
+
1. Run the script.
93
+
94
+
## Next step
95
+
96
+
> [!div class="nextstepaction"]
97
+
> [Scan your SQL servers for vulnerabilities](defender-for-sql-on-machines-vulnerability-assessment.md)
0 commit comments