Skip to content

Commit 51da065

Browse files
committed
Stage update to troubleshooting guide
1 parent 26e31a8 commit 51da065

1 file changed

Lines changed: 22 additions & 4 deletions

File tree

docs/sql-server/azure-arc/troubleshoot-extension.md

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ ms.topic: troubleshooting-general
1111

1212
[!INCLUDE [sqlserver](../../includes/applies-to-version/sqlserver.md)]
1313

14-
Use Azure Resource Graph to identify the state the Azure extension for SQL Server on your Azure Arc-enabled servers. This article demonstrates queries that identify unhealthy extensions.
14+
Use Azure Resource Graph to identify the state the Azure extension for SQL Server on your Azure Arc-enabled servers. This article demonstrates queries that identify unhealthy extensions.
1515

1616
> [!TIP]
1717
> If you're not already familiar, learn about Azure Resource Graph:
@@ -21,7 +21,14 @@ Use Azure Resource Graph to identify the state the Azure extension for SQL Serve
2121
2222
## Identify unhealthy extensions
2323

24-
This query returns instances of SQL Server on servers with extensions installed, but not healthy.
24+
You can create a dashboard in Azure portal to show the health for all deployed Azure extensions for SQL Server.
25+
26+
> [!TIP]
27+
> Create your own dashboard with this file from the sql-server-samples GitHub repository: [Arc-enabled SQL Server Health.json](https://github.com/microsoft/sql-server-samples/blob/master/samples/features/azure-arc/dashboard/Arc-enabled%20SQL%20Server%20Health.json).
28+
29+
### Query unhealthy extensions
30+
31+
This query returns instances of SQL Server on servers with extensions installed, but not healthy.
2532

2633
```kusto
2734
resources
@@ -54,7 +61,7 @@ resources
5461
)
5562
| extend RecommendedAction = //Attempt to Identify RootCause based on information gathered, and point customer to what they should investigate first.
5663
iif(MachineStatus == "Disconnected", "Machine is disconnected. Please reconnect the machine.",
57-
iif(MachineStatus == "Expired", "Machine cert is expired. Go to the machine on the Azure Portal for more information on how to resolve this issue.",
64+
iif(MachineStatus == "Expired", "Machine cert is expired. Go to the machine on the Azure portal for more information on how to resolve this issue.",
5865
iif(MachineStatus != "Connected", strcat("Machine status is ", MachineStatus,". Investigate and resolve this issue."),
5966
iif(MachineProvisioningStatus != "Succeeded", strcat("Machine provisioning status is ", MachineProvisioningStatus, ". Investigate and resolve machine provisioning status"),
6067
iff(MachineErrors != "[]", "Machine is reporting errors. Investigate and resolve machine errors",
@@ -83,6 +90,17 @@ resources
8390

8491
To identify possible problems, review the value in the **RecommendedAction** or the **FailureReasons** column. The RecommendedAction column provides possible first steps to solve the issue or clues for what to check first. The FailureReasons column lists the reasons the resource was deemed unhealthy. Finally, check **LastExtensionStatusMessage** to see the last reported message by the agent.
8592

93+
### Troubleshooting guide
94+
95+
| Recommended Action | Action Details |
96+
|--------------------|----------------|
97+
| Machine cert is expired.<br /><br />Go to the machine on the Azure portal for more information on how to resolve this issue. | The Arc-enabled machine must be re-onboarded to Arc because the certificate used to authenticate to Azure has expired. The Arc machine status is **Expired** in the Azure portal. Uninstall the agent by following the documentation [here](/azure/azure-arc/servers/manage-agent#uninstall-the-agent) and then re-onboard [here](/azure/azure-arc/servers/deployment-options). There is no need to delete the Arc-enabled SQL Server resources in the portal if you are just re-onboarding. The SQL extension will be automatically installed again as long as [auto-onboarding](connect.md) is enabled (default). |
98+
| Machine is disconnected.<br /><br />Reconnect the machine. | The Arc machine is in a `state = Disconnected`. This state could be for a variety of reasons:<br /><br />Arc connected machine agent is stopped, disabled or constantly crashing<br /><br />or<br /><br />Connectivity is blocked between the agent and Azure.<br /><br />[Check the state of that Arc connected machine services/daemons to make sure they are enabled and running](/azure/azure-arc/servers/agent-overview#agent-resources).<br /><br />[Check the connectivity](/azure/azure-arc/servers/troubleshoot-agent-onboard).<br /><br />[Troubleshoot the agent using the verbose log](/azure/azure-arc/servers/troubleshoot-agent-onboard#agent-verbose-log). |
99+
| Extension reported as unhealthy.<br /><br />View FailureReasons and LastExtensionStatusMessage for more information as to the cause of the failure.<br /><br />Last upload outside acceptable range (within the last 3 days). | Check the **LastExtensionUploadTimestamp** column. If it is **No timestamp**, it has never reported inventory or usage data to Azure. [Troubleshoot connectivity from the SQL extension to Azure](troubleshoot-telemetry-endpoint.md).<br /><br />If the last upload is outside the acceptable range (within the last 3 days) and everything else looks OK such as **LastExtensionUploadStatus**, **ExtensionProvisioningState**, and **MachineStatus**, then it is possible that the Arc SQL Extension service/daemon is stopped. Figure out why it is stopped and start it again. Check the **LastExtensionStatusMessage** for any other clues about the problem. |
100+
| Extension provisioning status is **Failed**.<br /><br />Investigate and resolve extension provisioning state. | Either the initial installation of the SQL extension or the update failed.[ Check the deployer and extension logs](troubleshoot-deployment.md).<br /><br />Check the value in the **LastExtensionStatusMessage**. |
101+
| Upload status is not reported OK | Check the **LastExtensionMessage** column in the dashboard and look at the **uploadStatus** value and the **uploadMessage** value (if present, depending on version).<br /><br />The **uploadStatus** value is typically an HTTP error code. Review [Troubleshoot error codes](troubleshoot-telemetry-endpoint.md#error-codes).<br /><br />The **uploadMessage** may have more specific information. [General Arc SQL extension connectivity troubleshooting](troubleshoot-telemetry-endpoint.md). |
102+
| Extension provisioning status is **Updating**<br /><br />or<br /><br />Extension provisioning state is **Creating**<br /><br />or<br /><br />Extension provisioning state is **Failed**<br /><br />or<br /><br />Extension provisioning state is **Deleting** | If a given extension stays one of these states for more than 30 minutes, there is likely a problem with provisioning. Uninstall the extension and reinstall it using the CLI or portal. If the problem persists, [check the deployer and extension logs](troubleshoot-deployment.md).<br /><br />If delete fails, try uninstalling the agent and deleting the Arc machine resource in the portal if needed and then redeploy.<br /><br />Uninstall the agent by following the documentation [here](/azure/azure-arc/servers/manage-agent#uninstall-the-agent) and then re-onboard [here](/azure/azure-arc/servers/deployment-options). |
103+
86104
## Identify unhealthy extension (PowerShell)
87105

88106
This example runs in PowerShell. The example returns the same result as the previous query but through a PowerShell script.
@@ -128,7 +146,7 @@ resources
128146
)
129147
| extend RecommendedAction = //Attempt to Identify RootCause based on information gathered, and point customer to what they should investigate first.
130148
iif(MachineStatus == "Disconnected", "Machine is disconnected. Please reconnect the machine.",
131-
iif(MachineStatus == "Expired", "Machine cert is expired. Go to the machine on the Azure Portal for more information on how to resolve this issue.",
149+
iif(MachineStatus == "Expired", "Machine cert is expired. Go to the machine on the Azure portal for more information on how to resolve this issue.",
132150
iif(MachineStatus != "Connected", strcat("Machine status is ", MachineStatus,". Investigate and resolve this issue."),
133151
iif(MachineProvisioningStatus != "Succeeded", strcat("Machine provisioning status is ", MachineProvisioningStatus, ". Investigate and resolve machine provisioning status"),
134152
iff(MachineErrors != "[]", "Machine is reporting errors. Investigate and resolve machine errors",

0 commit comments

Comments
 (0)