Remote Desktop Hacks

I’m a heavy user of RDP (Remote Desktop, a.k.a. Terminal Services). I don’t remember how I ever got any work done before this technology existed. What follows are some miscellaneous tips.

To login to the console session on a Windows 2003 machine, start the Remote Desktop application from the command line with /console. You can also shadow a console session, so a person physically at the machine can interact with the session, too. See: How to Connect to and Shadow the Console Session with Windows Server 2003 Terminal Services. There is also an interesting but Rube Goldbergian trick I’ve never tried: How To Shadow a Remote Desktop Session in Windows XP Professional.

If you save connection settings in an .rdp file, you can add “connect to console:i:1” to make the console session preference permanent. This page extensively documents other .rdp file parameters.

When RDP misbehaves, qwinsta and rwinsta are available for remote management of sessions. Scott Forsyth has a nice write-up on how to use these tools: Managing Terminal Services Sessions Remotely.

When I connect to a Windows XP machine using RDP, the system replaces the “Turn Off Computer” button in the start menu with “Disconnect”. If I want to remotely power down the machine or reboot, I turn to the command line utility TSSHUTDN.

To connect to a Windows machine from a *nix machine I’ve used rdesktop successfully.

When paranoid, I change the default listening port for RDP on some of my machines.

Finally, some shortcut keys I commonly use:

ALT + PAGE UP replaces ALT+TAB to “tab” through running applications in the RDP window.
CTRL + ALT + + (numeric keypad plus) takes a screen print of the remote desktop (just like using PrintScrn on a local computer).
CTRL + ALT + - (numeric keypad minus) takes a screen print of the active window inside the RDP window (just like using ALT+PrintScrn on the desktop).

Any tips you want to share?

Print | posted @ Wednesday, April 19, 2006 4:42 AM

Comments on this entry:

Gravatar # re: Remote Desktop Hacks
by Phil Weber at 4/19/2006 5:50 AM

You may also turn off or reboot a remote XP machine by right-clicking on the taskbar and launching Task Manager, then using TaskMan's Shut Down menu.
  
Gravatar # re: Remote Desktop Hacks
by Jeff Atwood at 4/19/2006 6:33 AM

Very nice! I didn't know any of these shortcut keys.

However, I use task manager to shut down remote machines-- you'll notice it has the shutdown option in a RDP session.
  
Gravatar # re: Remote Desktop Hacks
by _cyclops_ at 4/19/2006 7:17 AM

With rdesktop there is a configuration tool called 'grdesktop'.. it looks like the configuration window in Windows.

Rdesktop can be found at http://sourceforge.net/projects/rdesktop/ (link in the article is invalid)
and grdesktop at http://www.nongnu.org/grdesktop/
  
Gravatar # re: Remote Desktop Hacks
by Lars Wilhelmsen at 4/19/2006 10:46 AM

There's no need to run a command-line application to shut down/restart the application - the "Turn off Computer" item is accessibly by using the added "Windows Security" menu item under Start -> Settings...

Regards,

Lars Wilhelmsen
  
Gravatar # re: Remote Desktop Hacks
by Foreman_Bob at 4/19/2006 11:29 AM

CTRL + ALT + END will show your task manager.
  
Gravatar # re: Remote Desktop Hacks
by Andrew Robinson at 4/19/2006 11:40 AM

CTL + ALT + END to bring up the windows security screen, get to the task manager or change your password.
  
Gravatar # re: Remote Desktop Hacks
by Joseph Sak at 4/19/2006 1:25 PM

for rebooting/shutting down, you can alternatively use the run command on the remote machine:

shutdown -r -t 00 (reboot in 0 seconds)

shutdown -s -t 00 (shutdown in 0 seconds)

  
Gravatar # re: Remote Desktop Hacks
by Eric at 4/19/2006 1:33 PM

You don't need a command line utility to shut down Windows XP.

