VM intermittent connection loss

Xue 0 Reputation points
2023-07-20T11:44:16.73+00:00

Hi all, I meet an issue, some of virtual machines hosted by me has experienced intermittent connection loss. it would suddenly lose connection from the VM and then back to live again. I have no clue what may cause it. I haven't made any change on those VMs for a while. any this issue only occurred on some of the VMs I hosted.

Please advise me with any potential solution, Thank you all in advanced

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,816 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. kobulloc-MSFT 26,246 Reputation points Microsoft Employee
    2023-07-20T14:24:05.63+00:00

    Hello, @Xue !

    Why am I suddenly experiencing intermittent connection loss on my VM?

    There are a large number of issues that could cause this (network configurations, network issues, software conflicts, hardware limitations, and more) but the fact that this VM has worked without issue in the past and that no configuration changes have been made will help in narrowing down the list of troubleshooting steps although ultimately a network trace may be needed:

    • SNAT port exhaustion: In some scenarios, the VM is placed behind a load balance solution that has a dependency on resources outside of Azure. In these scenarios, if you experience intermittent connection problems, the problem may be caused by SNAT port exhaustion. To resolve the issue, create a VIP (or ILPIP for classic) for each VM that is behind the load balancer and secure with NSG or ACL.
    • TCP Connection Limit: There's a limit on the number of outbound connections that can be made. The limit on outbound connections is associated with the size of the worker used.
    • RDP Listener Not Properly Configured: You may face intermittent RDP connectivity problems during your sessions. You can initially connect to the VM, but then the connection drops. This problem may occur if the RDP Listener is misconfigured. Typically, this problem occurs on a VM that uses a custom image.
    • High Resource Use on VM: Performance issues occur in different operating systems or applications, and every issue requires a unique approach to troubleshoot. Most of these issues revolve around CPU, Memory, Networking, and input/output (I/O) as key locations where the issue occurs. Each of these areas generates different symptoms (sometimes simultaneously) and requires a different diagnosis and solution.

    If those troubleshooting steps don't resolve the issue, then you'll likely want to take a closer look at the network traffic on the VM to establish exactly where you are running into issue. These are the most common troubleshooting guides although there are more here that may be useful:

    Hopefully this is useful! If you've completed all of the troubleshooting steps and are still running into issues, let us know in the comments so we can continue to troubleshoot this.


    Your feedback is important so please take a moment to accept answers.

    If you still have questions, please let us know what is needed in the comments so the question can be answered. Thank you for helping to improve Microsoft Q&A!

    User's image

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.