Terminal Services  «Prev  Next»

Lesson 3 Connect to Virtual Private Network
Objective Create a connection to a VPN.

Connect to a Virtual Private Network using Remote Desktop Services in Windows Server 2022

It is possible to connect to a VPN using Terminal Services (now known as Remote Desktop Services) in Windows Server 2022. There are a couple of ways to achieve this:
  1. Connect the Server to the VPN:
    • Install VPN Client: First, install the necessary VPN client software on the Windows Server 2022 machine.
    • Establish Connection: Configure the VPN client and establish a connection to your VPN provider.
    • Remote Desktop: Once the VPN connection is active, users can connect to the server using Remote Desktop. The traffic will be routed through the VPN tunnel.
  2. Use Remote Desktop Gateway (RD Gateway):
    • Install RD Gateway Role: Configure and install the Remote Desktop Gateway role on your Windows Server 2022.
    • VPN Connection on Client: Users connect to the VPN from their local device.
    • Connect via RD Gateway: Users then connect to the RD Gateway using Remote Desktop. The RD Gateway securely relays the Remote Desktop session through the VPN tunnel.
Important Considerations:
  • VPN Client Compatibility: Ensure the VPN client you choose is compatible with Windows Server 2022 and Remote Desktop Services.
  • Security: Always prioritize security when setting up VPN connections and Remote Desktop access. Use strong passwords, enable encryption, and consider additional security measures like two-factor authentication.


Just about any business that has more than a single location will want to network the computers at each location with each other. Traditionally, this has been accomplished by using dedicated leased lines, such as Frame Relay. While dedicated leased lines are reliable and secure, they are also very expensive. You can save your company a significant amount of money by creating a Virtual Private Network (VPN) to replace the expensive dedicated connections you maintain. A VPN provides a secure connection between computers or networks over a shared public network infrastructure such as the Internet. For the cost of either a dial-up or dedicated connection to the Internet via an ISP, you can save thousands of dollars over the course of a year by using a VPN instead of dedicated leased lines. You can use the Network Connection wizard to create a connection to a VPN. Note that you can create a tunnel between two networks using just PPTP or L2TP, but the tunnel is not secure, and therefore the network would be virtual but not private. But using protocols to encrypt the data inside the tunnel, you add the "private" to the virtual network, thus creating a Virtual Private Network (VPN). The procedure used to create a secure tunnel over a public network infrastructure such as the Internet is shown below.
VPN concepts
VPN Concepts

Create a VPN connection

To create a new VPN connection, perform the following steps:
  1. Open the Network Connection wizard.
  2. Click Connect to a private network through the Internet, click Next, and then do one of the following:
  1. If you want to establish a connection with your ISP or some other network before connecting to the VPN, click Automatically dial this initial connection, click a connection on the list, and then click Next.

Automatically dial this connection
Automatically dial this connection

  1. If you do not want to automatically establish an initial connection, click Do not dial the initial connection, and then click Next.
Do not automatically connect
Do not automatically connect
  1. Type the host name or IP address of the computer or network to which you are connecting, and then click Next.
Host name or IP address
Host name or IP address
  1. If you want this connection to be made available to all users of this computer, click For all users, and then click Next. If you want to reserve the connection for yourself, click Only for myself, and then click Next.
  2. If you selected Only for myself in the previous step, proceed to the next step. If you selected For all users, and you want to enable other computers to gain access to resources through this dial-up connection, select the Enable shared access for this connection check box, and then click Next.
  3. Type a name for the connection, and then click Finish.

In order to be presented with the option to dial an initial connection, you must create a dial-up connection that will connect to the destination before setting up the VPN connection. Note that creating the VPN connection actually involves two connections. The initial connection is to a network access server, such as your ISP, which provides access to the network known as the Internet. You establish the second connection to the VPN server after the link has been established. It is the IP address or host name that is "dialed" when creating the VPN connection. The next lesson explores how to create a direct cable connection.
[1] Virtual Private Network: A VPN is a network that is created by using tunneling protocols, such as PPTP/MPPE or L2TP/IPSec.

SEMrush Software 3 SEMrush Banner 3