I was not able to access my Windows Server VM from Cloud Shell, on account of a certificate error.
I'm following this documentation: https://docs.microsoft.com/en-us/azure/cloud-shell/quickstart-powershell#interactively-log-on-to-a-remote-vm
My instance is named 'mb2'. I was hoping to run:
Enable-AzVMPSRemoting -Name mb2 -ResourceGroupName mb2_group
cd 'Azure:/Free Trial/ResourceGroups/mb2_group/Microsoft.Compute/virtualMachines'
Get-Item mb2 | Enter-AzVM -Credential (Get-Credential)
But the final command fails:
PS Azure:\> Get-Item mb2 | Enter-AzVM -Credential (Get-Credential)
PowerShell credential request
Enter your credentials.
User: mb
Password for user mb: ***Enter-PSSession: /usr/local/share/powershell/Modules/PSCloudShellUtility/PSCloudShellUtility.psm1:958
Line |
958 | Enter-PSSession -ComputerName $cName -Credential $Credential …
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| Connecting to remote server 51.105.36.33 failed with the following error message : error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed For more
| information, see the about_Remote_Troubleshooting Help topic.Azure:/Free Trial/ResourceGroups/mb2_group/Microsoft.Compute/virtualMachines
PS Azure:\>
It appears that the 'Enter-AzVM' command is failing on account of not knowing my VM's thumbprint.
I'm able to connect to the VM from my local machine using RDP (blindly accepting the reported thumbprint).
A chat session with Azure support was not able to resolve the issue.