This article explains how you can connect to a PC over the internet using a VPN. I use this for work to allow me to connect to my work PC when I am away from the office, and it requires me to connect to our office VPN first. I won’t go into connecting to a VPN in this article, but may do up a VPN guide in the near future.
Once you are connected to your VPN, you will need to set up a way to connect to your machine. You have two options:
1) Remote Desktop – while this works just fine, I prefer the other option as I often only hibernate my machine, and if I log in via Remote Desktop, I’ll lose my current session.
2) VNC – this will connect to your current session, and whether you are logged in to your machine or not.
For both of these options, you need to know the local IP address of your machine. You should already have this information.
Remote Desktop Configuration
Under the Remote Desktop section, select the option to “Allow connections from computers running any version of Remote Desktop (less secure)”.
Close the alert if you got one, and then click OK.
I prefer to connect via VNC, simply because it will connect to your machine in it’s current state. So if you are logged in with several programs running, you will see these programs exactly how you left them.
The best program I have used for a VNC connection is Tight-VNC. Download the “Self-installing package for Windows”.
The installation is fairly self-explanatory, and most options can be left at their default settings. See screenshots below if you are unsure.
Set your passwords. The first one is for when you attempt to connect to your machine, it will ask you to authenticate. The second one is to access the control interface for VNC on the machine. The second password is optional, but probably a good idea.
Click install, and that’s it.
You will then see your login screen as if you were sitting in front of the machine. To send commands such as Ctrl-Alt-Del, there are some buttons at the top of the VNC Viewer window to send these commands to the remote machine.
Remote Turning on your PC
If your PC is switched off or hibernating, you need to power it up before you can connect to it. For this you will need to know the PCs MAC address to send it a Wake-On-Lan Packet (sometimes referred to as a Magic Packet) to wake up the machine.
You will need to download a tool to send the Magic Packet, and the easiest one I found is here. Download MC-WOL.EXE and save it somewhere on your machine (C:\ is an easy place to start). Open a command prompt at the location you saved MC-WOL.EXE, and run it giving the MAC address and IP address of your machine. Please note, you need to be connected to the VPN first before attempting this, else the command won’t get through. You need to pass the IP address so that you send the packet through the VPN.
e.g. MC-WOL MAC-address /a IP-address
I find the best way to check if the machine is awake is to ping the IP address. So once you’ve sent your WOL packet, enter ping IP-address /t (the /t will continue to send ping requests until you hit Ctrl-C). Once you start seeing replies, you can log in using your preferred option (from above).
Enjoy! As always, if you have any questions, please don’t hesitate to ask.