RDP Session with a RDP Gateway disconnects when copying larger files from \\tsclient to server.

Hello everyone,

We host a remote desktop environment for customers consisting of a Windows 2012 R2 Session Broker connecting to Terminal Servers 2012 R2. Clients run mostly Windows 7 and some Windows 8 machines (up-to-date) with Remote Desktop Connection 6.3.9600.

The following situation occurs:
When clients connect through the Remote Desktop Gateway (our Session Broker) and try copying a file from \\tsclient to the terminal server, the RDP connection disconnects and reconnects. The file transfer has been aborted with error message "Error 0x800703E3: The I/O operation has been aborted because of the closing of a thread or because of a command from an application" (Freely translated into English). Choosing Retry from the dialogue option results in a different error message: "Insufficient memory is available to complete this operation." (Again, this is a translated message.)

This problem only occurs when copying files larger than 2,5MB (estimation). Smaller files will be copied correctly. 
This problem does not occur when connecting directly (no RD Gateway) to the terminal server.
Using drag-and-drop to copy the files has no different effect.

Can anyone assist me resolving this issue? If there is need for more information, please let me know.

Auke, Netformatie

May 21st, 2015 12:05pm

Hi,

Have you looked at Wireshark capture(s) of when this problem occurs?  You may need to have multiple capture points.  For example, on the client PC, on the RDG, on the RDSH, the switch that the clients connect to, the switch that the servers connect to, any routers, etc.

Are there any entries in the RDG log when a user is disconnected?  The RDG logs are under Event Viewer\ Applications and Services Logs\ Microsoft\ Windows\ TerminalServices-Gateway

-TP


Free Windows Admin Tool Kit Click here and download it now
May 25th, 2015 11:30am

Hi,

Have you looked at Wireshark capture(s) of when this problem occurs?  You may need to have multiple capture points.  For example, on the client PC, on the RDG, on the RDSH, the switch that the clients connect to, the switch that the servers connect to, any routers, etc.

Are there any entries in the RDG log when a user is disconnected?  The RDG logs are under Event Viewer\ Applications and Services Logs\ Microsoft\ Windows\ TerminalServices-Gateway

-TP


May 25th, 2015 11:30am

Hello TP,

Thank you for your reply. We have not looked at Wireshark captures just yet, as we may have a solution to the problem. To clarify: we did some additional testing and know a bit more where the problem lies. 

The problem does not occur in the following situations:
Copying files when using RDP client 6.2.9200
Copying files with UDP disabled on the client via Group Policy (Enable: Computer Configuration\Administrative Templates\Windows Components\Remote Desktop Services\Remote Desktop Client\Turn Off UDP On Client)

The following messages are logged in the TerminalServices-Gateway log:

Log Name:      Microsoft-Windows-TerminalServices-Gateway/Operational
Source:        Microsoft-Windows-TerminalServices-Gateway
Date:          27/05/2015 08:51:04
Event ID:      303
Task Category: (3)
Level:         Information
Keywords:      (16777216)
User:          NETWORK SERVICE
Computer:      RDGateway
Description:
The user "user" client computer "<ip-address>", disconnected from the following network resource: "TS". Before the user disconnected, the client transferred 1865 bytes and received 4344 bytes. The client session duration was 46 seconds. Connection protocol used: "UDP".


It seems when copying files larger than 2,5MB (estimation), UDP is used to copy the file. With the current version on the client and RDGateway, the UDP causes a disconnect.