Start->Windows Security will bring up the familiar Ctrl-Alt-Del menu, which allows you to log off, shut down/reboot, etc. (Though I'm not 100% sure this works if Fast User Switching is enabled.)
  
Gravatar # re: Remote Desktop Hacks
by David M. Kean at 4/19/2006 1:51 PM

You can actually shutdown the computer from using the Windows Security button it puts on the Start menu.
  
Gravatar # re: Remote Desktop Hacks
by scott at 4/19/2006 2:21 PM

Thanks for the tips, guys. Obviously, I've been doing some things the hard way.

_cyclops_: thanks for finding that broken link. Late night posts always kill me.
  
Gravatar # re: Remote Desktop Hacks
by Joel at 4/19/2006 2:41 PM

I like to use Ctrl+Alt+Pause to toggle between fullscreen and windowed mode. That way I don't have to remember additional shortcut's for things like bring up the windows menu your capturing a screen since the fullscren mode captures those.
  
Gravatar # re: Remote Desktop Hacks
by Michael Kizer at 4/19/2006 8:23 PM

There is a complete list of keyboard shortcuts for Terminal Services/Remote Desktop available here: support.microsoft.com/default.aspx

I use Alt+Home then R quite a bit to pop up the Run dialog.
  
Gravatar # re: Remote Desktop Hacks
by Joshua Flanagan at 4/19/2006 8:33 PM

The common shortcut keys are always a few mouse clicks away. Good to keep in mind when you don't have them all memorized.

Just change to windowed mode, click on the system menu (top left), The bottom option is "Help" - Select "Remote Desktop Connection Help".
Expand "Concepts" and click on "Using Terminal Services shortcut keys".
  
Gravatar # re: Remote Desktop Hacks
by Chris D at 4/19/2006 10:16 PM

If you download the server 2003 admin pack (free), you can create an MMC snapin for remote desktops. In a multi server environment it is invaluable. Basically looks like windows explorer, your list or remote desktops on the left, and you can just toggle between them.

Also it is configurable per connection whether you want to use a console connection or not.

www.microsoft.com/.../details.aspx
  
Gravatar # re: Remote Desktop Hacks
by Scott.Other at 4/19/2006 10:35 PM

Drop to a command prompt (Start-Run- type “cmd” and hit enter) then type “shutdown -r -f.

-r restarts the computer
-f forces the issue. Otherwise the RDC client locks the workstation.

There are some other options too. Type “shutdown /?” to see them all.

I posted about this command a while back when I found out I didn't know how to send a ctrl-alt-del from the OS X RDC client. I believe it still works.
  
Gravatar # re: Remote Desktop Hacks
by Dan Miser at 4/21/2006 6:11 PM

Here is another link-based RD entry that shows how to get RD working over SSH:

distribucon.com/blog/archive/2006/01/03/858.aspx
  
Gravatar # re: Remote Desktop Hacks
by Mike at 4/23/2006 4:04 PM

While using RD, sometimes, there is an interval between the instance I type and the letters appearing on the remote screen..about 2 - 3 seconds..sometimes even more as if the remote machine has hung.
My remote machine has 1GB ram and it is 2+ Ghz P4, my machine at home is 512mb,P4 and I am on broadband through a wireless router - so I am not sure why this happens, my co-workers are not having this issue.
Any idea why this happens? is it my machine at home? or could it be that my internet gets disconnected at regular intervals?
  
Gravatar # re: Remote Desktop Hacks
by TristanK at 4/25/2006 11:52 PM

Mike - most often, it's the round-trip latency.

This can be caused by:
- congested Internet links between A and B
- busy server computer (eg, 100% CPU for extended periods)
- MTU stuff
- other stuff

If possible, try using PING at the same time to work out where the problem might be, or get a Netmon/Ethereal capture and look for any delays relating to RDP - TCP port 3389.

For a character to appear on the screen through RDP:
- You type the letter
- the RDP client at the local box sends the letter to the RDP server
- the RDP server does whatever it needs to do to update the screen in the application you're using
- the RDP server sends the changed pixels back to the client
- the client receives the changed pixels and updates the display

I'm something of a Wireless Luddite, so I think it's most likely someone's using your home microwave at the time you have the problem - eliminate that first. If you can't live without a microwave, try cabling the PC to the broadband connection temporarily, see if it gets any better.

I've seen RDP get into a state where it wouldn't update unless something else changed (eg, type a word and nothing, but click elsewhere and whop! the word appeared) - one such cause was fixed in XPSP2.
  
Gravatar # re: Remote Desktop Hacks
by kvbik at 4/28/2006 8:52 AM

Is there anybody who knows how to let remote desktop in xp listen only on specific ip address? In server2003 you can do it via tscc.msc, but there is none in xp.
  
Gravatar # re: Remote Desktop Hacks
by Sahil Malik at 4/28/2006 2:33 PM

Few more -codebetter.com/.../39831.aspx
  
Gravatar # re: Remote Desktop Hacks
by Adrian Johnson at 6/3/2006 12:34 PM

I need to reboot my remote desktop machine from the command line on my own machine. How do I do that?
  
Gravatar # re: Remote Desktop Hacks
by Seth Lester Leary III at 6/14/2006 4:09 PM

All of these alternate shutdown methods are handy, but might be hard to remember when it comes time to use them.

Did you also know you can get the shutdown/restart options by simply deselecting all windows (click a blank space on the taskbar or desktop) and pressing Alt-F4?
  
Gravatar # re: Remote Desktop Hacks
by James at 8/4/2006 3:32 PM

I want to remote desktop someones compter at skool so how do i do this whithout them knowing????plz help would be fun!
  
Gravatar # re: Remote Desktop Hacks HELP
by LuAnn at 8/17/2006 8:06 PM

I was using RDP from a XP Pro to my work XP Pro computer. Explorer appended with a request to send the information to Microsoft which I declined. The work XP Pro computer killed explorer, the start bar, all icons; basically got the classic blue screen. Is there a way to get to command line or anything to force a reboot?
  
Gravatar # re: Remote Desktop Hacks
by scott at 8/18/2006 4:21 PM

LuAnn:

If the only port on the work machine you can get to is the RDP port, then I don't think there is anything you can do remotely. You can try the ts shut down utility described here to try and reach the machine to force a reboot.
  
Gravatar # re: Remote Desktop Hacks
by Rob at 9/26/2006 12:30 PM

We have noted that RDP performs slower than expected when we are view a 400K PDF - It's more of the scrolling (page down) that is the problem. It's over a slow link and it appears that the network trace is showing that the client side session is looking for a ACK after every 4 packets - it seems that the third packet has the "pish bit" enabled. This is causing a 100ms - 200ms delay after each packet exchange. Some thoughts are - (1) can this be tweaked, can RDP use UDP instead of TCP. Has anyone else had simular issues?

Thanks
  
Gravatar # re: Remote Desktop Hacks
by Mark Anderson at 10/2/2006 11:35 AM

Thanks for all the tips these are great.

Two questions

1) is it possible to make the remote desktop session viewable to the user of the host computer like laplink. Ie when one of my employees connects to my computer can I keep an eye on the session?

2) If it is not possible to make a viewable session is there any way that the person that connects to my computer can disconnect so that I know that they are off my computer currently Windows says that it is locked and that the other person is using my computer even though they are off.
  
Gravatar # re: Remote Desktop Hacks
by david at 10/4/2006 7:21 PM

When using the Remote Desktops MMC snap-in does anyone know the keyboard shortcuts to switch between consoles or between the active console and the Console Root tree view?
  
Gravatar # re: Remote Desktop Hacks
by Lew at 12/18/2006 4:28 AM

Hmmmm, i seem to hav locked miself out of mi RDP and forgot mi pass :/ any1 know how to retrieve if it possible?!
Cheers
  
Gravatar # re: Remote Desktop Hacks
by GR8 at 1/19/2007 6:52 AM

i'm using rdt to manage several remote systems, always in full screen mode.
does anybody know an easy way (e.g. keyboard shortcut) to switch between the different sessions quickly?

thnx.
  

Your comment:

Title:
Name:
Email:
Website:
 
Italic Underline Blockquote Hyperlink
 
 
Please add 8 and 5 and type the answer here: