Fixing Copy/Paste for Remote Desktop Sessions

January 18th, 2007

I use Remote Desktop all the time to work inside of my development systems hosted by Microsoft Virtual Server. I use the host system to browse the web for documentation and searches as I work and when I need to copy some text from the web browser I find many times the link between the host clipboard and the remote clipboard is broken. In the past I have read that somehow the remote clipboard utility, rdpclip.exe, gets locked and no longer allows the clipboard to be relayed between the host and the client environment. My only way to deal with it was to use the internet clipboard, cl1p.net. I would create my own space and use it to send content between environments. But that is a cumbersome step if you are doing it frequently.

The only way I really knew to fix the clipboard transfer was to close my session and restart it. That meant closing the tools I was using like Visual Studio, Management Studio and the other ancillary processes I have running as I work and then restarting all of it just to restore the clipboard. But today I found a good link on the Terminal Services Blog explaining that what is really happening. The clipboard viewer chain is somehow becoming unresponsive on the local or remote system and events on the clipboards are not being relayed between systems. It is not necessarily a lock being put in place but some sort of failed data transmission. It then goes on to explain the 2 steps you can take to restore the clipboard without restarting your session.

  • Use Task Manager to kill the rdpclip.exe process
  • Run rdpclip.exe to restart it

The clipboard communications should be restored. My clipboard is currently working because I just restarted my session to fix it, but I wanted to test these steps. I killed rdpclip.exe and started it and was able to copy/paste from the remote to the host system. The next time my clipboard dies I will have to check to see if these steps truly do work.

[Update: I just experienced the broken clipboard and the above steps fixed it right away.]

14 Responses to “Fixing Copy/Paste for Remote Desktop Sessions”

  1. Alan Says:

    Thanks! That was frustrating. Do you need to kill and restart the rdpclip in both remote and local?

  2. brennan Says:

    You just need to do it on the remote system. And then you have to copy the source text again to send the text to the remote clipboard after rdpclip was restarted.

    I have done this 10 times in the last hour!

    I really wish they would just fix this. I have found this issue dating back to Windows 2000.

  3. /dev/Brian » Blog Archive » My collection of tips and tricks Says:

    [...] I’m going to start collecting useful links I’ve found while trolling and collecting them in this post. So here’s my first one from Brennan: You can copy/paste between terminal services sessions, but sometimes it breaks and stops working. Th... [...]

  4. Brennan’s Blog » Blog Archive » Improvments for Vista with Virtualization Says:

    [...] into the instance via Remote Desktop which causes problems, such as the issues I have had with the clipboard. I have noticed some performance benefits of using Virtual PC over Virtual Server. I also became [...]

  5. Scooter133 Says:

    typically have 2-7 RDP sessions open at once for the several servers I
    administer.

    When copy and pasting between my local PC and the Session, or from session
    to session. The copy does not always get into the Local PC clipboard, and/or
    transferred to the RDP session Clipboard.

    If I use the keyboard it takes maybe 8+ times of hitting CTRL-C to get
    something in the clipboard. 3-4 times if I right click and select copy.

    My Local PC is running Vista Enterprise Ed (x86), the RDP Sessions are
    mostly Win2003 R2, though Some Win2003 SP2, Win2000

    Its really annoying to have to copy multiple times to get somthing on the
    Clipboard.

    I'll try killing the rdpclip and see if that helps. IF I'm only running the one RDP session it seems to be fine.

    Scott

  6. anonymous Says:

    worked like a charm! Had to bump off both remote and local rdclip..exe

  7. Brian Says:

    Thanks. This was a nice fix to a problem that was frustrating me. Makes perfect sense, but I never would have gotten there without your blog so, Thank you.

  8. Hong Says:

    Thanks a lot, Brennan!

    The tip works well.

    Hong

  9. Marcel Says:

    Voila! It works! Thanks for sharing this.

  10. Brennan’s Blog » Blog Archive » Reasons to Blog and Tips to do it Well Says:

    [...] popular blog entries have been for annoying problems, like the clipboard problem with Remote Desktop. Occasionally I get new comments on that entry from thankful readers. The pennies that I earn [...]

  11. Dan Murphy’s Blogs » Blog Archive » Fixing Copy/Paste for Remote Desktop in Windows Says:

    [...] to my other computer at work and without the copy paste function it is a huge hassle.  I found another blog that ran into the same issue to solve this [...]

  12. jupa Says:

    Hi, I am unable to copy paste documents from my desktop to the terminal server session or viceversa. I know I did it once in another computer but not sure why is not working in this one?

  13. Earl Says:

    I have tried many suggestions and none have helped until this. I am using XP Pro SP 2 on both computers.

  14. lijeb Says:

    I am using Ubuntu at home, and the open source tsclient to rdp into my xppro system at work.

    I am having a related issue where if rdpclip is running, local-to-local copy and paste are broken on the remote system. Killing rdpclip solves the issue, but it would be nice to have both working.