Sql-server – How to disconnect a VM from a Log Analytics workspace that has already been deleted

azureconfigurationloggingsql servervirtual-machines

I created a Log Analytics Workspace (LAW) and connected the SQL Server to it in order to test a theory. I then deleted the Log Analytics Workspace (LAW) but did not "Disconnect" it from the LAW.

I then created a new LAW and connected the Web Server to it but am unable to connect the SQL Server because it still thinks its connected to a LAW.

Click this to see the example

In the Image you can see the VM-WEBSERVER is connected to "This Workspace" but the VM-SQLSERVER is connected to "Other Workspace"

I tried using the Azure Dashboard to "Disconnect" the SQL Server but after 2 hours of processing nothing happened and it is still connected to "Other Workspace". The presuming the reason it is not working is because that LAW no longer exists.

How do i disconnect the SQL Server from a LAW that no longer exists?

Best Answer

So I believe that I solved this.

What you need to do to disconnect a VM from an already deleted LAW is to delete any monitoring extensions from the VM.

Here is a link to an MSDN post that gave me the insight

How to reassign VM insights to another Log Analytics workspace? https://social.msdn.microsoft.com/Forums/en-US/7c24366a-66b6-4d97-9581-a8076e8a6bfa/how-to-reassign-vm-insights-to-another-log-analytics-workspace?forum=opinsights

Related Topic