question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

az network bastion rdp leads to msrestazure.azure_exceptions.CloudError: Unexpected internal error

See original GitHub issue

Bug when calling az network bastion rdp --name bastion --resource-group rg-test --subscription xxx --target-resource-id testmachineresourceId --verbose i receive

Creating a socket on port: 0 Setting socket options Binding to socket on local address and port Auto-selecting port: 60545 Finished initialization Exception in thread Thread-1: Traceback (most recent call last): File “threading.py”, line 932, in _bootstrap_inner File “threading.py”, line 870, in run File “D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/network/custom.py”, line 8089, in _start_tunnel File “D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/network/tunnel.py”, line 182, in start_server File “D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/network/tunnel.py”, line 117, in _listen File “D:\a\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/network/tunnel.py”, line 104, in _get_auth_token msrestazure.azure_exceptions.CloudError: Unexpected internal error Command ran in 9.468 seconds (init: 0.262, invoke: 9.205)

To Reproduce just calling the command

Expected behavior native rdp client opens and i can connect through rdp

Environment summary azure-cli 2.32.0 core 2.32.0 telemetry 1.0.6

Extensions: ssh 1.0.0

Dependencies: msal 1.16.0 azure-mgmt-resource 20.0.0

Python location ‘C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\python.exe’ Extensions directory ‘C:\Users\sykorlub.azure\cliextensions’

Python (Windows) 3.8.9 (tags/v3.8.9:a743f81, Apr 6 2021, 13:22:56) [MSC v.1928 32 bit (Intel)]

Additional context bastion is set to support native clients following https://docs.microsoft.com/en-us/azure/bastion/connect-native-client-windows. bastion is hosted in vnet which is peered with second vnet having my test machine. for test purposes all peering connectivity is allowed. for test purposes all incoming traffic is allowed on nsg for test machine. Connecting to test machine through bastion from portal UI works.

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:2
  • Comments:7

github_iconTop GitHub Comments

1reaction
ahmetcecencommented, Mar 15, 2022

Was this ever resolved?

0reactions
KarlRanseiercommented, Jun 3, 2022

still not working in “azure-cli”: “2.37.0”

Read more comments on GitHub >

github_iconTop Results From Across the Web

An internal error occurs when you try to connect to an Azure ...
Symptoms. You can't connect to an Azure VM by using the remote desktop protocol (RDP). The connection gets stuck on the Configuring Remote ......
Read more >
Our Azure Bastion tunnels stopped working yesterday (Apr. 2 ...
az login. az network bastion rdp --name ProdInfrastructure-vnet-bastion ... msrestazure.azure_exceptions.CloudError: Unexpected internal error.
Read more >
How to transfer files to your Azure VM with no public open ...
Then, the Azure Bastion host inside the same Azure virtual network connects to the VM's RDP port. The downside to this is the...
Read more >
Azure Virtual Machine - An Internal Error Occurred - Server Fault
Running the RDPSettings for the VM in question reset a few keys and solved the issue. enter image description here.
Read more >
Fixing the "Remote Desktop Connection: An Internal Error Has ...
The error is due to one or more configuration issues related to RDP and security. In this guide, we'll help you troubleshoot this...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found