How to Configure a Remote Access VPN Connection
A remote access VPN creates an encrypted tunnel between the server and the user's device over the Internet.
In this guide, you enable the VPN on the network, add the users, and configure the connection on a Windows device.
👍 What you get
A working L2TP/IPsec VPN with its users, and a Windows client configured to connect securely without losing Internet access.
📘 NAT limit: one connection at a time
Behind NAT, L2TP only supports one simultaneous connection per port it uses: a second user trying to connect through that same port will be rejected.
If you need multiple connections from the same private network, set up WireGuard instead.
Before you begin
Log in to the Plenit platform with an active organization.
Have a subscription of Servers or Remote Desktop to enable the VPN on the network.
Have access to the Windows device you will connect from.
Step 1. Enable the VPN on the network
Enter the subscription of Servers from its card.
In the sidebar, open VPN and go to the subsection Remote Access.
Select the network you are going to use and change its status from OFF to ON.
With the network enabled, locate the two details you will need on the client:
Pre-Shared Key: the shared key. You can see it with the eye icon in the column Pre-Shared Key.
public IP: the address the VPN connection is established against.
{/* 📸 SCREENSHOT 1 · Remote Access subsection with the network ON, the Pre-Shared Key, and the public IP */}

Step 2. Create the remote access users
Click New User, enter the username and password with confirmation, and click Accept. The user is enabled for the L2TP over IPsec. Repeat for each person who will connect.
{/* 📸 SCREENSHOT 2 · creation of a remote access user */}

📘 Two levels of authentication
The Pre-Shared Key authenticates the network (it is common to the connection); the username and password authenticate each person. You need both on the client.
Step 3. Configure the VPN on the Windows device
In Settings → Network & Internet → VPN, click Add a VPN connection and fill out the form:
VPN provider
Windows (built-in)
Connection name
An identifying name
Server name or address
The public IP from Step 1
VPN type
L2TP/IPsec with pre-shared key
Pre-shared key
The Pre-Shared Key from Step 1
Username
The user from Step 2 (for example user1)
Password
That user's password
Click Save.
Adjust routing so you do not lose Internet access
In L2TP, Windows sends by default all traffic through the VPN, so the device may end up without Internet.
To avoid this, open Control Panel → Network and Internet → Network and Sharing Center → Change adapter settings. On the VPN, right-click → Properties.
In Networking, choose your stack (IPv4 or IPv6), click Properties → Advanced options and disable Use default gateway on remote network. Accept.
Adjust security
In Properties → Security, set Data encryption to Require encryption (disconnect if server does not accept), keep enabled Microsoft CHAP Version 2 and accept.
{/* 📸 SCREENSHOT 3 · default gateway option disabled and security parameters */}

PowerShell alternative
If you're going to configure multiple devices, you can skip the entire GUI by creating the connection and split tunneling all at once. From PowerShell as administrator:
Validate the connection
Connect to the VPN from the network settings. If it connects, the device securely accesses the server's services. To check it from the terminal:
If something doesn't fit
The device loses Internet when connecting
The default gateway is still active
Disable it (or use Set-VpnConnection -SplitTunneling $true)
A second user does not connect after NAT
L2TP supports one connection per port
Use WireGuard for multiple users
Authentication fails
Incorrect user, password, or Pre-Shared Key
Check the credentials from Step 2 and the PSK from Step 1
Conclusion
With this, your users connect to the server through an encrypted tunnel from their Windows device. Two details make the difference between it working or causing trouble: disabling the default gateway so you do not lose Internet access, and remembering that L2TP behind NAT is one user per port. If that limit is too tight, WireGuard is the way to go for multiple connections at once.
Last updated
Was this helpful?

