RDP session disconnecting after 1 minute and 5 seconds

Minuano 0 Reputation points
2025-02-19T18:56:26.0566667+00:00

Hello, I'm trying to make an RDP connection between a Windows 11 24H2 and a Windows Server 2012 Standard and a disconnection occurs every 1 minute and 5 seconds, approximately.

I noticed that if I force the client to connect via TCP by inserting the fClientDisableUDP key with a value of 1 in the registry "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services\Client" the problem disappears.

In the client's event viewer I find the following messages:

  • RDP ClientActiveX disconnected (Reason=2308)
  • Multitransport connection disconnected.
  • The server is using version 0x80004 of the RDP graphical protocol (client mode: 0, AVC available: 0).
  • The client is using hardware memory for the frame buffer.
  • The client has established a multitransport connection with the server.
  • The server supports SSL = supported
  • Connected to domain (SRVXXX) with session 2.
  • RDP ClientActiveX disconnected (Reason=263)
  • RDPClient_SSL: Error transitioning from TsSslStateHandshakeInProgress to TsSslStateDisconnecting in response to TsSslEventHandshakeContinueFailed (error code 0x80004005)

I can't find anything in the server's event viewer regarding RDP connection problems with the server.

Any tips on what might be happening?

Windows Server
{count} votes

3 answers

Sort by: Most helpful
  1. Jose Benjamin Solis Nolasco 236 Reputation points
    2025-02-19T19:05:52.6033333+00:00

    Keep Using TCP (Quick Fix) thats probably why is working for you

    Since disabling UDP (fClientDisableUDP = 1) works, you can consider keeping this setting as a permanent fix. However, this might slightly increase latency in certain environments.

    1. Test UDP Connectivity

    If you want to diagnose the UDP issue rather than just switch to TCP, try the following:

    Run a network test using PowerShell:

    powershell
    CopyEdit
    Test-NetConnection -ComputerName <server_IP> -Port 3389 -UDP
    

    If the test fails, it confirms a UDP connectivity problem.

    Check for packet loss using pathping:

    cmd
    CopyEdit
    pathping <server_IP>
    

    Look for high packet loss on intermediary network nodes.

    1. Review Windows Server 2012 RDP Settings

    On the server:

    Open Group Policy Editor (gpedit.msc) Go to:

    rust
    CopyEdit
    Computer Configuration -> Administrative Templates -> Windows Components -> Remote Desktop Services -> Remote Desktop Session Host -> Connections
    
    • Ensure “Allow Remote Desktop connections only with Network Level Authentication” is enabled.
      • Ensure “Select RDP transport protocols” is set to Use both TCP and UDP.

    Restart the Remote Desktop Services:

     cmd
     CopyEdit
     net stop termservice /y
    
     
    
    • If your network has a firewall, VPN, or proxy, ensure it allows UDP traffic on port 3389.
    • If there’s a router doing aggressive NAT or session timeouts, try extending UDP session timeout values.

    Keep Using TCP (Quick Fix)

    Since disabling UDP (fClientDisableUDP = 1) works, you can consider keeping this setting as a permanent fix. However, this might slightly increase latency in certain environments.

    2. Test UDP Connectivity

    If you want to diagnose the UDP issue rather than just switch to TCP, try the following:

    • Run a network test using PowerShell:
          powershell
          CopyEdit
          Test-NetConnection -ComputerName <server_IP> -Port 3389 -UDP
      
      If the test fails, it confirms a UDP connectivity problem.
    • Check for packet loss using pathping:
          cmd
          CopyEdit
          pathping <server_IP>
      
      Look for high packet loss on intermediary network nodes.

    3. Review Windows Server 2012 RDP Settings

    On the server:

    • Open Group Policy Editor (gpedit.msc)
      Go to:
      rust
      CopyEdit
      Computer Configuration 
    
    • Ensure “Allow Remote Desktop connections only with Network Level Authentication” is enabled.
    • Ensure “Select RDP transport protocols” is set to Use both TCP and UDP.
    • Restart the Remote Desktop Services:
          cmd
          CopyEdit
          net stop termservice /y
      
          
      
    • If your network has a firewall, VPN, or proxy, ensure it allows UDP traffic on port 3389.
    • If there’s a router doing aggressive NAT or session timeouts, try extending UDP session timeout values.Keep Using TCP (Quick Fix) thats probably why is working for you Since disabling UDP (fClientDisableUDP = 1) works, you can consider keeping this setting as a permanent fix. However, this might slightly increase latency in certain environments.
      1. Test UDP Connectivity
      If you want to diagnose the UDP issue rather than just switch to TCP, try the following: Run a network test using PowerShell:
          powershell
          CopyEdit
          Test-NetConnection -ComputerName <server_IP> -Port 3389 -UDP
      
      If the test fails, it confirms a UDP connectivity problem. Check for packet loss using pathping:
          cmd
          CopyEdit
          pathping <server_IP>
      
      Look for high packet loss on intermediary network nodes.
      1. Review Windows Server 2012 RDP Settings
      On the server: Open Group Policy Editor (gpedit.msc) Go to:
          rust
          CopyEdit
          Computer Configuration -> Administrative Templates -> Windows Components -> Remote Desktop Services -> Remote Desktop Session Host -> Connections
      
      • Ensure “Allow Remote Desktop connections only with Network Level Authentication” is enabled.
        • Ensure “Select RDP transport protocols” is set to Use both TCP and UDP. Restart the Remote Desktop Services:
                   cmd
                   CopyEdit
                   net stop termservice /y
          
                   
          
      • If your network has a firewall, VPN, or proxy, ensure it allows UDP traffic on port 3389.
      • If there’s a router doing aggressive NAT or session timeouts, try extending UDP session timeout values. Keep Using TCP (Quick Fix) Since disabling UDP (fClientDisableUDP = 1) works, you can consider keeping this setting as a permanent fix. However, this might slightly increase latency in certain environments. 2. Test UDP Connectivity If you want to diagnose the UDP issue rather than just switch to TCP, try the following:
        • Run a network test using PowerShell:
          ```powershell
          powershell
          CopyEdit
          Test-NetConnection -ComputerName <server_IP> -Port 3389 -UDP
          ```
          
          If the test fails, it confirms a UDP connectivity problem.
          
        • Check for packet loss using pathping:
          ```yaml
          cmd
          CopyEdit
          pathping <server_IP>
          ```
          
          Look for high packet loss on intermediary network nodes.
          
          3. Review Windows Server 2012 RDP Settings On the server:
        • Open Group Policy Editor (gpedit.msc)
          Go to:
                    rust
                    CopyEdit
                    Computer Configuration 
          
        • Ensure “Allow Remote Desktop connections only with Network Level Authentication” is enabled.
        • Ensure “Select RDP transport protocols” is set to Use both TCP and UDP.
        • Restart the Remote Desktop Services:
          ```yaml
          cmd
          CopyEdit
          net stop termservice /y
          ```
          
          
          ```
          
          ```
          
        • If your network has a firewall, VPN, or proxy, ensure it allows UDP traffic on port 3389.
        • If there’s a router doing aggressive NAT or session timeouts, try extending UDP session timeout values.

  2. Minuano 0 Reputation points
    2025-02-19T22:54:26.6066667+00:00

    Apparently, removing the KB5051987 and KB5050094 updates solves the problem temporarily.

    0 comments No comments

  3. Minuano 0 Reputation points
    2025-02-19T22:55:54.1533333+00:00

    Apparently, removing the KB5051987 and KB5050094 updates solves the problem temporarily.

    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.