| by TheIneptOne | No comments

Ubiquiti VPN on Ubuntu/Pop_OS!

Previously, I posted about adding Meraki VPN On Pop_OS! I also work a lot of Ubiquiti Unifi products and needed to setup a VPN. Here’s what I did to get that working:

Software Install

I covered this part before in the Meraki post, but I’ll go over it again here. We’ll need to install L2TP support first (if you are not running Gnome, only install network-manager-l2tp).

sudo apt-get install network-manager-l2tp network-manager-l2tp-gnome

Next, stop and disable the xl2tpd service. If its running, network-manager will not be able to spawn its own instance on UDP port 1701 and will instead create a higher random port.

sudo systemctl stop xl2tpd
sudo systemctl disable xl2tpd

VPN Setup

Open Network from the settings panel click the + to create a new VPN profile. You should now see a new option called Layer 2 Tunneling Protocol (L2TP). Select that and enter the following info:

  • Give the connection a name
  • Enter the IP/DNS of your firewall
  • Enter your username/password


Ubiquiti VPN On Linux

Ubiquiti VPN On Linux

Click on IPsec Settings and change the following:

  • Click Enable IPsec tunnel to L2TP host
  • Enter your Pre-shared Key (setup in Meraki)
  • Enter 3des-sha1-modp1024 for the Phase 1 Algorithms and 3des-sha1 for the Phase 2 Algorithms
  • Click on Enforce UDP Encapsulation
  • Click OK to save


Ubiquiti VPN On Linux

  • Click on PPP Settings and uncheck PAP, CHAP, MSCHAP, and EAP leaving only MSCHAPv2 checked.
  • Click to enable Use Point-to-Point Encryption (MPPE)
  • Click OK to save.


Ubiquiti VPN On Linux

Once done, click the Add button to save the new VPN profile.

You should now be able to connect and disconnect from Gnome Menu and the Network Settings panel.

Ubiquiti VPN On Linux


Leave a Reply