none
mstsc.exe keeps running in background after closing RemoteApp - Server 2019 LTSC RRS feed

Answers

  • Hi,

    I did quick test with Server 2019 Standard Build 17763.805 running all RDS roles and client PC with Windows 10 Pro 1903 Build 18362.449.  Used IE to open RDWeb, selected Private option, logged on, launched RemoteApp, right-click on RADC icon --> Disconnect all connections, launched RemoteApp again, repeated many times.  Had no issues, and mstsc.exe process terminated automatically several seconds after disconnect.

    I tested with connection going through RD Gateway as well as direct.

    Have you tested with TCP only to see if it changes anything?  You can select this via Select RDP transport protocols group policy setting on your RDSH server and then test.

    If you right-click on the hung mstsc.exe process and choose Analyze wait chain, are there any clues?

    -TP

    • Marked as answer by TomvBr Wednesday, November 13, 2019 10:46 AM
    Tuesday, November 12, 2019 2:04 PM
    Moderator

All replies

  • HI
    1 if you publish notepad remoteapp on RDweb ,will the same issue happen for notepad remoteapp on win10 client?
    2 is this issue a random issue ?the issue will auto disappear after a while.
    3 can you enter winver in command prompt on problematical win10 computer and look the os version and os version number ?[for example windows 10  enterprise 1809 (os build 17763.316)]
      is your issue computer win10 1903 enterprise version or win10 1903 pro version or win10 1903 LTSC version?
    4 I think there may be domain policy ,third party software ,win10 OS,update patch cause your issue .you clean install one new win10(1903) vm by using below download link and snapshot for each step in step 2. then try to narrow down the current issut to one side.
    https://www.microsoft.com/en-us/software-download/windows10
    4.1 on win10 OS side:
    don't install any software and don't add it to AD domain and don't install any update patch,check if there is the same problem  ?
    4.2 on domain policy side:
    if there is no problem in step 2.1  ,we can add it to AD domain ,then check if there is the same problem ?
    4.3 on windows update side:
    if there is no problem in step2.2 and 2.1 ,we can go to install all update patches ,then look if your issue is caused by windows update.
    4.4 on third-party software side:
    if there is no problem in step2.1 to step 2.3 ,we can try to install all third-party software the same as problematical win10 ,then look if third-party software caused your issue.


    Best Regards
    Andy YOU
    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.

    Monday, October 28, 2019 9:44 AM
    Moderator
  • Hello,

    1 if you publish notepad remoteapp on RDweb ,will the same issue happen for notepad remoteapp on win10 client?
    Yes

    2 is this issue a random issue ?the issue will auto disappear after a while.
    Not Random, always after closing the application. mstsc.exe does not disappear.
    3 can you enter winver in command prompt on problematical win10 computer and look the os version and os version number ?[for example windows 10  enterprise 1809 (os build 17763.316)]
      is your issue computer win10 1903 enterprise version or win10 1903 pro version or win10 1903 LTSC version?
    1903 Pro Version (18362)

    4 I think there may be domain policy ,third party software ,win10 OS,update patch cause your issue .you clean install one new win10(1903) vm by using below download link and snapshot for each step in step 2. then try to narrow down the current issut to one side.
    https://www.microsoft.com/en-us/software-download/windows10
    Why? The installation is clean.
    4.1 on win10 OS side:
    don't install any software and don't add it to AD domain and don't install any update patch,check if there is the same problem  ?
    Yes, Same problem (also on Server 2019 LTSC as client)
    4.2 on domain policy side:
    if there is no problem in step 2.1  ,we can add it to AD domain ,then check if there is the same problem ?
    Yes, Same problem (also on Server 2019 LTSC as client)
    4.3 on windows update side:
    if there is no problem in step2.2 and 2.1 ,we can go to install all update patches ,then look if your issue is caused by windows update.
    Windows is up-to-date
    4.4 on third-party software side:
    if there is no problem in step2.1 to step 2.3 ,we can try to install all third-party software the same as problematical win10 ,then look if third-party software caused your issue.
    There is no third-party software, tested with notepad and Wordpad.
    Monday, October 28, 2019 12:18 PM
  • HI
    5“Why? The installation is clean.”
     because i am not sure if we have changed the setting of OS image and did sysprep then deploy this win10 image to all computers.
    6 what's your RDS deployment ? are RDCB,RDWEB,RDgateway,RDSH role installed on the same server ?
    7 if you open the same rdweb site in IE on RDSH server and use the same user account to open the remoteapp, will mstsc.exe still not be kill automatically?
    8 if you remote access w2019 session host server directly by using mstsc and open the same applicaiton,will the same problem happen?
    9 when the problem happen ,if you right click the mstsc.exe then "create a dump file" like picture , can we find new thread in dump file opened by WinDBG ?
    I suspect the memory for mstsc.exe process not release for some reason.
    Debugging Tools for Windows 10 (WinDbg)
    https://docs.microsoft.com/en-us/windows-hardware/drivers/debugger/debugger-download-tools

    Best Regards
    Andy YOU
    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.


    Thursday, October 31, 2019 6:21 AM
    Moderator
  • HI
    Is there any progress on your question?

    Best Regards
    Andy YOU
    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.

    Monday, November 4, 2019 6:35 AM
    Moderator
  • Hello Andy,

    5“Why? The installation is clean.”
     because i am not sure if we have changed the setting of OS image and did sysprep then deploy this win10 image to all computers.

    Ok, i have tested different installations.

    6 what's your RDS deployment ? are RDCB,RDWEB,RDgateway,RDSH role installed on the same server ?

    3 VM's:
    1. RDWeb + Gateway Server in DMZ
    2. RDS Broker Server
    3. RDSH Server

    7 if you open the same rdweb site in IE on RDSH server and use the same user account to open the remoteapp, will mstsc.exe still not be kill automatically?

    No, it is still running and freezing when pressing disconnect all connections
    8 if you remote access w2019 session host server directly by using mstsc and open the same applicaiton,will the same problem happen?
    No, not directly. Because the problem is related to wksprt.exe and remoteapps.
    9 when the problem happen ,if you right click the mstsc.exe then "create a dump file" like picture , can we find new thread in dump file opened by WinDBG ?
    I suspect the memory for mstsc.exe process not release for some reason.
    Debugging Tools for Windows 10 (WinDbg)
    https://docs.microsoft.com/en-us/windows-hardware/drivers/debugger/debugger-download-tools

    Nothing special (As far I can see)
    1. When I press Disconnect all connections, the remoteapps are frozen and not disconnecting.
    2. When I close all apps and wait a few minutes. mstsc.exe is not closing and running on the background. The session is in this case disconnected on the broker.

     



    • Edited by TomvBr Tuesday, November 5, 2019 10:56 AM
    Tuesday, November 5, 2019 10:54 AM
  • Download Windows Server LTSC 2019.
    Create 3 clean 2019 LTSC VM's on Windows Server 2019 Hyper-V.
    1. RDWeb + Gateway
    2. RDS Broker
    3. RDSH Server

    Install Windows 10 or Windows Server 2019 in a new VM and Boom, same issue.
    All connections are frozen after pressing disconnect all connections (instead of closing).
    Open the RemoteApp and close it. MSTSC.exe is still running on the background, instead of closing.

    Notepad or Wordpad.

    Tuesday, November 12, 2019 11:01 AM
  • Hi,

    I did quick test with Server 2019 Standard Build 17763.805 running all RDS roles and client PC with Windows 10 Pro 1903 Build 18362.449.  Used IE to open RDWeb, selected Private option, logged on, launched RemoteApp, right-click on RADC icon --> Disconnect all connections, launched RemoteApp again, repeated many times.  Had no issues, and mstsc.exe process terminated automatically several seconds after disconnect.

    I tested with connection going through RD Gateway as well as direct.

    Have you tested with TCP only to see if it changes anything?  You can select this via Select RDP transport protocols group policy setting on your RDSH server and then test.

    If you right-click on the hung mstsc.exe process and choose Analyze wait chain, are there any clues?

    -TP

    • Marked as answer by TomvBr Wednesday, November 13, 2019 10:46 AM
    Tuesday, November 12, 2019 2:04 PM
    Moderator
  • With TCP only it works fine! I will check the firewall configuration etc. for udp traffic. Thank you.

    • Edited by TomvBr Wednesday, November 13, 2019 10:51 AM
    Wednesday, November 13, 2019 10:50 AM