We hope to resolve this by installing KB2989039 on the RDGateway server. (https://support.microsoft.com/en-us/kb/2989039).

I'll let you know later this week when we installed the update and rebooted the server.

Auke - Netformatie


Free Windows Admin Tool Kit Click here and download it now
May 27th, 2015 3:34am

Hello TP,

Thank you for your reply. We have not looked at Wireshark captures just yet, as we may have a solution to the problem. To clarify: we did some additional testing and know a bit more where the problem lies. 

The problem does not occur in the following situations:
Copying files when using RDP client 6.2.9200
Copying files with UDP disabled on the client via Group Policy (Enable: Computer Configuration\Administrative Templates\Windows Components\Remote Desktop Services\Remote Desktop Client\Turn Off UDP On Client)

The following messages are logged in the TerminalServices-Gateway log:

Log Name:      Microsoft-Windows-TerminalServices-Gateway/Operational
Source:        Microsoft-Windows-TerminalServices-Gateway
Date:          27/05/2015 08:51:04
Event ID:      303
Task Category: (3)
Level:         Information
Keywords:      (16777216)
User:          NETWORK SERVICE
Computer:      RDGateway
Description:
The user "user" client computer "<ip-address>", disconnected from the following network resource: "TS". Before the user disconnected, the client transferred 1865 bytes and received 4344 bytes. The client session duration was 46 seconds. Connection protocol used: "UDP".


It seems when copying files larger than 2,5MB (estimation), UDP is used to copy the file. With the current version on the client and RDGateway, the UDP causes a disconnect.

We hope to resolve this by installing KB2989039 on the RDGateway server. (https://support.microsoft.com/en-us/kb/2989039).

I'll let you know later this week when we installed the update and rebooted the server.

Auke - Netformatie


May 27th, 2015 7:32am

Hi,

If your server has one of the more recent rollups it should already have this update.  If it doesn't then I would suggest applying the latest updates and see if the issue you are experiencing is resolved.  In my experience copying files works fine via Server 2012 RDG over UDP.

-TP

Free Windows Admin Tool Kit Click here and download it now
May 27th, 2015 11:52am

Hi Auke,

Are there any updates at the moment?

Best Regards,

Amy

May 30th, 2015 3:51pm

Hello,

This weekend we installed KB2984006 on the RDGateway server. This was the only server not containing this update. We rebooted the server and the Terminal Server, but to no avail. When transferring larger files, the RDP connection still resets.

The KB2984006 contains the update that fixes the UPD error, but this has not resolved our issue. 
I'm going to install the KB2989039 as a stand-alone update and see if that helps.

Any more suggestions?

Regards,
Auke

Free Windows Admin Tool Kit Click here and download it now
June 2nd, 2015 9:20am

Hello,

I'm very interested in the progression of this request as we appear to be having a very similar issue. We have RDS 2012 R2 and have published our app through it, this part works fine. Within our App there is the functionality to export reports to local user PCs using \\tsclient, this is where we have problems.

The reports vary in size, but when trying to save, the file is created, gets to 6KB in size and then hangs the whole app. We then have to kill the users from task manager or rdms.

On the client PCs we have disabled UDP transport in regedit as a test:

HKLM\Software\Microsoft\Terminal Server Client\DisableUDPTransport (DWORD) = 1 to the box

This fixes the problem for Windows 7 and 8.1 users on the latest RDP client. Please note we have this issue on varying Windows OS and RDP client versions.

We can't ask our customers to add that regedit, it's too much of a hack, there has to be something within RDS that we can change.

Has anyone else come across this problem?

Thanks

Steve


June 3rd, 2015 2:02pm

Hi Auke,

Did you do a network capture on the client PC and RDG server simultaneously and take a look at what is happening to the UDP packets?

-TP

Free Windows Admin Tool Kit Click here and download it now
June 3rd, 2015 6:51pm

Hello everyone,

There does not seems te be a stand-alone update for KB2989039, it is only available through the update package KB2984006.

This particular update is installed on the Windows 8.1 client, on the RDGateway server and on the terminal server. Just to be sure, I rebooted them all last night, but this issue is still occuring.

I'm going to schedule a network test with our network department, so we can capture the UDP packets and see what is happening with the stream and in which part of the proces the connection breaks. 

If anyone has anymore suggestions or helpful information, I would like to hear. I will keep you updated.

Regards,
Auke

June 4th, 2015 8:29am

Hello everyone,

We performed a Wireshark capture on my workstation and on the terminal server (RDGateway is not possible during production times), and here are the results:

WireShark capture between Win8.1 and Win2012R2 Terminal Server, through a Win2012R2 RD Gateway.
This is the capture from the client:
16808 11.916200000 <client-ip> <RDGateway-ip> TCP 54 1479443 [RST, ACK] Seq=33054 Ack=566 Win=0 Len=0

This is the capture from the terminal server:
10353 6.997612000 <RDGateway-ip> <TS-ip> TCP 60 647633389 [RST, ACK] Seq=25269 Ack=2645 Win=0 Len=0

From the results its seems that the Windows client sends a reset packet to the RDGateway server when the UDP stream has been started. The root of the problem probably lies in the connection between the client and the RDGateway. I double checked the client and the RDGateway to verify that KB2984006 has been installed. I will test with more client pc's to verify if they have the same issues.

As for Windows 7 clients, I found this article: https://social.technet.microsoft.com/Forums/windowsserver/en-US/bd96e1a9-81ec-4306-bacc-4cff442d30c8/rds-2012-http-udp-gateway-connections-reset?forum=winserverTS. It states that Win7 clients should not install http://support.microsoft.com/kb/2923545. I will try and verify if this is the case.

Regards,
Auke

Free Windows Admin Tool Kit Click here and download it now
June 4th, 2015 9:09am

Hi Auke,

Thank you for keeping us posted.

Best Regards,

Amy

June 9th, 2015 4:13am

Hello,

We managed to fix our problem as explained above by installing KB2984006 on our two web front ends and two session host servers. I found that this update was only installed on one of the four servers, after installing on all of them and rebooting we are now able to export from all client PCs.

This is a strange issue, upon first setting up RDS in our environment we didn't allow UDP traffic through the main firewall, so all connections were either HTTP or RCP-HTTP. We then allowed UDP traffic by changing the settings on the gateway servers, this allowed some clients to connect via UDP, but still didn't fix our problem.

We now appear to be in a position where UDP streaming is working and our reports are exporting.

Auke, I hope you fix your problem and will keep a look out on this thread for updates.

http://www.srs-net.co.uk/tsclient-file-transfer/


Free Windows Admin Tool Kit Click here and download it now
June 10th, 2015 3:32am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics