Remote Desktop fails after VPN connection

20,153

Solution 1

Are you using the same IP address for the VPN and the remote desktop? If not, are you using the default gateway on the remote network? If so, does the remote router support NAT loopback? If not, then your packets won't be routeable after you establish the VPN.

EDIT: Sorry, I misunderstood the question.

If your VPN is set up to use the default gateway on the remote network, then you will normally need to VPN to the remote network yourself and re-establish the remote desktop. But you can work around this by adding a static route back to you from the remote PC which should override the VPN default route.

For instance, if your public IP address is 1.2.3.4 and the remote desktop's default gateway is 5.6.7.8 then you would use

route add 1.2.3.4 gateway 5.6.7.8

Then when you connect the VPN the remote desktop still knows how to route packets back to you.

Solution 2

You really are not giving a lot of information. You should put things like networks (192.168.1.x, for example), and what VPN client you are using.

If you are using the Microsoft VPN client, I would try just unchecking the box: "Use default gateway on remote network" as in the image:

enter image description here

Share:
20,153

Related videos on Youtube

Samet S.
Author by

Samet S.

Updated on September 18, 2022

Comments

  • Samet S.
    Samet S. almost 2 years

    The local computer (comp 1) is connected to a remote computer (comp 2) with Remote Desktop. On the remote computer (comp 2), I try to establish an VPN connection to a different remote computer (comp 3). Once I try to establish the VPN connection from the remote computer (comp 2) to the second remote computer (comp 3), Remote Desktop freezes on comp 1. It is not possible to connect to comp 2 again via Remote Desktop.

    What can be done to connect to this remote computer (comp 2) after it establishes a VPN connection?

    The only thing that comes to my mind is to install a second NIC and configure Remote Desktop to accept connection from this NIC while VPN is working from the other...

    What do you suggest?

    EDIT:

    I want to use the internet connection of the VPN, so all traffic should go over the VPN but still RDP working.
    
    My IP: 100.0.0.1
    The IP where I'm connecting via RDP: 200.0.0.20 (Mask: 255.255.255.192, Gateway: 200.0.0.193)
    Where the 200.0.0.1 connects to VPN the IP of the VPN is: 65.254.61.250
    
    Will routing like this help (Command is issued in 200.0.0.20, the RDP location):
    route ADD 65.254.61.250 MASK 255.255.255.192 200.0.0.193
    
    Couldn't add gives the error: The route addition failed: The parameter is incorrect.
    I tried before connecting to VPN.
    
  • Samet S.
    Samet S. about 13 years
    what if i install some dynamic dns software and when vpn connects, get the new ip and try RDP to that ip? i'm trying free trial vpn from worldvpn.net/vpn-service/free-trial before purchase. i think it's not possible because it is a shared vpn ip and how it will route it back to my remote computer...
  • hicklypups
    hicklypups about 13 years
    @Samet Sorgut After our remote session, and understanding the problem, I re-wrote the beginning to better describe it. I think you were on the right track with the route add statement, but you need to know the remote network IP to add that. The routable address does not count.