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: samples/manage/azure-arc-enabled-sql-server/modify-license-type/README.md
+29-21Lines changed: 29 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,14 +3,13 @@ services: Azure Arc-enabled SQL Server
3
3
platforms: Azure
4
4
author: anosov1960
5
5
ms.author: sashan
6
-
ms.date: 6/4/2023
6
+
ms.date: 7/5/2023
7
7
---
8
8
9
9
10
10
# Overview
11
11
12
-
This script allows you to to set or change the license type on all Azure-connected SQL Servers
13
-
on a specific resource, in a single resource group, a specific subscription, a list of subscriptions or all subscriptions to which you have access. By default, it sets the specified license type value on the servers where it is undefined. But you can request to set it on all servers in the selected scope.
12
+
This script provides a scaleable solution to set or change the license type and/or enable or disable the ESU policy on all Azure-connected SQL Servers in a specified scope.
14
13
15
14
You can specify a single subscription to scan, or provide a list of subscriptions as a .CSV file.
16
15
If not specified, all subscriptions your role has access to are scanned.
@@ -28,11 +27,12 @@ The script accepts the following command line parameters:
|-SubId|subscription_id *or* a file_name|Optional: subscription id or a .csv file with the list of subscriptions<sup>1</sup>. If not specified all subscriptions will be scanned|
32
-
|-ResourceGroup |resource_group_name|Optional: Limit the scope to a specific resource group|
33
-
|-MachineName |machine_name|Optional: Limit the scope to a specific machine|
34
-
|-LicenceType | "Paid", "PAYG" or "LicenseOnly"| Required: Specifies the license type value |
35
-
|-Force|\$True or \$False (default)|Optional. Set the new license type for all installed extensions. By default the value is set only if license type is undefined.|
30
+
|-SubId|subscription_id *or* a file_name|Optional: Subscription id or a .csv file with the list of subscriptions<sup>1</sup>. If not specified all subscriptions will be scanned|
31
+
|-ResourceGroup |resource_group_name|Optional: Limits the scope to a specific resource group|
32
+
|-MachineName |machine_name|Optional: Limits the scope to a specific machine|
33
+
|-LicenceType | "Paid", "PAYG" or "LicenseOnly"| Optional: Sets the license type to the specified value |
34
+
|-EnableESU | "Yes", "No" | Optional. Enables the ESU policy the value is "Yrs" or disables it if the value is "No". To enable, the license type must be "Paid" or "PAYG"|
35
+
|-Force||Optional. Forces the change of the license type to the specified value on all installed extensions. If -Force is not specified, the -LicenseType value is set only if undefined. Ignored if -LicenseType is not specified|
36
36
37
37
<sup>1</sup>You can create a .csv file using the following command and then edit to remove the subscriptions you don't want to scan.
38
38
```PowerShell
@@ -52,15 +52,31 @@ The following command will scan all the subscriptions to which the user has acce
52
52
The following command will scan the subscription `<sub_id>` and set the license type value to "Paid" on all servers.
The following command will scan resource group <resource_group_name> in the subscription `<sub_id>` and set the license type value to "PAYG" on all servers.
60
+
The following command will scan resource group `<resource_group_name>` in the subscription `<sub_id>` and set the license type value to "PAYG" on all servers.
The following command will set License Type to 'Paid" and enables ESU on all servers in the subscriptions `<sub_id>` and the resource group `<resource_group_name>`.
# This script provides a scaleable solution to set or change the license type on all Azure-connected SQL Servers
3
-
# in a specific subscription, a list of subscruiptions or the entire account. By default, it sets the new license
4
-
# type value only on the servers where it is undefined.
2
+
# This script provides a scaleable solution to set or change the license type and/or enable or disable the ESU policy
3
+
# on all Azure-connected SQL Servers in a specified scope.
5
4
#
6
5
# You can specfy a single subscription to scan, or provide subscriptions as a .CSV file with the list of IDs.
7
6
# If not specified, all subscriptions your role has access to are scanned.
8
7
#
9
8
# The script accepts the following command line parameters:
10
9
#
11
-
# -SubId [subscription_id] | [csv_file_name] (Limit scope to specific subscriptions. Accepts a .csv file with the list of subscriptions.
10
+
# -SubId [subscription_id] | [csv_file_name] (Optional. Limits the scope to specific subscriptions. Accepts a .csv file with the list of subscriptions.
12
11
# If not specified all subscriptions will be scanned)
13
-
# -ResourceGroup [resource_goup] (Limit scope to a specific resoure group)
14
-
# -MachineName [machine_name] (Limit scope to a specific machine)
0 commit comments