I have deployed a test VDI setup on 2012 R2 remote desktop services, and when I attempt to shadow a session on one of our Windows 10 virtual desktops, I get a message that says; 'The computer name.
Alright folks, it’s time for a post on the fun, twisted history of shadowing RDP users in Microsoft Remote Desktop Services. Not a month goes by that I don’t field a call from an administrator confused about the shadowing changes across various Windows Server implementations. And, I’ll cover some of the basics in Remote Desktop Commander that make these RDP shadowing variations as seamless as possible among the different Microsoft OS versions.
First Rule of Shadow Club: You CANNOT Shadow RDP Users on Windows Server 2012, ONLY Windows Server 2012 R2
- Client - Windows 10; Server - Server 2012 R2; Server - Server 2016; Account - Administrator; Example 1: Works perfectly fine. Mstsc /v:x.x.x.x /shadow:1 /prompt /control. Example 2: Gives the 'This computer name is invalid' anytime port is specified including 3389. Mstsc /v:x.x.x.x:3389 /shadow:1 /prompt /control. Thanks for any advice you can.
- Running MSTSC from command line will allow you to remotely view (shadow) and control a computer. This will work from Command Prompt or Powershell. Shadowing was dropped in Windows 7 and brought back in Windows 8.1.
This keeps biting RDS admins in the butt. There is ZERO support for shadowing in Windows Server 2012. I’ve written at length about many of the radical changes between RDS on Windows Server 2008 and Windows Server 2012. Microsoft literally roto-rootered the whole RDS stack in Windows Server 2012, tearing out old plumbing and integrating new plumbing related to RemoteFX and RDP enhancements. It took them until the Windows Server 2012 R2 release to put Humpty Dumpty mostly back together again. So unless you REALLY like pain, don’t upgrade to Windows Server 2012 – bypass it and upgrade to Windows Server 2012 R2 or Windows 2016.
Review: Legacy Shadow Techniques for RDP Users on Windows Server 2003 and Windows Server 2008
Shadow Session Windows 10
Yes, I included Windows Server 2003 because I know some of you deviants still have some Windows 2003 systems running in your enterprise, long after extended support and updates have expired. That’s fine you slackers – blame legacy apps and management. 🙂
Uli laptops & desktops driver download for windows. Tron driver download for windows. Back in the good ole days of simpler operating systems, to shadow you would either:
1.) Fire up a copy of TSAdmin (Remote Desktop Services Manager), highlight the user session in question, then right mouse click to shadow them, OR:
2.) Command line it with the shadow command, passing it the user’s session ID and the server their session was located on.
Both of these approaches required you to run the app or the command from within a Remote Desktop session; you could not issue these commands directly from the console session of a server or workstation.
New Shadow Techniques for RDP Users in Windows Server 2012 R2 (and Windows 8.1 and Windows 10)
Alright, let’s engage in some fantasy now shall we? Let’s say that all of your servers are Windows 2012 R2, and all of your workstations are Windows 8.1 or Windows 10. Ha ha! See how funny I can be? In this case, you can use the new command line arguments built into the Remote Desktop Connection Client (mstsc.exe) to get the party started.
NOTE 1: Unlike Windows Server 2008, Windows Server 2003, and Windows 7, you DO NOT already have to be running in a remote desktop session to start shadowing another user session. You can be logged into the console session of your own desktop, laptop, etc and jump right into shadowing a remote user’s session, IF:
1.) Your Windows system is running Windows 8.1, Windows 10, Windows Server 2012 or later.
2.) Their Windows system is running Windows 8.1, Windows 10, Windows Server 2012 or later.
If either one of the systems is at a lower OS level, this new approach won’t work.
NOTE 2: In Windows Server 2012 R2, by default you need to be a local administrator on the machine hosting the sessions you wish to shadow. This is a major shift from Windows Server 2008 and earlier operating systems. There is a way around this however with a gnarly command you can run inside Powershell.
Again, provided you live in this magical world of fairy tales, unicorns, and homogeneous operating systems, you simply launch mstsc.exe with the appropriate combination of command line switches, such as:
1.) Switch /v, which is the remote computer with the session you want to shadow (e.g. /v:MY2012SERVER)
2.) Switch /shadow, which accepts the session id of the user session that will be shadowed (e.g. /shadow:1)
3.) Switches /control and /noConsentPrompt, which determine whether you can control or only view the session, and whether or not the user is notified that you are shadowing their activity, respectively.
Putting it together: mstsc /v:TARGETSERVER /shadow:1 /noConsentPrompt lets you monitor (but not control) session 1 on TARGETSERVER without notifying the user.
The RDP Shadow Reality: You Run a Heterogeneous Network Full of Systems That Are At Different OS Levels.
I gave a talk on RDP 8 at TechMentor once, and asked for a show of hands to find out who had deployed Windows Server 2012 in their environment. The vast majority of attendees were still running Windows Server 2008, and those who had started deploying Windows Server 2012 still had a lot of Server 2008 systems in place. It was clear that there would be two different approaches to shadowing RDP users for quite a while.
Given this challenge, we built a bit of magic quite some time ago into Remote Desktop Commander when it comes to shadowing users. We automatically detect whether or not you want to shadow a user on the local system or a remote system, and we also look at the OS level of both the local machine and the remote machine. If both systems are running Windows 8.1, 2012 R2, Windows 10 or later, we shell out immediately to MSTSC with the new options. If there is an OS level mismatch, we’ll first establish a client RDP session on the remote system, and then auto launch a helper utility on the remote system that will invoke the appropriate shadowing technique to start shadowing the desired session.
In addition, as you can see in the above screenshot, we give you even more options before starting the RDP user shadow attempt. For instance, you can temporarily override the GPO that controls whether or not users are notified that their session will be shadowed. You can also start your client session in Admin mode, so that the connection broker doesn’t block you from connecting to the desired server in the collection.
The Best Part Of This Twisted History?
These shadowing features come in versions of Remote Desktop Commander. So, luckily, this history doesn’t have too messy an ending.
Find out more about later developments in user session shadowing with Remote Desktop Commander or find out what fits your needs best – you can request a web demo from our team.
Updated: November 2020. Strongrising modems driver download for windows 10.
@ECHOOFF |
MODE CON:COLS=80 LINES=40 |
COLOR 1A |
SETLOCALEnableDelayedExpansion |
:ENTRY |
CLS |
CALL :PRINTBAR |
ECHO^| RDP Session Shadow Version 2.0 ^| |
ECHO^| By Craig Crawford ^| |
ECHO^|------------------------------------------------------------------------------^| |
ECHO^| This is designed to be used with: ^| |
ECHO^| * Windows 10 / 2016 and above, ^| |
ECHO^| * RDP Wrapper Library: https://github.com/stascorp/rdpwrap ^| |
CALL :PRINTBAR |
IF [%1][--noping] ( |
ECHO^| --noping switch enabled. The remote host will not be probed by echo requests ^| |
ECHO^| before attemping to connect. ^| |
CALL :PRINTBAR |
SETNOPING=TRUE |
) |
SET /P PC='Enter PC: ' |
CALL :PRINTBAR |
SETCOUNT=0 |
ECHO Attempting to connect to %PC%.. |
IF [%NOPING%][TRUE] GOTO NOPING |
PING%PC% -n 1 -w 100|FIND'Ping request could not find host %PC%'>NUL |
IF'%ERRORLEVEL%'EQU'0'GOTO FAILED_NOHOST |
:PING |
SET /A COUNT+=1 |
IF'%COUNT%'GEQ'5'GOTO FAILED_NOECHO |
ECHO Attempting to connect to %PC%. Attempt %COUNT% of 5. |
PING%PC% -n 1 -w 100>NUL |
IF'%ERRORLEVEL%'EQU'0' ( |
ECHO Connected. |
:NOPING |
CALL :PRINTBAR |
ECHO Attempting to display user sessions.. |
ECHO. |
QWINSTA /SERVER:%PC% |
ECHO. |
SET /P SESSIONID='Enter Session ID: ' |
MSTSC /v:%PC% /control /shadow:!SESSIONID! |
GOTO END |
) ELSE ( |
ECHO%PC% failed to respond, trying again in 5 seconds.. |
TIMEOUT /T 5 /NOBREAK >NUL |
GOTOPING |
) |
:FAILED_NOECHO |
CALL :PRINTBAR |
ECHO Failed to connect to the remote computer: [ %PC% ]. |
ECHO The remote computer is not responding to ping requests. |
GOTO END |
:FAILED_NOHOST |
CALL :PRINTBAR |
ECHO Failed to connect to the remote computer: [ %PC% ]. |
ECHO Unable to find the host's DNS entry. Does it exist? |
GOTO END |
:END |
CALL :PRINTBAR |
PAUSE |
GOTO ENTRY |
:PRINTBAR |
ECHO |