While trying to connect to my Azure SQL Virtual Machine, I got this error “The Remote computer that you are trying to connect to requires Network level Authentication (NLA, but your windows domain controller cannot be contacted to perform NLA. if you are an administrator on the remote computer, you can disable NLA by using the options on the remote tab of the system properties dialog box”.
Little Background : I have a SharePoint 2016 Farm provisioned in Azure with a Virtual Network, a Domain Controller, SQL Server and a SharePoint Beta 2 Machine. See the Configuration Step-by-Step: Create SharePoint 2016 Farm with Azure Virtual Machines
See the Configured SQL Server with DNS entry Provision SQL Server VM for SharePoint 2016 Install in Azure
I quickly googled and was referred to this article where the suggestion was to reconfigure the Domain on the Server. In my case, i couldn’t login with the domain id but my domain on the server was configured correctly.
So I followed another article where it was suggested to set “SecurityLayer” element in registry on the SQL server to “0”. So to do this, I needed to login with the initial local account that I created the image with (i.e. non-domain local account).
a) Login to the SQL server with Local Machine Credentials.
b) Run Registry Edit (Regedit) and navigate to HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Terminal Server\WinStations\RDP-Tcp
c) Set the value for SecurityLayer to 0.
I then disconnected the VM and logged in again with the Domain Id which totally worked.