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
@@ -196,6 +196,8 @@ The connection string specifies the login name that SQL insights should use when
196
196
The connections string will vary for each type of SQL resource:
197
197
198
198
#### Azure SQL Database
199
+
TCP connections from the monitoring machine to the IP address and port used by the database must be allowed by any firewalls or [network security groups](../../virtual-network/network-security-groups-overview.md) (NSGs) that may exist on the network path. For details on IP addresses and ports, see [Azure SQL Database connectivity architecture](../../azure-sql/database/connectivity-architecture.md).
200
+
199
201
Enter the connection string in the form:
200
202
201
203
```
@@ -208,36 +210,53 @@ Get the details from the **Connection strings** menu item for the database.
To monitor a readable secondary, include the key-value `ApplicationIntent=ReadOnly`in the connection string. SQL Insights supports monitoring a single secondary. The collected data will be tagged to reflect primary or secondary.
213
+
To monitor a readable secondary, append `;ApplicationIntent=ReadOnly`to the connection string. SQL Insights supports monitoring a single secondary. The collected data will be tagged to reflect primary or secondary.
212
214
213
215
#### Azure SQL Managed Instance
216
+
TCP connections from the monitoring machine to the IP address and port used by the managed instance must be allowed by any firewalls or [network security groups](../../virtual-network/network-security-groups-overview.md) (NSGs) that may exist on the network path. For details on IP addresses and ports, see [Azure SQL Managed Instance connection types](../../azure-sql/managed-instance/connection-types-overview.md).
Get the details from the **Connection strings** menu item for the managed instance.
222
-
225
+
Get the details from the **Connection strings** menu item for the managed instance. If using managed instance [public endpoint](../../azure-sql/managed-instance/public-endpoint-configure.md), replace port 1433 with 3342.
To monitor a readable secondary, include the key-value `ApplicationIntent=ReadOnly`in the connection string. SQL Insights supports monitoring of a single secondary. Collected data will be tagged to reflect Primary or Secondary.
229
+
To monitor a readable secondary, append `;ApplicationIntent=ReadOnly`to the connection string. SQL Insights supports monitoring of a single secondary. Collected data will be tagged to reflect Primary or Secondary.
227
230
228
231
#### SQL Server
232
+
The TCP/IP protocol must be enabled for the SQL Server instance you want to monitor. TCP connections from the monitoring machine to the IP address and port used by the SQL Server instance must be allowed by any firewalls or [network security groups](../../virtual-network/network-security-groups-overview.md) (NSGs) that may exist on the network path.
233
+
234
+
If you want to monitor SQL Server configured for high availability (using either availability groups or failover cluster instances), we recommend monitoring each SQL Server instance in the cluster individually rather than connecting via an availability group listener or a failover cluster name. This ensures that monitoring data is collected regardless of the current instance role (primary or secondary).
If your monitoring virtual machine is in the same VNET, use the private IP address of the Server. Otherwise, use the public IP address. If you're using Azure SQL virtual machine, you can see which port to use here on the **Security** page for the resource.
244
+
Use the IP address that the SQL Server instance listens on.
245
+
246
+
If your SQL Server instance is configured to listen on a non-default port, replace 1433 with that port number in the connection string. If you're using Azure SQL virtual machine, you can see which port to use on the **Security** page for the resource.
For any SQL Server instance, you can determine all IP addresses and ports it is listening on by connecting to the instance and executing the following T-SQL query, as long as there is at least one TCP connection to the instance:
251
+
252
+
```sql
253
+
SELECT DISTINCT local_net_address, local_tcp_port
254
+
FROMsys.dm_exec_connections
255
+
WHERE net_transport ='TCP'
256
+
AND
257
+
protocol_type ='TSQL';
258
+
```
259
+
241
260
## Monitoring profile created
242
261
243
262
Select **Add monitoring virtual machine** to configure the virtual machine to collect data from your SQL resources. Do not return to the **Overview** tab. In a few minutes, the Status column should change to read "Collecting", you should see data for the SQL resources you have chosen to monitor.
0 commit comments