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: azure-sql/database/failover-group-sql-db.md
+1-4Lines changed: 1 addition & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -90,10 +90,7 @@ There is some overlap of content in the following articles, be sure to make chan
90
90
91
91
-**Failover group read-only listener**
92
92
93
-
A DNS CNAME record that points to the current secondary. It's created automatically when the failover group is created and allows the read-only SQL workload to transparently connect to the secondary when the secondary changes after failover. When the failover group is created on a server, the DNS CNAME record for the listener URL is formed as `<fog-name>.secondary.database.windows.net`. By default, failover of the read-only listener is disabled as it ensures the performance of the primary isn't affected when the secondary is offline. However, it also means the read-only sessions won't be able to connect until the secondary is recovered. If you can't tolerate downtime for the read-only sessions and can use the primary for both read-only and read-write traffic at the expense of the potential performance degradation of the primary, you can enable failover for the read-only listener by configuring the `AllowReadOnlyFailoverToPrimary` property. In that case, the read-only traffic is automatically redirected to the primary if the secondary isn't available.
94
-
95
-
> [!NOTE]
96
-
> The `AllowReadOnlyFailoverToPrimary` property only has effect if Microsoft managed failover policy is enabled and a forced failover has been triggered. In that case, if the property is set to True, the new primary will serve both read-write and read-only sessions.
93
+
A DNS CNAME record that points to the current secondary. It's created automatically when the failover group is created and allows the read-only SQL workload to transparently connect to the secondary when the secondary changes after failover. When the failover group is created on a server, the DNS CNAME record for the listener URL is formed as `<fog-name>.secondary.database.windows.net`. By default, failover of the read-only listener is disabled as it ensures the performance of the primary isn't affected when the secondary is offline. However, it also means the read-only sessions won't be able to connect until the secondary is recovered.
Copy file name to clipboardExpand all lines: azure-sql/managed-instance/failover-group-configure-sql-mi.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -524,10 +524,12 @@ When using failover groups, consider the following limitations:
524
524
- after failover, and can delay or prevent a subsequent failover.
525
525
- Database rename isn't supported for databases in failover group. You'll need to temporarily delete the failover group to be able to rename a database.
526
526
- System databases aren't replicated to the secondary instance in a failover group. Therefore, scenarios that depend on objects from the system databases such as Server Logins and Agent jobs, require objects to be manually created on the secondary instances and also manually kept in sync after any changes made on primary instance. The only exception is Service master Key (SMK) for SQL Managed Instance that is replicated automatically to secondary instance during creation of failover group. Any subsequent changes of SMK on the primary instance however won't be replicated to secondary instance. To learn more, see how to [Enable scenarios dependent on objects from the system databases](#enable-scenarios-dependent-on-objects-from-the-system-databases).
527
+
- When new databases are added to a failover group, planned failover is unavailable until the new database has been seeded to the secondary replica and is synchronized. Forced failover is still available during this process.
527
528
- For instances inside of a failover group, changing the service tier to, or from, the Next-gen General Purpose tier isn't supported. You must first delete the failover group before modifying either replica, and then re-create the failover group after the change takes effect.
528
529
- SQL managed instances in a failover group must have the same [update policy](update-policy.md), though it's possible to [change the update policy](#change-update-policy) for instances within a failover group.
529
530
530
531
532
+
531
533
## <aid="programmatically-managing-failover-groups"></a> Programmatically manage failover groups
532
534
533
535
Failover groups can also be managed programmatically using Azure PowerShell, Azure CLI, and REST API. The following tables describe the set of commands available. Failover groups include a set of Azure Resource Manager APIs for management, including the [Azure SQL Database REST API](/rest/api/sql/) and [Azure PowerShell cmdlets](/powershell/azure/). These APIs require the use of resource groups and support Azure role-based access control (Azure RBAC). For more information on how to implement access roles, see [Azure role-based access control (Azure RBAC)](/azure/role-based-access-control/overview).
Copy file name to clipboardExpand all lines: azure-sql/managed-instance/failover-group-sql-mi.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -74,10 +74,7 @@ There's some overlap of content in the following articles, be sure to make chang
74
74
75
75
-**Failover group read-only listener**
76
76
77
-
A DNS CNAME record that points to the current secondary. It's created automatically when the failover group is created and allows the read-only SQL workload to transparently connect to the secondary when the secondary changes after failover. When the failover group is created on a SQL managed instance, the DNS CNAME record for the listener URL is formed as `<fog-name>.secondary.<zone_id>.database.windows.net`. By default, failover of the read-only listener is disabled as it ensures the performance of the primary isn't affected when the secondary is offline. However, it also means the read-only sessions won't be able to connect until the secondary is recovered. If you can't tolerate downtime for the read-only sessions and can use the primary for both read-only and read-write traffic at the expense of the potential performance degradation of the primary, you can enable failover for the read-only listener by configuring the `AllowReadOnlyFailoverToPrimary` property. In that case, the read-only traffic is automatically redirected to the primary if the secondary isn't available.
78
-
79
-
> [!NOTE]
80
-
> The `AllowReadOnlyFailoverToPrimary` property only has effect if Microsoft managed failover policy is enabled and a forced failover has been triggered. In that case, if the property is set to True, the new primary serves both read-write and read-only sessions.
77
+
A DNS CNAME record that points to the current secondary. It's created automatically when the failover group is created and allows the read-only SQL workload to transparently connect to the secondary when the secondary changes after failover. When the failover group is created on a SQL managed instance, the DNS CNAME record for the listener URL is formed as `<fog-name>.secondary.<zone_id>.database.windows.net`. By default, failover of the read-only listener is disabled as it ensures the performance of the primary isn't affected when the secondary is offline. However, it also means the read-only sessions won't be able to connect until the secondary is recovered.
81
78
82
79
## Failover group architecture
83
80
@@ -267,13 +264,16 @@ Performing a drill using forced failover is **not recommended**, as this operati
267
264
- The workload is stopped on the primary SQL managed instance.
268
265
- All long running transactions have completed.
269
266
- All client connections to the primary SQL managed instance have been disconnected.
270
-
-[Failover group status](failover-group-sql-mi.md#failover-group-status) is 'Synchronizing'.
267
+
-[Failover group status](failover-group-sql-mi.md#failover-group-status) is `Synchronizing` on **both** the primary and secondary instances.
271
268
272
269
Please ensure the two SQL managed instances have switched roles. Also that the failover group status has switched from *'Failover in progress'* to *'Synchronizing'* before optionally establishing connections to the new primary SQL managed instance and starting read-write workload.
273
270
274
-
To perform a data lossless failback to the original SQL managed instance roles, using manual planned failover instead of forced failover is **strongly recommended**. If forced failback is used:
271
+
To perform a data lossless failback to the original SQL managed instance roles, using manual planned failover instead of forced failover is **strongly recommended**.
272
+
273
+
If forced failback is used:
275
274
276
275
- Follow the same steps as for the data lossless failover.
276
+
- Forced failback is expected to fail if a previous forced failover did not succeed on both SQL managed instances. Ensure failover group status is `Synchronizing` on **both** instances before executing the forced failback.
277
277
- Longer failback execution time is expected if the forced failback is executed **shortly after** the initial forced failover is completed, as it has to wait for completion of outstanding automatic backup operations on the former primary SQL managed instance.
278
278
- Any outstanding automatic backup operations on an instance transitioning from the primary to the secondary role can impact database availability on this instance.
279
279
- Please use the failover group status to determine whether both instances have successfully changed their roles and are ready to accept client connections.
Copy file name to clipboardExpand all lines: docs/linux/sql-server-linux-custom-password-policy.md
+21-21Lines changed: 21 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ description: Learn how to use a custom password policy for SQL logins with SQL S
4
4
author: Madhumitatripathy
5
5
ms.author: matripathy
6
6
ms.reviewer: mikeray, randolphwest
7
-
ms.date: 05/01/2025
7
+
ms.date: 01/16/2026
8
8
ms.service: sql
9
9
ms.subservice: linux
10
10
ms.topic: how-to
@@ -30,23 +30,23 @@ Password policies are a crucial aspect of securing any database environment. The
30
30
This enforcement ensures that logins that use SQL Server authentication are secure.
31
31
32
32
> [!NOTE]
33
-
> Password policies are available on Windows. For more information, see [Password Policy](../relational-databases/security/password-policy.md).
33
+
> Password policies are available on Windows. For more information, see [Password policy](../relational-databases/security/password-policy.md).
34
34
35
35
## Custom policy settings
36
36
37
-
Beginning with [!INCLUDE [sssql25-md](../includes/sssql25-md.md)] on Linux, you can set the following configuration parameters in the `mssql.conf` file to enforce a custom password policy.
37
+
In [!INCLUDE [sssql25-md](../includes/sssql25-md.md)] and later versions on Linux, you can set the following configuration parameters in the `mssql.conf` file to enforce a custom password policy.
38
38
39
39
| Configuration option | Description |
40
40
| --- | --- |
41
-
|`passwordpolicy.passwordminimumlength`|Defines the minimum number of characters required for a password. The passwords can be up to 128 characters long. |
42
-
|`passwordpolicy.passwordhistorylength`|Determines the number of previous passwords that must be remembered. |
43
-
|`passwordpolicy.passwordminimumage`|Specifies the minimum duration a user must wait before changing their password again. |
41
+
|`passwordpolicy.passwordminimumlength`|Sets the minimum number of characters required for a password. Passwords can be up to 128 characters long. |
42
+
|`passwordpolicy.passwordhistorylength`|Sets the number of previous passwords that the system remembers. |
43
+
|`passwordpolicy.passwordminimumage`|Sets the minimum duration a user must wait before changing their password again. |
44
44
|`passwordpolicy.passwordmaximumage`| Sets the maximum duration a password can be used before it must be changed. |
45
45
46
46
> [!NOTE]
47
-
> Currently, the `passwordminimumlength` can be set to fewer than eight characters. [!INCLUDE [password-complexity](includes/password-complexity.md)]
47
+
> You can currently set the `passwordminimumlength` to fewer than eight characters. [!INCLUDE [password-complexity](includes/password-complexity.md)]
48
48
49
-
There are two ways to configure custom password policies for SQL authentication logins in SQL Server on Linux:
49
+
You can configure custom password policies for SQL authentication logins in SQL Server on Linux in two ways:
50
50
51
51
-[Enforce custom password policy](#adutil) with **adutil**
52
52
-[Manually configure the `mssql.conf` file](#manual) using the **mssql-conf** tool
@@ -55,19 +55,19 @@ There are two ways to configure custom password policies for SQL authentication
55
55
56
56
## Set custom password policy with adutil
57
57
58
-
In environments where policy management is centralized in an Active Directory (AD) server, domain administrators can set and modify the password policy values in the AD server. Additionally, the Linux machine running SQL Server must also be part of the Windows domain.
58
+
In environments where policy management is centralized in an Active Directory (AD) server, domain administrators set and modify the password policy values in the AD server. The Linux machine running SQL Server must also be part of the Windows domain.
59
59
60
60
Use [adutil](sql-server-linux-ad-auth-adutil-introduction.md) to fetch the password policy from the AD server and write it to the `mssql.conf` file. This method offers the benefit of centralized management, and ensures consistent application of policies across the SQL Server environment.
61
61
62
62
### Requirements for adutil
63
63
64
-
1. Establish a Kerberos authenticated session
64
+
1. Establish a Kerberos authenticated session:
65
65
66
-
- Run `kinit` with `sudo` to obtain or renew the Kerberos ticket-granting ticket (TGT).
66
+
- Run `kinit` with `sudo` to get or renew the Kerberos ticket-granting ticket (TGT).
67
67
68
-
- Use a privileged account for the `kinit` command. The account needs to have permission to connect to the domain.
68
+
- Use a privileged account for the `kinit` command. The account needs permission to connect to the domain.
69
69
70
-
In the following example, replace `<user>` with an account with elevated privileges in the domain.
70
+
In the following example, replace `<user>` with an account that has elevated privileges in the domain.
71
71
72
72
```bash
73
73
sudo kinit <user>@CONTOSO.COM
@@ -85,7 +85,7 @@ Use [adutil](sql-server-linux-ad-auth-adutil-introduction.md) to fetch the passw
85
85
sudo adutil updatepasswordpolicy
86
86
```
87
87
88
-
If the command is successful, you should see a similar message:
88
+
If the command is successful, the output looks similar to the following example:
89
89
90
90
```output
91
91
Successfully updated password policy in mssqlconf.
@@ -102,15 +102,15 @@ Use [adutil](sql-server-linux-ad-auth-adutil-introduction.md) to fetch the passw
102
102
103
103
<aid="manual"></a>
104
104
105
-
## Set custom password policy with mssql-conf manually
105
+
## Manually set a custom password policy using mssql-conf
106
106
107
107
You can set the SQL authentication login password policy by updating the parameters in the `mssql.conf` file with **mssql-conf**. This approach provides simplicity and direct control over the policy settings.
108
108
109
-
Use this method when the Linux host that is running SQL Server isn't part of the domain, and there's no domain controller to get the password policies from.
109
+
Use this method when the Linux host running SQL Server isn't part of the domain, and there's no domain controller to get the password policies from.
110
110
111
111
Run the following **mssql-conf** commands to set each policy configuration property.
112
112
113
-
1. Set the minimum password length to 14 characters, adhering to the complexity requirements outlined in the [Password Policy](../relational-databases/security/password-policy.md).
113
+
1. Set the minimum password length to 14 characters, adhering to the complexity requirements outlined in the [Password policy](../relational-databases/security/password-policy.md).
114
114
115
115
```bash
116
116
sudo /opt/mssql/bin/mssql-conf set passwordpolicy.passwordminimumlength 14
@@ -128,7 +128,7 @@ Run the following **mssql-conf** commands to set each policy configuration prope
128
128
sudo /opt/mssql/bin/mssql-conf set passwordpolicy.passwordhistorylength 8
129
129
```
130
130
131
-
1. Set the maximum password age is set to 45 days. A user can use a password for up to 45 days before the user must change it.
131
+
1. Set the maximum password age to 45 days. A user can use a password for up to 45 days before the user must change it.
132
132
133
133
```bash
134
134
sudo /opt/mssql/bin/mssql-conf set passwordpolicy.passwordmaximumage 45
@@ -146,13 +146,13 @@ Currently, the `minimumpasswordlength` can't be set to more than 14 characters.
146
146
147
147
After updating the group password policy in Active Directory, you must manually run the `adutil updatepasswordpolicy` command to update `mssql.conf`. This command doesn't run automatically. Ensure the Linux machine running SQL Server is part of the domain, or manually set it using **mssql-conf**.
148
148
149
-
In Active Directory, each group-level password policy can be defined or undefined using a checkbox.
149
+
In Active Directory, you can define or undefine each group-level password policy using a checkbox.
However, unchecking the policy doesn't disable it in SQL Server on Linux. To avoid applying the custom password policy, update the settings in **mssql-conf** instead of relying on the checkbox.
0 commit comments